답변 있음
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];...

거의 6년 전 | 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...

거의 6년 전 | 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...

거의 6년 전 | 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...

거의 6년 전 | 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 ...

거의 6년 전 | 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...

거의 6년 전 | 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...

거의 6년 전 | 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...

거의 6년 전 | 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...

거의 6년 전 | 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...

거의 6년 전 | 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...

거의 6년 전 | 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...

거의 6년 전 | 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 ...

거의 6년 전 | 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...

거의 6년 전 | 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...

거의 6년 전 | 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...

거의 6년 전 | 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...

거의 6년 전 | 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...

거의 6년 전 | 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...

거의 6년 전 | 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 ...

거의 6년 전 | 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...

거의 6년 전 | 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...

대략 6년 전 | 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 ...

대략 6년 전 | 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 ...

대략 6년 전 | 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...

대략 6년 전 | 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...

대략 6년 전 | 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...

대략 6년 전 | 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 [~...

대략 6년 전 | 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...

대략 6년 전 | 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...

대략 6년 전 | 0

| 수락됨

더 보기