回答済み
How do I need to configure Matlab's solver such that it returns the correct solutions when complex magnitudes are involved?
Better use solve(expression*expression'==1,w) instead of solve(abs(expression)==1,w) From your hand calculation it follows t...

3年弱 前 | 0

| 採用済み

回答済み
linsolve for coefficient matrix
A.'*X.' = B.'

3年弱 前 | 1

回答済み
system of non linear equations
%solving stsyem of nonlinear equation 3.31 and 3.32 Woods paper with fsolve % eta_l= x1 , eta_u= x2 r=2; v=20; F=13/9; fu...

3年弱 前 | 0

| 採用済み

回答済み
not enough input arguments help in line 6 please explain why.
Works (see above). The list of input arguments to your function in the call to ode45 was wrong. [v,x] = ode45(@(v,x)ch6(t,x),v...

3年弱 前 | 1

| 採用済み

回答済み
The return value of the objective callback function must be a real double scalar.
Looking at your objective function, it seems it it returns complex values. This will make MATLAB error - you cannot minimize a f...

3年弱 前 | 0

回答済み
Solving a system of 6 DAEs of first order - index error
The reason why it doesn't work is that you don't have an equation that directly solves for y. Equation (1) solves for w, equati...

3年弱 前 | 0

| 採用済み

回答済み
Please help me with this qustion
syms v1 vo = 4/10 + v1 eqn1 = v1/10 + (v1-60/20) + v1-5*vo/20 ==0 v1_sol=solve(eqn1, v1) vo_sol = subs(vo,v1,v1_sol)

3年弱 前 | 0

回答済み
odextend initial guess error
Compute the solution up to t1 using ode15s. Make a loop over the different F(t)'s you want to prescribe and restart all the con...

3年弱 前 | 1

回答済み
How can I correct this error "Invalid expression. When calling a function or indexing a variable, use parentheses. Otherwise, check for mismatched delimiters"?
Maybe [t,y] = ode45(@equfunc,[0 200],1); plot(t,y) Look at the examples provided in the documentation of ode45: https://uk....

3年弱 前 | 0

回答済み
Can't solve the equations
You must tell us which solution you want. syms pb pg sb = 1; ds=0.25; dm=0.2; k=1; sg=1; m=0.01; r=0.06; f=0.075; ms=0...

3年弱 前 | 0

回答済み
For some reason, I am not getting plots when I put in this code for this question.
if Delta > 0 % Case of real and distinct roots x1 = (-b + sqrt(Delta)) / (2*a); x2 = (-b - sqrt(Delta)) / (2*a)...

3年弱 前 | 0

回答済み
I get an error despite that the variable xddot is in the scope of the Nested function
To compute Fxfr in the line f1 = a*(Fyfr + Fyfl) - b*(Fyrr + Fyrl) + Bf/2*(Fxfl - Fxfr) + Br/2*(Fxrl - Fxrr); you need x...

3年弱 前 | 0

回答済み
correct the following code for unsteady maxwell nanofluids
dydx has to consist of 6 equations: dydx(1) = y(2), dydx(2) = y(3), dydx(3) = f''' dydx(4) = y(5), dydx(5) = g'' dydx(6) = h'...

3年弱 前 | 0

| 採用済み

回答済み
Numerical differentiation in time in function used by ODE
ode15s can solve systems of differential equations of the form M*y' = f(t,y) where M is the so called mass matrix. If a row j of...

3年弱 前 | 0

回答済み
Finding Solution to Inequality in Matlab
I don't understand the result, but there is some output from the symbolic toolbox. As you can see, the numerator of sol.x is a ...

3年弱 前 | 1

回答済み
Nonlinear equation solver for neoclassical growth model
Set the right-hand sides of the resource constraint and the production constraint equal and solve for i(t). You will get an equa...

3年弱 前 | 0

回答済み
Error: Incorrect dimensions for matrix multiplication
You set uold = unew, but unew is 30x1 instead of 29x1. Since D(2:N,2:N) is 29x29, MATLAB errors in the next iteration when you ...

3年弱 前 | 0

回答済み
Incorrect Dimensions for matrix multiplication
You multiply and divide arrays elementwise when you compute Rtf. Thus you have to use elementwise multiplication (.*) and elemen...

3年弱 前 | 0

回答済み
How to use pdist2 command for distance calculation?
If you implement your own distance function for the haversine distance, you can use pdist2.

3年弱 前 | 0

回答済み
Empty sym: 0-by-1
Use A = double(arrayfun(@(i)solve(GI(i),V),1:numel(P))) instead of A = solve(GI,V)

3年弱 前 | 0

| 採用済み

回答済み
How to use a constraint on the output of a goal function?
You must ask yourself: How could the objective function become complex-valued ? Maybe you have a log(x) expression in it and the...

3年弱 前 | 0

| 採用済み

回答済み
Objective function is returning Inf or NaN values at initial point. lsqcurvefit cannot continue.
Before you call lsqcurvefit, you should call your function "func" with the initial guess values for the parameters to see what i...

3年弱 前 | 0

| 採用済み

回答済み
NaN Error , while solving Newton Raphson method
@MAYUR MARUTI DHIRDE for i = 2:Nx - 1 J(i, i - 1) = -1 / (2 * dx); J(i, i + 1) = 1 / (2 * dx); end Your loop starts...

3年弱 前 | 1

回答済み
Is it possible to solve this differential equation by modifying a given algorithm?
Seems your function to be integrated has a singularity between d/2 and R. Applying "integral" in this case is almost impossible....

3年弱 前 | 1

| 採用済み

回答済み
Assisted Simplification with other equations?
I was told that using the below information that I can simplify eqn to be truely a function of gamma alone Since Q does not app...

3年弱 前 | 2

| 採用済み

回答済み
Shifting an array to create a time delay within a function.
Use dde23 instead of ode23t.

3年弱 前 | 0

| 採用済み

回答済み
Is there a possibility to solve this equation numerically using MATLAB?
Please include the code you are using at the moment and critical values for u'(0). Is there any equation for u without the inte...

3年弱 前 | 2

| 採用済み

回答済み
Problem fitting the curve with fminsearch
Using a polynomial of degree 5 to fit your data is a bad idea because the higher the degree, the greater the oscillations betwee...

3年弱 前 | 1

回答済み
Solve a matrix that has nonlinear coefficients
If the coefficients contain the unknowns, a matrix representation of your system of equations leads you nowhere. Write your sys...

3年弱 前 | 0

| 採用済み

回答済み
How can I solve this PDE kinetics equation with Symbolic Toolbox?
PDEs cannot be solved with the symbolic toolbox. Use "pdepe" as numerical solver instead.

3年弱 前 | 0

さらに読み込む