How to get 2 angle values for an asin?

16 views (last 30 days)
Hey guys, I'm trying to solve for 2 angles that have the same sine value.
i.e. if x = asin(0.5), then x could be 30 degrees or 150 degrees.
I can't get this to come out though.
tried declaring a 1x2 symbolic variable x: [x1,x2], but if I try:
S = solve('x = asin(0.5)',x)
Then what I get out is:
x = 0.52... (30 degrees)
x1 = 0
x2 = 0
Can anyone help me out here? What am I doing wrong?

Accepted Answer

A Jenkins
A Jenkins on 19 Jan 2015
>> syms x
>> solve('0.5 = sin(x)',x)
ans =

Sign in to comment.

More Answers (0)

Community Treasure Hunt

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

Start Hunting!

Translated by