# wrong answer from solve?

```
var('t')
test3 = -4*cos(t)^4 + 4*cos(t)^2 - 1
sage: solve(test3==0,t)
[]
```

When actually the equation is equivalent to (cos(t))^2 = 1/2 and it does have solutions.

wrong answer from solve?

```
var('t')
test3 = -4*cos(t)^4 + 4*cos(t)^2 - 1
sage: solve(test3==0,t)
[]
```

When actually the equation is equivalent to (cos(t))^2 = 1/2 and it does have solutions.

add a comment

1

```
sage: solve(test3==0,t,to_poly_solve=True)
[t == 1/4*pi + 1/2*pi*z35]
```

You do have to read the documentation of `solve?`

to see this option. It's not default because sometimes it will not return exact solutions.

So then, if solve returns [], that does not mean "there are no solutions". It means, "I didn't find any solutions". Similarly, if it does return a list of solutions, I guess that means "Here are the solutions I found", rather than, "Here are all the solutions." If this is the case, the documentation should say so up front. It says, "if there are no solutions it returns an empty list" but says nothing about the converse.

Asked: **
2016-01-22 10:03:04 -0600
**

Seen: **105 times**

Last updated: **Jan 22 '16**

Solving trigonometric functions

Display x-intercept of a plot, involving x raised to the 3rd power.

How to fit data to an arrhenius equation

Solve large system of linear equations over GF(2)

Getting a function from a symbolic expression (i.e. "y = x+2")

solve system of non-linear implicit equations numerically

Solving symbolic polynomials in terms of alternate variables (+ bug?)

How can I get back an expression for free variables in solve function.

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.