solve a system of equations symbolically with R2018a

조회 수: 14 (최근 30일)
Katy Skillings
Katy Skillings 2019년 7월 16일
댓글: Walter Roberson 2019년 7월 17일
>> eqn1='(Fa0*x1)/0.1*(9.05*(1-x1))*(27.8-9.05*x1))==3785'
eqn1 =
'(Fa0*x1)/0.1*(9.05*(1-x1))*(27.8-9.05*x1))==3785'
>> eqn2='(Fa0*(x2-x1))/0.1*(9.05*(1-x2))*(27.8-9.05*x2))==3785'
eqn2 =
'(Fa0*(x2-x1))/0.1*(9.05*(1-x2))*(27.8-9.05*x2))==3785'
>> eqn3='(Fa0*(0.95-x2))/0.1*(9.05*(1-0.95))*(27.8-9.05*0.95))==3785'
eqn3 =
'(Fa0*(0.95-x2))/0.1*(9.05*(1-0.95))*(27.8-9.05*0.95))==3785'
>> solT=solve(eqn1,eqn2,eqn3,x1,x2,Fa0)
Error using solve>getEqns (line 418)
List of equations must not be empty.
Error in solve (line 226)
[eqns,vars,options] = getEqns(varargin{:});

답변 (1개)

Walter Roberson
Walter Roberson 2019년 7월 16일
You are using R2018b or later. solve() no longer accepts character vectors for equations.
Furthermore, each of your equations has an extra ) before the ==
  댓글 수: 5
Katy Skillings
Katy Skillings 2019년 7월 17일
Thank you. I attempted solving another way and got this answer as well but was intimidated by the lengthy answer. What is vpa?

댓글을 달려면 로그인하십시오.

카테고리

Help CenterFile Exchange에서 Formula Manipulation and Simplification에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by