getting the error in solving non linear equations

2 visualizaciones (últimos 30 días)
sunitha
sunitha el 24 de Mzo. de 2021
Respondida: sunitha el 24 de Mzo. de 2021
This is the error i am getting , i didnt understand what that error means . The error is showing in S(i)=vpasolve([eqn1,eqn2],[N,J]);
can u help me
Error using sym.getEqnsVars>checkVariables (line 92)
Second argument must be a vector of symbolic variables.
Error in sym.getEqnsVars (line 56)
checkVariables(vars);
Error in sym/vpasolve (line 132)
[eqns,vars] = sym.getEqnsVars(varargin{1:N});
Error in Untitled (line 46)
Solutions{i}=vpasolve([eqn1,eqn2],[N,J]);

Respuestas (2)

KSSV
KSSV el 24 de Mzo. de 2021
You have to show us the full code to get a straight help. Without ocde it gets difficult for people to understand what exactly is the problem.
I suspect that, in this line:
Solutions{i}=vpasolve([eqn1,eqn2],[N,J]);
is N, J are symbolic variables? I think not in your case and this is the reason for your error. N, J should be symbolic variables which you are truing to solve in eqn1 and eqn2.
If this is not the case, show us your full code.

sunitha
sunitha el 24 de Mzo. de 2021
Now i am not getting any error but i am getting the wrong values.i dont know where i did mistake using the data first i have to find V value using that V value again i have to find out the N J values
The first code is to find the v value
The second code is to find the N J variables
The problem is i am getting the same value 4 even if change the another variables also i am getting the same result
can u please tell me what is the problem with this code? i am trying from the last two days

Categorías

Más información sobre Symbolic Math Toolbox en Help Center y File Exchange.

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by