trigint.rlg 3.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138
  1. Sun Aug 18 18:56:01 2002 run on Windows
  2. % some test examples for the trigint package. If the input expression is
  3. % free of sin, cos or tan at the moment, then no Weierstrass substitutions
  4. % will be made, and the standard int operator is called.
  5. trigint(1/x,x);
  6. log(x)
  7. trigint(1,y);
  8. x
  9. trigint(sin(x),x);
  10. pi + 2*x
  11. - 2*tan(----------)
  12. 4
  13. ----------------------
  14. pi + 2*x 2
  15. tan(----------) + 1
  16. 4
  17. trigint(1/(cos(x)+2),x);
  18. x
  19. tan(---)
  20. 2 - pi + x
  21. 2*sqrt(3)*(atan(----------) + floor(-----------)*pi)
  22. sqrt(3) 2*pi
  23. ------------------------------------------------------
  24. 3
  25. trigint(1/(cos(x)-2),x);
  26. x
  27. 3*tan(---)
  28. 2 - pi + x
  29. - 2*sqrt(3)*(atan(------------) + floor(-----------)*pi)
  30. sqrt(3) 2*pi
  31. -----------------------------------------------------------
  32. 3
  33. trigint(1/(sin(x)),x);
  34. pi + 2*x pi + 2*x
  35. log(tan(----------) - 1) - log(tan(----------) + 1)
  36. 4 4
  37. trigint(1/(sin(x)+2),x);
  38. pi + 2*x
  39. 3*tan(----------)
  40. 4 - pi + 2*x
  41. 2*sqrt(3)*(atan(-------------------) + floor(-------------)*pi)
  42. sqrt(3) 4*pi
  43. -----------------------------------------------------------------
  44. 3
  45. trigint(15/(cos(x)*(5-4*cos(x))),x);
  46. x - pi + x x
  47. 8*atan(3*tan(---)) + 8*floor(-----------)*pi - 3*log(tan(---) - 1)
  48. 2 2*pi 2
  49. x
  50. + 3*log(tan(---) + 1)
  51. 2
  52. trigint(3/(5+4*sin(x)),x);
  53. pi + 2*x - pi + 2*x
  54. 2*(atan(3*tan(----------)) + floor(-------------)*pi)
  55. 4 4*pi
  56. trigint(3/(5-4*cos(x)),x);
  57. x - pi + x
  58. 2*(atan(3*tan(---)) + floor(-----------)*pi)
  59. 2 2*pi
  60. trigint(tan(x),x);
  61. x
  62. 2*atan(tan(---))*tan(x)
  63. 2
  64. %trigint(sqrt(cos(x)),x);
  65. on tracetrig;
  66. trigint(1/(cos(x)-5),x);
  67. x
  68. 3*tan(---)
  69. 2 - pi + x
  70. - sqrt(6)*(atan(------------) + floor(-----------)*pi)
  71. sqrt(6) 2*pi
  72. ---------------------------------------------------------
  73. 6
  74. trigint(1/(sqrt(sin(x))),x);
  75. failed with substitution B: system could not
  76. integrate after subs, trying A
  77. failed with A: trying C now
  78. failed with C: trying D now
  79. trying all possible substitutions
  80. ***** system can't integrate after
  81. subs
  82. end;
  83. Time for test: 31649 ms, plus GC time: 550 ms