The usual symbols are available for most operations:
Below are examples of four common operations: addition, subtraction, multiplication, and division. However, try to evaluate the cell:
It looks like only the last line was acknowledged, and it wasn't even evaluated. This is simply because we didn't ask Sage to display the other values, even though they
were being computed. Now, try to evaluate again:
The last value is still being printed as 9/7. It's not wrong - in fact, Sage is automatically defaulting to the most precise answer possible. To force Sage to provide us with a decimal value of 9/7, simply use a decimal in the input (after any number):
Exponents and Roots
Absolute Value, Rounding, Floor/Ceiling
Constants
Modular Arithmetic
Combinations
Random Values
Logarithms
Trigonometry
Polynomials
Solving Equations
If Sage can't solve an equation \(f(x) = 0\) exactly, the equation will be reprinted. You can find an approximate solution using
find_root
and specifying an interval for the solution: