MathAction Root denesting



Root denesting
last edited 1 year ago by test1

FriCAS can denest many nested roots. This is implemented in an extra package so befor use we need to expose it:

fricas
(1) -> )expose RootSimplification
RootSimplification is now explicitly exposed in frame initial

Now we can try

fricas
r := sqrt(102*sqrt(7) + 272)
Type: AlgebraicNumber?
fricas
rsimp(r)
Type: Union(Expression(Integer),...)
fricas
r := sqrt(66000162*1000003^(1/2) + 11000159000324)
Type: AlgebraicNumber?
fricas
rsimp(r)
Type: Union(Expression(Integer),...)
fricas
r := sqrt(((-4030008370)*700001^(1/2)+12090025110)*1000003^(1/2)+((-78000162)*700001^(1/2)+312335685800846295))
Type: AlgebraicNumber?
fricas
rsimp(r)
Type: Union(Expression(Integer),...)

We can denest roots of higher degree:

fricas
r := (((-6670600520850)*7^(1/2)+73781123539185)*13^(1/2)+((-77245760121201)*7^(1/2)+89932095680661))^(1/7)
Type: AlgebraicNumber?
fricas
rsimp(r)
Type: Union(Expression(Integer),...)

Note: Current code supports root of degree 2, 3 or 4 outside. With square root outside inside can contain roots of degree up to 12. Roots of degree 3 outside more limited concerning what can appear inside.

And we can have roots of higher degree inside:

fricas
r := (((-827820)*(17^(1/3))^2+(-58105080)*17^(1/3)+(-134584260))*19^(1/2)+(17045208*(17^(1/3))^2+79043889*17^(1/3)+1426984144))^(1/4)
Type: AlgebraicNumber?
fricas
rsimp(r)
Type: Union(Expression(Integer),...)

Denesting is not limited to numbers, it works for algebraic functions and more general expressions:

fricas
)set output tex off
 
fricas
)set output algebra on
r := ((x^6+3*x^5+73*x^4+429*x^3+63*x^2+213*x-1287)*(x^3-3)^(1/2)+3*x^7+37*x^6+39*x^5+451*x^4+1545*x^3+315*x^2+351*x-4860)^(1/3)
(11) ROOT +------+ 6 5 4 3 2 | 3 7 (x + 3 x + 73 x + 429 x + 63 x + 213 x - 1287)\|x - 3 + 3 x + 6 5 4 3 2 37 x + 39 x + 451 x + 1545 x + 315 x + 351 x - 4860 , 3
Type: Expression(Integer)
fricas
rsimp(r)
+------+ +----------+ | 3 3| 3 (12) (\|x - 3 + x + 12)\|x + x - 3
Type: Union(Expression(Integer),...)
fricas
)set output algebra off
 
fricas
)set output tex on
r := ((2*exp(x)^2-12*exp(x)-14)*(exp(x)+3)^(1/2)+exp(x)^3-12*exp(x)^2+39*exp(x)+52)^(1/2)
Type: Expression(Integer)
fricas
rsimp(r)
Type: Union(Expression(Integer),...)




Subject: Be Bold !!
( 15 subscribers )
Please rate this page:

AltStyle によって変換されたページ (->オリジナル) /