simplification - How to simplify terms with usage of square root in maxima -


let's have term 1/4 * x/sqrt(2) * x^2 / 2; in maxima. output (without further modification) gives x^3/2^(7/2). how can force output format x^3/(8*sqrt(2)) usage of square roots whenever possible?

(%i1) sq2: " "(sqrt(2))$ (%i2) matchdeclare(n, lambda([n], oddp(n) , n#1))$ (%i3) defrule(r_sq2, 2^(n/2), sq2*2^((n-1)/2))     $ (%i4) e: 1/4 * x/sqrt(2) * x^2 / 2;                                        3                                       x (%o4)                                ----                                       7/2                                      2 (%i5) apply1(e, r_sq2);                                              3                                   (sqrt(2)) x (%o5)                            -------------                                       16 

a rule can insert sqrt(2). in example use "null" function prevent simplification. can consider box , rembox functions or leave sq2 undefined.


Comments

Popular posts from this blog

javascript - Clear button on addentry page doesn't work -

c# - Selenium Authentication Popup preventing driver close or quit -

tensorflow when input_data MNIST_data , zlib.error: Error -3 while decompressing: invalid block type -