123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192 |
- Tue Feb 10 12:29:13 2004 run on Linux
- % test file for residue package
- residue(x/(x^2-2),x,sqrt(2));
- 1
- ---
- 2
- poleorder(x/(x^2-2),x,sqrt(2));
- 1
- residue(sin(x)/(x^2-2),x,sqrt(2));
- sqrt(2)*sin(sqrt(2))
- ----------------------
- 4
- poleorder(sin(x)/(x^2-2),x,sqrt(2));
- 1
- residue(1/(x-1)^m/(x-2)^2,x,2);
- - m
- poleorder(1/(x-1)/(x-2)^2,x,2);
- 2
- residue(sin(x)/x^2,x,0);
- 1
- poleorder(sin(x)/x^2,x,0);
- 1
- residue((1+x^2)/(1-x^2),x,1);
- -1
- poleorder((1+x^2)/(1-x^2),x,1);
- 1
- residue((1+x^2)/(1-x^2),x,-1);
- 1
- poleorder((1+x^2)/(1-x^2),x,-1);
- 1
- residue(tan(x),x,pi/2);
- -1
- poleorder(tan(x),x,pi/2);
- 1
- residue((x^n-y^n)/(x-y),x,y);
- 0
- poleorder((x^n-y^n)/(x-y),x,y);
- 0
- residue((x^n-y^n)/(x-y)^2,x,y);
- n
- y *n
- ------
- y
- poleorder((x^n-y^n)/(x-y)^2,x,y);
- 1
- residue(tan(x)/sec(x-pi/2)+1/cos(x),x,pi/2);
- -2
- poleorder(tan(x)/sec(x-pi/2)+1/cos(x),x,pi/2);
- 1
- for k:=1:2 sum residue((a+b*x+c*x^2)/(d+e*x+f*x^2),x,
- part(part(solve(d+e*x+f*x^2,x),k),2));
- b*f - c*e
- -----------
- 2
- f
- residue(sin(x)/x^6,x,0);
- 1
- -----
- 120
- residue((1-cos(x))/x^5,x,0);
- - 1
- ------
- 24
- residue(exp(1/x),x,0);
- ***** taylor fails
- % not implemented
- residue((A*x+B*x^2+c)/(D*x+E),x,-E/D);
- 2 2
- - a*d*e + b*e + c*d
- ------------------------
- 3
- d
- residue(tan(x),x,pi/2);
- -1
- residue(sec(x),x,pi/2);
- -1
- residue(factorial(x),x,0);
- ***** not yet implemented
- % ***** not yet implemented
- residue(x^3/sin(1/x)^2,x,infinity);
- - 1
- ------
- 15
- poleorder(x^3/sin(1/x)^2,x,infinity);
- 5
- residue(x^3*sin(1/x)^2,x,infinity);
- -1
- poleorder(x^3*sin(1/x)^2,x,infinity);
- 1
- end;
- Time for test: 60 ms, plus GC time: 20 ms
|