This notebook is part of the Introduction to manifolds in SageMath by Andrzej Chrzeszczyk (Jan Kochanowski University of Kielce, Poland).
version()
'SageMath version 9.6, Release Date: 2022-05-15'
Recall that if $M$ is a smooth manifold, the set of all smooth functions from $M$ to $R$ is denoted by $C^∞(M)$.
This set is a ring with the operations given by
\begin{equation}
\begin{matrix}
( f + g)( p) = f ( p) + g( p),\\
( f g)( p) = f ( p)g( p),
\end{matrix}
\label{}\tag{7.1}
\end{equation}
for $f, g ∈ C^\infty(M),\ \ a ∈ R$ and $p ∈ M.$
One can also define an additional operation $$(a f )( p) = a f ( p),$$
for $f∈ C^\infty(M),\ \ a ∈ R$ and $p ∈ M.$
If $ψ$ is a smooth map from $M$ to a smooth manifold $N$ and $f ∈ C^∞ (N )$, the pullback $ \ \ ψ ^* f\ \ $ of $f$ under $\ \ ψ\ \ $ is defined by
\begin{equation} ψ^∗ f = f ◦ ψ. \label{}\tag{7.2} \end{equation}If $\phi\ $ and $\ \chi\ $ are charts on $M$ and $N$, respectively, then from $\ \ (ψ^∗ f ) ◦ φ^{−1} = ( f ◦ χ^{−1} ) ◦ (χ ◦ ψ ◦ φ^{−1} )\ \ $ it follows that $ψ^∗ f ∈ C^∞ (M).$
The operation $ψ^∗$ is applied to functions defined on $N$ to produce functions defined on $M$, hence the name pullback for $ψ^∗$.
Example 7.1
If we denote by $\psi$ the coordinate change defined by $x=r\cos(\phi),\; y=r\sin(\phi)$ on the open set $U=\{(r,\phi): r>0, 0<\phi <2\pi \},$ then for a scalar function $f$ of variables $x,y,$ the pullback $\psi^*f$ is the function $(r,\phi)\to f(r\cos(\phi),r\sin(\phi))$, defined on $U$.
%display latex
M = Manifold(2, 'R^2p') # manifold R^2
U = M.open_subset('U') # open subset of R2,
# polar coord. on U:
c_rphi.<r,phi>=U.chart(r'r:(0,oo) phi:(0,2*pi):\phi')
N = Manifold(2, 'R^2c') # second copy of R^2
c_xy.<x,y> = N.chart() # Cartesian coordinates:
# psi: M --> N : polar to Cart.:
psi = U.diff_map(N, (r*cos(phi), r*sin(phi)),name=r'\psi')
# f -scalar function on N
f = N.scalar_field(function('f')(x,y), name='f')
fplb=psi.pullback(f) # psi^*f -scalar func. on M
fplb.disp() # show pullback
If $ψ$ is a smooth map $M\to N$ then
\begin{equation}
ψ^∗ (a f + bg) = aψ^∗ f + bψ^∗ g,
\tag{7.3}
\end{equation}
for $f, g ∈ C^∞ (N )$ and $a, b ∈ R.$
In fact $$ψ^∗ (a f + bg) ( p) = (a f + bg)(ψ( p)) = a f (ψ( p)) + bg(ψ( p))\\ = a(ψ^∗ f )( p) + b(ψ^∗ g)( p) = (aψ^∗ f + bψ^∗ g)( p). $$
If $ψ$ is a smooth map $M\to N$ then
\begin{equation}
ψ^∗ ( f g) = (ψ^∗ f )(ψ^∗ g),
\tag{7.4}
\end{equation}
for $f, g ∈ C^∞ (N )$.
The last relation follows from
$$ψ^∗ ( f g) ( p) = ( f g)(ψ( p)) = f (ψ( p))g(ψ( p)) = (ψ^∗ f )( p)(ψ^∗ g)( p) = (ψ^∗ f )(ψ^∗ g) ( p). $$If $M_1,M_2,M_3$ are smooth manifolds and $ψ_1 : M_1 → M_2$ and $ψ_2 : M_2 → M_3$ are smooth maps, then
\begin{equation} (ψ_2 ◦ ψ_1 )^∗ = ψ_1^∗ ◦ ψ_2^∗ . \tag{7.5} \end{equation}This is consequence of
Let $M$ be a smooth manifold. A smooth curve $\gamma$ in
$M$, is a smooth mapping $\gamma : I → M$ where $I\subset R$ is an open interval.
Equivalently:
$\gamma : I → M$ is a smooth curve in $M$ if $I$ is an open interval of $R$ and
$φ ◦ \gamma: I\to R^n$ is a smooth map for every chart $(U, φ)$ of the atlas of $M$.
In local coordinates $\ \ (x^1,\ldots,x^n)\ $ the curve is defined if we define $\ n\ $ real functions
$$\gamma^1(t)=x^1(\gamma(t)),\ldots, \gamma^n(t)=x^n(\gamma(t)),\quad t\in I. $$Example 7.2
Assume, that in an open subset $U\subset R^2$ we have a curve defined in polar coordinates: $\ r=1,\phi=t, \ t\in(0,2\pi)$.
Since in this example the transition maps are defined, the representation of the curve in Cartesian coordinates is determined by the system.
M = Manifold(2, 'R^2', r'\RR^2') # the Euclidean plane R^2
c_xy.<x,y> = M.chart() # Cartesian coordinates on R^2
U = M.open_subset('U', coord_def={c_xy: (y!=0, x<0)})
# the complement of the segment y=0 and x>0
c_cart = c_xy.restrict(U) # Cartesian coordinates on U
# spherical coordinates on U:
c_spher.<r,ph> = U.chart(r'r:(0,+oo) ph:(0,2*pi):\phi')
# transition spher. to Cartesian
ch_cart_spher=c_cart.transition_map(c_spher, [sqrt(x*x+y*y),
atan2(y,x)])
# transition Cartesian to spher.
ch_cart_spher.set_inverse(r*cos(ph), r*sin(ph))
R.<t> = manifolds.RealLine() # manifold R
c = U.curve({c_spher: (1,t)}, (t, 0, 2*pi), name='c') # curve c
print()
print("Representations in polar and Cartesian coordinates:")
show(c.coord_expr(c_spher)) # curve c in spherical coord.
show(c.coord_expr(c_cart)) # curve c in Cartesian coord.
cp=c.plot(color='black',aspect_ratio=1) # curve plot
cp.show(figsize=[3,3]) # show plot
Check of the inverse coordinate transformation: x == x *passed* y == y *passed* r == r *passed* ph == arctan2(r*sin(ph), r*cos(ph)) **failed** NB: a failed report can reflect a mere lack of simplification. Representations in polar and Cartesian coordinates:
Example 7.3
Consider the curve in $R^3$ defined in Cartesian coordinates by $\ x=\cos 3t,\ y=\sin 3t,\ z=2t$:
J = manifolds.OpenInterval(0, 2*pi) # open interval
c.<t>=J.chart() # coordinate t on c
R3 = Manifold(3, 'R^3') # manifold R^3
X.<x,y,z> = R3.chart() # Cartesian coord. on R^3
# curve c in R^3:
c = R3.curve({X:[cos(3*t),sin(3*t),2*t]},(t,-pi/2,+pi/2),name='c')
# plot c:
p = c.plot(X,color='grey',thickness=4,plot_points=200,label_axes=False)
p.show(aspect_ratio=[1,1,0.3]) # show plot
Example 7.4
Define a curve on the sphere $S^2$, using spherical coordinates $\ \theta=t,\ \phi=\cos 2t$:
%display latex
S2=manifolds.Sphere(2) # sphere S^2
Phi=S2.embedding() # embedding S^2-> E^3
sph.<th,ph>=S2.spherical_coordinates() # spherical coord. on S^2
E=S2.ambient() # Euclidean space E^3
cart.<x,y,z> = E.cartesian_coordinates() # Cartesian coord. on E^3
fun=Phi.expr() # functions defining Phi
R.<t> = manifolds.RealLine() # Real line as manifold
c = S2.curve({sph: [t, cos(2*t)]}, (t, -oo, +oo),
name='c') # curve c
# plot c:
p1=c.plot(chart=cart,mapping=Phi,thickness=3,color='black',
plot_points=200, aspect_ratio=1,label_axes=False)
p2=parametric_plot3d(fun,(th,0,pi),(ph,0,2*pi),
color='lightgrey',opacity=0.7) # plot sphere
(p1+p2).rotateZ(pi/2).show(frame=False,label_axes=False) # show plot
If $\gamma$ is a smooth curve in $M$ and $f ∈ C^∞ (M),$ then $\gamma^∗ f = f ◦ \gamma$ is a smooth function from an open interval $I ⊂ R$ into $R$. If $t_0 ∈ I$ , the tangent vector to $\gamma$ at the point $\gamma(t_0 )$, denoted by $\gamma'_{t_0}$ , is the map $C^\infty(M)\to R$ defined by \begin{equation} \gamma'_{t_0}(f) =\frac{d}{dt}(\gamma^*f)\Big|_{t_0}= \frac{d}{dt}(f\circ\gamma)\Big|_{t_0},\quad f\in C^\infty(M). \label{}\tag{7.6} \end{equation}
Using (7.3), (7.4) we can check that $\gamma'_{t_0}:C^∞ (M)\to R$ has the properties
$$\gamma'_{t_0}(af+bg)=\frac{d}{dt}(\gamma^*(af+bg))\Big|_{t_0}=\frac{d}{dt}(a\gamma^*(f)+b\gamma^*(g))\Big|_{t_0}\\
=a\frac{d}{dt}(\gamma^*f)\Big|_{t_0}+
b\frac{d}{dt}(\gamma^*g)\Big|_{t_0}=
a\gamma'_{t_0}(f)+b\gamma'_{t_0}(f),
$$
and
$$\gamma'_{t_0}(fg)=\frac{d}{dt}(\gamma^*(fg))\Big|_{t_0}=\frac{d}{dt}(\gamma^*(f)\gamma^*(g))\Big|_{t_0}\\
=f (\gamma(t_0 ))\frac{d}{dt}(\gamma^*(g))\Big|_{t_0}
+g (\gamma(t_0 ))\frac{d}{dt}(\gamma^*(f))\Big|_{t_0}\\
=f (\gamma(t_0 ))\gamma'_{t_0}(g)+
g (\gamma(t_0 ))\gamma'_{t_0}(f),
$$
for $f, g ∈ C^∞ (M)$ and $a,b\in R$.
Take a look at the notebook Tangent spaces.