| 1 | initial version |
Use solve? to access the documentation of the solve function.
This reveals a lot of examples, including trigonometric equations.
There are basically two ways to get "all solutions" for such equations:
algorithm='sympy'to_poly_solve='force'If you use the to_poly_solve='force' option, you get something like:
sage: solve([eq], [x], to_poly_solve='force')
[x == pi*z1]
which means pi times any integer (indicated by z1,
standing for an indexed integer variable $z_1$).
You can get a different index $k$ for the $z_k$ integer variable each time you solve.
If you use the algorithm='sympy' option, you get something like:
sage: solve([eq], [x], algorithm='sympy')
[ImageSet(Lambda(_n, 2*_n*pi), Integers),
ImageSet(Lambda(_n, 2*_n*pi + pi), Integers)]
Copyright Sage, 2010. Some rights reserved under creative commons license. Content on this site is licensed under a Creative Commons Attribution Share Alike 3.0 license.