two equations, need solve symbolically in Mupad for a variable and getting errors

1 回表示 (過去 30 日間)
Danielle Strong
Danielle Strong 2015 年 12 月 13 日
編集済み: Walter Roberson 2015 年 12 月 13 日
I have two equations:
RA := (KA1-bA1*pA1+aB1*pB1)*(pA1)-YA1*[KA1-bA1*pA1+aB1*pB1]^2
RB := (KB1-bB1*pB1+aA1*pA1)*(pB1)-YB1*[KB1-bB1*pB1+aA1*pA1]^2
and I need a closed form solution for pA1 and pB1, symbolically. I have tried various solve commands in which I get an error "equation is an unknown type" and if I try linsolve I get that the equations are not linear. I am not sure how to go about this. I feel like it should be simple.

回答 (1 件)

Walter Roberson
Walter Roberson 2015 年 12 月 13 日
編集済み: Walter Roberson 2015 年 12 月 13 日
Do not use [] for brackets: it means list-building.
RA := (aB1*pB1-bA1*pA1+KA1)*pA1-YA1*(aB1*pB1-bA1*pA1+KA1)^2;
RB := (aA1*pA1-bB1*pB1+KB1)*pB1-YB1*(aA1*pA1-bB1*pB1+KB1)^2;
solve([RA,RB],[pA1,pB1])
there are 4 solutions that are not complicated.
Possibly though what you mean is
eqn1 := RA = (aB1*pB1-bA1*pA1+KA1)*pA1-YA1*(aB1*pB1-bA1*pA1+KA1)^2;
eqn2 := RB = (aA1*pA1-bB1*pB1+KB1)*pB1-YB1*(aA1*pA1-bB1*pB1+KB1)^2;
solve([eqn1, eqn2], [pA1,pB1])
The solutions to this are complicated, involving quartics

カテゴリ

Help Center および File ExchangeNumeric Solvers についてさらに検索

Community Treasure Hunt

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

Start Hunting!

Translated by