maple-changevarとCompleteSequare
x^4+3*x^2+5
を完全平方する。このときに、changevarを使う。
with(student):
p:=changevar(x^2=t,x^4+3*x^2+5);
2
t + 3 t + 5
q:=Student[Precalculus][CompleteSquare](p,t);
#がlong form. Shortformはwith(Student[Precalculus]);
#CompleteSquare(p,t)とする。
2
/ 3\ 11
|t + -| + --
\ 2/ 4
r:=changevar(t=x^2,q);
2
/ 2 3\ 11
|x + -| + --
\ 2/ 4
説明: Student[changevar](x^2=t,x^4+3*x^2+5);はx^2をtと置く。だからx^2はt^2
となる。そうしないと、Student[Precalculus][CompleteSquare](p,t);で平方完成できない。平方完成してから、t=x^2を入れてtを元に戻す