14
Lecture 9: Vector Calculus I 1. Key points Scalar and vector fields Gradient and directional derivative Laplacian Maple Derivatives VectorCalculus package SetCoordinates Vector Norm DotProduct Gradient , Del , Nabla Laplacian evalVF plots package plot3d fieldplot fieldplot3d display 2. Vectors as a function of time where , , and are unit vectors along , , and axes, respectively. Time derivative of time-dependent vectors. If we have a vector , then its time derivative is given by Example Suppose that a particle moving in a trajectory . Its velocity and acceleration are Using Maple

Lecture 9: Vector Calculus I - Dr. Ryoichi Kawai's …kawai.phy.uab.edu/courses/2011-Fall/ph420/maple/vector_analysis1.pdf · Lecture 9: Vector Calculus I 1. Key points Scalar and

Embed Size (px)

Citation preview

Lecture 9: Vector Calculus I

1. Key pointsScalar and vector fieldsGradient and directional derivativeLaplacian

MapleDerivativesVectorCalculus package

SetCoordinatesVectorNormDotProductGradient, Del, NablaLaplacianevalVF

plots packageplot3dfieldplotfieldplot3ddisplay

2. Vectors as a function of time

where , , and are unit vectors along , , and axes, respectively.

Time derivative of time-dependent vectors.

If we have a vector , then its time derivative is given by

ExampleSuppose that a particle moving in a trajectory . Its velocity and acceleration are

Using Maple

(2.2.1.1)(2.2.1.1)

(2.2.1.4)(2.2.1.4)

(2.2.1.2)(2.2.1.2)

(2.2.1.3)(2.2.1.3)

(2.2.1)(2.2.1)

Define a coordinate system.

There are many ways to differentiate vectors:

1. Using dot (common expression in physics)

We use the Cartesian coordinates.

Define a position vector as a function of t

Define the velocity vector

Define the acceleration

2. Using d/dx

We use the Cartesian coordinates.

Define a position vector as a function of t

(2.2.2.3)(2.2.2.3)

(2.2.2.2)(2.2.2.2)

(2.2.2.5)(2.2.2.5)

(2.2.3.3)(2.2.3.3)

(2.2.3.1)(2.2.3.1)

(2.2.3.2)(2.2.3.2)

(2.2.3.4)(2.2.3.4)

(2.2.2.4)(2.2.2.4)

Define the velocity vector

Define the acceleration

3. Using Maple command diff

We use the Cartesian coordinates.

Define a position vector as a function of t

Define the velocity vector

Define the acceleration

(2.2.4.3)(2.2.4.3)

(2.2.4.1)(2.2.4.1)

(2.2.4.2)(2.2.4.2)

(2.2.4.4)(2.2.4.4)

4. Using Maple differential operator

We use the Cartesian coordinates.

Define a position vector as a function of t

Define the velocity vector

Define the acceleration

Exercise

If the position vector is , find its velocity and acceleration.

Answer

We use the Cartesian coordinates.

Define the position vector:

Calculate the velocity:

Calculate the acceleration:

Show the results: = =

3. Scalar fields and Vector fields

A scalar field takes a scalar value at each point of space and expressed by a scalar function of spatial coordinates, i.e. or .Scalar fields are ubiquitous in physics. Foe examples:

U(r) Potential energy in classical mechanicsr) Electrostatic potential in electromagnetismr) Mass density, charge density r) Wave function in quantum mechanics

A vector field takes a vector value at each point of space and expressed by a vector function of spatialcoordinates, i.e. or .

Vector field is also ubiquitous in physics. For example,

Electric fields. Magnetic field

Vector potential Particle current Force field

4. GradientConsider a scalar field We want to know the change in when the position changed by

.

That is Now, we change the length of s without changing its direction. That can be done by writing where u is a unit vector in the direction of s and s is the length of s. Then, we have . Since u is constant, the change of f is solely

determined by s. Using the chain rule, the slope of the surface in the direction of is given by

This quantity is called directional derivative in the direction of .

The directional derivative has a form of dot product between u and .

is a vector field called "gradient of f" and it is also written as grad f. The direction of indicates the direction in which the field increases most rapidly (the largest slope) at point (x,y,z) and its magnitude is the slope of the field in that direction at the point.

can be viewed as a vector operator (del operator or nabla) defined as

f is perpendicular to the surface f=const.

and .

Suppose u lies on the surface defined by f=const, . Hence, . Since u is in the surface,

is perpendicular to the surface.

Example 1

We use the Cartesian coordinates.

Find the directional derivative of in the direction of at ()

Define the direction =

Normalization =

Define the scalar field Gradient =

Directional derivative =

Evaluate the gradient =

Example 2

Given the surface , find the unit vector normal to the surface at (1,-2,3).

Answer

Define the field

=

=

=

Example 2: Visualizing the gradient (2D)

=

Use mouse to rotate the image.

Example 3: Visualizing the gradient (3D)

Define the field.

Compute the gradient. =

Construct a vector field image.

The result is plotted in the right panel.

Gradient in other coordinates

Spherical Coordinates

=

The del operator in the spherical coordinates is defined by

.

Cylindrical coordinates

=

The del operator in the cylindrical coordinates is defined by .

Examples in Physics

Force = - gradient of potential energy

Electric field = - gradient of electrostatic potential

Fluid velocity = gradient of velocity potential

Exercise 4.1

Find the directional derivative of at in the direction of . Plot the gradient of .

Answer

=

=

=

Directional derivative = =

(Maple remark: DotProduct(u,v) can be expressed in a much simpler form u.v .)

At (1,2,-1), we have = 3 (Another

way: = 3)

Exercise 4.2

For the given field , find the vector normal to the surface at the point

.

Answer

=

=

=

5. Laplacian

Laplacian operator: =div$grad

Hence, the Laplacian operator is defined as .

When the Laplacian acts on a scalar field, the result is also scalar field.

Example

Evaluate the gradient of .

Define a scalar field

Laplacian is another scalar field =

Examples in Physics

Laplace equation

Poisson equation

Wave equation

Diffusion equation/heat equation

Schrödinger equation

Laplacian in other coordinates

Spherical coordinates

=

1

Rearranging the terms, we obtain the Laplacian in the spherical coordinates

Cylindrical coordinates

=

Rearranging the terms, we obtain the Laplacian in the cylindricalcoordinates

ExerciseCalculate the Laplacian of the following scalar fields.

(a) (b)

Answer

(a) = 0

(b) =

= simplify

0

Using the spherical coordinates for (b)

Noting that , = 0

Remark: The result in part b indicates that the Laplacian is zero everywhere. However, that isnot exactly true. At (0,0,0), the field diverges. Thus, the derivative is not defined at the origin.

The correct answer to (b) is . This is nothing but Poisson equation for a point

charge.

6. Homework (Due at 11am, 9/27/2011)

1Suppose that the temperature at the point is given by the equation

.In which direction is the temperature increasing most rapidly at (-1,2,3), and at what rate? Heat flows in the direction of . Plot the heat flow using 3D arrows.

2

For a given potential , the force at point is given by . Plot the force field for the potential . Find the force at (2,-1,1).

3

Find the gradient of and the derivative in the direction of at (1,2,-1).

4

For a spherical field where . Show that where r is a radial

vector.