radsimp
-- simplify radicals in
arithmetical expressionsradsimp
simplifies arithmetical expressions containing
radicals.
radsimp(z)
z |
- | an arithmetical expression |
an arithmetical expression.
Chapter ``Manipulating Expressions'' of the Tutorial.
combine
, ifactor
, normal
, rectform
, simplify
radsimp(
z)
tries to simplify the radicals
in the expression z
. The result is mathematically
equivalent to z
.radsimp(
z)
is equivalent to
simplify(z,
sqrt)
.We demonstrate the simplification of constant expressions with square roots and higher order radicals:
>> radsimp(2*2^(1/4) + 2^(3/4) - (6*2^(1/2) + 8)^(1/2))
0
>> radsimp( sqrt(14 + 3*sqrt(3 + 2*sqrt(5 - 12*sqrt(3 - 2*sqrt(2))))) )
1/2 2 + 3
>> radsimp(3*sqrt(7)/(sqrt(7) - 2))
1/2 2 7 + 7
>> radsimp(sqrt(1 + sqrt(3)) + sqrt(3 + 3*sqrt(3)) - sqrt(10 + 6*sqrt(3)))
0
>> x := sqrt(3)*I/2 + 1/2: y := x^(1/3) + x^(-1/3): z := y^3 - 3*y
/ 1 1/2 1/3 \3 | --------------------- + (1/2 I 3 + 1/2) | - | 1/2 1/3 | \ (1/2 I 3 + 1/2) / 1/2 1/3 3 3 (1/2 I 3 + 1/2) - --------------------- 1/2 1/3 (1/2 I 3 + 1/2)
>> radsimp(z)
1
>> delete x, y, z:
radsimp
also works on arithmetical
expressions containing variables:
>> z := x/(sqrt(3) - 1) - x/2
x x -------- - - 1/2 2 3 - 1
>> radsimp(z) = expand(radsimp(z))
/ 1/2 \ 1/2 | 3 | x x 3 x | ---- + 1/2 | - - = ------ \ 2 / 2 2
>> delete z:
radsimp
constructs
a tower of algebraic extensions of Q using
the domain Dom::AlgebraicExtension
. It
tries to return the simplest possible form.