 
                                2102222 ENGINEERING ELECTROMAGNETICS Vector Analysis & Vector Calculus 1 Outline • Vector representation and vector algebra • Orthogonal coordinate systems • Differentiation and integration of vectors • Line, surface, and volume integrals • “Del” operator () • Gradient, divergence, and curl 2 Scalar & Vector • A quantity is called a scalar if it has only magnitude. – Examples: mass, temperature, electric potential, population • A quantity is called a vector if it has both magnitude and direction. – Examples: velocity, force, electric field intensity 3 Vector Representation    • A vector A is represented by A  a A A  where A  | A | is the magnitude  a A is a unit vector specifying the direction Note: A can be real or complex!! • A vector can be represented graphically by an arrow. 4 Equality of Vectors   A  aA A   B  aB B     A  B where A  B and a A  aB Note: They may be displaced in space!! 5 Vector Addition • Head-to-tail rule    ABC     ABD  C  D  C  A  B 6 Vector Subtraction    ABC  C  B  A   Note: C arrowhead points to that of A 7 Vector Dot Product  B   A  B  AB cos  AB  AB B cos AB  A   B is projected onto A and multiplied by A Examples:   A  A  A  A  A2  A    ax ax 1    A  A  A 8 Example • Find    AB  C  B  AB  C  A Solution:   B      AB    AB  C      A  B  A  B  2 2   A  B  2 A B cos  AB  A 2  B 2  2AB cos  9 Vector Dot Product (cont.) • Vector dot product is the sum of products of their components on the same direction. Example:         A  a x A1  a y A2  a z A3 ; B  a x B1  a y B2  a z B3   A  B  A1B1  A2 B2  A3 B3       ax  ax  a y  a y  az  az  1       ax  a y  ax  az  a y  az  0 10 Vector Cross Product  an   A B  B   A  A  B    A  B  an A  B sin  Right-hand rule    an is a unit vector normal to the plane containing A and B     A  B  ( B  A) 11 Example  az  ax  ay        ax  ax  a y  a y  az  az  0 12 Length & Area Calculation • Length calculation by dot product    12 C  C  C  • Area calculation by cross product      A  B  a A A   aB B   an A B sin  AB    where an  a A  aB   Area  A  B  A B sin  AB   A B  B   A 13 Cartesian Coordinate System Z    • Base vectors: a x , a y , a z   Do not change with position • Point: P  ( x, y , z ) PP (X ( x, Y , y, Z, )z ) 0 Y X  • Position vector: OP  x, y, z   ax x  a y y  az z     • Vector: A  a x Ax  a y Ay  a z Az  • Vector field: A( x, y , z ) • Scalar field: V ( x, y , z ) 14 Vector Differential Line Z   0    d  a d     d   Y   ( x, y, z) X      d   a d  ax dx  a y dy  az dz 15 Vector Differential Surface   ds  a n ds  an  d dz Example:     ds z  a x dx  a y dy   a z dxdy   an  a z and ds  dxdy dy dx Z       d X ds Y  Note: The unit normal vector an is perpendicular to the plane containing ds 16 Differential Volume    dv  a z d z   [( a x d x )  ( a y d y )]    a z d z   a z d x d y   d xd yd z 17 Cylindrical Coordinate System    • Base vectors: ar , a , a z Change with  Constant 18 Cylindrical Coordinate (cont.) Z  PP  (X,rY,  , Z,)z   0 X   Z r Y • Point: P  r, , z • •    Position vector: OP  l ( r,  , z )  ar r  a z z     Vector: A  a r A r  a  A  a z A z  • Vector field: Ar ,  , z  • Scalar field: V r,  , z  19 Vector Differential Line Z   0    d  a d     d    Y  (rx,,y,, zz) X      d   a  d  a r dr  a  rd  a z dz 20 Vector Differential Surface   ds  a n ds For example:    ds z  (ar dr )  (a rd )    (ar  a )(rdrd )   a z rdrd Note: The unit normal vector perpendicular to the plane containing ds 21 Differential Volume   dv  a z dz   ds z    a z dz   a z rdrd   rdrddz 22 Spherical Coordinate System    • Base vectors: aR , a , a All change with  and  • Point: P  (R , ,  ) •  Position vector: OP  l ( R, ,  )  aR R     • Vector: A  a R A R  a  A  a  A •  Vector field: A(R, ,  ) • Scalar field: V(R , ,  ) 23 Vector Differential Line     dl  aR dR  a Rd  a R sin d 24 Vector Differential Surface   ds  a n ds For example: R sin d    ds R  (a Rd )  (a R sin d )  2  aR R sin dd dR  R sin(  d )d R Rd  Note: The unit normal vector perpendicular to the plane containing ds 25 Differential Volume R sin d dR  R sin(  d )d R  Rd   dv  aR dR  dsR    (aR dR )  (aR R 2 sin  dd )  R 2 sin  dRd d 26 Summary of Vector Relations 27 Coordinate Transformation Relations 28 Integral Containing Vector Functions • Line integral (of scalar and vector)     Vdl  F  dl C C • Surface integral (of vector)    A  ds or S    A  ds S • Volume integral (of vector)   Fdv or V   Fdv V 29 Line Integral of Scalar Function • General form   Vdl C  Vis a scalar function of space  dl is a differential increment of length  C is the path of integration • Integration path from a point P1 to another point P2 P2   Vdl P1 • Integration around a closed path C   Vdl C 30 Line Integral of Scalar Function • In Cartesian coordinates:      Vdl   V ( x, y, z )ax dx  a y dy  az dz  C C     a x  V ( x, y , z )dx  a y  V ( x, y , z )dy  a z  V ( x, y , z )dz C C C • In cylindrical coordinates:      Vdl   arV (r, , z )dr  r  aV (r, , z )d  az  V (r, , z )dz C C C C 31 Exercise • Write down the general form of a line integral of  a scalar function  Vdl in spherical coordinates. C R sin d dR  R sin(  d )d R  Rd     dl  aR dR  a Rd  a R sin d 32 Example P  • Evaluate the integral  r 2dr , where r 2  x 2  y 2 O from the origin O to the point P(1,1) along the path OP, the path OP1P, and the path OP2P. 33 Solution • Along the path OP: P 2    2 2 2 O r dr  ar 0 r dr  ar 3 2 2 2    a x cos 45  a y sin 45  3  2  2  ax  a y 3 3  34 Solution • Along the path OP1P: P 1 1 O 0 0    2 2 2 2 ( x  y ) d r  a y dy  a ( x  1)dx y x  1  1   ax  x3  x  0 3 0  4  1  ax  a y 3 3  1  ay y 3 31 35 Exercise P  • Evaluate the integral  r dr along the path OP2P. 2 O 36 Example   • Evaluate the line integral  F  dl B    where F  a x xy  a y 2 x along the quarter-circle shown in the figure. A  dl 37 Solution x 2  y 2  9 (0  x, y  3) • In Cartesian coordinates:  dl   F  dl  Fx dx  Fy dy  xydx  2 xdy 3   0 2 2 F  d l  x 9  x dx  2 9  y dy    B A 3 1   9  x 3 0     91   2  3  2 1 y    y 9  y  9 sin ( ) 3 3 0  0 2 3/ 2 38 Exercise   • Write down the integral  F  dl B in cylindrical coordinates.    F  a x xy  a y 2 x  dl A  Fr   cos  sin  0  Fx   F    sin  cos  0  F      y  0 1  Fz   Fz   0     F  ar Fr  a  F  a z Fz   dl  a  rd 39 Surface Integral of Vector Function • It is a double integral over two dimensions.      A  ds or  A  ds S S  • The integral measures the flux of the vector field A flowing through the surface S. (Note: The result is a scalar.)     A A  an A cos   at A sin   ds  at A sin   an A cos    a n  at   d s  an ds  aA     A  ds  A  an ds  ( A cos  )ds  A( ds cos  ) 40 Closed Surfaces vs. Open Surfaces 41 Example    • Given a vector field F  ar (k1 / r )  a z k2 z where k1 and k2 are constants,   evaluate the scalar surface integral  F  ds over the surface of a closed cylinder about the z-axis specified by r = 2 and z = 3. S 42 Solution • The cylinder has three surfaces: the top face, the bottom face, and the side wall.          F  ds   F  ands   F  ands   F  ands S top bottom side wall 43 Solution   • Top face: z  3, an  a z   F  an  k2 z  3k2 ds  rdrd 2 2    F  ands    3k2rdrd  12k2 top 0 0   • Bottom face: z  3, an  a z   ds  rdrd F  an  k2 z  3k2 2 2    F  ands    3k2rdrd  12k2 bottom 0 0 44 Solution   • Side wall: r  2, an  ar   k1 k1 ds  rd dz  2d dz F  an   r 2 3 2    F  ands    k1d dz  12k1 side wall 3 0 • The total integral:    F  ds  12k2  12k2  12k1  12 (k1  2k2 ) S 45 Volume Integral of Vector Function   Fdv or V   Fdv V  • By resolving the vector F into its three components in the appropriate coordinate system, the volume  integral of F can be evaluated as the sum of three scalar integrals. • In Cartesian coordinates:     F ( x , y , z ) dv  ( a F ( x , y , z )  a F ( x , y , z )  a y y z Fz ( x , y , z )) dxdydz   x x V V     a x  Fx ( x, y , z )dxdydz  a y  Fy ( x, y , z )dxdydz  a z  Fz ( x, y , z )dxdydz V V V 46 Exercise  • Write down the integral  Fdv V in cylindrical coordinates.     F  ar Fr  a  F  a z Fz dv  rdrd dz 47 Del Operation 48 Gradient of Scalar Field • The gradient of a scalar is the vector that represents the magnitude and the direction of the maximum space rate of increase of that scalar.  dV grad V  V  an dn  is the “del” operator dV dV dn dV dV      cos   ( an  al )  (V )  al dl dn dl dn dn 49 Gradient of Scalar Field (cont.)   dV  (V )  al dl  (V )  dl         e.g. dl  a x dx  a y dy  a z dz dl  au1dl1  au 2dl2  au 3dl3 V V V dV  dl1  dl2  dl3 l1 l2 l3   V  V  V       au1dl1  au 2dl2  au 3dl3    au1  au 2  au 3 l1 l2 l3     V  V  V     dl   au1  au 2  au 3 l1 l2 l3    V  V  V V  au1  au 2  au 3 l1 l2 l3 50 Gradient in General Orthogonal Curvilinear Coordinates  V  V  V V  au1  au 2  au 3 l1 l2 l3         au 1  au 2  au 3 l1 l2 l3  1   1   1   au 1  au 2  au 3 h1 u1 h2 u2 h3 u3 li where hi  ui 51 Gradient in Principal Coordinates • In Cartesian coordinates:         ax  ay  az x y z • In cylindrical coordinates:    1      ar  a  az r r  z • In spherical coordinates: 1     1     aR  a  a R R  R sin   52 Example  • The electric field intensity E is derivable as the negative gradient of a scalar electric potential V, i.e.  E  V  Determine E at the point (0, 1, 0) if x V  E0e sin( y 4 ) 53 Solution          y  x E  V   a x  ay  a z  E0e sin( )  y z  4   x y  y y   x    a x sin( )  a y cos( )  E0e 4 4 4         E0  E (0, 1, 0)   a x  a y   aE E 4 2  Exercise  E  ?; aE  ? 54 Divergence of Vector Field  • The divergence of a vector field A at  any point is defined as the net outward flux of A per unit volume as the volume about the point tends to zero.   A  ds    div A    A  lim S v 0 v 55 Mathematical Representation of Divergence • Cartesian coordinates:  Ax Ay Az  A    x y z • Cylindrical coordinates:  1  1 A Az  A  ( rAr )   r r r  z • Spherical coordinates:  1  1  1 A 2  A  2 ( R AR )  ( A sin  )  R R R sin   R sin   56 Example • Find the divergence of the position vector to an arbitrary point P.  P P Solution     • In Cartesian coordinates: P  a x x  a y y  a z z  Px Py Pz P    x y z x y z    3 x y z 57 Solution   • In spherical coordinates: P  aR R  1  1  1 P 2 P  2 ( R PR )  ( P sin  )  R R R sin   R sin   1  1  2  2 ( R  R)  2 ( R3 )  3 R R R R    • In cylindrical coordinates: P  ar r  a z z  1  1 P Pz P  ( rPr )   r r r  z 1  z  (r  r)   3 r r z 58 Example  • The magnetic flux density B outside a very long current-carrying wire is circumferential and is inversely proportional to the distance to the distance to the axis of the wire.  Find   B Magnetic flux Wire 59 Solution • Let the long wire be coincident with the z-axis in a cylindrical coordinate system.   k B  a r where k is a constant  1  1 B Bz B  ( rBr )   r r r  z 1  k  ( )0 r  r 60 Divergence Theorem • The volume integral of the divergence of a vector field equals the total outward flux of the vector through the surface that bounds the volume.       Adv   A  ds V Closed surface S S  A Volume dv 61 Example   2   • Given A  a x x  a y xy  a z yz Verify the divergence theorem over a cube one unit on each side, i.e. show that     A  ds     Adv cube cube Given that the cube is situated in the first octant of the Cartesian coordinate system with one corner at the origin. z y x 62 Solution   • Front face: x  1, ds  a x dydz   11 2 2 1 1 A  d s  x dydz  x y0z0 1   front 0 0   • Back face: x  0, ds  a x dydz 1 1   2 2 1 1 A  d s   x dydz   x y0z0  0   back • Right face: 0 0   y  1, ds  a y dxdz 1   11  x2  1 1 A  ds    xydxdz  y   z 0   2  2 0 right 0 0 63 Solution   • Left face: y  0, ds  a y dxdz 1 1   x A  ds     xydxdz  y    2 left 0 0 • Top face:   z  1, ds  a z dxdy 1 1 2 1  1  z 0  0 0 1   1 1 y  A  ds    yzdxdy  z x 0      2 0 2 top 0 0 2   • Bottom face: z  1, ds  a z dxdy 1 1 1   1 y  A  ds     yzdxdy   z x 0    0   2 0 bottom 0 0 2 64 Solution • Add the surface integral over the six faces:   1 1 A  ds  1    2  2 2 cube  • The divergence of A is  Ax Ay Az  2    A     ( x )  ( xy )  ( yz )  3x  y x y z x y z 1 1 1     Adv     (3x  y )dxdydz cube 0 0 0 3 1 1 1 1 2 1  3 2 1  y 0 z 0 x  x 0 z 0  y    2 2 0 2 0 2 2 1 1 65 Curl of Vector Field  • The curl of a vector field B describes its rotational property, or circulation.  • Thecirculation of B is defined as the line integral of B around a closed contour C:    Circulation B   B  dl C 66 Example   • Find the circulation of a uniform field B  a x B0 around the contour abcd. c  b    Circulation B   a x B0  a x dx   a x B0  a y dy a b d a c d       a x B0  a x dx   a x B0  a y dy  B0 x  B0 x  0 The circulation of a uniform field is zero. 67 Example   • Find the circulation of an azimuthal field B  a B0 around the contour C.    Circulation B   B  dl C 2     a B0  a rd 0  2rB0  The circulation of B depends on the choice of contour. 68 Curl of Vector Field (cont.)   • The curl of a vector field B is the circulation of B per unit area, with the area s of the contour C being oriented such that the circulation is maximum.   1      B  curl B  lim nˆ  B  dl   s 0 s  C  max 69 Mathematic Representation of Curl • Cartesian coordinates:    Az Ay    Ax Az    Ay Ax    a y     A  a x       a z  z  x  y   z  y  x • Cylindrical coordinates:    1 Az A    Ar Az     a    A  ar      az z  r   z  r  1  Ar  (rA )  r  r     • Spherical coordinates:     A  aR 1 R sin     1 A   1  1 AR  AR  ( A sin  )   a  ( RA )  a ( RA )            R  sin   R R  R     70 Stokes’s Theorem • Stokes’s theorem converts the surface integral of the curl of a vector over an open surface S into a line integral of the vector along the contour C bounding the surface S.      (  B)  ds   B  dl S C 71