# David Hill

Electrical Engineering with minors in Computer Science, Mathematics, and Creative Writing.

Working as Undergraduate Research Assistant in the field of Computational Photonics

**Statistics**

RANK**47**

of 242,645

REPUTATION**3,170**

CONTRIBUTIONS

**0** Questions

**1,325** Answers

ANSWER ACCEPTANCE **
0.00%
**

VOTES RECEIVED**344**

RANK**3,474** of 16,974

REPUTATION**385**

AVERAGE RATING**4.80**

CONTRIBUTIONS**18** Files

DOWNLOADS **132**

ALL TIME DOWNLOADS**2773**

CONTRIBUTIONS**0 Posts**

CONTRIBUTIONS**0** Public Channels

AVERAGE RATING

CONTRIBUTIONS**0** Highlights

AVERAGE NO. OF LIKES

**Content Feed**

Solved

Multiply binary numbers

Write a function to multiply two binary numbers input as strings. For example, input values of ‘1011’ and ‘101’ should give ’110...

3 hours ago

Solved

Combination logic

Create an algorithm in MATLAB that calculate the combination for the given positive integers n and k as inputs. When k > n, the ...

1 day ago

Solved

Easy Sequences 10: Sum of Cumsums of Fibonacci Sequence

The function F(n) is defined as the set of Fibonacci numbers from the first up to the n-th. S(n) is the result of applying to F,...

2 days ago

Solved

Count the primes in Collatz sequences

Several Cody problems (21, 69, 42937, 44448, 44784, 52422) involve Collatz sequences. These start with a seed . If is odd, the ...

3 days ago

Solved

The perimeter of a circle

Calculate the perimeter of a circle E.g If input r(radius) = 2 , the output( the perimeter of a circle) = 12.5664.

3 days ago

Solved

Easy Sequences 17: Mu Variant Function

The mobius function is an important arithmetic function. It is often represented by the Greek letter mu (μ), and is sometimes ca...

3 days ago

Solved

Easy Sequences 16: Volume of Embedded Octahedron

An octahedron (not regular) is formed by joining the centers of the faces of a rectangular parallelepiped (see below figure). ...

4 days ago

Random number selection from matrix column and from decimal number

[A(randi(3,1,4)+[0 3 6 9]),rand(1,2)];

5 days ago | 0

How to store array?

x=0:.1:3; for k=1:length(x) A=[5*x(k),0;2*x(k)^2,1] B=[0;2.55] Y(:,k)=A\B; end

5 days ago | 1

Solved

Easy Sequences 15: Pythagorean Area with maximum Hypotenuse

A pythagorean triangle is defined as a right triangle with all three sides having integer lengths. Examples of pythogorean trian...

7 days ago

Create table of means from multiple tables

temp=T1.Properties.VariableNames; T=array2table((T1{:,:}+T2{:,:}+T3{:,:})/3); T.Properties.VariableNames=temp;

8 days ago | 0

Solved

List the Moran numbers

The quotient of a Moran number and its digit sum is prime. For example, 117 and 481 are Moran numbers because 117/(1+1+7) is 13 ...

8 days ago

Solved

Easy Sequences 14: Consecutive Composites

Generating a given number of consecutive numbers all of which are composites is easy. For example the following is a sequence of...

9 days ago

Solved

Easy Sequences 13: Average Speed of Spaceship

A certain alien spaceship is capable of traveling at extremely high velocities and is able to change speed instantaneously. The ...

9 days ago

Solved

List modest numbers up to n

After determining the nude numbers, or the numbers that openly display some of their divisors as their digits, one would think t...

9 days ago

Solved

Determine whether a number is unprimeable

The number 204 is unprimeable because no single digit can be changed to make it prime. In contrast, the number 207 is not unprim...

9 days ago

Solved

Determine whether a number is a fibodiv number

The number 14 is a fibodiv number because you can divide it into 1 and 4, use those numbers as the seeds for a Fibonacci sequenc...

9 days ago

Solved

Easy Sequences 12: 50th Prime

Write a function that outputs the 50th prime after a given number. For example, the 50th prime after 500 is 829. NOTE: If 'n' i...

20 days ago

Solved

Easy Sequences 7: Easy as Composite Pi

The prime Pi function is defined as the number of prime numbers from 1 to a certain given limit. In MATLAB, it is easy to create...

28 days ago

Printing out zeros as empty character for a tex file

s=sprintf([num2str(i) ' & ' num2str(myData(i,1), format)... ' & ' num2str(myData(i,2), format) ... ' & ' nu...

29 days ago | 0

| accepted

Solved

Shuffle

Shuffle a vector by breaking it up to segments of |n| elements, and rearranging them in a reversed order. For example, the ve...

29 days ago

Change error bar colour and data point colour in a loop

errorbar(x(i),y(i),err(i),'o', 'LineWidth', 2, 'MarkerFaceColor','g','Color','g');

29 days ago | 1

| accepted

How do I randomly extract 20 segments of data from a signal?

You could just keep matrix form with a 3rd dimension for k=1:20 newMatrix(:,:,k)=yourMatrix(randperm(60001,1000),:); end

29 days ago | 0

Solved

Cos Function

x is the abscissa. find the absolute value of cosine of -x and the same value with changed sign.

29 days ago

Plotting the function of single variable

n0 = 400; r0 = 1/n0; gamma = 1.26; p=20;%assumed s=.7;%assumed P=1:(p+1); r=r0*gamma.^(0:p); N=@(t)r0*n0*(2*s/(2*s-1))^(p...

29 days ago | 0

Solved

Retirement savings

At the start of what year will you have reached or exceeded a savings goal? Parameters (all are constant scalars given in a s...

29 days ago

Solved

Easy Sequences 2: Trigonometric function with integral input and output

The function 'F', defined as: , will always return an integer if the input is a natural number (in radian...

30 days ago

Solved

pick up 2 number!

create number A with 5 digits,number 1 is appear 2 times,other is 1 times. How many way to pick up n number randomly from 1 to ...

30 days ago