View source: R/tensor_fields.R
g_sph | R Documentation |
Provides the metric tensor of the sphere S^n
with radius 1.
g_sph()
returns a symbolic tensor field in generalized spherical
coordinates {\phi_1, \phi_2, ..., \phi_{n-1}}
.
d\Omega^2= d\phi_1^2 + \sum_{i=1}^{n-1} \prod_{m=1}^{i-1} sin(\phi_m)^2 d\phi_i^2
g_sph(n, coords = paste0("ph", 1:n))
n |
The dimension of the metric tensor. |
coords |
A character vector of coordinate names. The length needs to match the tensor dimensions. |
As usual, spherical coordinates are degenerate at \phi_l = 0
, so be
careful around those points.
The covariant metric tensor as array imputed with coordinate names.
Wikipedia: Sphere
Other metric tensors:
g_eucl_cart()
,
g_mink_cart()
,
g_ss()
,
metric_field()
g_sph(3)
g_sph(3) %_% .(+i, +j)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.