passagemath-symbolics 10.6.40__cp314-cp314t-macosx_13_0_x86_64.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.

Potentially problematic release.


This version of passagemath-symbolics might be problematic. Click here for more details.

Files changed (172) hide show
  1. passagemath_symbolics/.dylibs/libgmp.10.dylib +0 -0
  2. passagemath_symbolics/__init__.py +3 -0
  3. passagemath_symbolics-10.6.40.dist-info/METADATA +187 -0
  4. passagemath_symbolics-10.6.40.dist-info/RECORD +172 -0
  5. passagemath_symbolics-10.6.40.dist-info/WHEEL +6 -0
  6. passagemath_symbolics-10.6.40.dist-info/top_level.txt +3 -0
  7. sage/all__sagemath_symbolics.py +17 -0
  8. sage/calculus/all.py +14 -0
  9. sage/calculus/calculus.py +2826 -0
  10. sage/calculus/desolvers.py +1866 -0
  11. sage/calculus/predefined.py +51 -0
  12. sage/calculus/tests.py +225 -0
  13. sage/calculus/var.cpython-314t-darwin.so +0 -0
  14. sage/calculus/var.pyx +401 -0
  15. sage/dynamics/all__sagemath_symbolics.py +6 -0
  16. sage/dynamics/complex_dynamics/all.py +5 -0
  17. sage/dynamics/complex_dynamics/mandel_julia.py +765 -0
  18. sage/dynamics/complex_dynamics/mandel_julia_helper.cpython-314t-darwin.so +0 -0
  19. sage/dynamics/complex_dynamics/mandel_julia_helper.pyx +1035 -0
  20. sage/ext/all__sagemath_symbolics.py +1 -0
  21. sage/ext_data/kenzo/CP2.txt +45 -0
  22. sage/ext_data/kenzo/CP3.txt +349 -0
  23. sage/ext_data/kenzo/CP4.txt +4774 -0
  24. sage/ext_data/kenzo/README.txt +49 -0
  25. sage/ext_data/kenzo/S4.txt +20 -0
  26. sage/ext_data/magma/latex/latex.m +1021 -0
  27. sage/ext_data/magma/latex/latex.spec +1 -0
  28. sage/ext_data/magma/sage/basic.m +356 -0
  29. sage/ext_data/magma/sage/sage.spec +1 -0
  30. sage/ext_data/magma/spec +9 -0
  31. sage/geometry/all__sagemath_symbolics.py +8 -0
  32. sage/geometry/hyperbolic_space/all.py +5 -0
  33. sage/geometry/hyperbolic_space/hyperbolic_coercion.py +743 -0
  34. sage/geometry/hyperbolic_space/hyperbolic_constants.py +5 -0
  35. sage/geometry/hyperbolic_space/hyperbolic_geodesic.py +2409 -0
  36. sage/geometry/hyperbolic_space/hyperbolic_interface.py +206 -0
  37. sage/geometry/hyperbolic_space/hyperbolic_isometry.py +1082 -0
  38. sage/geometry/hyperbolic_space/hyperbolic_model.py +1502 -0
  39. sage/geometry/hyperbolic_space/hyperbolic_point.py +621 -0
  40. sage/geometry/riemannian_manifolds/all.py +7 -0
  41. sage/geometry/riemannian_manifolds/parametrized_surface3d.py +1632 -0
  42. sage/geometry/riemannian_manifolds/surface3d_generators.py +461 -0
  43. sage/interfaces/all__sagemath_symbolics.py +1 -0
  44. sage/interfaces/magma.py +3017 -0
  45. sage/interfaces/magma_free.py +92 -0
  46. sage/interfaces/maple.py +1397 -0
  47. sage/interfaces/mathematica.py +1345 -0
  48. sage/interfaces/mathics.py +1312 -0
  49. sage/interfaces/sympy.py +1398 -0
  50. sage/interfaces/sympy_wrapper.py +197 -0
  51. sage/interfaces/tides.py +938 -0
  52. sage/libs/all__sagemath_symbolics.py +6 -0
  53. sage/manifolds/all.py +7 -0
  54. sage/manifolds/calculus_method.py +555 -0
  55. sage/manifolds/catalog.py +437 -0
  56. sage/manifolds/chart.py +4019 -0
  57. sage/manifolds/chart_func.py +3419 -0
  58. sage/manifolds/continuous_map.py +2183 -0
  59. sage/manifolds/continuous_map_image.py +155 -0
  60. sage/manifolds/differentiable/affine_connection.py +2475 -0
  61. sage/manifolds/differentiable/all.py +1 -0
  62. sage/manifolds/differentiable/automorphismfield.py +1383 -0
  63. sage/manifolds/differentiable/automorphismfield_group.py +604 -0
  64. sage/manifolds/differentiable/bundle_connection.py +1445 -0
  65. sage/manifolds/differentiable/characteristic_cohomology_class.py +1840 -0
  66. sage/manifolds/differentiable/chart.py +1241 -0
  67. sage/manifolds/differentiable/curve.py +1028 -0
  68. sage/manifolds/differentiable/de_rham_cohomology.py +541 -0
  69. sage/manifolds/differentiable/degenerate.py +559 -0
  70. sage/manifolds/differentiable/degenerate_submanifold.py +1671 -0
  71. sage/manifolds/differentiable/diff_form.py +1658 -0
  72. sage/manifolds/differentiable/diff_form_module.py +1062 -0
  73. sage/manifolds/differentiable/diff_map.py +1315 -0
  74. sage/manifolds/differentiable/differentiable_submanifold.py +291 -0
  75. sage/manifolds/differentiable/examples/all.py +1 -0
  76. sage/manifolds/differentiable/examples/euclidean.py +2517 -0
  77. sage/manifolds/differentiable/examples/real_line.py +897 -0
  78. sage/manifolds/differentiable/examples/sphere.py +1186 -0
  79. sage/manifolds/differentiable/examples/symplectic_space.py +187 -0
  80. sage/manifolds/differentiable/examples/symplectic_space_test.py +40 -0
  81. sage/manifolds/differentiable/integrated_curve.py +4035 -0
  82. sage/manifolds/differentiable/levi_civita_connection.py +841 -0
  83. sage/manifolds/differentiable/manifold.py +4254 -0
  84. sage/manifolds/differentiable/manifold_homset.py +1826 -0
  85. sage/manifolds/differentiable/metric.py +3032 -0
  86. sage/manifolds/differentiable/mixed_form.py +1507 -0
  87. sage/manifolds/differentiable/mixed_form_algebra.py +559 -0
  88. sage/manifolds/differentiable/multivector_module.py +800 -0
  89. sage/manifolds/differentiable/multivectorfield.py +1520 -0
  90. sage/manifolds/differentiable/poisson_tensor.py +268 -0
  91. sage/manifolds/differentiable/pseudo_riemannian.py +755 -0
  92. sage/manifolds/differentiable/pseudo_riemannian_submanifold.py +1839 -0
  93. sage/manifolds/differentiable/scalarfield.py +1343 -0
  94. sage/manifolds/differentiable/scalarfield_algebra.py +472 -0
  95. sage/manifolds/differentiable/symplectic_form.py +910 -0
  96. sage/manifolds/differentiable/symplectic_form_test.py +220 -0
  97. sage/manifolds/differentiable/tangent_space.py +412 -0
  98. sage/manifolds/differentiable/tangent_vector.py +616 -0
  99. sage/manifolds/differentiable/tensorfield.py +4665 -0
  100. sage/manifolds/differentiable/tensorfield_module.py +963 -0
  101. sage/manifolds/differentiable/tensorfield_paral.py +2450 -0
  102. sage/manifolds/differentiable/tensorfield_paral_test.py +16 -0
  103. sage/manifolds/differentiable/vector_bundle.py +1728 -0
  104. sage/manifolds/differentiable/vectorfield.py +1717 -0
  105. sage/manifolds/differentiable/vectorfield_module.py +2445 -0
  106. sage/manifolds/differentiable/vectorframe.py +1832 -0
  107. sage/manifolds/family.py +270 -0
  108. sage/manifolds/local_frame.py +1490 -0
  109. sage/manifolds/manifold.py +3090 -0
  110. sage/manifolds/manifold_homset.py +452 -0
  111. sage/manifolds/operators.py +359 -0
  112. sage/manifolds/point.py +994 -0
  113. sage/manifolds/scalarfield.py +3718 -0
  114. sage/manifolds/scalarfield_algebra.py +629 -0
  115. sage/manifolds/section.py +3111 -0
  116. sage/manifolds/section_module.py +831 -0
  117. sage/manifolds/structure.py +229 -0
  118. sage/manifolds/subset.py +2764 -0
  119. sage/manifolds/subsets/all.py +1 -0
  120. sage/manifolds/subsets/closure.py +131 -0
  121. sage/manifolds/subsets/pullback.py +885 -0
  122. sage/manifolds/topological_submanifold.py +891 -0
  123. sage/manifolds/trivialization.py +733 -0
  124. sage/manifolds/utilities.py +1348 -0
  125. sage/manifolds/vector_bundle.py +1342 -0
  126. sage/manifolds/vector_bundle_fiber.py +332 -0
  127. sage/manifolds/vector_bundle_fiber_element.py +111 -0
  128. sage/matrix/all__sagemath_symbolics.py +1 -0
  129. sage/matrix/matrix_symbolic_dense.cpython-314t-darwin.so +0 -0
  130. sage/matrix/matrix_symbolic_dense.pxd +6 -0
  131. sage/matrix/matrix_symbolic_dense.pyx +1022 -0
  132. sage/matrix/matrix_symbolic_sparse.cpython-314t-darwin.so +0 -0
  133. sage/matrix/matrix_symbolic_sparse.pxd +6 -0
  134. sage/matrix/matrix_symbolic_sparse.pyx +1029 -0
  135. sage/modules/all__sagemath_symbolics.py +1 -0
  136. sage/modules/vector_callable_symbolic_dense.py +105 -0
  137. sage/modules/vector_symbolic_dense.py +116 -0
  138. sage/modules/vector_symbolic_sparse.py +118 -0
  139. sage/rings/all__sagemath_symbolics.py +4 -0
  140. sage/rings/asymptotic/all.py +6 -0
  141. sage/rings/asymptotic/asymptotic_expansion_generators.py +1485 -0
  142. sage/rings/asymptotic/asymptotic_ring.py +4858 -0
  143. sage/rings/asymptotic/asymptotics_multivariate_generating_functions.py +4153 -0
  144. sage/rings/asymptotic/growth_group.py +5373 -0
  145. sage/rings/asymptotic/growth_group_cartesian.py +1400 -0
  146. sage/rings/asymptotic/term_monoid.py +5237 -0
  147. sage/rings/function_field/all__sagemath_symbolics.py +2 -0
  148. sage/rings/polynomial/all__sagemath_symbolics.py +1 -0
  149. sage/symbolic/all.py +15 -0
  150. sage/symbolic/assumptions.py +985 -0
  151. sage/symbolic/benchmark.py +93 -0
  152. sage/symbolic/callable.py +459 -0
  153. sage/symbolic/complexity_measures.py +35 -0
  154. sage/symbolic/constants.py +1287 -0
  155. sage/symbolic/expression_conversion_algebraic.py +310 -0
  156. sage/symbolic/expression_conversion_sympy.py +317 -0
  157. sage/symbolic/expression_conversions.py +1713 -0
  158. sage/symbolic/function_factory.py +355 -0
  159. sage/symbolic/integration/all.py +1 -0
  160. sage/symbolic/integration/external.py +270 -0
  161. sage/symbolic/integration/integral.py +1115 -0
  162. sage/symbolic/maxima_wrapper.py +162 -0
  163. sage/symbolic/operators.py +267 -0
  164. sage/symbolic/random_tests.py +462 -0
  165. sage/symbolic/relation.py +1907 -0
  166. sage/symbolic/ring.cpython-314t-darwin.so +0 -0
  167. sage/symbolic/ring.pxd +5 -0
  168. sage/symbolic/ring.pyx +1396 -0
  169. sage/symbolic/subring.py +1025 -0
  170. sage/symbolic/symengine.py +19 -0
  171. sage/symbolic/tests.py +40 -0
  172. sage/symbolic/units.py +1470 -0
@@ -0,0 +1,359 @@
1
+ # sage_setup: distribution = sagemath-symbolics
2
+ r"""
3
+ Operators for vector calculus
4
+
5
+ This module defines the following operators for scalar, vector and tensor
6
+ fields on any pseudo-Riemannian manifold (see
7
+ :mod:`~sage.manifolds.differentiable.pseudo_riemannian`), and in particular
8
+ on Euclidean spaces (see :mod:`~sage.manifolds.differentiable.examples.euclidean`):
9
+
10
+ - :func:`grad`: gradient of a scalar field
11
+ - :func:`div`: divergence of a vector field, and more generally of a tensor
12
+ field
13
+ - :func:`curl`: curl of a vector field (3-dimensional case only)
14
+ - :func:`laplacian`: Laplace-Beltrami operator acting on a scalar field, a
15
+ vector field, or more generally a tensor field
16
+ - :func:`dalembertian`: d'Alembert operator acting on a scalar field, a
17
+ vector field, or more generally a tensor field, on a Lorentzian manifold
18
+
19
+ All these operators are implemented as functions that call the appropriate
20
+ method on their argument. The purpose is to allow one to use standard
21
+ mathematical notations, e.g. to write ``curl(v)`` instead of ``v.curl()``.
22
+
23
+ Note that the :func:`~sage.misc.functional.norm` operator is defined in the
24
+ module :mod:`~sage.misc.functional`.
25
+
26
+ .. SEEALSO::
27
+
28
+ Examples 1 and 2 in :mod:`~sage.manifolds.differentiable.examples.euclidean`
29
+ for examples involving these operators in the Euclidean plane and in the
30
+ Euclidean 3-space.
31
+
32
+ AUTHORS:
33
+
34
+ - Eric Gourgoulhon (2018): initial version
35
+ """
36
+
37
+ # *****************************************************************************
38
+ # Copyright (C) 2018 Eric Gourgoulhon <eric.gourgoulhon@obspm.fr>
39
+ #
40
+ # This program is free software: you can redistribute it and/or modify
41
+ # it under the terms of the GNU General Public License as published by
42
+ # the Free Software Foundation, either version 2 of the License, or
43
+ # (at your option) any later version.
44
+ # http://www.gnu.org/licenses/
45
+ # *****************************************************************************
46
+
47
+
48
+ def grad(scalar):
49
+ r"""
50
+ Gradient operator.
51
+
52
+ The *gradient* of a scalar field `f` on a pseudo-Riemannian manifold
53
+ `(M,g)` is the vector field `\mathrm{grad}\, f` whose components in any
54
+ coordinate frame are
55
+
56
+ .. MATH::
57
+
58
+ (\mathrm{grad}\, f)^i = g^{ij} \frac{\partial F}{\partial x^j}
59
+
60
+ where the `x^j`'s are the coordinates with respect to which the
61
+ frame is defined and `F` is the chart function representing `f` in
62
+ these coordinates: `f(p) = F(x^1(p),\ldots,x^n(p))` for any point `p`
63
+ in the chart domain.
64
+ In other words, the gradient of `f` is the vector field that is the
65
+ `g`-dual of the differential of `f`.
66
+
67
+ INPUT:
68
+
69
+ - ``scalar`` -- scalar field `f`, as an instance of
70
+ :class:`~sage.manifolds.differentiable.scalarfield.DiffScalarField`
71
+
72
+ OUTPUT:
73
+
74
+ - instance of
75
+ :class:`~sage.manifolds.differentiable.vectorfield.VectorField`
76
+ representing `\mathrm{grad}\, f`
77
+
78
+ EXAMPLES:
79
+
80
+ Gradient of a scalar field in the Euclidean plane::
81
+
82
+ sage: E.<x,y> = EuclideanSpace()
83
+ sage: f = E.scalar_field(sin(x*y), name='f')
84
+ sage: from sage.manifolds.operators import grad
85
+ sage: grad(f)
86
+ Vector field grad(f) on the Euclidean plane E^2
87
+ sage: grad(f).display()
88
+ grad(f) = y*cos(x*y) e_x + x*cos(x*y) e_y
89
+ sage: grad(f)[:]
90
+ [y*cos(x*y), x*cos(x*y)]
91
+
92
+ See the method
93
+ :meth:`~sage.manifolds.differentiable.scalarfield.DiffScalarField.gradient`
94
+ of :class:`~sage.manifolds.differentiable.scalarfield.DiffScalarField` for
95
+ more details and examples.
96
+ """
97
+ return scalar.gradient()
98
+
99
+
100
+ def div(tensor):
101
+ r"""
102
+ Divergence operator.
103
+
104
+ Let `t` be a tensor field of type `(k,0)` with `k\geq 1` on a
105
+ pseudo-Riemannian manifold `(M, g)`. The *divergence* of `t` is the tensor
106
+ field of type `(k-1,0)` defined by
107
+
108
+ .. MATH::
109
+
110
+ (\mathrm{div}\, t)^{a_1\ldots a_{k-1}} =
111
+ \nabla_i t^{a_1\ldots a_{k-1} i} =
112
+ (\nabla t)^{a_1\ldots a_{k-1} i}_{\phantom{a_1\ldots a_{k-1} i}\, i}
113
+
114
+ where `\nabla` is the Levi-Civita connection of `g` (cf.
115
+ :class:`~sage.manifolds.differentiable.levi_civita_connection.LeviCivitaConnection`).
116
+
117
+ Note that the divergence is taken on the *last* index of the tensor field.
118
+ This definition is extended to tensor fields of type `(k,l)` with
119
+ `k\geq 0` and `l\geq 1`, by raising the last index with the metric `g`:
120
+ `\mathrm{div}\, t` is then the tensor field of type `(k,l-1)` defined by
121
+
122
+ .. MATH::
123
+
124
+ (\mathrm{div}\, t)^{a_1\ldots a_k}_{\phantom{a_1\ldots a_k}\, b_1\ldots b_{l-1}}
125
+ = \nabla_i (g^{ij} t^{a_1\ldots a_k}_{\phantom{a_1\ldots a_k}\, b_1\ldots b_{l-1} j})
126
+ = (\nabla t^\sharp)^{a_1\ldots a_k i}_{\phantom{a_1\ldots a_k i}\, b_1\ldots b_{l-1} i}
127
+
128
+ where `t^\sharp` is the tensor field deduced from `t` by raising the
129
+ last index with the metric `g` (see
130
+ :meth:`~sage.manifolds.differentiable.tensorfield.TensorField.up`).
131
+
132
+ INPUT:
133
+
134
+ - ``tensor`` -- tensor field `t` on a pseudo-Riemannian manifold `(M,g)`,
135
+ as an instance of
136
+ :class:`~sage.manifolds.differentiable.tensorfield.TensorField` (possibly
137
+ via one of its derived classes, like
138
+ :class:`~sage.manifolds.differentiable.vectorfield.VectorField`)
139
+
140
+ OUTPUT:
141
+
142
+ - the divergence of ``tensor`` as an instance of either
143
+ :class:`~sage.manifolds.differentiable.scalarfield.DiffScalarField`
144
+ if `(k,l)=(1,0)` (``tensor`` is a vector field) or `(k,l)=(0,1)`
145
+ (``tensor`` is a 1-form) or of
146
+ :class:`~sage.manifolds.differentiable.tensorfield.TensorField`
147
+ if `k+l\geq 2`
148
+
149
+ EXAMPLES:
150
+
151
+ Divergence of a vector field in the Euclidean plane::
152
+
153
+ sage: E.<x,y> = EuclideanSpace()
154
+ sage: v = E.vector_field(cos(x*y), sin(x*y), name='v')
155
+ sage: v.display()
156
+ v = cos(x*y) e_x + sin(x*y) e_y
157
+ sage: from sage.manifolds.operators import div
158
+ sage: s = div(v); s
159
+ Scalar field div(v) on the Euclidean plane E^2
160
+ sage: s.display()
161
+ div(v): E^2 → ℝ
162
+ (x, y) ↦ x*cos(x*y) - y*sin(x*y)
163
+ sage: s.expr()
164
+ x*cos(x*y) - y*sin(x*y)
165
+
166
+ See the method
167
+ :meth:`~sage.manifolds.differentiable.tensorfield.TensorField.divergence`
168
+ of :class:`~sage.manifolds.differentiable.tensorfield.TensorField` for
169
+ more details and examples.
170
+ """
171
+ return tensor.divergence()
172
+
173
+
174
+ def curl(vector):
175
+ r"""
176
+ Curl operator.
177
+
178
+ The *curl* of a vector field `v` on an orientable pseudo-Riemannian
179
+ manifold `(M,g)` of dimension 3 is the vector field defined by
180
+
181
+ .. MATH::
182
+
183
+ \mathrm{curl}\, v = (*(\mathrm{d} v^\flat))^\sharp
184
+
185
+ where `v^\flat` is the 1-form associated to `v` by the metric `g` (see
186
+ :meth:`~sage.manifolds.differentiable.tensorfield.TensorField.down`),
187
+ `*(\mathrm{d} v^\flat)` is the Hodge dual with respect to `g` of the
188
+ 2-form `\mathrm{d} v^\flat` (exterior derivative of `v^\flat`) (see
189
+ :meth:`~sage.manifolds.differentiable.diff_form.DiffForm.hodge_dual`)
190
+ and
191
+ `(*(\mathrm{d} v^\flat))^\sharp` is corresponding vector field by
192
+ `g`-duality (see
193
+ :meth:`~sage.manifolds.differentiable.tensorfield.TensorField.up`).
194
+
195
+ An alternative expression of the curl is
196
+
197
+ .. MATH::
198
+
199
+ (\mathrm{curl}\, v)^i = \epsilon^{ijk} \nabla_j v_k
200
+
201
+ where `\nabla` is the Levi-Civita connection of `g` (cf.
202
+ :class:`~sage.manifolds.differentiable.levi_civita_connection.LeviCivitaConnection`)
203
+ and `\epsilon` the volume 3-form (Levi-Civita tensor) of `g` (cf.
204
+ :meth:`~sage.manifolds.differentiable.metric.PseudoRiemannianMetric.volume_form`)
205
+
206
+ INPUT:
207
+
208
+ - ``vector`` -- vector field on an orientable 3-dimensional
209
+ pseudo-Riemannian manifold, as an instance of
210
+ :class:`~sage.manifolds.differentiable.vectorfield.VectorField`
211
+
212
+ OUTPUT:
213
+
214
+ - instance of
215
+ :class:`~sage.manifolds.differentiable.vectorfield.VectorField`
216
+ representing the curl of ``vector``
217
+
218
+ EXAMPLES:
219
+
220
+ Curl of a vector field in the Euclidean 3-space::
221
+
222
+ sage: E.<x,y,z> = EuclideanSpace()
223
+ sage: v = E.vector_field(sin(y), sin(x), 0, name='v')
224
+ sage: v.display()
225
+ v = sin(y) e_x + sin(x) e_y
226
+ sage: from sage.manifolds.operators import curl
227
+ sage: s = curl(v); s
228
+ Vector field curl(v) on the Euclidean space E^3
229
+ sage: s.display()
230
+ curl(v) = (cos(x) - cos(y)) e_z
231
+ sage: s[:]
232
+ [0, 0, cos(x) - cos(y)]
233
+
234
+ See the method
235
+ :meth:`~sage.manifolds.differentiable.vectorfield.VectorField.curl`
236
+ of :class:`~sage.manifolds.differentiable.vectorfield.VectorField` for more
237
+ details and examples.
238
+ """
239
+ return vector.curl()
240
+
241
+
242
+ def laplacian(field):
243
+ r"""
244
+ Laplace-Beltrami operator.
245
+
246
+ The *Laplace-Beltrami operator* on a pseudo-Riemannian manifold `(M,g)`
247
+ is the operator
248
+
249
+ .. MATH::
250
+
251
+ \Delta = \nabla_i \nabla^i = g^{ij} \nabla_i \nabla_j
252
+
253
+ where `\nabla` is the Levi-Civita connection of the metric `g` (cf.
254
+ :class:`~sage.manifolds.differentiable.levi_civita_connection.LeviCivitaConnection`)
255
+ and `\nabla^i := g^{ij} \nabla_j`
256
+
257
+ INPUT:
258
+
259
+ - ``field`` -- a scalar field `f` (instance of
260
+ :class:`~sage.manifolds.differentiable.scalarfield.DiffScalarField`) or a
261
+ tensor field `f` (instance of
262
+ :class:`~sage.manifolds.differentiable.tensorfield.TensorField`) on a
263
+ pseudo-Riemannian manifold
264
+
265
+ OUTPUT:
266
+
267
+ - `\Delta f`, as an instance of
268
+ :class:`~sage.manifolds.differentiable.scalarfield.DiffScalarField` or of
269
+ :class:`~sage.manifolds.differentiable.tensorfield.TensorField`
270
+
271
+ EXAMPLES:
272
+
273
+ Laplacian of a scalar field on the Euclidean plane::
274
+
275
+ sage: E.<x,y> = EuclideanSpace()
276
+ sage: f = E.scalar_field(sin(x*y), name='f')
277
+ sage: from sage.manifolds.operators import laplacian
278
+ sage: Df = laplacian(f); Df
279
+ Scalar field Delta(f) on the Euclidean plane E^2
280
+ sage: Df.display()
281
+ Delta(f): E^2 → ℝ
282
+ (x, y) ↦ -(x^2 + y^2)*sin(x*y)
283
+ sage: Df.expr()
284
+ -(x^2 + y^2)*sin(x*y)
285
+
286
+ The Laplacian of a scalar field is the divergence of its gradient::
287
+
288
+ sage: from sage.manifolds.operators import div, grad
289
+ sage: Df == div(grad(f))
290
+ True
291
+
292
+ See the method
293
+ :meth:`~sage.manifolds.differentiable.scalarfield.DiffScalarField.laplacian`
294
+ of :class:`~sage.manifolds.differentiable.scalarfield.DiffScalarField` and
295
+ the method
296
+ :meth:`~sage.manifolds.differentiable.tensorfield.TensorField.laplacian`
297
+ of :class:`~sage.manifolds.differentiable.tensorfield.TensorField` for
298
+ more details and examples.
299
+ """
300
+ return field.laplacian()
301
+
302
+
303
+ def dalembertian(field):
304
+ r"""
305
+ d'Alembert operator.
306
+
307
+ The *d'Alembert operator* or *d'Alembertian* on a Lorentzian manifold
308
+ `(M,g)` is nothing but the Laplace-Beltrami operator:
309
+
310
+ .. MATH::
311
+
312
+ \Box = \nabla_i \nabla^i = g^{ij} \nabla_i \nabla_j
313
+
314
+ where `\nabla` is the Levi-Civita connection of the metric `g` (cf.
315
+ :class:`~sage.manifolds.differentiable.levi_civita_connection.LeviCivitaConnection`)
316
+ and `\nabla^i := g^{ij} \nabla_j`
317
+
318
+ INPUT:
319
+
320
+ - ``field`` -- a scalar field `f` (instance of
321
+ :class:`~sage.manifolds.differentiable.scalarfield.DiffScalarField`) or a
322
+ tensor field `f` (instance of
323
+ :class:`~sage.manifolds.differentiable.tensorfield.TensorField`) on a
324
+ pseudo-Riemannian manifold
325
+
326
+ OUTPUT:
327
+
328
+ - `\Box f`, as an instance of
329
+ :class:`~sage.manifolds.differentiable.scalarfield.DiffScalarField` or of
330
+ :class:`~sage.manifolds.differentiable.tensorfield.TensorField`
331
+
332
+ EXAMPLES:
333
+
334
+ d'Alembertian of a scalar field in the 2-dimensional Minkowski spacetime::
335
+
336
+ sage: M = Manifold(2, 'M', structure='Lorentzian')
337
+ sage: X.<t,x> = M.chart()
338
+ sage: g = M.metric()
339
+ sage: g[0,0], g[1,1] = -1, 1
340
+ sage: f = M.scalar_field((x-t)^3 + (x+t)^2, name='f')
341
+ sage: from sage.manifolds.operators import dalembertian
342
+ sage: Df = dalembertian(f); Df
343
+ Scalar field Box(f) on the 2-dimensional Lorentzian manifold M
344
+ sage: Df.display()
345
+ Box(f): M → ℝ
346
+ (t, x) ↦ 0
347
+
348
+ See the method
349
+ :meth:`~sage.manifolds.differentiable.scalarfield.DiffScalarField.dalembertian`
350
+ of :class:`~sage.manifolds.differentiable.scalarfield.DiffScalarField` and
351
+ the method
352
+ :meth:`~sage.manifolds.differentiable.tensorfield.TensorField.dalembertian`
353
+ of :class:`~sage.manifolds.differentiable.tensorfield.TensorField` for
354
+ more details and examples.
355
+ """
356
+ return field.dalembertian()
357
+
358
+
359
+ # NB: norm() is already defined in src/sage/misc/functional.py