I would like to get the specific number

1 view (last 30 days)
Redwood
Redwood on 30 Apr 2013
Dear Matlab experts,
I coded in Matlab to get the b value.
syms b
G = 7340;
G1 = 4516.881;
M1 = 5222.328;
M2 = 3264.034;
P1 = 3000;
P2 = 10000;
solve(G1 == G*(P1*exp(-b*M1/P1)/( P1*exp(-b*M1/P1)+ P2*exp(-b*M2/P2))), b)
But I got this in Matlab.
ans =
(65970697666560000*log(9312156501286059/49663631807804870))/93307147182466409
I would like to get the number, so please let me know how to fix this.
Thank you very much in advance.
Sincerely yours,
Redwood

Answers (1)

Azzi Abdelmalek
Azzi Abdelmalek on 30 Apr 2013
syms b
G = 7340;
G1 = 4516.881;
M1 = 5222.328;
M2 = 3264.034;
P1 = 3000;
P2 = 10000;
out=solve(G1 == G*(P1*exp(-b*M1/P1)/( P1*exp(-b*M1/P1)+ P2*exp(-b*M2/P2))), b)
out=double(out)

Tags

Community Treasure Hunt

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

Start Hunting!