已回答
Grouping sequence within interval
Something like this should do the trick for you V1 = [0.73 0.74 0.77 0.78 0.79 11.17 11.18 11.19 11.20 11.22 11.23];...

4 years 前 | 0

| 已接受

已回答
How do I round off the answer for the depth to within 2mm?
If you want to round to a specific unit (m, mm, etc), you can do this by just adding an extra parameter to the round function wi...

4 years 前 | 0

| 已接受

已回答
How do I make a scatter 3D plot move towards a line
It mostly depends of what points should move (only neighbours or all of them), but after you decide it you can calculate the clo...

4 years 前 | 0

已回答
Particle size calculation from given image
The size for each particle is a task which is extremely hard to automatize, you will always get some error due to different ligh...

4 years 前 | 0

已回答
Mean absolute value for ecg signal
Your code is okay with exception of the length. If you have a sampling rate of 250 Hz (or, in another way of expression, values ...

4 years 前 | 0

已回答
How to work with Matrices that have a great difference in element size (e.g. 1 to 10e+15)?
I don't believe you're facing problems due to the difference of magnitudes, but rather because your problem may be very ill-cond...

4 years 前 | 0

| 已接受

已回答
Nonlinear multiobjective optimization - Gamultiobj - Options
If you write your optimization problem like this: x = gamultiobj(fun,nvars) You're basically telling the optimizer that you ha...

4 years 前 | 0

已回答
How to generate lines between a fixed point and evenly spaced points on a line
If I understood your question right you mean something like this? clc; xlim([0, 100]); ylim([0, 100]); hold on Ax=0; Ay...

4 years 前 | 1

| 已接受

已回答
PLOTTING A SINE WAVE USING TRIGNOMETRIC FOURIER SERIES
You have an analytical waveform, so you can generate it for 4 cycles without using any fourier function. Then, if you use the ff...

4 years 前 | 0

已回答
how to imput a matrix end outpur four arguments
The main function creation in matlab has the following form: function output = FuncName(input) output = f(input) end Input...

4 years 前 | 0

已回答
Optimization of 4 variables by minimizing RMSE error as an objective function using fminsearch
Some points: Your rmse function is not returning any value You need to pass a function to the optimization function that takes...

4 years 前 | 0

| 已接受

已回答
I'm getting an error in obtaining the optimal solution for a nonlinear equation
You have an error in your wolf loop. It should be like this: while ( ( ( fh > f + c*alpha0*gradx'*p ) || ( abs(gradk)'*p > cu*a...

4 years 前 | 0

| 已接受

已回答
odeEueler Explicit Eurlers method
You had many syntax errors on your code. Here is a version with them fixed and it should work. Although a negative weighting is ...

4 years 前 | 0

| 已接受

已回答
Filter time-variant data and reduce its length
Take a look at medfilt1 and/or movmean. They sould help you reduce the fluctuations. To reduce the data length you just index th...

4 years 前 | 0

已回答
How to use function like `min` in symfun?(I got an error)
You can't use min or max in symbolic variables in matlab. A work around can be this one: syms x1 x2 real; xlt = symfun(1/2*(x1...

4 years 前 | 1

| 已接受

已回答
Minimum of a function
You had some typos in your constrain function and also you don't need to create a function file for your function since you alre...

4 years 前 | 1

| 已接受

已回答
How do I fix the array error?
Look this part as example: for t = ProjectedTime HatchVec = Hatchling - (Hatchling .* 0.675) - (Hatchling .* 0.325) + (Bre...

4 years 前 | 0

| 已接受

已回答
how to fit a Nonlinear model with multiple input and single output by using dataset in matlab
Without your data nor any code is difficult to specifically help you. Still, a general thing you may do, if you already have the...

4 years 前 | 0

已回答
Is there any method to plot two dimensional view of a function which depends on multi variables?
What exactly you expect to get with this? Your function dependes on three variables, so if you vary only x, the result will depe...

4 years 前 | 1

已回答
Retrive variable out of a parfor loop
You have an error in your mont_carlo inputs, it should be [x,neigh,E,M]= monte_carlo ( N, T, iter,init ) or you should delete ...

4 years 前 | 0

| 已接受

已回答
Predict function in KNN
Your KNN is not a single model to make predictions but rather a RegressionPartitionedModel. Which means it has all the statistic...

4 years 前 | 0

| 已接受

已回答
Find params that minimize function
You can define it as an annonymous function and then call fminsearch to solve it: e = 5; xi = [1,2,3,4]; yi = [3,4,5,6]; si...

4 years 前 | 0

| 已接受

已回答
How to implement mathematical functions
Considering that nu is a function of x,y,z and you described it as a 3-dimensional matrix in your code you could implement then ...

4 years 前 | 1

已回答
Swap all the values in a vector
Yes, randperm: rng(31415) x=[ 1 2 3 4 5 6 7 8]; p = randperm(length(x)); xnew = x(p) xnew = 7 8 1 2 ...

4 years 前 | 0

已回答
Multidimensional surface fitting to n independent variables.
You first have to define which kind of function you would like to build. lsqcurvefit can surely be used, but you first have to d...

4 years 前 | 0

已回答
how to intergrate my acceleration vs time curve to velocity vs time curve with simpson's rule, instead of using cumtrapz?
You need to implement the simpson's rule on your own. A naive implementation would be something like that f = @(t)t.^2; N = 1...

4 years 前 | 0

已回答
The first letter of the string value was not written
I would advise you to perform the last string into a loop, so you're sure they are going to be displayed right: n=input('Please...

4 years 前 | 0

已回答
Finding index of a value in the matrix
This is probably the shortest you can get range=find( abs(A(:,1) - targetPhase) < 2 ); % targetPhase is the required phase [~...

4 years 前 | 0

| 已接受

已回答
How can i plot this graph?
Making y=... substitute the whole array. Try something like this: x=0:0.5:5; y = zeros(size(x)); for idx = 1:length(x) i...

4 years 前 | 0

已回答
Find the average difference of two adjacent frames on a set of images
Without further details it is difficult to know how exactly you would like to calculate it. A naive implementation that does exa...

4 years 前 | 0

| 已接受

加载更多