Generate a vector like 1,2,2,3,3,3,4,4,4,4
Generate a vector like 1,2,2,3,3,3,4,4,4,4
So if n = 3, then return
[1 2 2 3 3 3]
And if n = 5, then return
[1 2 2 3 3 3 4...
4 years 前
已解决
Sum of series IX
What is the sum of the following sequence:
Σ 1/k! for k=1...n
for different n?
4 years 前
已解决
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?
4 years 前
已解决
Sum of series I
What is the sum of the following sequence:
Σ(2k-1) for k=1...n
for different n?
Make the vector [1 2 3 4 5 6 7 8 9 10]
In MATLAB, you create a vector by enclosing the elements in square brackets like so:
x = [1 2 3 4]
Commas are optional, s...