Respondida
How to solve "Rank deficient, rank = 7, tol = 6.169247e+09." in nlinfit
There must be something that you misunderstood in the article. The problem from above is a linear fitting problem for the vecto...

casi 4 años hace | 0

| aceptada

Respondida
There are 500 different sizes of a bolt ranging around 0.5 mm. I want to separate the sizes that are above or below the tolerance. then add those results in a column vector
boltMeasurements = 0.5+0.005*randn(500,1); n = length(boltMeasurements) %number of values in array which is n=500 different ...

casi 4 años hace | 1

| aceptada

Respondida
help on solving system of differential equations
Your code gives f = y and g = z with the z in the solution for g as a free parameter. It has nothing to do with your function z(...

casi 4 años hace | 1

| aceptada

Respondida
Issue with finding the indices of the minimum element in a 3-Dimensional Array
A = rand(10,10,11); B = A(:); index = find(A==min(B)) B(index) [i j k] = ind2sub([10 10 11],index) A(i,j,k)

casi 4 años hace | 0

| aceptada

Respondida
Solving overdetermined linear sytem for possible solutions
Choose RI as a binary integer vector (0 or 1) of length N. Constraint is sum(RI) = K and sum(RI.'*A) = B. Of course, this is on...

casi 4 años hace | 0

Respondida
I need to make a Gaussian fit, problem is i dont know how to type the parameters using lsqcurvefit
M = [ 24.6 1.518572825 24.7 1.5083088954 24.8 1.5210166178 24.9 1.4203323558 24...

casi 4 años hace | 1

| aceptada

Respondida
Index in position 1 exceeds array bounds.
Seems that with the command if k == numfilesperday data(1:4,:) = []; end you have destroyed the complete matrix "data"....

casi 4 años hace | 1

Respondida
Matrix inside for loop not updating
hold on for t =1:1:200 g1(t)=3*cos(2*pi*450*t-141); plot(t,g1(t),'.') drawnow end

casi 4 años hace | 0

| aceptada

Respondida
Failing in creating a surface from three array
To create a surface, you need a z value for each combination of (x/y) values. Thus instead of a vector z with 6 elements you nee...

casi 4 años hace | 1

Respondida
Please explain how to solve coupled equation in MATLAB? ODE 45 or Runge kutta method? The equation is d/dz(Ep) + (n/c) d/dt (Ep) = Es M where n= 1.45 and C = 3e8
The equation you posted is a PDE, not an ODE. So an ODE integrator cannot be used directly for its solution. You will have to d...

casi 4 años hace | 0

Respondida
Intersection of two parametric circles in R3
Minimize(t1,t2) norm(v1(t1)-v2(t2))^2 Use an optimizer to determine t1 and t2, e.g. fminsearch.

casi 4 años hace | 0

Respondida
Using a fucntion in loop
P = [1 -2 4] a = 0; n = 3; while(a < n) P = polyder(P) a = a + 1; end

casi 4 años hace | 0

| aceptada

Respondida
increasing amplitude of sine wave
y=t/StopTime.*sin(2*pi*Fc*t); instead of y = A*sin(2*pi*Fc*t);

casi 4 años hace | 0

Respondida
Fit custom equation with two datasets
help lsqcurvefit

casi 4 años hace | 0

| aceptada

Respondida
Contour plot of a function
H = 0:0.01:3; XI = 0:0.01:2; for i=1:numel(H) h = H(i); for j=1:numel(XI) xi = XI(j); for k=1:m q = x +...

casi 4 años hace | 0

Respondida
Where is the wrong in this code??
f_b(1/z) = (0.1000 - 0.3000i)z^-1 + (0.2121 - 0.0008i)z^-2 + (0.9000 +0.0010i)z^-3 I wrote it several times already, but this f...

casi 4 años hace | 0

| aceptada

Respondida
Bisection Method Code Help
I didn't check whether there is a programming error in bisection1. In comparison to fzero it's very inexact - that's for sure. ...

casi 4 años hace | 0

Respondida
While loop setting error calculation is not calculating properly.
betaIter_deg (and thus betaIter) need to be reset because they are incremented in the while-loop.

casi 4 años hace | 1

Respondida
can I generate random no. from 0 to 10E5, but the condition is ?
numbers = sort(100e3*rand(1,80),'ascend') or numbers(1) = 100e3*rand; for i = 2:80 numbers(i) = numbers(i-1) + (100e3 - ...

casi 4 años hace | 0

Respondida
Index exceeds the number of array elements. Index must not exceed 2.
dr = (r1 - r2)/Ang; implies r1 > r2 r = r1:dr:r2; implies r2 > r1 So what is correct ?

casi 4 años hace | 0

Respondida
How to calculate the center of the obtained Area in this case?
https://en.wikipedia.org/wiki/Centroid#Of_a_polygon https://de.mathworks.com/help/matlab/ref/polyshape.centroid.html

casi 4 años hace | 0

Respondida
How to find the index of the values which are bigger than zero the following case?
M = [ 0 0.5 0.7]; [~,indices] = find(M>0)

casi 4 años hace | 0

Respondida
"A matrix 'B' of 5x5 whose elements are all 5"
B = 5*ones(5)

casi 4 años hace | 1

Respondida
anonymous, piecewise-defined function that has NaN as response for a certain subdomain
g=@(x) (x) .* (x<=-1)+... (x+1) .* (x>-1 & x<1)+... (-x+4) .* (x>=1); x = [-2,0,1.5,2.5,5]; gx = g(x); gx(x>2 & x<=...

casi 4 años hace | 0

Respondida
For loop alternative method
SensorA_under_30_degrees = SensorA(Temperature<30)

casi 4 años hace | 1

| aceptada

Respondida
Symbolic Integration Problem Using Symbolic Math Toolbox
syms par1 par2 par3 par4 par5 syms a q p s b mR nR r syms y yA yU K5 = cos(par1*y+par2)*sin(par3*y+par4)*cos(par5*y); K55 ...

casi 4 años hace | 0

| aceptada

Respondida
4 graph in 1 figure
Choose what you need: https://de.mathworks.com/help/matlab/creating_plots/graph-with-multiple-x-axes-and-y-axes.html https://d...

casi 4 años hace | 0

Respondida
How can I specify a parameter to solve a system of equations symbolically?
syms v_0 t_1 v_1 p_1 eqns_1 = [ ... t_1 == 2.0, ... v_1 == v_0, ... p_1 == v_0 * t_1, ... ]; solve(eqns_1,...

casi 4 años hace | 0

| aceptada

Respondida
Deterministic SEIR ODE model running slow
%Define model parameters as a structure (N.B. stick to days here for ease %later on) A = [10 0.1; 0.1 1]; J = 13000000+530000...

casi 4 años hace | 0

| aceptada

Respondida
How to write an if-else statement for a function
n = 6; f = 2; for i = 2:n f = sqrt(1+f); end f finf = 0.5+sqrt(0.5^2+1)

casi 4 años hace | 0

Cargar más