I would like to get the b value in Matalb.

조회 수: 5 (최근 30일)
Redwood
Redwood 2013년 5월 16일
Dear Matlab experts,
I would like to get the b value in Matlab, but I got nothing in Matlab. I attached my coding below. Please let me know how to get the b value.
syms b G G1 M1 M2 M3 P1 P2 P3
b = 0:.0001:10;
Out=solve(' G1 == G*(P1*exp(-b*M1/P1)/( P1*exp(-b*M1/P1)+ P2*exp(-b*M2/P2) + P3*exp(-b*M3/P3)))', b)
G = [7340, 7194];
G1 = [4516.881, 5002.953];
M1 = [5222.328, 6009.419];
M2 = [3264.034, 2632.621];
M3 = [1264.034, 1632.621];
P1 = [3000, 3025];
P2 = [10000, 10051];
P3 = [5000, 5051];
Out=subs(Out)
Thank you very much in advance.
Sincerely,
Redwood

답변 (4개)

Walter Roberson
Walter Roberson 2013년 5월 16일
Use
syms b
instead of assigning a numeric value to b.

Redwood
Redwood 2013년 5월 16일
Dear Walter,
Thank you very much for your help.
I already used syms b.
But I did not get anything in Matlab.
Sincerely yours,
Redwood
  댓글 수: 1
Walter Roberson
Walter Roberson 2013년 5월 16일
Is there reason to expect that there is an algebraic solution? If not then you are going to have to do the substitution first and then do a numeric solution. You will likely have to do each set of values individually rather than the two sets together.

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


sami
sami 2013년 5월 16일
inner matrix must agree

Redwood
Redwood 2013년 5월 16일
Dear Sami,
What do you mean, "inner matrix must agree"?
Sincerely yours,
Redwood

태그

Community Treasure Hunt

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

Start Hunting!

Translated by