source: git/Tst/Long/solve_l.tst @ 3dda3c

spielwiese
Last change on this file since 3dda3c was 796e5a, checked in by Olaf Bachmann <obachman@…>, 24 years ago
* solve stuff cleanup git-svn-id: file:///usr/local/Singular/svn/trunk@3853 2c84dea3-7e68-4137-9b89-c4e89433aadc
  • Property mode set to 100644
File size: 2.4 KB
Line 
1//
2// solve_s.tst - short tests for
3
4LIB "tst.lib";
5tst_init();
6tst_ignore("CVS ID $Id: solve_l.tst,v 1.2 1999-11-18 16:38:35 obachman Exp $");
7
8LIB "solve.lib";
9
10////////////////////////////
11
12tst_ignore( "ring rs1 = 0,(x,y,z),lp;" );
13ring rs1 = 0,(h,x,y,z),lp;
14
15poly f0= x+y+z+1;
16poly f1= x^2 + 6*x + 3*y + 6*z - 4;
17poly f2= y^2 + 2*x -7*y + 5 + 2*z;
18poly f3= x^2 + y^2 + z^2 - 1;
19ideal i=f1,f2,f3;
20ideal im=f0,f1,f2,f3;
21
22ures_solve(homog(i,h),1);
23mp_res_mat(homog(im,h),1);
24
25tst_ignore( "ring rs2 = 0,(x,y,z),lp;" );
26ring rs2 = 0,(x,y,z),lp;
27
28poly f0= x+y+z;
29poly f1= x^2 + 6*x + 3*y + 6*z - 4;
30poly f2= y^2 + 2*x -7*y + 5 + 2*z;
31poly f3= x^2 + y^2 + z^2 - 1;
32ideal i=f1,f2,f3;
33ideal im=f0,f1,f2,f3;
34
35ures_solve(i);
36mp_res_mat(im);
37
38fglm_solve(i,30);
39rlist;
40
41setring rs2;
42triangL_solve(i,30);
43rlist;
44
45setring rs2;
46triangLf_solve(i,30);
47rlist;
48
49setring rs2;
50triangM_solve(i,30);
51rlist;
52
53////////////////////////////
54
55tst_ignore( "ring rs3 = 0,(x1,x2,x3),lp;" );
56ring rs3 = 0,(x0,x1,x2,x3),lp;
57
58poly f0= x1+x2+x3+1;
59poly f1= -1 + 6*x1^2 - 4*x1*x2 + 3*x2^2 - 8*x1*x3 + 10*x2*x3 + 13*x3^2;
60poly f2= -2*x1 - 2*x1^2 + x2 - 2*x2^2 + 3*x1 - 4*x1*x3 - 4*x2*x3 - 4*x3^2;
61poly f3= x1 - 5*x1^2 - x2 + 2*x1*x2 - 2*x2^2 + 8*x1*x3 - 10*x2*x3 - 13*x3^2;
62ideal i=f1,f2,f3;
63ideal im=f0,f1,f2,f3;
64
65ures_solve(homog(i,x0),1);
66mp_res_mat(homog(im,x0),1);
67
68tst_ignore( "ring rs4 = 0,(x1,x2,x3),lp;" );
69ring rs4 = 0,(x1,x2,x3),lp;
70
71poly f0= x1+x2+x3;
72poly f1= -1 + 6*x1^2 - 4*x1*x2 + 3*x2^2 - 8*x1*x3 + 10*x2*x3 + 13*x3^2;
73poly f2= -2*x1 - 2*x1^2 + x2 - 2*x2^2 + 3*x1 - 4*x1*x3 - 4*x2*x3 - 4*x3^2;
74poly f3= x1 - 5*x1^2 - x2 + 2*x1*x2 - 2*x2^2 + 8*x1*x3 - 10*x2*x3 - 13*x3^2;
75ideal i=f1,f2,f3;
76ideal im=f0,f1,f2,f3;
77
78ures_solve(i);
79mp_res_mat(im);
80
81fglm_solve(i,30);
82rlist;
83
84setring rs4;
85triangL_solve(i,30);
86rlist;
87
88setring rs4;
89triangLf_solve(i,30);
90rlist;
91
92setring rs4;
93triangM_solve(i,30);
94rlist;
95
96////////////////////////////
97
98tst_ignore( "ring rs6= 0,(x,y),lp;" );
99ring rs6= 0,(x,y),lp;
100poly f = 15x5 + x3 + x2 - 10;
101laguerre_solve(f);
102
103laguerre_solve(f,10);
104
105tst_ignore( "ring rsc= (real,20,I),x,lp;" );
106ring rsc= (real,20,I),x,lp;
107poly f = (15.4+I*5)*x^5 + (25.0e-2+I*2)*x^3 + x2 - 10*I;
108laguerre_solve(f);
109
110////////////////////////////
111
112ring rs7 = 0,(x),lp;
113ideal v=16,0,11376,1046880,85949136;
114interpolate( 3, v, 4 );
115
116ring rs8 = 0,(x,y),dp;
117ideal p = 2,3;
118ideal v= 1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16;
119poly ip= interpolate( p,v,3 );
120ip;
121
122////////////////////////////
123
124tst_status(1);$
125
Note: See TracBrowser for help on using the repository browser.