Spherical Inspection

Mohammad Ghomi and James Wenk
September 2020

This notebook is an accompaniment to the paper

              Shortest closed curve to inspect a sphere

by the authors. Here we verify  some of the longer symbolic computations in the above paper, and also include the codes for generating the plots. The enumeration of the sections below correspond to the sections in the above paper.

Section 3: The Integral Formula for Efficiency

Here we check the computations in Proposition 3.1 for the Jacobian of the map

F[t_,θ_]=λ[t] e0[t]+ρ[t](Cos[θ]e1[t]+Sin[θ]e2[t]);

where we have set e0:=(OverBar[γ]).

3.1 The case where (OverBar[γ])’(t_0)≠0.

D[F[t,θ],t]/.{e0'[t]->v e1[t],e1'[t]->-v e0[t], e2'[t]->0}

So the coordinates of the first partial derivative of F with respect to the frame (e0, e1, e2) are

{λ'[t]-v Cos[θ] ρ[t],v  λ[t]+ρ'[t]Cos[θ],ρ'[t]Sin[θ]}

D[F[t,θ],θ]

The coordinates of the second partial derivative of F with respect to  (e0, e1, e2) are

ρ[t]{0,-Sin[θ],Cos[θ]}

Now we take the cross product of the partial derivatives:

ρ[t]{λ'[t]-v Cos[θ] ρ[t],v  λ[t]+ρ'[t]Cos[θ],ρ'[t]Sin[θ]}\[Cross]{0,-Sin[θ],Cos[θ]}//FullSimplify

The square of the norm of the Jacobian of F is given by

Dot[%,%]//FullSimplify

Next we rewrite the Jacobian as follows

((ρ[t])^2) ((v^2) ((Cos[θ])^2) (((λ[t])^2)+((ρ[t])^2))-2 v Cos[θ] ( ρ[t] λ'[t]-λ[t] ρ'[t])+((ρ'[t])^2) +((λ'[t])^2))

By definition we have

λ[t][t_]=(Sqrt[1-((ρ[t])^2)]);

So

((λ[t])^2)+((ρ[t])^2)=1

Furthermore, we have

ρ[t] λ'[t]- λ[t] ρ'[t]//Simplify

((λ'[t])^2)+((ρ'[t])^2)//Simplify

So it follows that the the square of the Jacobian of F is given by

((ρ[t])^2)((v^2) ((Cos[θ])^2) -2 c Cos[θ] ((λ'[t])/(ρ[t]))+(((λ'[t])^2)/((ρ[t])^2)))

((ρ[t])^2)(((v Cos[θ]-((λ'[t])/(ρ[t]))))^2)

(((ρ[t] v Cos[θ]+λ'[t]))^2)

3.2 The case where (OverBar[γ])’(t_0)=0

D[F[t,θ],t]/.{e0'[t]->0,e1'[t]->0, e2'[t]->0}

D[F[t,θ],θ]

ρ[t]{0,-Sin[θ],Cos[θ]}

The cross product of the partial derivatives  yields the Jacobian of F:

ρ[t]{λ'[t],ρ'[t]Cos[θ],ρ'[t]Sin[θ]}\[Cross]{0,-Sin[θ],Cos[θ]}//FullSimplify

The norm squared of the Jacobian of F is

Dot[%,%]//FullSimplify

which can be simplified as follows

((ρ[t])^2) (((λ'[t])^2)+((ρ'[t])^2))

((ρ[t])^2) ((((λ'[t])^2)/((ρ[t])^2)))

((λ'[t])^2)

Section 6: Efficiency of Line Segments

The formula for the intersection of two spherical caps with radii (Subscript[ρ, 0]), (Subscript[ρ, 1]), and distance d between the centers is as follows. Note that this formula is valid only if the boundaries of the caps intersect.

A[ρ0_,ρ1_,d_]=2( 
      ArcCos[((-Cos[d]+Cos[ρ0]Cos[ρ1])/(Sin[ρ0]Sin[ρ1]))]
-ArcCos[((Cos[ρ1]-Cos[d]Cos[ρ0])/(Sin[d]Sin[ρ0]))]Cos[ρ0]
-ArcCos[((Cos[ρ0]-Cos[d]Cos[ρ1])/(Sin[d]Sin[ρ1]))]Cos[ρ1]);

Next we set

H1[ρ0_,ρ1_,d_]=4π (((Sin[((ρ0)/2)]))^2)+4π (((Sin[((ρ1)/2)]))^2)-2A[ρ0,ρ1,d];

So we add the areas of two caps, and subtract twice the area on the intersection.

The horizon of a line segment with h0, h1 being the heights of its vertices and l the length of the segment is given by

FullSimplify[H1[ArcCos[(1/h0)],ArcCos[(1/h1)],ArcCos[((l^2-h0^2-h1^2)/(-2h0 h1))]],{h1> h0≥1,l>0,0<α<π}]

So after some simplifications we set

H2[h0_,h1_,l_]=4(ArcCos[(((h0^2)+(h1^2)-(l^2)-2)/(2 (Sqrt[((h0^2)-1) ((h1^2)-1)])))]+(1/h0) ArcSin[(((h1^2)-(h0^2)-(l^2))/(Sqrt[((h0^2)-1) ((l^2)-(((h1-h0))^2)) ((((h0+h1))^2)-(l^2))  ]))]+ (1/h1)ArcSin[(((h0^2)-(h1^2)-(l^2))/(Sqrt[((h1^2)-1) ((l^2)-(((h1-h0))^2)) ((((h0+h1))^2)-(l^2))]))]);

Next note that

FullSimplify[H2[h0,(Sqrt[(h0^2)+(l^2)+2h0 l Cos[α]]) ,l],{h0≥1,l>0,0<α<π}]

So letting ,

h1[l_,α_]= (Sqrt[(h0^2)+(l^2)+2 h0 l Cos[α]]);

we have

H3[h0_,l_,α_]=4(  ArcCos[((-1+(h0^2)+h0 l Cos[α])/(Sqrt[(-1+(h0^2)) (-1+((h1[l,α])^2))]))]+((-1)/(h1[l,α])) ArcSin[(((l+h0 Cos[α]) )/(h0 Sin[α](Sqrt[-1+((h1[l,α])^2)])))]+(1/h0)ArcSin[((Cot[α])/(Sqrt[-1+(h0^2)]))] );

In particular, note that

FullSimplify[H3[h0,l,(π/2)],{h0≥1,l>0}]

So we obtain the following formula for one-edge spirals

H4[h0_,l_]=4 (ArcCos[(Sqrt[((-1+(h0^2))/(-1+(h0^2)+(l^2)))])]-(1/(Sqrt[(h0^2)+(l^2)]))ArcSin[(l/(h0 (Sqrt[-1+(h0^2)+(l^2)])))]);

We may also rewrite the above formula in terms of h0 and h1:

FullSimplify[H4[h0,(Sqrt[(h1^2)-(h0^2)])],{h1≥h0≥1}]

So we set

H5[h0_,h1_]=4 (ArcCos[(Sqrt[(((h0^2)-1)/((h1^2)-1))])]-(1/h1) ArcSin[((Sqrt[(h1^2)-(h0^2)])/(h0 (Sqrt[(h1^2)-1])))]);

Finally we define

Eff[h0_,h1_]=((H5[h0,h1])/(Sqrt[(h1^2)-(h0^2)]));

Plot3D[Eff[h0,h1],{h0,1,3},{h1,h0,3}]

ContourPlot[Eff[h0,h1],{h0,1,3},{h1,h0,3},Contours->60]

Section 7: Efficiency of Spirals

H[t_]=H4[r+t,(Sqrt[(h1^2)-(((r+t))^2)])]

FullSimplify[H'[0],{h1>r>1}]

Section 8: Instantaneous Efficiency

If we set

F[h_,α_,θ_]=(1/(h^2)) ((Sqrt[(h^2)-1])Sin[α]Cos[θ]+Cos[α]);

then the instant efficiency is given by

IE[h_,α_]:=(∫_0^(2π))Abs[F[h,α,θ]]\[DifferentialD]θ;H

Set

(Subscript[θ, 0])=ArcCos[-((Cot[α])/(Sqrt[-1+(h^2)]))];

then

IE[h_,α_]=(∫_(-(Subscript[θ, 0]))^(Subscript[θ, 0]))F[h,α,θ]\[DifferentialD]θ-(∫_(Subscript[θ, 0])^(2π-(Subscript[θ, 0])))F[h,α,θ]\[DifferentialD]θ//Simplify

which simplifies to

(2/(h^2))(2 ArcCos[-((Cot[α])/(Sqrt[-1+(h^2)]))] Cos[α]-2 ArcCos[((Cot[α])/(Sqrt[-1+(h^2)]))] Cos[α]+2  (Sqrt[-1+(h^2)-((Cot[α])^2)]) Sin[α])

(4/(h^2))((π/2)- ArcCos[-((Cot[α])/(Sqrt[-1+(h^2)]))] Cos[α]+ (Sqrt[(h^2)((Sin[α])^2)-1]) )

(4/(h^2))(ArcSin[-((Cot[α])/(Sqrt[-1+(h^2)]))] Cos[α]+ (Sqrt[(h^2)((Sin[α])^2)-1]) )

So we set

IE[h_,α_]=(4/(h^2))(ArcSin[((Cot[α])/(Sqrt[-1+(h^2)]))] Cos[α]+ (Sqrt[(h^2)((Sin[α])^2)-1]) );

Next we generate some plots:

Plot3D[IE[h,α], {h,1,3}, {α,ArcSin[(1/h)],π/2}]

g1=ContourPlot[IE[h,α], {h,1,3}, {α,ArcSin[(1/h)],π/2},PlotPoints->50, PlotLegends->Automatic];

g2=ContourPlot[IE[h,α]==2, {h,1,3}, {α,ArcSin[(1/h)],π/2},PlotPoints->100,ContourStyle->Red];

g3=ContourPlot[IE[h,α]==2, {h,1.3,1.6}, {α,1.4,π/2},PlotPoints->1000, ContourStyle->Red];

Show[g1,g2,g3]

g4=Plot[ArcSin[((Sqrt[2])/h)],{h,(Sqrt[2]),3},PlotStyle->Yellow];

g5=Plot[{ArcSin[(((Sqrt[2])-0.25)/h)],ArcSin[(((Sqrt[2])+0.25)/h)],ArcSin[(((Sqrt[2])+0.5)/h)], ArcSin[(((Sqrt[2])+0.75)/h)],ArcSin[(((Sqrt[2])+1)/h)]},{h,1,3},PlotStyle->Yellow];

Show[g1,g2,g3,g4,g5]

In Lemma 8.2 we compute

(∂_α)(IE[h,α])//Simplify

Disregarding 4/(h^2), we may simplify  the rest of the expression as follows:

(((h^2) Cos[α] Sin[α]-Cot[α] )/( (Sqrt[-1+(h^2) ((Sin[α])^2)])))-ArcSin[((Cot[α])/(Sqrt[-1+(h^2)]))] Sin[α]

Cot[α](Sqrt[-1+(h^2) ((Sin[α])^2)]) -ArcSin[((Cot[α])/(Sqrt[-1+(h^2)]))] Sin[α]

Section 9: Lifting and Splitting of Spirals

We set (Subscript[h, 0]):=|(Subscript[p, 0])|,  (Subscript[h, 1]):=|(Subscript[p, 1])|. Let ((Subscript[p, 0])^t):=(1 + t)(Subscript[p, 0. ])Then the length of the segment  ((Subscript[p, 0])^t)(Subscript[p, 1]) is given by:

L[t_]=(Sqrt[((Subscript[h, 1])^2)+((t^2)-1)((Subscript[h, 0])^2)]);

So the horizon of (p^t)(p^1) is:

H[t_]=H2[(1+t) (Subscript[h, 0]),(Subscript[h, 1]),L[t]];

FullSimplify[H'[0],(Subscript[h, 1])>(Subscript[h, 0])≥1]

FullSimplify[H''[0],(Subscript[h, 1])>(Subscript[h, 0])>1]

-((4 ((Subscript[h, 0]^2)-(Subscript[h, 1]^2)))/(Sqrt[-(-1+(Subscript[h, 0]^2)) ((((Subscript[h, 0]^2)-(Subscript[h, 1]^2)))^3)]))

which is equivalent to:

((4 )/(Sqrt[((Subscript[h, 0]^2)-1) ((Subscript[h, 1]^2)-(Subscript[h, 0]^2))]))

Finally we have:

L''[0]