ENGI 5432 Advanced Calculus

    Faculty of Engineering and Applied Science
    2009 Winter

    Problem Set 8   -   Solutions

    [Sections 1.7, 2.6, 3]
    1. A point charge   Q   at the origin gives rise to the electrostatic potential field

      V = 13/r
      Find

      1. the potential   V   at the point   (x, y, z )   =   (3, -4, 12).

        (x, y, z)   =   (3, -4, 12)     Þ     r2 = 9 + 16 + 144 = 169
        Þ     r = 13 .     Therefore

        V(3, -4, 12) = 13/13 = 1V


      2. the electric field vector   E   at the point   (x, y, z )   =   (3, -4, 12).

        E = -grad V = (-d/dr(13r^(-1)))rHat + 0 thetaHat + 0 phiHat
         = 13/r^2 rHat
        At r=13  E = 13/13^2 rHat =

        1/13 rHat V/m


      3. the volume charge density   rV   at the point   (x, y, z )   =   (3, -4, 12).
        [Hint:   use Poisson’s equation   div D = rV .]

        div E = (1/r^2) d/dr(r^2 13/r^2) + 0 + 0
    = (1/r^2) d/dr(13)  =  0
        and  D = eE   ==>  div D = 0
        But  div D = rho_V  ==>  rho_V = 0   (r not= 0)
        Therefore

        rho_V = 0  at (3, -4, 12)


      4. the magnitude   Q   of the point charge at the origin.

        Q  =  Integral {D dot dS}  =  e Integral {E dot dS} 
    = 13 e Integral {(1/r^2) dS}
        where   S   is any sphere, centre O, radius r.
        Q = 13e Int_0^2pi {Int_0^pi { r^2 sin theta / r^2 dtheta} dphi}
         (r not= 0)
        =  13e [phi]_0^2pi [-cos theta]_0^pi  
         =  13e 2pi (1+1)
        Therefore

        Q = 52*pi*e C approx= 1.446 nC

        or

        |E| = 13/r^2 = Q/(4*pi*e*r^2)  ==> 
        Q = 52*pi*e


    1. In spherical polar coordinates, the scalar field V is defined by

      V(x, y, z)   =   r cos2q .

      1. The vector field   F   is defined by F = ÑV .   Find F.

        F  =  grad V  =  rHat dV/dr  +  thetaHat/r dV/dtheta
         + phiHat/(r sin theta) dV/dphi
          =  cos^2 theta rHat  +  -2r sin theta cos theta thetaHat/r 
         + 0 phiHat/(r sin theta) ==>

        F  =  cos^2 theta rHat  -  2 sin theta cos theta thetaHat


      2. Find the divergence of F.

        div F  =  (1/r^2) d/dr(r^2 (cos^2 theta))   +
  + (1/(r sin theta)) {d/dtheta(sin theta (-2 sin theta cos theta))
  + d/dphi (0)}
          =  (2/r) cos^2 theta   -
    (2/(r sin theta)) {d/dtheta(sin^2 theta cos theta)) + 0}
          =  (2/r) cos^2 theta   -
    (2/(r sin theta)) (2 sin theta cos^2 theta - sin^3 theta)
          =  -(2/r) (cos^2 theta  -  sin^2 theta)
        Therefore

        div F  =  (-2/r) cos (2 theta)

        Note that the divergence of F is also the Laplacian of V :   del^2 V  =  (-2/r) cos (2 theta)


      3. Find the curl of F.

        [Long method:]
        curl F  =  1/(r^2 sin theta) *
  | rHat         r thetaHat               r sin theta phiHat |
  | d/dr          d/dtheta                     d/dphi        |
  | cos^2 theta  -2r sin theta cos theta         0           |
          =  1/(r^2 sin theta) (rHat (0-0) + r thetaHat (0-0)
        + r sin theta phiHat (-2 sin theta cos theta 
        + 2 sin theta cos theta))
        Therefore (except possibly on the z axis)

        curl F = vector 0

        [It can be shown that the curl remains the zero vector as one approaches any point on the z axis in the limit from any direction.]

        [Short method:]

        F is the gradient of a scalar function V.
        A quotable identity is   curl grad V º 0   for all twice-differentiable scalar fields V.
        Therefore   curl F º 0 .


    1. For the scalar field   V(x,y,z)  =  z * sqrt{x^2 + y^2}

      1. Find   ÑV   in the Cartesian coordinate system.

        grad V  =  < dV/dx, dV/dy, dV/dz >
        Note that
        d/dx (x^2 + y^2)^(1/2)  =  x / sqrt{x^2 + y^2}
        Using symmetry, it then follows that   d/dy (x^2 + y^2)^(1/2)  =  y / sqrt{x^2 + y^2}

        grad V = < xz/sqrt{x^2 + y^2}, yz/sqrt{x^2 + y^2},
         sqrt{x^2 + y^2} >


      2. Find the Laplacian   Ñ2V   in the Cartesian coordinate system in simplified form.

        del^2 V  =  d^2 V/dx^2 + d^2 V/dy^2 + d^2 V/dz^2
        Using the quotient rule:
          =  (zr - x^2 z/r)/r^2 + (zr - y^2 z/r)/r^2 + 0
         where r = sqrt{x^2 + y^2}
          =  (zr^2 - x^2 z)/r^3 + (zr^2 - y^2 z)/r^3 
         where r = sqrt{x^2 + y^2}
        Therefore

        del^2 V  =  z/sqrt{x^2 + y^2}

        [Also note that (Laplacian of V) = div grad V .]


      3. Convert V(x, y, z) to spherical polar coordinates.

        x = r sin q cos f
        y = r sin q sin f
        z = r cos q
        Þ     x2 + y2   =   r2 sin2q (cos2f + sin2f)   =   (r sinq)2
        ==>  z sqrt{x^2 + y^2}  =  r cos theta r sin theta
        Therefore

        V(r, theta, phi)  =  r^2 sin theta cos theta
         = (1/2) r^2 sin (2 theta)


      4. Find   ÑV   in the spherical polar coordinate system in simplified form.

        grad V  =  r sin 2theta rHat
         +  (r^2 cos theta) thetaHat/r + 0
        Therefore

        grad V  =  r(sin 2theta rHat + cos 2theta thetaHat)

        This is equivalent to
        grad V  =  r(2 sin theta cos theta rHat  +
       (cos^2 theta - sin^2 theta) thetaHat)


      5. Show that the Laplacian   Ñ2V   in the spherical polar coordinate system is cot q.

        Either use (Laplacian of V) = div grad V, or quote the spherical polar form for the Laplacian:
        del^2 V  =  (1/r^2) d/dr(r^2 dV/dr)) 
  + (1/(r^2 sin theta)) {d/dtheta(sin theta dV/dtheta)
  + (1/sin theta) d^2 V/dphi^2}
          =  (1/r^2) d/dr(r^3 sin 2theta)) 
  + (1/(r^2 sin theta)) {d/dtheta(r^2 sin theta cos 2theta) + 0}
          =  (3 r^2/r^2) sin 2theta +  
         r^2 /(r^2 sin theta)) {cos theta cos 2theta
         - 2 sin theta sin 2theta)}
          =  3 sin 2theta + cot theta cos 2theta - 2 sin 2theta
         = sin 2theta + cot theta cos 2theta
          =  2 sin theta cos theta +
         cot theta (1 - 2 sin^2 theta)
     = 2 sin theta cos theta + cot theta - 2 sin theta cos theta
        Therefore

          Ñ2V   =   cot q  


      6. Hence show that the value of the Laplacian of V is the same in both coordinate systems (except possibly on the z-axis).

        From part (c),   z = r cos q   and   x2 + y2   =   (r sinq)2
        From part (b),   del^2 V  =  z/sqrt{x^2 + y^2}
        Therefore
        del^2 V  =  r cos theta / (r sin theta)  = cot theta
        which is the spherical polar form found in part (e).


    1. A set of functions   {fn(x) }   is said to be orthonormal on the interval   (a, b)   if

      Integral{phi_m(x)*phi_n(x) dx 
     = 0 (for m not= n) ;  = 1 (for m=n)
      where   m   and   n   are positive integers.
      Show that   { sin npx }, { cos npx }   are both orthonormal on the interval (-1, 1).

      [Note:   It then follows that if f(x) = Sum_k=1 ^oo {a_k phi_k(x)} then a_n = Integral {f(x) phi_n(x)} dx 
     / Integral {(phi_n(x))^2} dx   which leads to methods of series solution of differential equations, including Fourier series.]


      The following trigonometric identities are quotable:

      sin A sin B   º   ( cos(A-B) - cos(A+B) ) / 2

      and

      cos A cos B   º   ( cos(A+B) + cos(A-B) ) / 2

      Therefore
      Int_-1^1 sin m*pi*x sin n*pi*x dx  =  
     (1/2) Int_-1^1 (cos(m-n)pi*x - cos(m+n)pi*x) dx

      If   m ¹ n   then
      Int_-1^1 sin m*pi*x sin n*pi*x dx  =  
     (1/2) [sin(m-n)pi*x / (m-n)pi - sin(m+n)pi*x / (m+n)pi]_-1^1
      =  (1/2) ((0-0) - (0-0))  =  0
      [Note that   m + n   cannot be zero because both   m and n   are positive.]

      If   m = n   then
      Int_-1^1 sin n*pi*x sin n*pi*x dx  =  
     (1/2) Int_-1^1 (cos 0 - cos 2n*pi*x) dx
        =  (1/2) [x - sin 2n*pi*x / (2n*pi)]_-1^1
     =  (1/2) ((1-0) - (-1-0))  =  1

      Therefore   { sin np x }   is an orthonormal set of functions on   (-1, 1).

      Int_-1^1 cos m*pi*x cos n*pi*x dx  =  
     (1/2) Int_-1^1 (cos(m+n)pi*x + cos(m-n)pi*x) dx

      If   m ¹ n   then
      Int_-1^1 cos m*pi*x cos n*pi*x dx  =  
     (1/2) [sin(m+n)pi*x / (m+n)pi + sin(m-n)pi*x / (m-n)pi]_-1^1
      =  (1/2) ((0+0) - (0+0))  =  0

      If   m = n   then
      Int_-1^1 cos n*pi*x cos n*pi*x dx  =  
     (1/2) Int_-1^1 (cos 2n*pi*x + cos 0) dx
        =  (1/2) [sin 2n*pi*x / (2n*pi) + x]_-1^1
     =  (1/2) ((0+1) - (0-1))  =  1

      Therefore   { cos np x }   is an orthonormal set of functions on   (-1, 1).

      [One can also show that every member of the set   { cos mp x }   is orthogonal to every member of the set   { sin np x }   on (-1, 1).]


    1. Find the Fourier series for the function   f (x)   defined on the interval [–1, 1] by

      f(x) = (1 - x^2) on -1 < x < 0;  0 else


      [graph of y = f(x)]

      L = 1
      Integral for a_0
      a0 = 2/3


      Integral for a_n
      Integral for a_n
      a_n = -2(-1)^n / (n pi)^2
      [tabular integration by parts]

      Integral for b_n
      Integral for b_n
      b_n = 2((-1)^n - 1) / (n pi)^3 - 1/(n pi)
      [tabular integration by parts]

      The Fourier series of   f (x)   on [–L, +L] in general is
      [general Fourier series]
      Therefore

      f(x) = 1/3 + Sum { 2(-1)^(n+1) cos(n pi x)/(n pi)^2 
     + (2((-1)^n - 1)/(n pi)^3 - 1/(n pi)) sin(n pi x) }

      The first few terms of this series are
      1/3 + 2 cos(pi x)/pi^2 - (4/pi^3 + 1/pi) sin(pi x)
    - cos(2 pi x)/(2 pi^2) - sin(2 pi x)/(2 pi) + ...
      The convergence is quite slow, due to the discontinuity at x = 0 and the abrupt change in slope at the ends of the interval, as this graph of the fourth partial sum   S4   illustrates:

      [graph of S4 and f(x)]
      y = f (x)   is in red
      y = S4   is in cyan.


    1. Find the Fourier series for the function   f (x)   defined on the interval [–1, 1] by

      f(x) = 1 - |x|


      [graph of y = f(x)]

      L = 1
      f (x) is even     Þ     bn = 0   for all n.
      Integral for a_0
      a0 = 1


      Integral for a_n
      Integral for a_n
      Integral for a_n
      a_n = 4 / (n pi)^2  for odd  n  only
      [tabular integration by parts]

      Therefore the Fourier series is

      f(x) = 1/2 + (4/pi^2) Sum { cos((2k-1) pi x)/((2k-1) pi)^2 }

      The first few terms of this series are
      1/2 + (4/pi^2) ( 
     cos(pi x) + cos(3 pi x)/9 + cos(5 pi x)/25 + ...)
      The partial sum of just the first three non-zero terms yields an impressively good approximation everywhere except near the points where f (x) is not differentiable:

      [graph of y = f(x)]
      y = f (x)   is in red
      y = S3   is in blue.


    1. Find the Fourier cosine series for the function   f (x)   defined on the interval [0, 2] by

      f(x) = 4 - x^2


      [graph of y = f(x)]

      L = 2
      An even extension of f (x) is required
      bn = 0   for all n.
      Integral for a_0
      a0 = 16/3


      Integral for a_n
      Integral for a_n
      a_n = 16(-1)^(n+1) / (n pi)^2
      [tabular integration by parts]

      Therefore the Fourier series is

      f(x) = 8/3 + (16/pi^2) Sum { (-1)^(n+1) cos(n pi x/2)/(n pi)^2 }

      The first few terms of this series are
      8/3 + (16/pi^2) ( 
     cos(pi x/2) - cos(pi x)/4 + cos(3 pi x/2)/9 + ...)
      The partial sum of the first four terms yields a fair approximation everywhere except near the endpoints, where f (x) is not differentiable:

      [graph of y = f(x)]
      y = f (x)   is in red
      y = S3   is in blue.


    1. Find the Fourier sine series for the function   f (x)   defined on the interval [0, 2] by

      f(x) = 2x - x^2

      Also comment on why the rate of convergence of this Fourier series everywhere in the interval [0, 2] is much more rapid than in question 7.


      [graph of y = f(x)]

      L = 2
      An odd extension of f (x) is required.
      an = 0   for all n.

      Note how the periodic extension of   f (x)   is not only continuous everywhere but differentiable everywhere, even at the endpoints.   We therefore anticipate a more rapid convergence than in question 7.


      Integral for b_n
      Integral for b_n
      b_n = 32 / (n pi)^3   for odd n only
      [tabular integration by parts]

      Therefore the Fourier series is

      f(x) = (32/pi^3) Sum { sin((2k-1) pi x/2)/(2k-1)^3 }

      The first few terms of this series are
      8/3 + (16/pi^2) ( 
     sin(pi x/2) + sin(3 pi x/2)/27 + sin(5 pi x/2)/125 + ...)
      The partial sum of just the first two non-zero terms yields an excellent approximation everywhere:

      [graph of y = f(x)]
      y = f (x)   is in red
      y = S3   is in blue.


    1. [A more challenging question:]
      An incompressible viscous fluid is in steady-state flow around the z-axis, trapped between a pair of coaxial rotating cylinders, aligned along the z-axis.   The inner cylinder has radius a and rotates at angular velocity w k.   The outer cylinder has radius b (> a) and rotates at angular velocity u k.
      In response, the velocity vector at any point in the fluid, in cylindrical polar coordinates (r, f, z), is   vector v = v(rho) phiHat   and   v(r)   obeys the ordinary differential equation
                    Laplacian of v = v / rho^2
      Where it is in contact with a cylinder, the fluid must move with the same velocity as that cylinder.
      Solve the ODE to find the velocity at all points in the fluid.


      The Laplacian of any scalar function   V   in cylindrical polar coordinates is, in general,
      del^2 V = d^2 V/drho^2 + (1/rho) dV/drho
     + (1/rho^2) d^2 V/dphi^2 + d^2 V/dz^2
      However, the velocity vector has neither radial nor vertical components.
      The f component of the velocity vector is a function of r only, so that the ODE becomes
      geometry of the water in the annular cylinder d^2 v/drho^2 + (1/rho) dv/drho  =  v / rho^2
      (1/rho) dv/drho - v / rho^2  =  (d/drho) (v/rho)   so that the ODE becomes
      dv/drho + v/rho = A
      This is a linear first order ODE and can be solved by that method,
      or one may use a similar shortcut to an exact form again:
      d/drho (rho v) = A rho
      v  =  A rho / 2  +  B / rho
      The two arbitrary constants are determined by the two boundary conditions.
      The linear speed of each cylinder is just the product of the radius of that cylinder with its angular speed:
      v(a) = aw , v(b) = bu
      [eliminating  A]
      B  =  (ab)^2(w-u) / (b^2 - a^2)
      A  =  (b^2 u - a^2 w) / (b^2 - a^2)
      The complete solution for the velocity vector at any point (r, f, z) in the fluid is therefore

      v  =  ((b^2 u - a^2 w) rho / 2
     +  (ab)^2(w-u) / rho) / (b^2 - a^2)


          Return to the Index of Solutions   [To the Index of Solutions.]
          Back to previous page   [Return to your previous page]
    Created 2008 01 29 and most recently modified 2008 12 27 by Dr. G.H. George