passagemath-repl 10.5.27__py3-none-any.whl → 10.5.29__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (96) hide show
  1. passagemath_repl-10.5.29.data/data/share/jupyter/kernels/sagemath/kernel.json +1 -0
  2. passagemath_repl-10.5.29.data/data/share/jupyter/kernels/sagemath/logo-64x64.png +0 -0
  3. passagemath_repl-10.5.29.data/data/share/jupyter/kernels/sagemath/logo.svg +352 -0
  4. {passagemath_repl-10.5.27.dist-info → passagemath_repl-10.5.29.dist-info}/METADATA +38 -13
  5. {passagemath_repl-10.5.27.dist-info → passagemath_repl-10.5.29.dist-info}/RECORD +95 -24
  6. {passagemath_repl-10.5.27.dist-info → passagemath_repl-10.5.29.dist-info}/top_level.txt +1 -0
  7. sage/ext_data/all__sagemath_repl.py +1 -0
  8. sage/interfaces/all__sagemath_repl.py +1 -0
  9. sage/repl/ipython_kernel/install.py +6 -8
  10. sage/tests/books/__init__.py +2 -0
  11. sage/tests/books/computational-mathematics-with-sagemath/__init__.py +1 -0
  12. sage/tests/books/computational-mathematics-with-sagemath/calculus_doctest.py +549 -0
  13. sage/tests/books/computational-mathematics-with-sagemath/combinat_doctest.py +1053 -0
  14. sage/tests/books/computational-mathematics-with-sagemath/domaines_doctest.py +443 -0
  15. sage/tests/books/computational-mathematics-with-sagemath/float_doctest.py +477 -0
  16. sage/tests/books/computational-mathematics-with-sagemath/graphique_doctest.py +254 -0
  17. sage/tests/books/computational-mathematics-with-sagemath/graphtheory_doctest.py +418 -0
  18. sage/tests/books/computational-mathematics-with-sagemath/integration_doctest.py +290 -0
  19. sage/tests/books/computational-mathematics-with-sagemath/linalg_doctest.py +454 -0
  20. sage/tests/books/computational-mathematics-with-sagemath/linsolve_doctest.py +421 -0
  21. sage/tests/books/computational-mathematics-with-sagemath/lp_doctest.py +234 -0
  22. sage/tests/books/computational-mathematics-with-sagemath/mpoly_doctest.py +560 -0
  23. sage/tests/books/computational-mathematics-with-sagemath/nonlinear_doctest.py +490 -0
  24. sage/tests/books/computational-mathematics-with-sagemath/numbertheory_doctest.py +155 -0
  25. sage/tests/books/computational-mathematics-with-sagemath/polynomes_doctest.py +405 -0
  26. sage/tests/books/computational-mathematics-with-sagemath/premierspas_doctest.py +180 -0
  27. sage/tests/books/computational-mathematics-with-sagemath/programmation_doctest.py +662 -0
  28. sage/tests/books/computational-mathematics-with-sagemath/recequadiff_doctest.py +392 -0
  29. sage/tests/books/computational-mathematics-with-sagemath/sol/__init__.py +1 -0
  30. sage/tests/books/computational-mathematics-with-sagemath/sol/calculus_doctest.py +264 -0
  31. sage/tests/books/computational-mathematics-with-sagemath/sol/combinat_doctest.py +217 -0
  32. sage/tests/books/computational-mathematics-with-sagemath/sol/domaines_doctest.py +59 -0
  33. sage/tests/books/computational-mathematics-with-sagemath/sol/float_doctest.py +141 -0
  34. sage/tests/books/computational-mathematics-with-sagemath/sol/graphique_doctest.py +105 -0
  35. sage/tests/books/computational-mathematics-with-sagemath/sol/graphtheory_doctest.py +53 -0
  36. sage/tests/books/computational-mathematics-with-sagemath/sol/integration_doctest.py +56 -0
  37. sage/tests/books/computational-mathematics-with-sagemath/sol/linalg_doctest.py +56 -0
  38. sage/tests/books/computational-mathematics-with-sagemath/sol/linsolve_doctest.py +25 -0
  39. sage/tests/books/computational-mathematics-with-sagemath/sol/lp_doctest.py +47 -0
  40. sage/tests/books/computational-mathematics-with-sagemath/sol/mpoly_doctest.py +115 -0
  41. sage/tests/books/computational-mathematics-with-sagemath/sol/nonlinear_doctest.py +111 -0
  42. sage/tests/books/computational-mathematics-with-sagemath/sol/numbertheory_doctest.py +167 -0
  43. sage/tests/books/computational-mathematics-with-sagemath/sol/polynomes_doctest.py +107 -0
  44. sage/tests/books/computational-mathematics-with-sagemath/sol/recequadiff_doctest.py +58 -0
  45. sage/tests/books/judson-abstract-algebra/__init__.py +1 -0
  46. sage/tests/books/judson-abstract-algebra/actions-sage-exercises.py +51 -0
  47. sage/tests/books/judson-abstract-algebra/actions-sage.py +173 -0
  48. sage/tests/books/judson-abstract-algebra/algcodes-sage.py +130 -0
  49. sage/tests/books/judson-abstract-algebra/boolean-sage.py +269 -0
  50. sage/tests/books/judson-abstract-algebra/cosets-sage-exercises.py +87 -0
  51. sage/tests/books/judson-abstract-algebra/cosets-sage.py +170 -0
  52. sage/tests/books/judson-abstract-algebra/crypt-sage.py +151 -0
  53. sage/tests/books/judson-abstract-algebra/cyclic-sage.py +450 -0
  54. sage/tests/books/judson-abstract-algebra/domains-sage.py +163 -0
  55. sage/tests/books/judson-abstract-algebra/fields-sage.py +299 -0
  56. sage/tests/books/judson-abstract-algebra/finite-sage.py +108 -0
  57. sage/tests/books/judson-abstract-algebra/galois-sage.py +484 -0
  58. sage/tests/books/judson-abstract-algebra/groups-sage.py +280 -0
  59. sage/tests/books/judson-abstract-algebra/homomorph-sage-exercises.py +65 -0
  60. sage/tests/books/judson-abstract-algebra/homomorph-sage.py +200 -0
  61. sage/tests/books/judson-abstract-algebra/integers-sage.py +197 -0
  62. sage/tests/books/judson-abstract-algebra/isomorph-sage.py +172 -0
  63. sage/tests/books/judson-abstract-algebra/normal-sage.py +133 -0
  64. sage/tests/books/judson-abstract-algebra/permute-sage.py +319 -0
  65. sage/tests/books/judson-abstract-algebra/poly-sage.py +300 -0
  66. sage/tests/books/judson-abstract-algebra/rings-sage.py +413 -0
  67. sage/tests/books/judson-abstract-algebra/sets-sage.py +163 -0
  68. sage/tests/books/judson-abstract-algebra/struct-sage.py +63 -0
  69. sage/tests/books/judson-abstract-algebra/sylow-sage.py +250 -0
  70. sage/tests/books/judson-abstract-algebra/vect-sage-exercises.py +48 -0
  71. sage/tests/books/judson-abstract-algebra/vect-sage.py +211 -0
  72. sage/tests/memcheck/__init__.py +1 -0
  73. sage/tests/memcheck/run_tests.py +25 -0
  74. sage/tests/memcheck/run_tests_in_valgrind.py +36 -0
  75. sage/tests/memcheck/symbolic_expression.py +12 -0
  76. sage/tests/memcheck/verify_no_leak.py +28 -0
  77. sage/tests/all.py +0 -0
  78. {passagemath_repl-10.5.27.data → passagemath_repl-10.5.29.data}/scripts/sage-cachegrind +0 -0
  79. {passagemath_repl-10.5.27.data → passagemath_repl-10.5.29.data}/scripts/sage-callgrind +0 -0
  80. {passagemath_repl-10.5.27.data → passagemath_repl-10.5.29.data}/scripts/sage-cleaner +0 -0
  81. {passagemath_repl-10.5.27.data → passagemath_repl-10.5.29.data}/scripts/sage-coverage +0 -0
  82. {passagemath_repl-10.5.27.data → passagemath_repl-10.5.29.data}/scripts/sage-eval +0 -0
  83. {passagemath_repl-10.5.27.data → passagemath_repl-10.5.29.data}/scripts/sage-fixdoctests +0 -0
  84. {passagemath_repl-10.5.27.data → passagemath_repl-10.5.29.data}/scripts/sage-inline-fortran +0 -0
  85. {passagemath_repl-10.5.27.data → passagemath_repl-10.5.29.data}/scripts/sage-ipynb2rst +0 -0
  86. {passagemath_repl-10.5.27.data → passagemath_repl-10.5.29.data}/scripts/sage-ipython +0 -0
  87. {passagemath_repl-10.5.27.data → passagemath_repl-10.5.29.data}/scripts/sage-massif +0 -0
  88. {passagemath_repl-10.5.27.data → passagemath_repl-10.5.29.data}/scripts/sage-notebook +0 -0
  89. {passagemath_repl-10.5.27.data → passagemath_repl-10.5.29.data}/scripts/sage-omega +0 -0
  90. {passagemath_repl-10.5.27.data → passagemath_repl-10.5.29.data}/scripts/sage-preparse +0 -0
  91. {passagemath_repl-10.5.27.data → passagemath_repl-10.5.29.data}/scripts/sage-run +0 -0
  92. {passagemath_repl-10.5.27.data → passagemath_repl-10.5.29.data}/scripts/sage-run-cython +0 -0
  93. {passagemath_repl-10.5.27.data → passagemath_repl-10.5.29.data}/scripts/sage-runtests +0 -0
  94. {passagemath_repl-10.5.27.data → passagemath_repl-10.5.29.data}/scripts/sage-startuptime.py +0 -0
  95. {passagemath_repl-10.5.27.data → passagemath_repl-10.5.29.data}/scripts/sage-valgrind +0 -0
  96. {passagemath_repl-10.5.27.dist-info → passagemath_repl-10.5.29.dist-info}/WHEEL +0 -0
@@ -0,0 +1,290 @@
1
+ # sage_setup: distribution = sagemath-repl
2
+ """
3
+ This file (./integration_doctest.sage) was *autogenerated* from ./integration.tex,
4
+ with sagetex.sty version 2011/05/27 v2.3.1.
5
+ It contains the contents of all the sageexample environments from this file.
6
+ You should be able to doctest this file with:
7
+ sage -t ./integration_doctest.sage
8
+ It is always safe to delete this file; it is not used in typesetting your
9
+ document.
10
+
11
+ Sage example in ./integration.tex, line 73::
12
+
13
+ sage: x = var('x'); f(x) = exp(-x^2) * log(x)
14
+ sage: result = integrate(f, x, 1, 3)
15
+ ...
16
+ sage: N(result) # abs tol 1e-14
17
+ 0.03586029499126769
18
+
19
+ Sage example in ./integration.tex, line 78::
20
+
21
+ sage: plot(f, 1, 3, fill='axis')
22
+ Graphics object consisting of 2 graphics primitives
23
+
24
+ Sage example in ./integration.tex, line 104::
25
+
26
+ sage: N(integrate(sin(x^2)/(x^2), x, 1, infinity)) # abs tol 2e-15
27
+ 0.285736646322853 - 6.93889390390723e-18*I
28
+
29
+ Sage example in ./integration.tex, line 108::
30
+
31
+ sage: plot(sin(x^2)/(x^2), x, 1, 10, fill='axis')
32
+ Graphics object consisting of 2 graphics primitives
33
+
34
+ Sage example in ./integration.tex, line 162::
35
+
36
+ sage: fp = plot(f, 1, 3, color='red')
37
+ sage: n = 4
38
+ sage: interp_points = [(1+2*u/(n-1), N(f(1+2*u/(n-1))))
39
+ ....: for u in range(n)]
40
+ sage: A = PolynomialRing(RR, 'x')
41
+ sage: pp = plot(A.lagrange_polynomial(interp_points), 1, 3, fill='axis')
42
+ sage: fp+pp
43
+ Graphics object consisting of 3 graphics primitives
44
+
45
+ Sage example in ./integration.tex, line 522::
46
+
47
+ sage: N(integrate(cos(log(cos(x))), x, 0, pi/4)) # rel tol 2e-12
48
+ 0.7766520331543109
49
+
50
+ Sage example in ./integration.tex, line 536::
51
+
52
+ sage: integrate(log(1+x)*x, x, 0, 1)
53
+ 1/4
54
+ sage: N(integrate(log(1+x)*x, x, 0, 1))
55
+ 0.250000000000000
56
+
57
+ Sage example in ./integration.tex, line 562::
58
+
59
+ sage: numerical_integral(cos(log(cos(x))), 0, pi/4) # rel tol 2e-11
60
+ (0.7766520331543109, 8.622569693298564e-15)
61
+
62
+ Sage example in ./integration.tex, line 600::
63
+
64
+ sage: numerical_integral(exp(-x^100), 0, 1.1)
65
+ (0.99432585119150..., 4.0775730...e-09)
66
+ sage: numerical_integral(exp(-x^100), 0, 1.1, algorithm='qng') # abs tol 2e-12
67
+ (0.9943275385765319, 0.016840666914705607)
68
+
69
+ Sage example in ./integration.tex, line 612::
70
+
71
+ sage: integrate(cos(log(cos(x))), x, 0, pi/4)
72
+ integrate(cos(log(cos(x))), x, 0, 1/4*pi)
73
+
74
+ Sage example in ./integration.tex, line 622::
75
+
76
+ sage: N(integrate(cos(log(cos(x))), x, 0, pi/4), digits=60) # abs tol 2e-12
77
+ 0.7766520331543109
78
+
79
+ Sage example in ./integration.tex, line 628::
80
+
81
+ sage: N(integrate(sin(x)*exp(cos(x)), x, 0, pi), digits=60)
82
+ 2.35040238728760291376476370119120163031143596266819174045913
83
+
84
+ Sage example in ./integration.tex, line 644::
85
+
86
+ sage: sage.calculus.calculus.nintegral(sin(sin(x)), x, 0, 1)
87
+ (0.430606103120690..., 4.78068810228705...e-15, 21, 0)
88
+
89
+ Sage example in ./integration.tex, line 654::
90
+
91
+ sage: g = sin(sin(x))
92
+ sage: g.nintegral(x, 0, 1)
93
+ (0.430606103120690..., 4.78068810228705...e-15, 21, 0)
94
+
95
+ Ensure consistent results on 32-bit and 64-bit systems by using the same
96
+ precision::
97
+
98
+ sage: _ = gp.default('realprecision', 38)
99
+
100
+ Sage example in ./integration.tex, line 703::
101
+
102
+ sage: gp('intnum(x=17, 20, exp(-x^2)*log(x))')
103
+ 2.5657285005610514829173563961304785900 E-127
104
+
105
+ Sage example in ./integration.tex, line 717::
106
+
107
+ sage: gp('intnum(x=0, 1, sin(sin(x)))')
108
+ 0.43060610312069060491237735524846578643
109
+ sage: old_prec = gp.set_precision(50)
110
+ sage: gp('intnum(x=0, 1, sin(sin(x)))')
111
+ 0.43060610312069060491237735524846578643360804182200
112
+
113
+ Sage example in ./integration.tex, line 746::
114
+
115
+ sage: p = gp.set_precision(old_prec) # we reset the default precision
116
+ sage: gp('intnum(x=0, 1, x^(-99/100))') # rel tol 1e-9
117
+ 73.629142577870966597465391764897770039
118
+
119
+ Sage example in ./integration.tex, line 754::
120
+
121
+ sage: gp('intnum(x=[0, -99/100], 1, x^(-99/100))')
122
+ 100.00000000000000000000000000000000000
123
+
124
+ Sage example in ./integration.tex, line 766::
125
+
126
+ sage: gp('intnum(x=[0, -1/42], 1, x^(-99/100))') # rel tol 1e-9
127
+ 74.472749314025559405335761513474670714
128
+
129
+ Sage example in ./integration.tex, line 785::
130
+
131
+ sage: import mpmath
132
+ sage: mpmath.mp.prec = 53
133
+ sage: mpmath.quad(lambda x: mpmath.sin(mpmath.sin(x)), [0, 1])
134
+ mpf('0.43060610312069059')
135
+
136
+ Sage example in ./integration.tex, line 795::
137
+
138
+ sage: a = RDF(pi); b = mpmath.mpf(a); b
139
+ mpf('3.1415926535897931')
140
+ sage: c = RDF(b); c
141
+ 3.141592653589793
142
+
143
+ Sage example in ./integration.tex, line 824::
144
+
145
+ sage: mpmath.mp.prec = 113
146
+ sage: mpmath.quad(lambda x: mpmath.sin(mpmath.sin(x)), [0, 1])
147
+ mpf('0.430606103120690604912377355248465809')
148
+
149
+ Sage example in ./integration.tex, line 846::
150
+
151
+ sage: f(x) = sin(sin(x))
152
+ sage: mpmath.quad(f, [0, 1])
153
+ Traceback (most recent call last):
154
+ ...
155
+ TypeError: no canonical coercion from <class '...mpf'> to ...
156
+
157
+ Sage example in ./integration.tex, line 866::
158
+
159
+ sage: g(x) = max_symbolic(sin(x), cos(x))
160
+ sage: mpmath.mp.prec = 100
161
+ sage: mpmath.quadts(lambda x: g(N(x, 100)), [0, 1])
162
+ mpf('0.873912416263035435957979086252')
163
+
164
+ Sage example in ./integration.tex, line 878::
165
+
166
+ sage: mpmath.mp.prec = 170
167
+ sage: mpmath.quadts(lambda x: g(N(x, 190)), [0, 1])
168
+ mpf('0.87391090757400975205393005981962476344054148354188794')
169
+ sage: N(sqrt(2) - cos(1), 100)
170
+ 0.87391125650495533140075211677
171
+
172
+ Sage example in ./integration.tex, line 892::
173
+
174
+ sage: mpmath.quadts(lambda x: g(N(x, 170)), [0, mpmath.pi / 4, 1])
175
+ mpf('0.87391125650495533140075211676672147483736145475902551')
176
+
177
+ Sage example in ./integration.tex, line 979::
178
+
179
+ sage: y = var('y'); integrate(exp(y*sin(x)), (x, 0, sqrt(y))) # long time
180
+ integrate(e^(y*sin(x)), x, 0, sqrt(y))
181
+
182
+ Sage example in ./integration.tex, line 990::
183
+
184
+ sage: f = lambda y: numerical_integral(lambda x: exp(y*sin(x)), \
185
+ ....: 0, sqrt(y))[0]
186
+ sage: f(0.0), f(0.5), f(1.0) # abs tol 2e-15
187
+ (0.0, 0.8414895067661431, 1.6318696084180513)
188
+
189
+ Sage example in ./integration.tex, line 998::
190
+
191
+ sage: numerical_integral(f, 0, 1) # abs tol 2e-16
192
+ (0.8606791942204567, 6.301207560882073e-07)
193
+
194
+ Sage example in ./integration.tex, line 1008::
195
+
196
+ sage: f = lambda y: sage.calculus.calculus.nintegral(exp(y*sin(x)), \
197
+ ....: x, 0, sqrt(y))[0]
198
+ sage: numerical_integral(f, 0, 1) # abs tol 2e-16
199
+ (0.8606791942204567, 6.301207560882096e-07)
200
+
201
+ Sage example in ./integration.tex, line 1016::
202
+
203
+ sage: f = lambda y: RDF(mpmath.quad(lambda x: mpmath.exp(y*mpmath.sin(x)), \
204
+ ....: [0, sqrt(y)]))
205
+ sage: numerical_integral(f, 0, 1) # abs tol 2e-16
206
+ (0.8606791942204567, 6.301207561187562e-07)
207
+
208
+ Sage example in ./integration.tex, line 1027::
209
+
210
+ sage: mpmath.mp.dps = 60
211
+ sage: f = lambda x, y: mpmath.exp(y*mpmath.sin(x))
212
+ sage: mpmath.quad(f, [0,1], [0,1])
213
+ mpf('1.28392205755238471754385917646324675741664250325189751108716305')
214
+
215
+ Sage example in ./integration.tex, line 1044::
216
+
217
+ sage: def evalI(n):
218
+ ....: f = lambda y: numerical_integral(lambda x: exp(y*sin(x)),
219
+ ....: 0, sqrt(y), algorithm='qng', max_points=n)[0]
220
+ ....: return numerical_integral(f, 0, 1, algorithm='qng', max_points=n)
221
+ sage: evalI(100) # abs tol 2e-12
222
+ (0.8606792028826138, 5.553962923506737e-07)
223
+
224
+ Sage example in ./integration.tex, line 1228::
225
+
226
+ sage: T = ode_solver()
227
+
228
+ Sage example in ./integration.tex, line 1244::
229
+
230
+ sage: def f_1(t, y, params): return [y[1],params[0]*(1-y[0]^2)*y[1]-y[0]]
231
+ sage: T.function = f_1
232
+
233
+ Sage example in ./integration.tex, line 1266::
234
+
235
+ sage: def j_1(t, y, params):
236
+ ....: return [[0, 1],
237
+ ....: [-2*params[0]*y[0]*y[1]-1, params[0]*(1-y[0]^2)],
238
+ ....: [0,0]]
239
+ sage: T.jacobian = j_1
240
+
241
+ Sage example in ./integration.tex, line 1279::
242
+
243
+ sage: T.algorithm = "rk8pd"
244
+ sage: T.ode_solve(y_0=[1,0], t_span=[0,100], params=[10],
245
+ ....: num_points=1000)
246
+ sage: f = T.interpolate_solution()
247
+
248
+ Sage example in ./integration.tex, line 1302::
249
+
250
+ sage: plot(f, 0, 100)
251
+ Graphics object consisting of 1 graphics primitive
252
+
253
+ Sage example in ./integration.tex, line 1363::
254
+
255
+ sage: t, y = var('t, y')
256
+ sage: desolve_rk4(t*y*(2-y), y, ics=[0,1], end_points=[0, 1], step=0.5) # abs tol 1e-12
257
+ [[0, 1], [0.5, 1.12419127424558], [1.0, 1.461590162288825]]
258
+
259
+ Sage example in ./integration.tex, line 1399::
260
+
261
+ sage: import mpmath
262
+ sage: mpmath.mp.prec = 53
263
+ sage: sol = mpmath.odefun(lambda t, y: y, 0, 1)
264
+ sage: sol(1)
265
+ mpf('2.7182818284590451')
266
+ sage: mpmath.mp.prec = 100
267
+ sage: sol(1)
268
+ mpf('2.7182818284590452353602874802307')
269
+ sage: N(exp(1), 100)
270
+ 2.7182818284590452353602874714
271
+
272
+ Sage example in ./integration.tex, line 1436::
273
+
274
+ sage: mpmath.mp.prec = 53
275
+ sage: f = mpmath.odefun(lambda t, y: [-y[1], y[0]], 0, [1, 0])
276
+ sage: f(3)
277
+ [mpf('-0.98999249660044542'), mpf('0.14112000805986721')]
278
+ sage: (cos(3.), sin(3.))
279
+ (-0.989992496600445, 0.141120008059867)
280
+
281
+ Sage example in ./integration.tex, line 1497::
282
+
283
+ sage: mpmath.mp.prec = 10
284
+ sage: sol = mpmath.odefun(lambda t, y: y, 0, 1)
285
+ sage: sol(1)
286
+ mpf('2.7148')
287
+ sage: mpmath.mp.prec = 100
288
+ sage: sol(1)
289
+ mpf('2.7135204235459511323824699502438')
290
+ """