Matlab computing a wrong value
Show older comments
I am trying to do a simple calculation but matlab is outputting a different value than from what it should be, any ideas why?
R=0.5;
Cv=0.4;
B1= 60;
R= Cv/2*(tan(B1) + tan(B2));
[B2] = vpasolve([R], [B2]);
disp(B2);
You are supposed to find that B2 should be around 37.5 but matlab displays a value of -0.3097 so why is matlab getting a different answer?
4 Comments
Vidhan Malik
on 22 Mar 2016
John D'Errico
on 22 Mar 2016
I answered your problem. It appears that the symbolic toolbox does not use tand. But I show there how to convert between degrees and radians.
Vidhan Malik
on 22 Mar 2016
John D'Errico
on 22 Mar 2016
There is a time lag, lol. And half the time, I answer a question, only to find that someone else has already answered while I was writing a wordy dissertation on the problem.
Accepted Answer
More Answers (0)
Categories
Find more on Lengths and Angles in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!