Community Profile

photo

David Hill


483 total contributions since 2017

Contact

David Hill's Badges

  • Knowledgeable Level 2
  • First Answer
  • Creator
  • Leader
  • Computational Geometry II Master
  • Card Games Master
  • Introduction to MATLAB Master
  • Community Group Solver
  • Sequences And Series I Master
  • Indexing I Master
  • Number Manipulation I Master
  • Magic Numbers II Master
  • Tiles Challenge Master
  • Project Euler I
  • Functions I Master

View all

Contributions in
View by

Answered
find magnitude of approximate percent relative error
a=(-1).^k.*(x.^(2*k+1)./factorial(2*k+1)); MagTrueerr=abs(cumsum(a)-f_exact); MAPRE=100*MagTrueerr./cumsum(a); No loops neede...

ungefär 18 timmar ago | 0

Answered
function results into a vector
You just need a dot! Vreg = [(230-(VL))./(VL)];

ungefär 18 timmar ago | 0

Answered
Adding number in a sequence
movsum(jj,2);

ungefär 21 timmar ago | 0

Answered
How tatement to use if statement to eliminate unwanted value
m=max(i(i~=Inf));

ungefär 22 timmar ago | 0

| accepted

Answered
HOW TO get answer in 6 decimal places .
format long

ungefär 22 timmar ago | 0

| accepted

Answered
I can't figure out this matlab function that returns the exponential of each element
function ex = seriesExp(x) i=0:9; ex=arrayfun(@(x)sum(x.^i./factorial(i)),x); end

ungefär 22 timmar ago | 0

Answered
how to remove the error showing undefined function or variable
Preallocate X1 before the loop. X1=zeros(m1*k2,n1);

ungefär 23 timmar ago | 0

| accepted

Answered
How do I calculate the square of TStep5 divided by the average of TStep4 and TStep2?
TStep5^2/mean([TStep4,TStep2]); If you explained what you really what to do, it would be easier to help. There is likely a must...

en dag ago | 0

Answered
How do I find the sum of two vectors?
Row + Step;

en dag ago | 0

Answered
How would I convert this equation to code? My likely flawed coding is below. Thanks!
Assuming L and T are vector arrays of equal length and all others are defined constants. es=e0*exp((L/rv).*(1/t0 - 1./T));

en dag ago | 0

Answered
How can I create multiple arrays, based on unique column values, from a single array?
For your array x: function Plot(x) hold on; z=x(:,1); arrayfun(@(y)plot(x(ismember(z,y),3),x(ismember(z,y),2),'Marker','*','...

en dag ago | 0

Answered
backward recurssion in a loop
c=zeros(9,20); c(9,:)=b(9,:)-a(9,:); for i=8:-1:1 c(i,:)=c(i+1,:)-a(i,:); end

en dag ago | 0

| accepted

Answered
help plotting basic x vs y?
x =linspace(0,L,100); y =w0./(120*E*I*L)*(-5*x.^4+6*L^2*x.^2-L^4); plot(x,y);

en dag ago | 0

| accepted

Answered
correlation coefficients for a matrix that includes NaNs
[R,P]=corrcoef(rmmissing(PK6mab)); If you can tolerate deleting the entire rows of any missed data.

en dag ago | 0

Solved


Tell me the slope
Tell me the slope, given a vector with horizontal run first and vertical rise next. Example input: x = [10 2];

2 dagar ago

Solved


Sum of diagonal of a square matrix
If x = [1 2 4; 3 4 5; 5 6 7] then y should be the sum of the diagonals of the matrix y = 1 + 4 + 7 = 12

2 dagar ago

Answered
Sorting Prime Numbers From an Array of Numbers, Into a New Array
Why not use the primes function? NN=primes(100);

2 dagar ago | 0

Answered
Return if No Solution
If A will always be a square matrix, then if the det(A)==0 then return (no solution).

9 dagar ago | 0

Solved


Must be in the front row...
You are given a matrix followed by a single number. Your object is to write a script that will shift the matrix around so that ...

9 dagar ago

Solved


Approximation of Pi (vector inputs)
Pi (divided by 4) can be approximated by the following infinite series: pi/4 = 1 - 1/3 + 1/5 - 1/7 + ... For a given numbe...

9 dagar ago

Solved


Approximation of Pi
Pi (divided by 4) can be approximated by the following infinite series: pi/4 = 1 - 1/3 + 1/5 - 1/7 + ... For a given numbe...

9 dagar ago

Solved


Generate Square Wave
Generate a square wave of desired length, number of complete cycles and duty cycle. Here, duty cycle is defined as the fraction ...

9 dagar ago

Solved


Sum of series VII
What is the sum of the following sequence: Σ(km^k)/(k+m)! for k=1...n for different n and m?

9 dagar ago

Solved


Sum of series VI
What is the sum of the following sequence: Σk⋅k! for k=1...n for different n?

9 dagar ago

Solved


Sum of series V
What is the sum of the following sequence: Σk(k+1) for k=1...n for different n?

9 dagar ago

Solved


Sum of series IV
What is the sum of the following sequence: Σ(-1)^(k+1) (2k-1)^2 for k=1...n for different n?

9 dagar ago

Solved


Sum of series III
What is the sum of the following sequence: Σ(2k-1)^3 for k=1...n for different n?

9 dagar ago

Load more