test/Tools/isac/Knowledge/equation.sml
author Walther Neuper <neuper@ist.tugraz.at>
Tue, 28 Sep 2010 09:06:56 +0200
branchisac-update-Isa09-2
changeset 38031 460c24a6a6ba
parent 37960 ec20007095f2
child 38050 4c52ad406c20
permissions -rw-r--r--
tuned error and writeln

# raise error --> error
# writeln in atomtyp, atomty, atomt and xmlsrc
     1 (* tests on the equation solver
     2    author: Walther Neuper
     3    070703
     4    (c) due to copyright terms
     5 
     6 use"../smltest/IsacKnowledge/equation.sml";
     7 use"equation.sml";
     8 *)
     9 val thy = Isac.thy;
    10 
    11 "-----------------------------------------------------------------";
    12 "table of contents -----------------------------------------------";
    13 "-----------------------------------------------------------------";
    14 "----------- CAS input -------------------------------------------";
    15 "-----------------------------------------------------------------";
    16 "-----------------------------------------------------------------";
    17 "-----------------------------------------------------------------";
    18 
    19 
    20 "----------- CAS input -------------------------------------------";
    21 "----------- CAS input -------------------------------------------";
    22 "----------- CAS input -------------------------------------------";
    23 states:=[];
    24 CalcTree [([], ("e_domID", ["e_pblID"], ["e_metID"]))];
    25 Iterator 1;
    26 moveActiveRoot 1;
    27 replaceFormula 1 "solve (x+1=2, x)";
    28 autoCalculate 1 CompleteCalc;
    29 val ((pt,p),_) = get_calc 1;
    30 val Form res = (#1 o pt_extract) (pt, ([],Res));
    31 show_pt pt;
    32 if p = ([], Res) andalso term2str res = "[x = 1]" then ()
    33 else error "equation.sml behav.changed for CAS solve (x+1=2, x))";