読者です 読者をやめる 読者になる 読者になる

cineqs4 使用例

作動確認バージョン.

Maxima 5.39.0
using Lisp CMU Common Lisp 21b (21B Unicode)

高次不等式.

(%i1) ep(1,0)$cineqs4('(   (x-1)*(x^2-2)*(x^3-3)*(x^2+4)<=0   ));
Evaluation took 0.0000 seconds (0.0000 elapsed) using 856 bytes.
Evaluation took 0.0600 seconds (0.0600 elapsed) using 1.337 MB.
(%o2) [[-sqrt(2) <= x,x <= 1],[sqrt(2) <= x,x <= 3^(1/3)]]

代数的な表示が出来ない場合は,近似値(内部では小数第6位以下を切り捨てています)で答えます.

(%i3) ep(1,0)$cineqs4('(   (x-1)*(x^2-2)*(x^3-3)*(x^2+4)<=1/10   ));
Evaluation took 0.0000 seconds (0.0100 elapsed) using 720 bytes.
Evaluation took 0.0100 seconds (0.0100 elapsed) using 1.091 MB.
(%o4) [[-1.414631932468004 <= x,x <= 1.010331702011963],
       [1.374072765807135 <= x,x <= 1.473559962228517]]

分数関数で表された不等式.

(%i5) ep(1,0)$cineqs4('(   (x-1)/x<2 ));
Evaluation took 0.0000 seconds (0.0000 elapsed) using 720 bytes.
Evaluation took 0.0000 seconds (0.0100 elapsed) using 520.242 KB.
(%o6) [[x < -1],[0 < x]]

連言.

(%i7) ep(1,0)$cineqs4('(   (x-1)*(x^2-2)*(x^3-3)<=0 and (x-1)/x<2 ));
Evaluation took 0.0000 seconds (0.0000 elapsed) using 720 bytes.
Evaluation took 0.0400 seconds (0.0500 elapsed) using 2.571 MB.
(%o8) [[-sqrt(2) <= x,x < -1],[0 < x,x <= 1],[sqrt(2) <= x,x <= 3^(1/3)]]

選言.

(%i9) ep(1,0)$cineqs4('(   (x-1)*(x^2-2)*(x^3-3)<=0 or (x-1)/x<2 ));
Evaluation took 0.0000 seconds (0.0000 elapsed) using 720 bytes.
Evaluation took 0.0300 seconds (0.0300 elapsed) using 2.804 MB.
(%o10) [[true]]

こんな場合は...

(%i11) ep(1,0)$cineqs4('(   x^4-x-1<=0   ));
Evaluation took 0.0000 seconds (0.0000 elapsed) using 720 bytes.
Evaluation took 0.2500 seconds (0.2500 elapsed) using 24.248 MB.
(%o12) [[-(sqrt(sqrt(6)*sqrt((sqrt(849)+9)^(1/3)*(3*sqrt(849)+155)^(1/3)
                                                *(2^(8/3)*18^(2/3)*sqrt(849)
                                                 -9*2^(8/3)*18^(2/3))
                              +(sqrt(849)+9)^(1/3)*(3*sqrt(849)+155)^(2/3)
                                                  *(2^(1/3)*18^(2/3)*sqrt(849)
                                                   -9*2^(1/3)*18^(2/3))
                              +(sqrt(849)+9)^(1/3)
                               *(32*18^(2/3)*sqrt(849)-16*18^(5/3)))
                 +3*2^(11/3)*(3^(3/2)*sqrt(283)-27)^(1/3)
                 -8*18^(2/3)*(sqrt(3)*sqrt(283)+9)^(1/3))
          -sqrt(6)*sqrt(2^(1/3)*(3*sqrt(849)-27)^(1/3)*(3*sqrt(849)+155)^(1/3)
                         -2^(8/3)*(3*sqrt(849)-27)^(1/3)))
          /24
           <= x,
         x <= (sqrt(sqrt(6)*sqrt((sqrt(849)+9)^(1/3)*(3*sqrt(849)+155)^(1/3)
                                                    *(2^(8/3)*18^(2/3)
                                                             *sqrt(849)
                                                     -9*2^(8/3)*18^(2/3))
                                  +(sqrt(849)+9)^(1/3)*(3*sqrt(849)+155)^(2/3)
                                                      *(2^(1/3)*18^(2/3)
                                                               *sqrt(849)
                                                       -9*2^(1/3)*18^(2/3))
                                  +(sqrt(849)+9)^(1/3)
                                   *(32*18^(2/3)*sqrt(849)-16*18^(5/3)))
                     +3*2^(11/3)*(3^(3/2)*sqrt(283)-27)^(1/3)
                     -8*18^(2/3)*(sqrt(3)*sqrt(283)+9)^(1/3))
           +sqrt(6)*sqrt(2^(1/3)*(3*sqrt(849)-27)^(1/3)
                                *(3*sqrt(849)+155)^(1/3)
                          -2^(8/3)*(3*sqrt(849)-27)^(1/3)))
           /24]]

コントローラー ep の第一引数を 0 にすると,近似値で答えます.

(%i13) ep(0,0)$cineqs4('(   x^4-x-1<=0   ));
Evaluation took 0.0000 seconds (0.0000 elapsed) using 736 bytes.
Evaluation took 0.0000 seconds (0.0100 elapsed) using 175.711 KB.
(%o14) [[-0.7244919786096257 <= x,x <= 1.220744081172491]]

無理関数で表された不等式.

(%i15) ep(1,0)$cineqs4('(   sqrt(x)<x-1  ));
Evaluation took 0.0000 seconds (0.0000 elapsed) using 720 bytes.
Evaluation took 0.0100 seconds (0.0100 elapsed) using 674.156 KB.
(%o16) [[(sqrt(5)+3)/2 < x]]

含意.

(%i17) ep(1,0)$cineqs4('(   1<sqrt(x) implies 1<x  ));
Evaluation took 0.0000 seconds (0.0000 elapsed) using 720 bytes.
Evaluation took 0.0100 seconds (0.0100 elapsed) using 428.797 KB.
(%o18) [[true]]

根号が複数あっても.

(%i19) ep(1,0)$cineqs4('(   sqrt(x)+sqrt(3-x)<2  ));
Evaluation took 0.0000 seconds (0.0000 elapsed) using 720 bytes.
Evaluation took 0.0300 seconds (0.0200 elapsed) using 1.524 MB.
(%o20) [[0 <= x,x < -(2^(3/2)-3)/2],[(2^(3/2)+3)/2 < x,x <= 3]]
(%i21) ep(0,0)$cineqs4('(   sqrt(x)+sqrt(3-x)+sqrt(3+x)<22/5  ));
Evaluation took 0.0000 seconds (0.0000 elapsed) using 736 bytes.
Evaluation took 0.0200 seconds (0.0200 elapsed) using 2.500 MB.
(%o22) [[0 <= x,x < 0.9647335423197492],[2.937906564163217 < x,x <= 3]]

ネストされても.

(%i23) ep(1,0)$cineqs4('(   1/sqrt(sqrt(1+x)-x)<2   ));
Evaluation took 0.0000 seconds (0.0000 elapsed) using 720 bytes.
Evaluation took 0.0700 seconds (0.0800 elapsed) using 4.835 MB.
(%o24) [[-1 <= x,x < 5/4]]

有理数冪でも.

(%i25) ep(1,0)$cineqs4('(   x^4-x^(1/3)-1>0   ));
Evaluation took 0.0000 seconds (0.0000 elapsed) using 720 bytes.
Evaluation took 0.0300 seconds (0.0400 elapsed) using 1.039 MB.
(%o26) [[x < -0.6196702671972711],[1.198342827550492 < x]]