Beruflich Dokumente
Kultur Dokumente
Useful resources 4
Vectors 5
Vector space . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5
Linear independence and linear dependence . . . . . . . . . . . . . . . . . . . . . . . 7
Basis . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8
Dimension of a vector space . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8
Norms . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9
Norms over a real and a complex space . . . . . . . . . . . . . . . . . . . . . . . 9
Norms over polynomial spaces . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10
Scalar (or dot) product of vectors over a real and a complex space . . . . . . . . . . . 10
Scalar (or dot) product of vectors over a polynomial space . . . . . . . . . . . . . . . 10
Matrices 11
Spectial Matrices . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11
I. Square Matrices . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11
II. Rectangular Matrices . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12
Equality, Addition, Multiplication by a scalar . . . . . . . . . . . . . . . . . . . . . . 12
Matrix multiplication . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 13
Matrix Multiplication Rules . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 13
Invertible Matrix . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14
Matrix transposition and related matrices . . . . . . . . . . . . . . . . . . . . . . . . 14
Determinant, minor and rank . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15
Linear systems 17
Solution of a linear system and its geometrical interpretation . . . . . . . . . . . . . . 17
Finding a solutions of systems of inhomogeneous linear equations . . . . . . . . . . . 19
Gauss elimination . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19
Cramer’s rule . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19
Solutions of systems of homogeneous linear equations . . . . . . . . . . . . . . . 20
Remarques on numerical solution of systems of linear equations . . . . . . . . . . . . 20
Derivatives 22
Limit of a function . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 22
Rules to calculate derivatives . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23
Interpretation of derivatives . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 24
Table of Key Derivatives . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 27
1
Derivatives of functions of multiple variables 28
Partial derivatives . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 28
Chain rule for the function of multiple variables. Jacobian matrix . . . . . . . . . . . 29
Directional derivative . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 31
Definite integral 42
Defined integral: properties . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 43
Fundamental theorem of calculus . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 43
Substitution rule for definite integrals . . . . . . . . . . . . . . . . . . . . . . . . . . . 44
Multiple Integrals 45
Product under the integral sign and product of the integrals . . . . . . . . . . . . . . 46
Double Integrals Over General Regions . . . . . . . . . . . . . . . . . . . . . . . . . 46
Gaussian Integrals . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 48
Surface integrals 59
Divergence . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 59
Operator of Laplace . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 60
Vector form of Green’s Theorem . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 60
Surface integral and the Divergence Theorem . . . . . . . . . . . . . . . . . . . . . . 60
2
Differential equations 62
Ordinary differential equations of first order: first order ODE . . . . . . . . . . . . . . 63
Separation of variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 63
Substitutions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 65
Exact first order ordinary differential equation . . . . . . . . . . . . . . . . . . 66
Inexact equations: integrating factors . . . . . . . . . . . . . . . . . . . . . . . . 67
Variation of a constant parameter . . . . . . . . . . . . . . . . . . . . . . . . . . 69
3
Useful resources
Theory:
On calculus (derivatives, integration, etc):
http://tutorial.math.lamar.edu/
Exercises:
On calculus (derivatives, integration, etc) the same resource as the theory:
http://tutorial.math.lamar.edu/
On matrices:
https://matrix.reshish.com/
Plot of graphic
https://graphsketch.com/
4
Vectors
Vector space
Definition 1: Closed set:
The set is closed under a certain operation if and only if the result of the operation belongs to
the set.
Defitions 2: Vector space:
A vector space V is a collection of objects with two operations: (vector) addition and multipli-
cation by a scalar (number). This collection (vector space) is closed under these two operations.
The two operation should satisfy the following axioms ∀~x, ~y , ~z ∈ V and α, β ∈ R
Figure 1: Graphical representation of a vector from a linear vector space R2 using (x, y) coor-
dinate plane
How to define the addition of vectors and their multiplication by a scalar in a R2 ? These
definitions are up to us providing they satisfy axioms formulated at the beginnig
of the chapter! For example, let define the addition of two vectors (a1 , a2 ) and (b1 , b2 ) as :
(a1 , a2 ) + (b1 , b2 ) = (a1 + b1 , a2 + b2 ) (2)
5
A graphical representation of the ”just defined” vector addition in R2 corresponds to a so-called
parallelogram rule (fig.2)
Figure 2: Graphical representation of the addition of vectors in a linear vector space R2 using
(x, y) coordinate plane
Example 3: C2 and Cn respectively to R2 and Rn where the underlying field is C, the complex
numbers.
Example 4: Linear vector polynomial space of all polynomials of degree n (including those
whose degree is less than n) Pn
( n
)
X
Pn = aj xj |a0 , a1 , · · · , an ∈ R (4)
j=0
6
Figure 3: Graphical representation of a vector from a linear vector polynomial space P n using
(x, y) coordinate plane
Exercise:
Consider a linear vector space R2 = {(a1 , a2 )|a1 , a2 ∈ R}.
7
From the given definition it follows that if a vector space S = {~v1 , ~v2 , ..., ~vk } ⊂ V, is linearly
dependent, then one member of this set can be expressed as a linear combination of the others.
Indeed, if aj 6= 0, taking into account that
1
~vj = − [a1~v1 + · · · + ak~vk ]
aj
Basis
Definition. A basis is a (finite or infinite) set S = {~vi }i∈N ⊂ V of vectors, that spans the
whole vector space V and is linearly independent. ”Spanning the whole space” means that any
vector ~u ∈ V can be expressed as a linear combination of the basis elements:
where the ak are scalars, called the coordinates (or the components) of the vector ~u with respect
to the basis S, and ~vik , (k = 1, ..., n) elements of S.
Note that if S = {~vi }i∈N ∈ V is a basis of V, then every vector ~u ∈ V has a unique represen-
tation in S. Indeed, suppose that a second representation is possible, so:
then, using the axioms for the addition operation in a vector space, make a difference of these
two equality for the ~u:
Since, by definition, the set of vectors {~vi }i∈N is linearly independent, it follows that ai = bi .
8
Examples:
1. dim(Rn ) = n
2. dim(P n ) = n + 1 (see the following example)
3. Consider a linear vector space of polynomials of degree n P n = {an xn + an−1 xn−1 + · · · +
a1 x 1 + a0 } .
Prove that the powers x0 = 1, x2 , · · · xn are linearly independent and since they span the P n ,
they form a basis of P n .
Proof demonstration in the class
Exercise: Prove the statement made above that dim(P n ) = n + 1
Exercise:
Let vector space M equal to all rectangular arrays of two rows and three columns with real
entries. Find a basis for M, and find the dimension of M. Note
(" # )
a b c
M= a, b, c, d, e, f ∈ R (9)
d e f
Norms
Norms are a way of putting a measure of distance on vector spaces. First, we shall present
norms over R and C and then norms on polynomials vector space.
Definition Let V be a linear vector space and suppose that a norm on V, defined hereafter as
|| · || is a function from V to the nonnegative reals for which the follwing fulfils:
Examples. Let V = Rn ( or Cn ).We can define for elements ~x = (x1 , · · · , xn ) of V the following
norms:
It can be proved that all norms defined by eqs.13,14 and 15 correspond to the definition of the
norm given above. Yet, how to deal with 3 different norms?
Definition Let k·ka and k·kb be two vector norms on Cn . We say that these norms are equiv-
alent if there are positive constants m, M such that ∀x ∈ Cn m kxka ≤ kxkb ≤ M kxka .
9
Theorem All norms are equivalent.
Exercise: Take as an example the linear vector space R2 .
Question 1: Can you interpret graphically all given norms?
Question 2: What means that all norm are equivalent if you compare two vectors from R2 ?
Polynomial spaces, as we have considered earlier, can be given norms as well. Yet, sometimes it
is difficult to consider all the values of the independent variable. In many cases a domain of the
polynomials has to be restricted. Let us introduce a notation P k (a, b) = P k for the polynomials
whose independent variable is restricted to a domain [a, b].
Now, let us define norms accepting that a polynomial from the P k (a, b) can be considered as a
function p(x):
Z b 1/2
2
(a) kp(x)k2 = |p(x)| dx
a
Z b
(b) kp(x)k1 = |p(x)|dx
a
(c) kp(x)k∞ = max |p(x)|
a≤x≤b
Scalar (or dot) product of vectors over a real and a complex space
Definition. If ~xquadandquad~y are vectors of the same length defined in Rn (or Cn ) , with
~x = (x1 , · · · , xn ), ~y = (y1 , · · · yn ), then the scalar product (or dot product) of ~x and ~y is given
by the formula:
n
X
~x · ~y = h~x, ~y i = xi y i (16)
1
10
Matrices
Definition
Matrix is a collection of objects (such as numbers, polynomials, etc) ordered in rows and
columns. The size of the array is written as m × n, where m is number of rows and n is
number of columns.
Examples:
" #
a b c
A2,3 =
d e f
x2 + y 2 + 1 5xy 7
B3,3 = 11 8x + y 2 −3xy + 4x2
columns
a11 a12 · · · a1n
a21 a22 · · · a2n
Am,n =
· · · · · ·
rows
···
am1 am2 · · · amn
For a matrix given above:
· uppercase A denotes a matrix
· lowercase a denotes an entry (an element) of a matrix
· both, an indexed uppercase Aij and lowercase aij denotes an entry ij of the matrix
Notation
The set of all m × n matrices is denoted by Mm,n (or Mm,n (F ) where F is a field, it can be R
or C or polynomials, etc)
In a case where m = n we write M n (Mn (F )) to denote the matrices of size n × n.
Spectial Matrices
I. Square Matrices
If m = n, the matrix is called square. For a square matrix the following cases can be considered
1. Diagonal matrices
If aij = 0 for i 6= j and aii 6= 0, a matrix A is called diagonal
A diagonal matrix A may be denoted by diag(d1 , d2 , · · · , dn ) where aii = di
11
2. Identity matrix
The diagonal matrix diag(1, 1, · · · , 1)is called the identity matrix and is usually denoted by In
(cf illustration):
1 0 ··· 0
0 1 · · · 0
In = ..
0
0 . 0
0 0 ··· 1
The identity matrix can be simply denoted I if n is supposed to be known.
Definitions
A rectangular matrix A is called nonnegative if aij ≥ 0∀i, j.
A rectangular matrix A is called positive if aij > 0∀i, j.
aij = bij ∀ i, j
Definition If A is any matrix and α ∈ R (or α ∈ C) then the scalar multiplication is defined
as
B = αA with
bij = αaij ∀ i, j
12
A theorem says that the defined operations of additions of matrices and multiplication by a
scalar satisfy the rules of (i) commutativity, (ii) associativity, (iii) distributivity of a scalar and
also to:
4. The equality α(βA) = αβA
5. A sum with a zero matrix (a matrix full of all zeros) for which A + 0 = A and α0 = 0.
6. (α + β)A = αA + βA
7. 0A = 0
8. α0 = 0
This theorem can be proved using the properties of scalars and of the field (sets) to which
element of the matrices belongs
Matrix multiplication
Definition
If A is m × n and B is n × p. C = AB is the m × p matrix with entries defined as
Pn
cij = k=1 aik bkj for 1 ≤ i ≤ m and 1 ≤ j < p
A1 = A, A2 = AA, A3 = AAA
An = An−1 A = A · · · A (n f actors)
AIn = A, and Im A = A
Invertible Matrix
AB = BA = I
In this case B is called the inverse of A, and the notation for the inverse is A−1 .
Example. Let
" #
1 3
A=
−1 2
Find A−1 . Solutions: using the definition of the inverse matrix, compose a system of linear
equations. Solve it. You should get the answer:
2 3 " #
− 1 2 −3
A−1 = 51 15 =
5 1 1
5 5
Remark: A square matrix is NOT necessarily invertible. A matrix A should satisfy a certain
condition to be reversible, see the section of Linear systems.
(A)Tij = Aji
In words: The rows of A become the columns of AT , taken in the same order.
Notations
Let us denote as A∗ a matrix whose entries are complex conjugate to the entries of A: aij = a∗ij
Clearly, (A∗ )∗ = A
Properties of transpose For matrices A, B and scalar c we have the following properties of
transpose:
14
T
1. AT = A
2. (A + B)T = AT + BT
3. (AB)T = BT AT
4. (cA)T = cAT
∗
5. (A∗ )T = AT
AT = A
AT = −A
Remark 1: A similar procedure can be applied if the size of the matrix is larger.
Remark 2: A general formula for the determinant of a square matrix can be found elsewhere
(cf. wikipedia)
15
(i, j) minor, or a first minor) is the determinant of the submatrix formed by deleting the i-th
row and j-th column. This number is often denoted Mi,j .
16
Linear systems
The solutions of linear systems is likely the single largest application of matrix theory.
Definition of a linear system of equations
Let the coefficients aij , 1 ≤ i ≤ m and 1 ≤ j ≤ n and the data bl , 1 ≤ l ≤ m are known. We
define the linear system for the n unknowns x1 , ·, xn to be:
Ax = b
with
a11 a12 ··· a1n x1 b1
a21 a22 ··· a2n x2 b2
A=
.. .. .. ,
.. x=
.. ,
b=
..
. . . . . .
am1 am2 · · · amn xn bm
Definition of linearly dependent equations. An equation is said to be linearly dependent
with others in the system if it can be obtained from them with operation of multiplication by
a scalar and summation.
the first case the solution set does not change, it corresponds to the found point while in the
second the solution set is empty, see Fig.5.
Figure 5: Graphical interpretation of solution of a linear system for two variables with three
equations. At the left overestimated systems, but any system of two equations gives the same
solution; at the right: overestimated inconsistent system
A necessary and sufficient condition for the existence of a solution set for the system
of linear equation is the following:
A system of linear equations has one and only one solution set if it consists of linearly indepen-
dent equation, number of which is equal to the number of unknowns.
18
equal to the number of independent variables.
Example: consider a system with a matrix A of a size n × n, with n unknowns and the vector
of free members b is not full of zeros
An x = b
It will have one and only one solutions set if det |A| =
6 0.
In theory, solution of a system can be obtained using Gauss elimination which is based on three
operations:
(GE1) Interchange two equations
(GE2) Multiply any equation by a nonzero constant
(GE3) Add a multiple of one equation to another
It can be proved that these operations do not change the solution set of the systems. The idea
is to get from an initial matrix A an upper-triangle matrix (fig.) which allows easily find the
unknowns.
a11 a12 a12 · · · a1n x1 b1
0 a22 a23 · · · a2n x2 b2
A=
0 0 a 33 · · · a 3n x3 = b3
. .. .. . . .. . .
.. . . . . . .
. .
0 0 0 · · · amn xn bn
Cramer’s rule
Alternatively, Cramer’s rule can be used which says that if a system of equations is given in a
matrix form
Ax = b
and if det(A) 6= 0, then the system has a unique solution, whose individual values for the
unknowns are given by:
det(Ai )
xi = i = 1, . . . , n
det(A)
where Ai is the matrix formed by replacing the i-th column of the matrix A by the column
vector b.
19
Solutions of systems of homogeneous linear equations
A system of linear equations where the right part (free members) is equal to zero (cf.20) is
called a system of homogeneous linear equations.
Ax = 0 (20)
From consideration above we know that if det(A) 6= 0 in 20 then the given system has one
and only one solution set which is (obviuosly) x ≡ 0. The solution set which contains only
zeros is called ”trivial solution”. Consequently, to a necessarily condition that the system 20
would have non-trivial solution is det(A) = 0 and in this case there are infinitely many solution
sets which have the following properties:
· If u and v are two vectors representing solutions to a homogeneous system, then the vector
sum u + v is also a solution to the system.
· If u is a vector representing a solution to a homogeneous system, and r is any scalar, then ru
is also a solution to the system.
20
Exercises with matrices and linear systems
Matrix transposition
Transpose the following matrices:
x1
x2
8x 5y 12xy
x3
A = 28z 43x 87y X= (21)
x4
4 11 5xy .
.
.
xn
a11 a12 a13 0 0 0
A = a21 a22 a23 0 0 0 (22)
1 2 −1
−61
B= 2 (24)
−13
Block Matrices
Sometimes it is convenient work with partitioned or blocked matrices, that are matrices whose
entries are themselves matrices. Let us try to see an example. Let I2 is an identity 2 × 2
matrix. Let the matrix A is expressed as:
" #
aI2 cI2
A= (25)
dI2 eI2
21
Derivatives
Limit of a function
To start with, first of all we should refresh the definition of the limit of a function which is the
following.
Definition of the limit of a function Suppose f : R → R is defined on the real line and
p, L ∈ R. It is said the limit of f , as x approaches p, is L and written
if the following property holds: For every real ε > 0, there exists a real δ > 0 such that for all
real x condition 0 < |x − p| < δ implies |f (x) − L| < ε. The value of the limit does not depend
on the value of f (p), nor even that p be in the domain of f .
Example
The function
sin x
f (x) = (27)
x
is not defined at x = 0 but the limit there exists and is equal to 1.
Example
Limits can also have infinite values, example is the function f (x) = 1/|x| where at x = 0 the
function is not defined and limits from the left and from the right (i.e. for x > 0 and x < 0)
are both equal to infinity.
Calculation of a limit of a function Among one of properties of the limit the one is of
special interest for us and which actually serves for the definition of a continuous function: The
function f is continuous at p if and only if the limit of f (x) as x approaches p exists and is
equal to f (p).
Consequently, for continuous functions the value of a limit at a certain point is simply a value
of the function at this point.
Definition of a derivative
The derivative of f (x) with respect to x (in any point) is the function f 0 (x) which is defined
as a limit
f (x + h) − f (x)
f 0 (x) = lim (28)
h→0 h
If this limit exist for any point where the function is defined, we say that the function f (x)
is differentiable everywhere. When we say that the limit exist, we assume that both, left and
right limits exist and they are equal.
22
Example of a derivative calculation via definition 1: Consider example f (x) = x2 . Let’s
check if the function is differentiable everywhere. Apply the definition
f (x + h) − f (x) (x + h)2 − x2
f 0 (x) = lim = lim =
h→0 h h→0 h
2xh + h2
= lim = 2x
h→0 h
Another example of a derivative calculation via definition: Consider a function
x2 , if x ≤ 1
f (x) = (29)
x, if x 1
According to the previous example, for all points x < 1 the derivative exists and is equal to 2x.
For all points x > 1 according to definition, the derivative is
f (x + h) − f (x) (x + h) − x h
f 0 (x) = lim = lim = lim = 1
h→0 h h→0 h h→0 h
Consequently, in the point x = 1 the limit from the left side (x → 1 − 0) exists and equal to
2, but the limit from the right side (x → 1 + 0) is equal to 1. The limits are not equal, the
function has no derivative in the point x = 1.
where A does not depend on dx and o(x) is so-called ”little o”. In this case the linear part
dy = Adx is called ”differential”.
Note that the function y = f (x) has a (first) differential at the point x if and only if it has a
(first) derivative at this point defined as dy/dx = f 0 (x), so that δy = f 0 (x)dx + o(dx).
Using definition given by eq.28, it is possible to define some key derivatives, list of them is
provided at the end of this chapter.
Summation rule
d [f (x) + g(x)] df dg
[f (x) + g(x)]0 = = f 0 (x) + g(x)0 = + (31)
dx dx dx
23
Product rule
d [f (x) · g(x)]
[f (x) · g(x)]0 = = f 0 (x)g(x) + f (x)g(x)0 (32)
dx
As a consequence, a rule for the case of a product with a constant
Chain rule
d[f (g(x))]
(f [g(x)]))0 = = f 0 [g(x)] · g 0 (x) (33)
dx
As a consequence, a quotient rule (demonstrated in slides)
Interpretation of derivatives
Slope of the tangent line
One of the major interpretations of the derivative f (x) at a point x0 is the slope of the tangent
line to f (x) at x0 (cf fig. 6). Furthermore, the slope of the line perpendicular to the tangent
(or the line which is ”normal” to the curve) at the point x0 can be obtain.
Figure 6: Illustration of a tangent line and a perpendicular line to f (x) = x2 at the point x = 1
Example 1: Sketch the graph of a derivative for the function given at fig.7. Steps to do:
1. Define the ”critical points” that are points where the line tangential to the curve is horizon-
tal. At these points the derivative is equal to zero.
2. Define if the function increases or decreases between the critical points found during the
first step: this will provide the sign of the derivatives between the critical points
Example 2: study the property of the function y(x) = x(ln x)2 and sketch this function
(demonstrated in slides)
24
Figure 7: Sketch a graph for derivative of the given function
Figure 8: A graph of derivative of the function given in fig. 7. What about the second
derivative?
Implicit derivation
A functions can be given in a form not resolved for y(x), i.e. f (x, y) = g(x, y) examples are:
yx = 1
x2 + y 2 = 9
x3 y 5 + 3x = 8y 3 + 1
··· (34)
25
e2x+3y = x2 − ln(xy 3 )
0 2x+3y (y 3 + 3xy 2 y 0 )
(2 + 3y )e = 2x −
xy 3
1 3y 0 )
2e2x+3y + 3y 0 e2x+3y = 2x − −
x y
1 1
3y 0 (e2x+3y − ) = 2x − 2e2x+3y −
y x
(35)
26
Table of Key Derivatives
Table of derivatives
dxα
= αxα−1
dx
dex
= ex
dx
dax
= ax ln a
dx
dln(x) 1
=
dx x
dC
=0
dx
(36)
d sin x
= cos x
dx
d cos x
= − sin x
dx
d tan x 1
= = (secx)2
dx (cos x)2
d cot x 1
=− = (−cscx)2
dx (sin x)2
(37)
Let
x = sin y y = arcsin x
then
d arcsin x 1
=p
dx (1 − x2 )
d arccos x 1
= −p
dx (1 − x2 )
d arctan x 1
=
dx 1 + x2
(38)
27
Derivatives of functions of multiple variables
Similar to the definition of a limit of a function of one variable x, we can introduce definition
of a limit for the function of multiple variables. A simple formulation is as following
x2 y 2 02 y 2
lim = lim =0
(x,y)→(0,0) x4 + 3y 4 (0,y)→(0,0) 04 + 3y 4
x2 y 2 x2 x2 1
lim 4 4
= lim 4 4
=
(x,y)→(0,0) x + 3y (x,x)→(0,0) x + 3y 4
Partial derivatives
Definition of partial derivatives
Two first order partial derivatives can be defined for the function of two variables as following:
∂f (x, y) f (x + h, y) − f (x, y)
fx0 (x, y) = = lim (40)
∂x h→0 h
f (x, y + h) − f (x, y)
fy0 (x, y) = lim (41)
h→0 h
Example
√
f (x, y) = x4 − 10x2 y 2 + 6 y − 10
fx0 (x, y) = 4x3 − 20xy 2
1
fy0 (x, y) = −20x2 y + 3 √
y
Definition of the differential
Definition of the differential of a function of multiple variable (here we have only two) is similar
to the case of one variable. Let the function z = f (x, y) is defined in a neighborhood of a point
(x, y) and dx, dy are variations (increase) of the independent variables x and y. It is said that
the function z = f (x, y) has a (first) differential in the point (x, y) if its variation at this point
can be presented as
The function f (x, y) can be represented as z = f (g(t), h(t)). Then the ”simple” chain rule is
applicable:
dz d[f (x, y)] ∂f (x, y) dx ∂f (x, y) dy
= = +
dt dt ∂x dt ∂y dt
Example
z = x2 y 3 + y cos x, x = ln(t2 ), y = sin(4t). Calculate dz/dt
dz ∂z dx ∂z dy 2
= + = (2xy 3 − y sin x) + (3x2 y 2 + cos x)(4 cos t)
dt ∂x dt ∂y dt t
Now, we can express everything in t or leave with x, y, accounting for t = ex/2 or t = 1/4 arcsin(t)
Example
z = x ln(xy) + y 3 , y = cos(x2 + 1). Calculate dz/dx.
Note that dy = −2x sin(x2 + 1)
dz ∂z dx ∂z dy y x
= + = ln(xy) + x + x + 3y (−2x sin(x2 + 1)) =
2
dx ∂x dx ∂y dx xy xy
x
(ln(xy) + 1) + + 3y 2 (−2x sin(x2 + 1))
y
Here we have simple extension of the chain rule: if z = f (x, y), x = g(s, t), y = h(s, t),
then, obviously, z is a function of s and t and corresponding partial derivatives are:
∂z ∂z ∂x ∂z ∂y
= +
∂s ∂x ∂s ∂y ∂s
∂z ∂z ∂x ∂z ∂y
= +
∂t ∂x ∂t ∂y ∂t
29
Example
For the function z = e2r sin(3θ) compute partial derivatives ∂z/∂r and ∂z/∂θ.
√ ∂z ∂z
Now, let r = st − t2 , θ = s2 + t2 . Compute and :
∂s ∂t
∂z ∂z ∂r ∂z ∂θ s
= + = 2e2r sin(3θ) · t + 3e2r cos(3θ) √
∂s ∂r ∂s ∂θ ∂s s2 + t2
∂z ∂z ∂r ∂z ∂θ t
= + = 2e2r sin(3θ)(s − 2t) + 3e2r cos(3θ) √ (43)
∂t ∂r ∂t ∂θ ∂t s2 + t2
here either r, θ should be replaced with s, t or vice versa
Example
Let us consider a function z = 5r2 and let us know that x = r cos θ and y = r sin θ. Find ∂z/∂x
and ∂z/∂y.
Solution Using chain rule, we can write:
∂z ∂z ∂r ∂z ∂θ ∂z ∂z ∂r ∂z ∂θ
= + = +
∂x ∂r ∂x ∂θ ∂x ∂y ∂r ∂y ∂θ ∂y
(44)
The determinant of the Jacobian matrix det(J) = |J| is called Jacobian. There are different
notations for Jacobians, for example:
g g
(g, h) t s
= h h
t, s
t s
Finally, let us put everything together. We note that if we put partial derivatives in a form of
a vector (∂z/∂x, ∂z/∂y), then we can write:
−1
(∂z/∂x, ∂z/∂y) = (∂z/∂r, ∂z/∂θ)Jr,θ (x, y) = (∂z/∂r, ∂z/∂θ)Jx,y (r, θ)
where, as we discussed earlier, a matrix in the power −1 means the ”inverse matrix”.
Directional derivative
The rate of change of f (x, y) in the direction of the unit vector ~u = (u1 , u2 ) is called the
directional derivative and is denoted by D~u f (x, y). The definition of the directional derivative
is:
f (x + u1 h, y + u2 h) − f (x, y)
D~u f (x, y) = lim (49)
h→0 h
A more ”practical” formula to compute a directional derivative in case of two variables is:
D~u f (x, y, z) = fx0 (x, y, z)u1 + fy0 (x, y, z)u2 + fz0 (x, y, z)u3 (51)
Example: Compute D~u f (2, 0) for f (x, t) = xexy +y and ~u is a vector in the direction θ = 2π/3.
√
Solution: Using Cartesian coordinate, we can write for the directional vector ~u = (−1/2, 3/2).
The directional derivative is
√
−1 xy xy 3 2 xy
D~u f (x, y, z) = (e + xye ) + (x e + 1)
2 2
To finish the calculation, the values x = 2 and y = 0 should be put into the previous formulae.
Note that the eq.50 and eq.51 can be written using the scalar product (” dot product”) of two
vectors:
D~u f (x, y, z) = (fx0 (x, y, z), fy0 (x, y, z), fz0 (x, y, z)) · (u1 , u2 , u3 )
31
The second vector is a vector giving a direction along which the derivative has to be taken
whereas the first vector has special notation which is called gradient of the function f (x, y, z):
where ∇~ is a special notation for the ”set of partial derivatives” which in Cartesian coordinates
is written as
~ = e~x ∂ + e~y ∂ + e~z ∂
∇ (52)
∂x ∂y ∂z
Exercise: Let a function z = f (x, y) is given and x = x(t, s) and y = y(t, s). Then the gradient
~ s,t f (x, y) can be calculated using the gradient of
of the function f over the coordinates (s, t) ∇
the given function over the coordinates (x, y) ∇~ x,y f (x, y) and a Jacobian matrix.
32
Taylor’s theorem, Taylor’s polynomial, Taylor and MacLau-
rin Series
Let us consider a function f (x) = sin x. According to the presentation with a circle, (see fig.9a),
y y
sin α = =p (53)
h x2 + y 2
Using (53), it is easy to obtain a value of the sinus/cosinus for α = 0. What if we wish to
obtain a value of sinus/cosinus for α = 30 = π/60?
(x − a)k+1 rk+1
|Rk (x)| ≤ M ≤M (58)
(k + 1)! (k + 1)!
Example Let us approximate with Taylor’s polynomial the function f (x) = sin x at a = 0
with the error of approximation less than 10−8 up to order k = 7. For which interval this will
be valid? Sinus approximation with Taylor’s polynomial up to 7 order at 0 is:
1 3 1 5 1 5
sin x = x − x + x − x + R7 (x)
3! 5! 7!
Remainder is estimated as
f (7+1) (ξL ) f (8) (ξL ) 8
R7 (x) = (x − 0)7+1 = (x) < 10−8
(7 + 1)! (8)!
Obviously, the maximal possible value of sin(8) (ξL ) is 1 whatever is ξL , so the condition is:
1
(r)8 < 10−8
(8)!
that gives r < (8· 10−8)1/8 , i.e. r < 0.3672029. We can check: the value of sin(0.3672029) =
0.3709204694 and the value P7 (x) = 0.3709204690. As we can see, we underestimated the
interval at which the difference between the Taylor’s polinomial P7 and the function itself still
satisfies imposed condition because the maxiaml value for f (ξL ) was taken too high. The
approximation with P7 is valid up to x ≈ 0.5
Example (from https://en.wikipedia.org/wiki/Taylor%27s_theorem) Suppose that
we wish to approximate the function f (x) = ex on the interval [1, 1] while ensuring that the
error in the approximation is no more than 105. In this example we pretend that we only know
d x
the following properties of the exponential function: (∗) e0 = 1, dx
e = ex , ex >
0, x∈R.
We know that f (k) (x) = ex for all k, and in particular, f (k) (0) = 1. Hence the k −th order
Taylor polynomial of f at 0 and its remainder term in the Lagrange form are given by
x2 xk eξ
Pk (x) = 1 + x + + ··· + , Rk (x) = xk+1 ,
2! k! (k + 1)!
where ξ is some number between 0 and x. Since ex is increasing by (*), we can simply use
ex ≤ 1 for x ∈ [1, 0] to estimate the remainder on the subinterval [1, 0]. To obtain an upper
bound for the remainder on [0, 1], we use the property e < ex for 0 < < x to estimate
eξ 2 ex
ex = 1 + x + x < 1 + x + x2 , 0<x≤1
2 2
using the second order Taylor expansion. Then we solve for ex to deduce that
1+x 1+x
ex ≤ x2
=2 ≤ 4, 0≤x≤1
1− 2 2 − x2
34
simply by maximizing the numerator and minimizing the denominator. Combining these esti-
mates for ex we see that
4|x|k+1 4
|Rk (x)| ≤ ≤ , −1 ≤ x ≤ 1,
(k + 1)! (k + 1)!
so the required precision is certainly reached, when
4
< 10−5 ⇔ 4 · 105 < (k + 1)! ⇔ k ≥ 9.
(k + 1)!
As a conclusion, Taylor’s theorem leads to the approximation
x2 x9
ex = 1 + x + + ... + + R9 (x), |R9 (x)| < 10−5 , −1 ≤ x ≤ 1.
2! 9!
For instance, this approximation provides a decimal expression e ≈ 2.71828, correct up to five
decimal places.
In general, the radius of convergence of a power series can be computed from the Cauchy-
Hadamard formula (see short discussion below).
The eq.59 represent a Taylor’s series for the function f (x). If the point a = 0 then this series
also has a special title: M acLaurenseries.
sin x =
cos x =
ex =
Yet, there is a question: is it possible that the sum of infinite number of terms is still finite?
Yes. To check if a series converges one can use D’Alambert ratio test.
35
D’Alambert ratio test
and q < 1.
36
Indefinite integral or anti-derivative or primitive
Given a function f (x), an anti-derivative (or a primitive function) of f (x) is any function F (x)
such that
F 0 (x) = f (x) (62)
Taking into account that the derivative of a constant value is zero, it is evident that F (x) + C
where C is any constant is also anti-derivative of f (x). If F (x) is any anti-derivative of f (x)
then the most general anti-derivative of f (x) is called an indefinite integral and is denoted
as: Z
F (x) = f (x)dx + c (63)
Using knowledge from the section of derivative, we can guess anti-derivatives (or primitive)
functions for some basics:
Z
Cdx = Cx + C1
xα+1
Z
xα dx = + C, if α 6= −1
α+1
Z Z
−1 1
x dx = = lnx + C
x
Z
cos xdx = sin x + C
···
(64)
Generally, integration of a function is made using the knowledge of the ”basic” integrals
(or, similar: basic derivatives) and some rules described below.
Substitution rule
Z Z
0
f [g(x)] g (x)dx = f (u)du with u = g(x) (67)
37
Indeed: du/dx = d[g(x)]/dx so du = g 0 (x)dx
Example: Z Z
1 1 1
sin 2xdx = sin udu|u=2x = − cos u = − cos 2x + c
2 2 2
Indeed: u = 2x then du = 2dx and dx = du/2
Example:
Z Z
2 3 4 1 1 1
x (3 − 10x ) dx = − (3 − 10x3 )4 d(3 − 10x3 ) = − · (3 − 10x3 )5 + c
30 30 5
Here intermediate steps with the substitution u = (3 − 10x3 ) and du = −30x2 dx were not done
explicitly.
Example (easy): Z
(sin 2x)3 cos 2xdx
Example: Z
tan xdx
Integration by parts
Note that
Z Z
[f (x)g (x)] dx = f (x)g(x) − f 0 (x)g(x)dx
0
Z Z
udv = uv − vdu
Example:
Z Z Z
x cos xdx = xd(sin x) = x · sin x − sin xdx = x · sin x + cos x + C (68)
Example:
Z Z Z Z
x e dx = x de = x e − e d(x ) = x e − 2 ex xdx =
2 x 2 x 2 x x 2 2 x
Z Z
x e − 2 xd(e ) = x e − 2[xe − ex dx] = x2 ex − 2xex + 2ex + C
2 x x 2 x x
(69)
38
Another way to take the proposed integral is the following:
Suppose that the solution is of the form I = (a0 + a1 x + a2 x2 )ex , so, it’s derivative must be
equal to x2 ex . We get:
Taking dv = xn dx, we know that v = xn+1 /(n + 1). Consequently, u = ln x. Then obtain:
xn+1
Z Z Z Z
n 1 1
x ln xdx = udv = uv − vdu = ln x − xn+1 dx =
n+1 n+1 x
n+1 Z
x 1
ln x − 2
xn+1 + C (70)
n + 1 (n + 1)
for the integrals
Z
P (x) sin xdx
Z
P (x) cos dx
Z
P (x)ex dx
Z
P (x)ax dx
(71)
39
Z
A nice example of the integration xn sin(x)dx can be found in the internet:
https://math.stackexchange.com/questions/231100/computing-the-indefinite-integral-int-xn-sin-x-dx
This recommendation is known as LIATE rule of thumb rule proposed by Herbert Kasube
advises that functions comes first in the following list should be chosen as u: L - Logarithmic
Functions: ln(x), logb (x), etc.
I - Inverse trigonometric functions: arctan(x), arcsec(x), etc.
A - Algebraic functions: x2 , 3x50 etc
T - Trigonometric functions: sin(x), tan(x) etc
E - Exponential functions: ex , 19x , etc
The function which is to be dv is whichever comes last in the list: functions lower on the list
have easier antiderivatives than the functions above them. The rule is sometimes written as
”DETAIL” where D stands for dv.
Use the substitution cos x = t with dt = − sin xdx, i.e. dx = −dt sin−1 x and identity
sin2 x + cos2 x = 1, i.e. sin2 x = 1 − cos2 x = 1 − t2 then
Z Z Z
m α 2 (m−1)/2 α
sin x cos xdx = (1 − t ) t dt = (1 − t2 )(m−1)/2 tα dt =
Z
(1 − t2 )k tα dt (72)
2u 1 − u2 2du
sin x = , cos x = , dx =
1 + u2 1 + u2 1 + u2
Example
2du 1 + u2
Z Z Z
dx du
= = = ln|u| + C = ln|tan(x/2)| + C
sinx 1 + u2 2u u
Yet, sometimes this substitution can lead to complicated functions. Other substitutions are
recommended: sin x = t, cos x = t, tan x = t.
40
Integration of R(shx, chx)
Reminder:
ex − e−x ex + e−x sinh x e2x − 1
shx = sinh x = , chx = cosh x = , tanh x = = 2x
2 2 cosh x e +1
Recommended substitution is u = th(x/2) which gives also
2u 1 + u2 2du
shx = , chx = , dx =
1 − u2 1 − u2 1 − u2
√ √ √
Integration of R(xand 1 − x2 , x2 − 1, x2 + 1)
Integration of these functions is reduced to the previous case with the substitution x = cos v
or x = shv or x = shv. Recommended substitution is u = th(x/2) which gives also
2u 1 + u2 2du
shx = , chx = , dx =
1 − u2 1 − u2 1 − u2
41
Definite integral
Let f (x) is a function defined and limited at a segment [a, b]. Let us divide this segment on n
intervals with points a = x0 < x1 < x2 < ... < Xn = b. For each of these intervals let us choose
an arvitrary point ξi : (xi ≤ ξi ≤ ξi+1 ) and make a sum
n
X
f (ξi )(xi − xi1 ) (73)
i=1
If a limit of a the sum given by eq.73 when the length of the largest interval goes to zero exists,
then f (x) is said to be integrable in Riemann’s sense at the segment [a, b]. The limit
n
X Z b
I = limmax(xi −xi−1 )→0 f (ξi )(xi − xi1 ) = f (x)dx (74)
i=1 a
is a definite integral of f (x) on the closed interval [a, b] in Riemann’s sense (or Riemann’s
integral).
Figure 10: Illustration to the definition of the definite integral. Note that the given division
for the intervals would not correspond to the one providing a good value of the integral or the
area bounded by the f (x), x-axis and vertical lines x = a and x = b
This definition means that for any positive ε we can find δ > 0 such that for any arbitrary
division of the segment [a, b] on the sub-intervals with the length less than δ, i.e.
and for any arbitrary choice of the points ξi the following inequality fulfils
n
X
| f (ξi )(xi − xi1 ) − I| < ε
i=1
According to the definition, the definite integral of the function f (x) on the segment [a, b]
is a signed area bounded by the graph of the function f (x), the x-axis and the vertical lines
corresponding to the limits of the integral, x = a and x = b (Fig.10). Terminology: a and b
are limits of integration
42
Definite integral: properties
Z b Z a
f (x)dx = − f (x)dx (75)
a b
Z a
f (x)dx = 0 (76)
a
Z b Z b
c · f (x)dx = c · f (x)dx (77)
a a
Z b Z b Z b
[f (x) ± g(x)]dx = f (x)dx ± g(x)dx (78)
a a a
Z c Z c Z b
f (x)dx = f (x)dx + f (x)dx (79)
a a c
Great, but how to calculate a definite integral? Is it related to the indefinite integral that
we studied just before?
F 0 (x) = f (x)
In this example a dirrect application of the first part of the theorem is needed.
Example Differentiate the following:
Z 1 4
t +1
g(x) = 2
dt
x2 t + 1
43
Here the limit the integral is not given in a good form. Let us: (a) change the order of the
limits, (b) then substitute a ”good” variable use a chain rule, (c) put the variable x back into
formula
Step a:
Z 1 4 Z x2 4
dg(x) d t +1 d t +1
= 2
dt = − dt
dx dx x2 t + 1 dx 1 t2 + 1
Step b:
u = x2
dg(u) dg(u) du
=
u dx du dx
t4 + 1 u4 + 1 du
Z
dg(x) du d du
=− dt =− 2
du dx du 1 t2 + 1 dx u + 1 dx
Step c: account for that du/dx = 2x and put back x:
u4 + 1 du x8 + 1
− = −2x
u2 + 1 dx x4 + 1
Suppose f (x) is a continuous function on [a, b] and also suppose that F (x) is any anti-derivative
for f (x). Then,
Z b
F (x) = f (t)dt = F (x)|ba = F (b) − F (a)
a
Example:
8 8
x3 83 (−1)3
Z
2
511
x + 30 = + 30x =
+ 30 · 8 − − 30 = + 270
−1 3 −1 3 3 3
44
Multiple Integrals
Similar to the integral of one variable it is possible to introduce an integral for a function of two
variables, f (x, y). In case of 2 variables we will integrate over a region of R2 (two-dimensional
space). We will start out by assuming that the region in R2 is a rectangle which we will denote
as follows:
R = [a, b] × [c, d]
for one variable: we should subdivide the given rectangle into smaller non-overlapping regions,
for each of them choose points at the surface S whic will define the height of the corresponding
element and to calculated the volume. If, with decreasing the area of the constructed element
we have a limit for the volume, then the functionis integrable, etc. Fubinis Theorem
If f (x, y) is continuous on R = [a, b] × [c, d] then,
Z Z Z bZ d Z d Z b
f (x, y)dA = f (x, y)dydx = f (x, y)dxdy (80)
R a c c a
45
Let us first integrate over x:
2 1 2 1
−1 2
Z
−1
Z Z Z
−2 −1 1 1
(2x + 3y) dydx = (2x + 3y) dy = − dy =
1 0 1 2 0 2 1 2 + 3y 3y
2
−1 1 1 −1
ln |2 + 3y| − ln |y| = (ln 8 − ln 2 − ln 5) (81)
2 3 3 1 6
Example
Z Z
x(cos y)2 dA, R = [−2, 3] × [0, π/2]
R
Figure 12: Illustration to the definition of the definite integral. Note that the given division
for the intervals would not correspond to the one providing a good value of the integral or the
area bounded by the f (x), x-axis and vertical lines x = a and x = b
46
and for the second
Properties
Z Z of the double integral:
Z Z Z Z
1. (f (x, y) + g(x, y))dA = (f (x, y)dA + g(x, y))dA
Z ZA Z Z A A
Example:
√
Let A is the region bounded by x3 and x, one should take the integral 4xy − y 3 over the
region A. Solution:
√
1. The imits over y axis are given by equations y1 (x) = x3 and y2 (x) = x
√
2. The limits over the x-axis can be found via solution of the equality: x3 = x which gives
two roots: x1 = 0, x2 = 1.
3. The integral to take:
Z 1 Z √
x Z 1 √
4 x
y
(4xy − y 3 )dydx = 2xy 2 − dx =
0 x3 0 4 x3
Z 1 2 1
x12
3
x8 x13
7x 7 7x 55
− 2x + dx = − + = (82)
0 4 4 12 4 52 0 156
Example:
Integrate 6x2 −40y over a triangle with vertices given by the coordinates (0, 3), (1, 1) and (5, 3).
Solution:
1. Define equations for lines bounded the region of integration as shown in the fig.13.
1.a. In terms of y as a function of x:
Figure 13: Illustration to the problem of integration of 6x2 − 40y over a triangle
47
for 0 ≤ x ≤ 1 y1 (x) = −2x + 3
for 1 ≤ x ≤ 5 y2 (x) = 1/2x + 1/2
for 0 ≤ x ≤ 5 y3 (x) = 3
or Z 3 Z x2 (y)
(6x2 − 40y)dxdy (84)
1 x1 (y)
Gaussian Integrals
In mathematics, a Gaussian function, often simply referred to as a Gaussian, is a function of
the form:
(x − b)2
−
f (x) = ae 2c2 (85)
The
Z remarkable
Z fact is that the indefinite integrals from gaussian function, i.e. integrals like
2 2
e−x dx or xp e−λx dx cannot be expressed with elementary functions, but finite integrals
given by eqs.86, 87 can be taken!
48
Clearly, Z ∞ Z ∞
2 +y 2 )
Y = 2
e−(x dxdy (90)
−∞ −∞
Note:
Here we deal with so-called multiple integral which is a definite integral of a function of more
than one real variable. Here let’s change the coordinate system from cartesian to polar using
transition formula x = cos φ, y = sin φ and accounting for the fact the elementary surface area or
elementary volume in different coordinate system can be obtained using Jacobian (determinant
of the Jacobian matrix) and the product of corrdinates’ differentials:
Step 2:
∞ √
Z
2
Let us consider the integral: e−λx , then making the substitution t = x λ, obtain:
−∞
Z ∞ π 1/2
2
e−λx dx = (94)
−∞ λ
So, taking into account that the integrand (the function under the integral) is even function,
one can write Z ∞
2 1 π 1/2
I0 (λ) = e−λx dx = (95)
0 2 λ
Step 3:
Z ∞ Z ∞
−λx2 1 2
I1 (λ) = xe dx = − (−2λx)e−λx dx =
0 0 2λ
Z ∞
1 −λx2 1 −λx2 ∞ 1
− d(e )=− e = (96)
2λ 0 2λ 0 2λ
Using the same technique, it is possible to calculate
Z ∞ Z ∞ Z ∞
2k+1 −λx2 1 −λx2 1 2
I2k+1 (λ) = x e dx = − 2k
x (−2λx)e dx = − x2k d(e−λx ) =
0 2λ 0 2λ 0
∞
Z inf ty Z inf ty
1 h
2
i 1 2 k 2
− x2k e−λx + (2k) x2k−1 e−λx dx = x2k−1 e−λx dx (97)
2λ 0 2λ 0 λ 0
That means that a recurrent relation has been found:
k kk−1 k! k!
I2k+1 (λ) = I2k−1 = I2k−3 = · · · = k I1 (λ) = k+1 (98)
λ λ λ λ 2λ
49
Step 4:
For the even powers of x:
Z inf ty Z ∞
12k −λx2 2
I2k (λ) = x e dx = − x2k−1 d[e−λx ] =
0 2λ 0
1 2k−1 −λx2 ∞ 2k − 1 ∞ 2k−2 −λx2
Z
− [x e ]0 + x e dx (99)
2λ 2λ 0
A recurrent relation is
2k − 1 2k − 1 2k − 3 1 · 3 · · · (2k − 1)
I2k = I2k−2 = I2k−4 = · · · = I0 (λ)
2λ 2λ 2λ (2λ)k
1 · 3 · · · (2k − 1) 1 π 1/2
= (100)
(2λ)k 2 λ
Summary
Z ∞
2 1 π
I0 = e(−λx ) dx = ( )1/2 (101)
0 2 λ
Consequently, Z ∞
2 π
e(−λx ) dx = ( )1/2 (102)
−∞ λ
Z ∞
2 1
I1 = xe(−λx ) dx = (103)
0 2λ
Consequently, Z ∞
2
xe(−λx ) dx = 0 (104)
−∞
Recurrent relations: Z ∞
2 1 1 π 1/2
I2 = x2 e(−λx ) dx = I0 (λ) = (105)
0 2λ 4λ λ
Consequently, Z ∞
2 (−λx2 ) 1 π 1/2
xe dx = (106)
∞ 2λ λ
Example
Z ∞ Z ∞ π 1/2
−λ(x−x0 )2 2
e dx = e(−λt ) dt = (107)
−∞ −∞ λ
Example
Z ∞ Z ∞ √
(−x2 −y 2 ) (−y 2 ) 2 2)
G(y) = e dx = e e−x dx = e(−y π (108)
−∞ −∞
Example
Z ∞ Z ∞ Z ∞ √
Z ∞
(−x2 −y 2 ) 2
H= G(y)dy = e dxdy = π e(−y ) dy = π (109)
−∞ −∞ −∞ −∞
50
Integrals in physics: line integral, surface integral
Line integral
A line integral is an integral taken along a curve. The terms path integral, curve integral, and
curvilinear integral and contour integral are used as well.
The line can be given in the form of a parametric curve or as and the function can be either
scalar of vector.
Let the C curve along which the integral is evaluated is smooth and is given by the parametric
equations (see the table for parametric presentation of some curves):
where ds is a small part of the curve C. It can be shown that ds is related to the variations of
dt, dx, dy as: s
2 2
dx dx
ds = + dt (111)
dt dy
Using parametric presentation of a curve with a radius-vector ~r(t) eq.110, it is possible also to
write
ds = k~r0 (t)k (112)
Example: Z
Take the integral xy 4 ds where C is the right half of the circle x2 + y 2 = 16.
C
Solution:
The circle is presented in the parametrization form as x = 4 cos t, y = 4 sin t. For its right half,
−π/2 ≤ t ≤ π/2. Then, taking the require derivatives, obtain:
p
ds = 16 sin2 (t) + 16 cos2 (t)dt = 4t
51
Parametric presentations for some curves in two dimensions
Curve Parametric presentation
Ellipse Counter-Clockwise Clockwise
2
x2
a2
+ yb2 = 1 x = a cos(t) x = a cos(t)
y = b sin(t) y = −b sin(t)
0 ≤ t ≤ 2π 0 ≤ t ≤ 2π
Circle Counter-Clockwise Clockwise
x + y 2 = r2
2
x = r cos(t) x = r cos(t)
y = r sin(t) y = −r sin(t)
0 ≤ t ≤ 2π 0 ≤ t ≤ 2π
y = f (x) x=t
y = f (t)
x = g(y) x = g(t)
y=t
Line segment ~r(t) = (1 − t) · (x0 , y0 , z0 ) + t · (x1 , y1 , z1 ), 0 ≤ t ≤ 1
from (x0 , y0 , z0 ) to (x1 , y1 , z1 ) or
x = (1 − t)x0 + tx1
y = (1 − t)y0 + ty1 , 0 ≤ t ≤ 1
z = (1 − t)z0 + tz1
52
Example Z
Take the integral 4x3 ds over the line shown in the fig.14 Solution:
Figure 14: Path to consider for the integration in the given example
First, a parametrization for each of the curves is needed:
C1 : x = t, y = −1, −2 ≤ t ≤ 0
C2 : x = t, y = t3 − 1, 0≤t≤1
C3 : x = 1, y = t, 0≤t≤2
(113)
Example
Let us take the same integral but on a linear path from (−2, −1) and (1, 2). Let’s use radius-
vector for the parametrization of the linear segment.
( ) ( ) ( ) ( ) ( )
−2 1 −2 + 2t t −2 + 3t
~r(t) = (1 − t)(−2, −1) + t(1, 2) = (1 − t) +t = + =
−1 2 −1 + t 2t −1 + 3t
for 0 ≤ t ≤ 1.
That means that individual parametric equations are
x = −2 + 3t, y = −1 + 3t
53
Then
1 √
Z Z
3
4x ds = 4(−2 + 3t)3 9 + 9dt = −21.213 (115)
C 0
Example
Let us take the same integral but on the same linear path but with changing the direction from
(1, 2) to (−2, −1). Note that parametrization changes and becomes
( )
1 − 3t
~r(t) =
2 − 3t
for 0 ≤ t ≤ 1.
The integral becomes:
1 √
Z Z
3
4x ds = 4(1 − 3t)3 9 + 9dt = −21.213 (116)
C 0
So, the change of the direction for the integration path did not change the sign of the integral.
For these integrals, contrary to the previous case of the integration over the arc length, we
have:
Z Z
f (x, y)dx = − f (x, y)dx
−C
Z ZC
f (x, y)dy = − f (x, y)dy
−C C
Z Z
P dx + Qdy = − P (x, y)dx + Q(x, y)dy (120)
−C C
54
Vector fields
Definition:
A vector field on two (or three) dimensional space is a function F~ that assigns to each point
(x, y) in 2D or (x, y, z) in 3D a two (or three dimensional) vector given by F~ (x, y) in 2D or
F~ (x, y, z) in 3D.
Examples from Physics:
· Velocity field of the liquid (fig.15c)
V~ (x, y, z) = ~iVx (x, y, z) + ~jVy (x, y, z) + ~kVz (x, y, z) = (Vx (x, y, z), Vy (x, y, z), Vz (x, y, z))
F~ = (Fx , Fy , Fz )
Example: Calculate the integral of the vector function F (x,~ y) = 3y~i + 5x~j over the right part
of a circle x2 + y 2 = 16.
Solution
~ y) over the
Using parametrization for the circle, we can present variations of the function F (x,
required path as
~ y) = 3(4 sin(t))~i + 5(4 cos(t))~j
F (x,
Remark: the primitive of cos2 (t) can be found using integration by parts:
Z Z Z Z
cos (t)dt = cos(t)d sin(t) = cos(t) sin(t) − sin(t)d cos(t) = cos(t) sin(t) + sin2 (t)dt
2
Z Z
= cos(t) sin(t) + (1 − cos (t))dt = cos(t) sin(t) + t − cos2 (t)dt
2
From where
Z Z
1
2 cos2 (t)dt = cos(t) sin(t) + t , i.e. cos2 (t)dt = [cos(t) sin(t) + t]
2
Note that the two-dimensional vector field F~ (x, y) can be drawn schematically since in some
56
Figure 17: Illustration to the integration of a vector field over a line
selected points the vectors can be constructed. Illustration for the field given in the previous
example is shown inZ fig.17 as well as for the integration along the semi-circle. Example:
Take the integral F~ d~r for F~ = xz~i − yz~k and C been the line segment from (−1, 2, 0) to
C
(3, 0, 1).
Solution
Parametrization of the segment (cf. table) using notation in form of vectors:
−1
3
−1 + t 3t −1 + 4t
~r(t) = (1 − t) 2 + t 0 = 2 − 2t + 0 = 2 − 2t for 0 ≤ t ≤ 1
0 1 0 t t
that means that we should use presentations for x = 4t − 1, y = 2 − 2t and z = t that gives for
the function F~ = (4t − 1)t~i + (2 − 2t)t~k and d~r = (4~i − 2~j + ~k)dt. Then for the integration:
Z Z 1h i
~
F d~r = (4t2 − t)~i + (2t − 2t2 )~k (4~i − 2~j + ~k)dt =
C
Z 01
18t2 − 6t dt = (6t3 − 3t2 )0 1 = 3
(123)
0
Green theorem
Note that without going to parametrization, we can write the differential d~r = ~idx + ~jdy + ~kdz.
Then, presenting the function F~ as
it is possible to write the line integral over a path C of the vector filed F~ in a form of:
Z Z h i h i
~
F (x, y, z)d~r = P~i + Q~i + R~k d ~idx + ~jdy + ~kdz =
C C
Z
P dx + Qdy + Rdz (124)
C
57
i.e. as three integrals, each integral is taken over one variable but along the path C.
Green theorem Let C be a positively oriented, piecewise smooth, simple closed curve in a
plane, and let D be the region bounded by C. If P and Q are functions of (x, y) defined on an
open region containing D and have continuous partial derivatives there, then
I ZZ
∂Q ∂P
(P dx + Q dy) = − dx dy (125)
C D ∂x ∂y
Remark:In mathematics, a positively oriented curve is a planar simple closed curve (that is,
a curve in the plane whose starting point is also the end point and which has no other self-
intersections) such that when traveling on it one always has the curve interior to the left (and
consequently, the curve exterior to the right).
Example
H
Take the integral C y 3 dx − x3 dy where C is a circle of the radius 2 at the origin.
Solution:
Given example satisfies conditions of the Green’s theorem, P = y 3 and Q = −x3 . Then
∂Q/∂x = −3x2 , ∂P/∂y = 3y 2 that gives
I ZZ
3 3
y dx − x dy = − (3x2 + 3y 2 )dxdy (126)
C D
where D is a disk of the radius 1. It is convinient to take this integral in the polar coordinate
for which dxdy = rdrdθ:
Z 1 Z 2π Z 2 2
3πr4
I
3 3 2 3
y dx − x dy = − dr dθ(3r )r = −2π 3r dr = = −24π (127)
C 0 0 0 2 0
Example
H
Take the integral C y 3 dx − x3 dy where C consists of two circles: one of a radius 2and another
of a radius 1 (18).
Solution:
Although the region with hole(s) (multiply connected space) do not satisfy conditions of Green’s
Theorem, the region D between the two circles satisfies them! Another option is to consider
integration over ”4 semi-circles” connected by paths denoted C5 and C6 in fig.18. The integrals
over these paths will be compensated, the rest will be the difference between the integrals taken
over different contours:
Z 2 Z 2π Z 2 2
3πr4
I
3 3 2 3 45π
y dx − x dy = − dr dθ(3r )r = −2π 3r dr = =− (128)
C 1 0 1 2 1 2
58
Figure 18: Integration over a contour consisting of two circles
Surface integrals
Divergence
Given the vector field F~ = P~i + Q~j + R~k the divergence is defined to be
∂P ∂Q ∂R
div F~ = + + (129)
∂x ∂y ∂z
The definition can be written with the nabla operator:
div F~ = ∇
~ · F~ (130)
Example
In hydrodynamics the mass transport equation through a unit volume is written as
∂ρ ~ · V~ = Sm
+ ρ∇
∂t
∂ρ
where Sm is a possible source of the mass. For incompressible fluids = 0, so, if no sources of
∂t
mass exist, the divergence of the velocity field is zero. Compare an illustration for vector fields
given in fig.19a,b. One of the presented field is a divergent-free, while another one Example
Figure 19: Illustration to a divergence-free vector field and a vector field with a sink
In thermal physics a gradient of the temperature field without the heat source is a divergence-
free vector field.
59
Operator of Laplace
Here ~n is a unit normal vector to the curve bounded the area D. The illustration is given in
fig.20
Further, the function to be integrated f (x, y, z) can also be re-written using this parametriza-
tion, i.e. in the form f (x(u, v)y(u, v), z(u, v)), then the susrface integral
Z
f (x, y, z)dS
S
60
can be reduced to the integration over a some (simpler) region D, i.e. the idea of the integration
of a scalar function over the surface is quite similar to the inegration over a line.
Furthermore, a Divergence theorem for the integration of the vector functions over a
surface, relates integration over a surface and integration over a volume.
Divergence theorem
Let E be a simple solid region and S is the boundary surface of E with positive orientation.
Let F~ be a vector field whose components have continuous first order partial derivatives. Then,
ZZ ZZZ
~ ~
F · dS = div F~ dV (132)
S E
61
Differential equations
Classification of the differential equations:
1. With respect to number of variables: ordinary or partial
· ordinary differential equation (ODE) is a differential equation containing one or more
functions of one independent variable and its derivatives
· partial differential equations are those that contain unknown multivariable functions and
their partial derivatives
2.With respect to the order of the highes derivative: first order, second order, etc....
3. Linear or non-linear:
Linear ordinary differential equations are of the form
where the differential operator L is a linear operator. A linear differential operator, involving
the n-th derivative, Ln may be considered to be of the form
dn y dn−1 y dy
Ln [y(t)] ≡ n
+ A1 (t) n−1
+ · · · + An−1 (t) + An (t)y (134)
dt dt dt
Particular solution of a differential equation
Particular solution for a differential equation is any function which satisfies differential equation
on the required interval.
Initial Condition(s)
Initial conditions are given values of the function and/or its derivative(s) at specific points.
Initial Condition(s) allows us to choose one solution from the general solution.
Initial Value Problem
An Initial Value Problem (or IVP) is a differential equation along with an appropriate number
of initial conditions.
Example
dy
y0 = = f (x)
dx
Solution: Z
y = f (x)dx + C
62
Example
00d2 y
y = 2 = −g
dt
y(0) = 3y 0 (0) = V0
Solution:
Z
0
y = gdt + C1 = gt + C1
gt2
Z
y= (gt + C1 )dt = + C1 t + C2
2
Using initial conditions:
y(0) = C2 => C2 = 3
y 0 (0) = C1 => C1 = V0
Finally:
gt2
y(t) = + V0 t + 3
2
Separation of variables
x2 y 0 + y − 1 = 0
Solution:
dy dx
= 2 for x2 6= 0 andy 6= 1
1−y x
1
− ln |1 − y| = − + C3
x
|1 − y| = e1/x−C3
= Ce 1/x
where C = e−C3 , C > 0
Finally:
y = 1 − Ce1/x for C > 0 and C < 0 (135)
Yet, this solution has probably to be updated since it was obtained under condition y − 1 6= 0
and x 6= 0. Actually, eq.135 includes solution y = 1 if C = 0. But the case x = 0 has to be
considered separately, so, finally we have:
Problem
Find the general solution for
xy 0 = 2y + y 0 (136)
y 0 (x − 1) = 2y
dy dx
=2 for x 6= 1 and y 6= 0
y x−1
ln |x| = 2 ln |x − 1| + C = ln(x − 1)2 + C
|y| = C(x − 1)2 for C > 0 and C < 0
No special solution exists for this case since x = 1 implies y = 0 that can be obtained if C = 0.
So, the last formula is for all values of C.
A particular solution: if for x = 2, y = 3, we can find a particular value for c and get
finally:y = 3(x − 1)2 .
64
First, we shall separate the variable and then we will integrate the equation:
dy
y = ey
dx
ye−y = dx
Z
Note that ye−y dy = −ye−y − e−y
−ye−y − e−y = x + C
(y + 1)e−y = −x + C
Solution given by the last eqution has an implicit form. Soltion exist for all x and y 6= 0.
Substitutions
Case 1: for
y 0 = f (ax + by + c) (137)
use the substitution z = ax + by + c and note hat according to initial equation 137, y 0 = f (z)
Then:
dz dy
=a+b
dx dx
z 0 = a + by 0 = a + bf (z)
dz
= dx
a + bf (z)
Z Z
dz
= dx for a + bf (z) 6= 0 (138)
a + bf (z)
Case 2: for
y 0 = f (y/x) (139)
use the substitution z = y/x and note hat according to initial equation 139 y 0 = f (z). Then
y = zx
y0 = z0x + z
z 0 x + z = f (z)
Z Z
dz dx
= for f (z) − z 6= 0
f (z) − z x
(140)
Example
0 y y
y = + tan
x x
65
Solution: take v = y/x. Then:
y0 = v0x + x
0
Zv x + v = v + tan v
cos v
dv = ln x + C
sin v
ln(sin v) = ln x + C
v = arcsin(Cx)
y = x arcsin(Cx) (141)
Then, taking a partial derivative of the last equation over y, and accounting for the fact that
∂U
= B(x, y) obtain:
∂y Z
∂ dF (y)
A(x, y)dx + =0
∂y dy
which allows us to find F (y).
Example
dy
x + 3x + y = 0 (144)
dx
66
The given equation can be re-written as (3x + y)dx + xdy = 0, A(x, y) = 3x + y, B = x. If
we chack the condition:∂A/∂y = ∂B/∂x = 1, so the equation is exact. Let us find a function
U(x,y):
3x2
Z
U (x, y) = (A(x, y)dx + F (y) = + xy + F (y) = C0 (145)
2
Taking into account that ∂U (x, y)/∂y = B(x, y) and taking the partial derivative of 145 on y,
obtain:
dF (y)
x+ =x
dy
dF (y)
=0
dy
F (y) = C1 (146)
So, finally:
3x2
U (x, y) = + xy + C1 = C0
2
or
3x2
U (x, y) = + xy = C
2
but ∂A/∂y 6= ∂B/∂x. So, it is not a differential of a certain function. The idea is to find the
integrating factor µ(x, y) such that:
∂(µA) ∂(µB)
=
∂y ∂x
Yet, find the integrating factor µ which would be a function of both variable, x and y, is
quite complicated and no general procedure exists.
However, it is possible to find µ as a function of only x or only y, as explained below.
Let an inexact differential equation is given:
∂M ∂N
M (x, y)dx + N (x, y)dy = 0, 6=
∂y ∂x
and an integrating factor depending only on x exists, that means that
∂(µ(x)M ) ∂(µ(x)N )
=
∂y ∂x
since µ(x) does not depend on y, obtain:
∂M ∂N dµ(x)
µ(x) = µ(x) +N
∂y ∂x dx
∂M ∂N dµ(x)
µ(x) − =N
∂y ∂x dx
dµ(x) 1 ∂M ∂N 1
= −
dx µ(x) ∂y ∂x N
67
If on the left side the function depend only on x, therefore, on the right side we also should
have a function depending only on x. Let us denote the right side as g(x). Then:
dµ(x) 1
= g(x)
dx µ(x)
Z
ln(µ(x)) = g(x)dx
Z
g(x)dx ∂M
∂N 1
µ(x) = e , where g(x) = − (147)
∂y ∂x N
Remarks:
1. The role of x and y can be reversed, then we have to look for a function h(y):
∂M ∂N 1
h(y) = −
∂y ∂x M
2. For the first order ODE of the type
dy
+ a(x)y = b(x)
dx
the integrating factor is
Z
a(x)dx
µ=e
Example
y 2 dx + (2xy − y 2 ey )dy = 0
68
This equation can be solved using the method of solution for exact equation. Let us find U (x, y):
Z
U (x, y) = y 2 dx + F (y) = y 2 x + F (y) = C0
dF (y)
2yx + = 2xy − y 2 ey
dy
dF = −y 2 eydy => F (y) = −ey (y 2 − 2y + 2) + C1
U (x, y) = C0 = y 2 x − ey (y 2 − 2y + 2) + C1
Finally: y 2 x − ey (y 2 − 2y + 2) = C
The last step is to verify that with taking the appropriate derivative we really get the initial
equation.
2. Assume that the constant C depends on (x) and plug the obtained solution into the differ-
ential equation. Find C(x)
69