Ask Your Question

how to get simplified result of solving equation

asked 2015-08-17 12:38:14 -0600

ismon gravatar image

updated 2015-08-17 15:21:01 -0600

calc314 gravatar image

Hi there!

In a linear algebra assignment I have the following equation I need to find a solution for:

-2*sqrt(3)*sin(t)^2+2*cos(t)*sin(t)+sqrt(3)==0. I know the result is pi/3.

Now, when I use solve, solve(-2*sqrt(3)*sin(t)^2+2*cos(t)*sin(t)+sqrt(3)==0, t). I get:

[sin(t) == -1/6*sqrt(3)*(sqrt(cos(t)^2+6)-cos(t), sin(t) == 1/6*sqrt(3)*sqrt(cos(t)^2+6)+cos(t))].

How do I use the solve function to get the more simplified result?

NB: I have also tried to use find_root and different simplify functions, but also without any luck. I am new to sage, so it is quite possible that I don't know a specification to the solve function which I should use.

Thank you in advance!

Sincerly Simon

edit retag flag offensive close merge delete

1 answer

Sort by ยป oldest newest most voted

answered 2015-08-17 15:25:06 -0600

calc314 gravatar image

updated 2015-08-17 15:29:37 -0600

First, be sure to define your variable using var('t').

To find a numerical solution, you can plot the function to help identify where the roots are.


For example, to get the first positive root, you can now use find_root to find the root between 0 and 3.


which gives 2.6179938779914944.

For an analytic solution, you can do the following:

solve(-2*sqrt(3)*sin(x)^2+2*cos(x)*sin(x)+sqrt(3)==0, x,to_poly_solve ='force')

This gives: [x == 1/3*pi + pi*z1, x == -1/6*pi + pi*z2]

The z1 and z2 can be any integers.

(Interestingly, I could not get the solve to work with t as the variable. I'm not sure why.)

edit flag offensive delete link more


Thank you very much for your answer!

I have marked your answer as being the correct answer. I don't know if I am to give you points, but if I am, please reply of how I do this.

Sincerly Simon

ismon gravatar imageismon ( 2015-08-18 01:54:34 -0600 )edit

Thank you. The points are managed by the website automatically.

calc314 gravatar imagecalc314 ( 2015-08-18 17:21:23 -0600 )edit

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

1 follower


Asked: 2015-08-17 12:38:14 -0600

Seen: 471 times

Last updated: Aug 17 '15