By "nontrivial way", do you mean the cosine or the square root (or both)? 
And yes, I could eliminate b and then solve for a, but that's a manual step 
I'd rather avoid. 

Ok, so I simplified the expressions using Sage (I'm quite surprised to see 
that simplify_full() produces better results than Matlab's simplify() 
function). Then, replacing the cos(2pi/n) by a new variable x results in a 
much clearer system of equations. The complete code to solve for a and b is 
included below. 

a,b,x = var('a,b,x')
L = 2*b^2*x^2 + sqrt(4*b^2*x^4 - 4*(a + 2*b - 1)*x^2)*b - a - 2*b + 1
M = 8*b^2*x^4 - 8*b^2*x^2 + 2*b^2 + sqrt(64*b^2*x^8 - 128*b^2*x^6 + 
16*(6*b^2 - a - 2*b + 1)*x^4 - 16*(2*b^2 - a - 2*b + 1)*x^2 + 4*b^2 - 4*a - 
8*b + 4)*b - a - 2*b + 1

Eq1 = L == 1/2
Eq2 = M == 1/4

Sol = solve([Eq1, Eq2], a, b)

Sage starts/tries to solve it, but after half an hour it was still running 
so I terminated it. Are there any parameters I can tune for the solve() 
function for it to work properly, or can Sage just not solve these types of 
equations (yet)? Thanks.

-- 
You received this message because you are subscribed to the Google Groups 
"sage-support" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-support+unsubscr...@googlegroups.com.
To post to this group, send email to sage-support@googlegroups.com.
Visit this group at http://groups.google.com/group/sage-support.
For more options, visit https://groups.google.com/d/optout.

Reply via email to