geology 351 - geomathematics an introduction to...
TRANSCRIPT
Geology 351 - Geomathematics
Tom Wilson, Department of Geology and Geography
Dept. Geology and GeographyWest Virginia University
An introduction to differential calculus
Developing basic concepts and learning some
differentiation rules
Tom Wilson, Department of Geology and Geography
• Developing the relationship of the slope of a function to its derivative illustrated using exponential, trig and polynomial functions.
Basic rules:• Power rule• Sum rule• Chain rule• Product and quotient rules• Exponential rules
Some in-class example problems
Problems handed out last time -
Turn in porosity problem before leaving
Tom Wilson, Department of Geology and Geography
In the porosity density relationship = 0e(-z/), assume 0 is 0.4 and is 1.5. What is the
slope (or porosity gradient) between depths of 1 and 2 km in this area? What is the slope
between 1.4 and 1.6 kilometers? Calculate these slopes out explicitly and sketch your
results on the graph of this function on the back of this page.
The derivative is just a slope: the slope at a point on the curve or the tangent.
Between 1 and 2 km depths, slope =-0.099/km
Between 1.4 and 1.6 km depths, slope =-0.0982/km
Tom Wilson, Department of Geology and Geography
The derivative or slope of the tangent line at the depth 1.5 km =-0.0981/km
z
Slope = /z
Slope at this point is the derivative
At 2.5km, the slope is -0.05
at 3.5 km the slope is -0.0259
at 0.5, -0.191
Tom Wilson, Department of Geology and Geography
Z
0 1 2 3 4 5
PH
I
-0.3
-0.2
-0.1
0.0
0.1
0.2
0.3
0.4Porosity depth relationship
=0.4e-z/1.5
Check in-class work
Tom Wilson, Department of Geology and Geography
0.5~ 0.19
1.5~ 0.1
3~ 0.04
z
z
z
Slopes evaluated over z of
0.2km about a given depth
You’ll find the derivative z
ode
dz
Evaluation of the derivative at each of these points yields
0.51.5
1.51.5
1.51.5
0.40.19
1.5
0.4 0.098
1.5
0.4 0.036
1.5
zod
e edz
e
e
The individual slope calculations provide approximate estimates of the
slope at the midpoint. The derivative is exact and also provides an
analytical expression that is easily plotted.
Slopes of the cosine are a little more obvious
Tom Wilson, Department of Geology and Geography
0, -0.707 (at 0.785), -1 (at 1.571), -0.707 (at 2.356)
Tom Wilson, Department of Geology and Geography
(radians)0.
00.
51.
01.
52.
02.
53.
03.
54.
04.
55.
05.
56.
0
cos
()
-1.0
-0.5
0.0
0.5
1.0Cosine function
-sin()
Calculation of these
slopes, point-by-
point, outline the
negative sine function
For y=x2
Tom Wilson, Department of Geology and Geography
x0 1 2 3 4 5 6
y
0
5
10
15
20
25
30
35
40
y=x2
Derivative of a constant: i.e. y-a
Tom Wilson, Department of Geology and Geography
y=a
y
x
What’s the slope?
So derivative of a constant is 0
The y is zero so y/x and dy/dx are always 0.
Tom Wilson, Department of Geology and Geography
The book works through the differentiation of y = x2, so let’s try y =x4.
4)( dxxdyy
multiplying that out -- you get ...432234 )()(4)(64 dxdxxdxxdxxxdyy
Tom Wilson, Department of Geology and Geography
432234 )()(4)(64 dxdxxdxxdxxxdyy
Tom Wilson, Department of Geology and Geography
432234 )()(4)(64 dxdxxdxxdxxxdyy
Remember the idea of the dy and dx is that they represent differential changes that are infinitesimal - very small.
So if dx is 0.0001 (that’s 1x10-4) then (dx)2 = 0.00000001 (or 1x10-8) (dx)3 = 1x10-12 and (dx)4 = 1x10-16.
So even though dx is very small, (dx)2 is orders of magnitude smaller
Tom Wilson, Department of Geology and Geography
432234 )()(4)(64 dxdxxdxxdxxxdyy
so that we can just ignore all those terms with (dx)n where n is greater than 1.
dxxxdyy 34 4
Our equation gets simple fast
Also, since y =x4, we have
dxxydyy 34
dxxdy 34
and then -
Tom Wilson, Department of Geology and Geography
34xdx
dy
Divide both sides of this equation by dx to get
dxxdy 34
This is just another illustration of what you already know as the power rule,
Tom Wilson, Department of Geology and Geography
1 nnaxdx
dyis
Just as a footnote, remember that the constant factors in an expression carry through the differentiation.
This is obvious when we consider the derivative -
baxy 2
which - in general for naxy
+ =
The shift does not change the slope (derivative).
Tom Wilson, Department of Geology and Geography
bdxxadyy 2)(
bdxxdxxadyy )2( 22
axdxbaxdyy 2)( 2
axdxydyy 2
)2( xadx
dy
Examining the effects of differential increments in y and x we get the following
Where y=ax2+b
Alternatively
Tom Wilson, Department of Geology and Geography
2
2
2
( )
=
=
=2
dy d ax b
dx dx
dax db
dx dx
dax
dx
ax
=0 since b is a constant.
Line with slope 2a
and 0 intercept.
Distribute the d/dx operator
Tom Wilson, Department of Geology and Geography
Don’t let negative exponents fool you. If n is -1, for example, we still have
1 nnaxdx
dy
2 axdx
dy
or just
Tom Wilson, Department of Geology and Geography
Tom Wilson, Department of Geology and Geography
)()()( xgxfxy Given the function -
what is dx
dy?
dx
dg
dx
df
dx
dy
We just differentiate f and g individually and take their sum, so that
Distribute the d/dx operator
Tom Wilson, Department of Geology and Geography
Take the simple example
)()( 42 baxcxy
- what is dx
dy?
baxcxy 42We can rewrite
Then just think of the derivative operator as being a distributive operator that acts on each term in the sum.
Tom Wilson, Department of Geology and Geography
Where
then -
On the first term apply the power rule
What happens to
baxcxy 42
2 4( )dy d
x c ax bdx dx
2 4dy dx dc dax db
dx dx dx dx dx and
2dx
dxdc
dx?
What is the derivative of a flat line?
Tom Wilson, Department of Geology and Geography
Successive differentiations yield
Thus -
342 axxdx
dy
2 4
32 0 4 0
dy dx dc dax db
dx dx dx dx dx
dyx ax
dx
Tom Wilson, Department of Geology and Geography
)()( 42 baxcxdx
d
dx
dy
Differences are treated just like sums
so that
is just
342 axxdx
dy
Tom Wilson, Department of Geology and Geography
Tom Wilson, Department of Geology and Geography
Differentiating functions of functions -
Given a function 22 )1( xy we consider
)()1( 2 xhx write 2hy compute hhdh
d
dh
dy22
Then compute xxdx
d
dx
dh212 and
take the product of the two, yielding dx
dh
dh
dy
dx
dy.
Tom Wilson, Department of Geology and Geography
xxdx
dh
dh
dy
dx
dy2).1(2. 2
)1(4 2 xx
22 )1( xy
We can also think of the application of the chain rule especially when powers are involved as working form the outside to
inside of a function
Tom Wilson, Department of Geology and Geography
22 )1( xyWhere
xxdx
dy2.)1(2 12
Derivative of the quantity squared viewed from the outside.
Again use power rule to differentiate the inside term(s)
Tom Wilson, Department of Geology and Geography
Using a trig function such as
)2sin( axy
let axh 2
then dx
dh
dh
dy
dx
dy.
Which reduces to aaxdx
dy2).2cos( or just
)2cos(2 axadx
dy
(the angle is another function 2ax)
A brief look at derivatives of trig functions.
Consider dsin()/d.
Start with the following -
Tom Wilson, Department of Geology and Geography
sin( ) sin( )
sin( ) sin cos cos sin
sin( ) sin cos cos sin
cos( ) cos cos sin sin
cos( ) cos cos sin sin
identities
Take notes as we go through this and the derivative of the cosine in class.
We end up with
Tom Wilson, Department of Geology and Geography
0
sincos lim
3 5 7
sin ...3! 5! 7!
When is small (such as in ), sin~
We can also see this graphically using arc length relationships
Tom Wilson, Department of Geology and Geography
In general if
))...))))((...(((( xqihgfy
then
dx
dq
di
dh
dh
dg
dg
df
df
dy
dx
dy........
Tom Wilson, Department of Geology and Geography
How do you handle derivatives of functions like
)()()( xgxfxy
?
or
)(
)()(
xg
xfxy
The products and quotients of other functions
Tom Wilson, Department of Geology and Geography
fgy
Removing explicit reference to the independent variable x, we have
))(( dggdffdyy
Going back to first principles, we have
Evaluating this yields
dfdgfdggdffgdyy
Since dfdg is very small we let it equal zero; and since y=fg, the
above becomes -
Product rule applied to straight line formula
with its constants
Tom Wilson, Department of Geology and Geography
y=ax+b
y
x
b is the intercept
The slope a=y/x is a constant
dy/dx=xda/dx+adx/dx +db/dx = a
b, the intercept is a constant that just gets added to the ax and shifts it up or down. The slope does not change.
Product rule
Tom Wilson, Department of Geology and Geography
&
dy gdf fdg
dy df dgg f
dx dx dx
Which is a general statement of the rule used to evaluate the derivative of a product of functions.
The quotient rule is just a variant of the product rule, which is used to differentiate functions like
g
fy
Tom Wilson, Department of Geology and Geography
2g
dxdg
fdx
dfg
g
f
dx
d
The quotient rule states that
The proof of this relationship can be tedious, but I think you can get it much easier using the power rule
Rewrite the quotient as a product and apply the product rule to y as shown below
1 fgg
fy
Tom Wilson, Department of Geology and Geography
fhy
We could let h=g-1 and then rewrite y as
Its derivative using the product rule is just
dx
dhf
dx
dfh
dx
dy
dh = -g-2dg and substitution yields
2g
dxdg
f
g
dxdf
dx
dy
Tom Wilson, Department of Geology and Geography
2g
dxdg
f
g
dxdf
g
g
dx
dy
Multiply the first term in the sum by g/g (i.e. 1) to get >
Which reduces to
2g
dxdg
fdx
dfg
dx
dy
the quotient rule
Tom Wilson, Department of Geology and Geography
Next time we’ll use Excel to demonstrate that the rules
noted below accurately characterize slope variations.
Tom Wilson, Department of Geology and Geography
xxde
edx
( )cxcx cxdAe d cx
Ae cAedx dx
This is an application of the rule for differentiating exponents and the chain rule
Basically indestructible in this form
( )( )
h xh xde dh
edx dx
Rewrite the function
Take derivative of the exponent
For a function like , this is not the case. Calculating the derivative becomes a little more complex.
cxAe
Tom Wilson, Department of Geology and Geography
xxde
edx
( )cxcx cxdAe d cx
Ae cAedx dx
Basic rule for differentiating exponential functions
Sketch and discuss
Rewrite the exponential function and multiply it by the derivative of the exponent – a two-step process.
Second derivative?
Tom Wilson, Department of Geology and Geography
2
2
cxd Ae
dx
cxcxdAe
cAedx
2
2
cx cxd Ae dcAe
dx dx and
Follow up on carrying the constants through
Tom Wilson, Department of Geology and Geography
Use the product rule to differentiate a simple function like
2y ax
dy dg dff g
dx dx dx
….
Tom Wilson, Department of Geology and Geography
If we finish these today
hand in otherwise bring in
for discussion next time
Next time we’ll put the rule to the test using Excel
Tom Wilson, Department of Geology and Geography
0
czdc e
dz
In the lab exercise c = 1.
derivative
Look over problems 8.13 and 8.14
Tom Wilson, Department of Geology and Geography
•Bring questions to class next time•No due date set at present for these two problems.
Tom Wilson, Department of Geology and Geography
Next time we’ll continue with exponentials and logs, but also have a look at question 8.8 in
Waltham (see page 148).
xexi . )( 2
)sin(.3 )( 2 yii
)tan(.xx.cos(x) )( 2 xziii
24 17)ln(.3 )( Biv
Find the derivatives of
Before leaving
Tom Wilson, Department of Geology and Geography
• Hand in analysis of porosity/depth relationship
• Depending on progress in the class today I may pick up the in-class differentiation problems.
Looking ahead
Tom Wilson, Department of Geology and Geography
continue reading Chapter 8 – Differential Calculus
Look over problems 8.13 and 8.14