Sunday, July 28, 2024

Vectors+ 03 - Direction Cosines: UNIZOR.COM - Math+ & Problems - Vectors

Notes to a video lecture on http://www.unizor.com

Vectors+ 03 - Direction Cosines

Problem A

Find three-dimensional vector V(v1,v2,v3) by its magnitude (modulus, length) l and three direction cosines of angles it forms with three axes of coordinates cos(α), cos(β) and cos(γ), where
α is an angle between V and X-axis,
β is an angle between V and Y-axis,
γ is an angle between V and Z-axis.

Solution A

Consider a unit vector along X-axis i(1,0,0).
Its scalar (dot) product with vector V(v1,v2,v3) is
V(v1,v2,v3i(1,0,0) = v1
On the other hand, this scalar product is equal to
V·i = |V|·|i|·cos(α) = l·cos(α)
Therefore,
v1 = l·cos(α)
Analogously, considering scalar product of vector V(v1,v2,v3) with unit vectors j(0,1,0) on Y-axis, we'll get
v2 = l·cos(β)
Similarly, considering scalar product of vector V(v1,v2,v3) with unit vectors k(0,0,1) on Z-axis, we'll get
v3 = l·cos(γ)


Problem B

A triangle on a coordinate plane is given by coordinates of its three vertices A(a1,a2), B(b1,b2), C(c1,c2).
Find point X(x1,x2) on segment AB that divides this segment in a ratio p/q.


Note B
Use vector algebra.

Solution B

Consider every segment on the picture above as a vector with a direction specified by the order of vertices used in notation.
For example, CA is a vector from vertex C to vertex A.
As a vector, its coordinates are (a1−c1,a2−c2).
Also, notice that vectors AX and XB are collinear, hence the ratio between the length of segment AX to the length of XB is the same as the ratio of vectors AX and XB.

Using this approach, we can form the following equations
CX = CA + AX
CX + XB = CB
AX = p·XB
The above system of three vector equations is a linear one and contains three unknown vectors: CX, AX and XB.

Simple transformations will immediately yield the solution.
Resolving the second equation for CX and substituting into the first one result in a system of two equations
CBXB = CA + AX
AX = p·XB

Using the last equation to express AX in terms of XB as AX = (p/q)·XB, we get a single linear equation with one unknown
CBXB = CA + (p/q)·XB

The solution for XB is
XB = (CBCA) / (1+p/q)

Expressing the above equation in coordinate form allows to find coordinates of point X(x1,x2).
b1−x1 = [(b1−c1) − (a1−c1)] / (1+p/q)
from which follows
x1 = b1[(b1−c1) − (a1−c1)] / (1+p/q)
or
x1 = [(p/q)·b1+a1] / (1+p/q)
or
x1 = (q·a1 + p·b1) / (p+q)
Analogously,
x2 = (q·a2 + p·b2) / (p+q)

Friday, July 26, 2024

Vectors+ 02 Angle between vectors: UNIZOR.COM - Math+ & Problems - Vectors

Notes to a video lecture on http://www.unizor.com

Vectors+ 02

Problem A

Unknown vector X(x1,x2) is defined as a linear combination of given non-collinear vectors A(a1,a2) and B(b1,b2):
X = a·A + b·B.
Find the coefficients γ and δ in representation of the same vector X as a linear combination of another pair of given non-collinear vectors C(c1,c2) and D(d1,d2):
X = γ·C + δ·D

Solution A

Straight forward method would be to express existing equations in coordinate form.
The following pair defines unknown x1 and x2 from equation X=a·A+b·B
x1 = a·a1 + b·b1
x2 = a·a2 + b·b2
Then, using them as known variables, the second pair of equations defines unknown coefficients γ and β from equation X=γ·C+δ·D
x1 = γ·c1 + δ·d1
x2 = γ·c2 + δ·d2
This is a simple algebraic problem of solving a system of two linear equations with two unknowns γ and δ.
Its solution is
γ =
d2·x1−d1·x2
c1·d2−c2·d1
δ =
c1·x2−c2·x1
c1·d2−c2·d1
where x1 and x2 were defined above in terms of a, b, a1, a2, b1, b2.


Problem B

Two vectors in two-dimensional space are presented on a picture below.

Find the cosine of an angle between them.

Solution B1

Recall that a scalar (dot) product of two vectors X and Y equals to a product of their magnitudes (moduli, lengths) by a cosine of an angle φ between them:
X · Y = |X| · |Y| · cos(φ)
from which we can easily express cosine of an angle between these vectors in terms of their scalar product and magnitudes.

On the other hand, the same scalar product and magnitudes can be expressed in coordinate form, which can be easily derived from a picture.

Our two vectors in coordinate form are
RED(4,−4)
BLUE(2,4)

Their scalar product is
RED · BLUE = 4·2 − 4·4 = −8

Their magnitudes are
|RED| = 4√2
|BLUE| = 2√5

Now, dividing scalar product by a product of magnitudes, we can get a cosine of an angle between these vectors.
cos(φ) = −8/(8√10) = −1/√10

Calculations show the approximate result
arccos(−0.316227766) =
= 108.434949°

that is slightly more than 90°, which does look like on the picture above.

Solution B2

Let's solve this problem trigonometrically.
Start with bringing both vectors to the same beginning point - the origin of coordinates. The RED vector will have the coordinates of its tip X(4,−4), while the BLUE one will have the coordinates of its tip Y(2,4).

So, we have to determine a cos(∠XOY)

To simplify our work, consider point Z(4,4).
Obviously, ∠XOZ=90° and
∠XOY = ∠YOZ + 90°
In its turn,
∠YOZ = α − β
Knowing sin(α), cos(α), sin(β) and cos(β), we can easily evaluate any trigonometric function of α−β and, from it, any trigonometric function of ∠XOY=α−β+90°.

Length of OY is 2√5. Therefore,
sin(α) = 4/(2√5) = 2/√5
cos(α) = 2/(2√5) = 1/√5
Length of OZ is 4√2. Therefore,
sin(β) = 4/(4√2) = 1/√2
cos(β) = 4/(4√2) = 1/√2

From this
sin(α−β) =
= sin(α)·cos(β) − cos(α)·sin(β) =
= (2/√5)·(1/√2) − (1/√5)·(1/√2) =
= 1/√10


Using trigonometric identity
cos(φ+90°) = −sin(φ)
we derive
cos(∠XOY) = cos(α−β+90°) =
= −sin(α−β) = −1/√10

which is exactly what we have calculated in Solution B1.

Thursday, July 18, 2024

Vectors+ 01 Dot & Cross Products: UNIZOR.COM - Math+ & Problems - Vectors

Notes to a video lecture on http://www.unizor.com

Vectors+ 01

Problem A

Given a two-dimensional vector A with known coordinates (a1,a2) and another two-dimensional vector B with known coordinates (b1,b2).
Find the coordinates (x,y) of vector X, if it's known that
scalar product A·X = c and
scalar product B·X = d.

Solution A
We have a system of two linear equations with two unknowns
a1·x + a2·y = c
b1·x + b2·y = d

Answer A
x = (c·b2 − d·a2) / Δ
y = (d·a1 − c·b1) / Δ

where Δ is determinant of the matrix of coefficients
Δ = a1·b2 − a2·b1

Note A1
The obvious necessary and sufficient condition for the problem to have a unique solution is that Δ≠0, which means that vectors A and B must not be collinear.

Note A2
This problem can be easily extended to three-dimensional or any N-dimensional case with N-dimensional vectors
A(a1,a2,...,aN)
B(b1,b2,...,bN)
X(x1,x2,...,xN)
and scalar products
A·X = Σi∈[1,N]ai·xi
B·X = Σi∈[1,N]bi·xi
The solution would lead to a system of three or, generally, N linear equations with as many unknowns - coordinates of unknown vector X.
Similar condition on the determinant of a matrix of coefficients not equal to zero should be specified to have a unique solution.


Problem B

Determine a three-dimensional vector X(x1,x2,x3)
if its known that
X A = B and AX
where A(a1,a2,a3) and B(b1,b2,b3) are given non-collinear vectors and signifies a vector (cross) product of two three-dimensional vectors.

Solution B

First of all, let's analyze the geometry of these three vectors A, B and X.
Since X A = B, vector B, as follows from the definition of the vector product, must be perpendicular to two others:
BX
BA
Since it's given that AX, all three vectors are mutually perpendicular to each other.
In particular, both A and X lie in the plane perpendicular to vector B.

The magnitude of vector B equals to a product of magnitudes of A and X times a sine of an angle from A to X.
The direction of vector B is along the perpendicular to a plane defined by vectors A and X.

Without the condition AX we have the freedom to change the magnitude of X and rotate it within the same plane where it was, changing inverse-proportionally the sine of the angle from A to X and getting the same vector B=XA. So, this last condition is important to get to the unique solution.
With the condition AX the sine of an angle from A to X is 1 and all we need to do to obtain vector X is to determine its magnitude |X| from an obvious equation
|A|·|X| = |B|
since the direction of B is known - it's perpendicular to a plane defined by A and B.

Knowing the magnitude |X|=|B|/|A| and line perpendicular to a plane defined by A and B, along which vector X should be positioned, all that remains to establish is to chose one of two directions along this line. This is an elementary choice based on the right hand rule of forming a vector product.

Let's approach this problem in coordinate form.

Perpendicularity AB can be expressed in terms of scalar product A·B=0, that is
a1·b1 + a2·b2 + a3·b3 = 0
We will use it later on.

As derived in the Math 4 Teens course on UNIZOR.COM site (see lecture Vectors - Vector Product - Coordinate Form), since XA=B,
b1 = x2·a3 − x3·a2
b2 = x3·a1 − x1·a3
b3 = x1·a2 − x2·a1
This is a system of three linear equations with three unknowns.
Can we solve it and be done?
NO!
Our geometric analysis showed that without condition AX the problem does not have a unique solution, and this condition is not part of our system of 3 linear equations with 3 unknowns.

What's wrong with solving the above system of 3 equations?
THESE THREE EQUATIONS ARE LINEARY DEPENDENT and, therefore, we really have only two independent equations, not three.
To determine this, we can rewrite our three equations in a canonical form
x1·0 + x2·a3 + x3·(−a2) = b1
x1·(−a3) + x2·0 + x3·a1 = b2
x1·a2 + x2·(−a1) + x3·0 = b3
and calculate the determinant of a matrix of coefficients Ω:
0a3−a2
−a30a1
a2−a10
det(Ω) =
= 0·0·0 + a1·a2·a3 − a1·a2·a3
− a2·0·a2 − a1·0·a1
− a3·0·a30 = 0


Condition AX will be the really independent third equation
a1·x1+a2·x2+a3·x3 = 0

Let's assume that a3≠0, in which case we can find x1 and x2 in terms of x3 from the first two equations of the system above.
b1 + x3·a2 = x2·a3
−b2 + x3·a1 = x1·a3
from which follows
[b1 + x3·a2]/a3 = x2
[−b2 + x3·a1]/a3 = x1
Substitute this into an expression
a1·x1+a2·x2+a3·x3 = 0
getting
a1·[−b2 + x3·a1]/a3 +
+ a2·
[b1 + x3·a2]/a3 +
+ a3·x3 = 0

Resolve it for x3:
x3·(a12+a22+a32) =
= a1·b2 − a2·b1

or

x3 = (a1·b2 − a2·b1)/ |A|2

where |A| is a modulus (magnitude, length) of vector A.

From this we can find other coordinates of vector X.
x2·a3 = b1 + x3·a2 =
= b1 + a2·(a1·b2−a2·b1)/|A|2 =
= (b1·|A|2 + a2·a1·b2
− a2·a2·b1)/|A|2 =
= (b1·a12 + b1·a22 + b1·a32 + a2·a1·b2 − a2·a2·b1)/|A|2 =
(b1·a22 cancels −a2·a2·b1)
= (b1·a12+ b1·a32 +
+ a2·a1·b2)/|A|2 =
=
[a1·(a1·b1+a2·b2) +
+ b1·a32
]/|A|2 =
(since a1·b1+a2·b2+a3·b3=0,
a1·b1+a2·b2=−a3·b3
)
=
[a1·(−a3·b3) + b1·a32]/|A|2 =
= a3·(b1·a3 − a1·b3)/|A|2


Therefore,

x2 = (a3·b1 − a1·b3)/ |A|2

Analogously,

x1 = (a2·b3 − a3·b2)/ |A|2


Obviously, we could've come to the same result if we considered the mutual perpendicularity of all three vectors A, B and X. This factor alone is sufficient to state that vector A⨯B is collinear with vector X.
As we know (see the reference above, when we considered B=X⨯A), vector Y=A⨯B has coordinates
y1 = a2·b3 − a3·b2
y2 = a3·b1 − a1·b3
y3 = a1·b2 − a2·12
which exactly what numerators in the above expressions for X-components are.
The magnitude of vector Y is |Y|=|A|·|B|.

Since it's given that |B|=|A|·|X|, all we need to find vector X is to take vector Y and to alter its length to satisfy the condition |B|=|A|·|X|, which means to divide it by |A|.

Friday, July 12, 2024

Algebra+ 10 - Function: UNIZOR.COM - Math+ & Problems - Algebra

Notes to a video lecture on http://www.unizor.com

Algebra+ 10 - Functions

Problem A

Prove that function
f(x) = x/(1+x²) is
(a) monotonously decreasing on interval (−∞,−1),
(b) monotonously increasing on interval (−1,1) and
(c) monotonously decreasing on interval (1,+∞).

Solution A

Our first observation is that, if we replace x with −x, function f(x)=x/(1+x²) changes the sign while retaining the absolute value
f(−x) = −f(x).
That means, our function is odd, and its graph is centrally symmetrical relative to the origin of coordinates.
It also means that f(0)=0 and the graph on interval (−∞,0) can be obtained from the graph on interval (0,+∞) by turning it by 180° around the origin of coordinates.

When this rotation is done, an interval on the positive side of the X-axis, where the function was increasing, would be transformed by a rotation into a corresponding interval on the negative side, and the function there would still be increasing.
Similarly, an interval on the positive side of the X-axis, where the function was decreasing, would be transformed by a rotation into a corresponding interval on the negative side, where the function would still be decreasing.
The following is an illustration of this characteristic of odd functions.


Therefore, it's sufficient to investigate the behavior of this function on interval (0,+∞), and the results are sufficient to tell how this function behaves on interval (−∞,0).

If we prove that f(x) is monotonously increasing on interval (0,1) from f(0)=0 to f(1)=½, it implies that this function is monotonously increasing on interval (−1,0) from f(−1)=−½ to f(0)=0
Analogously, if we prove that f(x) is monotonously decreasing on interval (1,+∞) from f(1)=½ to infinitesimal value, it implies that this function is monotonously decreasing on interval (−∞,−1) from infinitesimal value to f(−1)=−½.

Let's prove that f(x) is increasing on interval (0,1).
Assume, both x1 and x2, which is greater than x1, belong to interval (0,1), and prove that f(x2) is greater than f(x1).

Analysis:
x1/(1+x12) < x2/(1+x22)
Multiply both sides by positive value (1+x12)·(1+x12), which does not affect the inequality.
x1·(1+x22) < x2·(1+x12)
Open the parenthesis, getting
x1 + x1·x22 < x2 + x2·x12
Rearrange,
x1·x2·(x2−x1) < x2 − x1
Since we assumed that both x1 and x2, which is greater than x1, belong to interval (0,1), all components of this inequality are positive, we can cancel the multiplier (x2−x1), arriving to an obvious inequality
x1·x2 < 1

Proof:
All transformations of inequalities are invariant and reversible, therefore, from the obvious inequality
x1·x2 < 1
we can obtain the original inequality using only invariant transformations, which proves its validity.

Let's prove that f(x) is decreasing on interval (1,+∞).
Assume, both x1 and x2, which is greater than x1, belong to interval (1,+∞), and prove that f(x1) is greater than f(x2).

Analysis:
x1/(1+x12) > x2/(1+x22)
Multiply both sides by positive value (1+x12)·(1+x12), which does not affect the inequality.
x1·(1+x22) > x2·(1+x12)
Open the parenthesis, getting
x1 + x1·x22 > x2 + x2·x12
Rearrange,
x1·x2·(x2−x1) > x2 − x1
Since we assumed that both x1 and x2, which is greater than x1, belong to interval (1,+∞), all components of this inequality are positive, we can cancel the multiplier (x2−x1), arriving to an obvious inequality
x1·x2 > 1

Proof:
All transformations of inequalities are invariant and reversible, therefore, from the obvious inequality
x1·x2 > 1
we can obtain the original inequality using only invariant transformations, which proves its validity.


Problem B

Prove that function
f(x) = x + (1/x2) is
(a) monotonously increasing on interval (−∞,0),
(b) monotonously decreasing on interval (0,2) and
(c) monotonously increasing on interval (2,+∞).

Solution B1

Consider an expression
Δ = f(x2) − f(x1)
for x1 being smaller than x2 on each of the three intervals mentioned in the problem.
Based on the sign of Δ that reflects the relationship between f(x1) and f(x2), we can determine the behavior of the function on each interval.

(a) −∞ < x1 < x2 < 0
Δ = x2+(1/x22) − x1−(1/x12) =
= (x2−x1) + (1/x22−1/x12) =
= (x2−x1) +
+ (x1−x2)·(x1+x2)/(x12·x22)
=
Since −∞ < x1 < x2 < 0, all components of the above expression are positive, which proves that in this interval the function is monotonously increasing.

(b) 0 < x1 < x2 < 2
Δ = (x2−x1) +
+ (x1−x2)·(x1+x2)/(x12·x22) =
= (x2−x1) ·
·
[1 − (x1+x2)/(x12·x22)] =
= (x2−x1) ·
· (x1·x2−1/x1−1/x2)/(x1·x2)

The term (x2−x1) is positive.
The term (x1·x2) is positive.
Let's evaluate the sign of
x1·x2−1/x1−1/x2 =
= x1·x2 − (1/x1+1/x2)

Component (x1·x2) on interval from 0 to 2 does not exceed 2·2 = 4.
Components (1/x1+1/x2) exceeds 1/2+1/2 = 4.
Therefore, in this case Δ is negative, which means that the function is decreasing in this interval.

(c) 2 < x1 < x2 < +∞
Evaluating again the term in question
x1·x2 − (1/x1+1/x2)
Now situation with the sign of this term is opposite to the previous one.
Component (x1·x2) on this interval exceed 2·2 = 4.
Components (1/x1+1/x2) does not exceed 1/2+1/2 = 4.
Therefore, in this case Δ is positive, which means that the function is increasing in this interval.

Solution B2

Obviously, using the apparatus of Calculus, the solution is shorter.
The first derivative of the function f(x)=x+(1/x2) is
f'(x) = 1 −2/x3
This derivative is equal to zero only at one point
x = 2 = 21/3
The local minimum at that point is
y = 21/3 + 2−2/3
When x is either negative or is greater then 2, the derivative is positive and, therefore, the function is increasing.
When x is positive but less than 2, the derivative is negative and, therefore, the function is decreasing.

Graph B
Incidentally, the graph of the function f(x)=x+(1/x2) looks like this

Friday, July 5, 2024

Algebra+ 09 - Progressions: UNIZOR.COM - Math+ & Problems - Algebra

Notes to a video lecture on http://www.unizor.com

Algebra+ 09 - Progression

Problem A

Solve the following equation
X3+7·X2−21·X−27=0
if it's given that its three solutions form a geometric progression.

Solution A

Let's analyze the relationship between the solutions to an equation of the 3rd power
X3+P·X2+Q·X+R=0
and its coefficients.
If a, b and c are the solutions of an equation of the 3rd power with a coefficient 1 at X3 then
(X−a)·(X−b)·(X−c) = 0
Opening the parenthesis, we obtain
X3−(a+b+c)·X2+
+(ab+bc+ca)·X−abc = 0


Notice that for this type of equation the product of its solutions equals to a free coefficient R with minus sign, while a sum of its solutions equals to a coefficient P at X2 with a minus sign.
Therefore, in case of a given equation
a·b·c = −R = 27 and
a + b + c = −P = −7

Since it's given that three solutions of this equation form a geometric progression,
b = a·r and c = a·r²
where r is a progression's common ratio.
This allows us to represent two equations above in terms of a and r as follows
a·(a·r)·(a·r²) = 27
a + (a·r) + (a·r²) = −7
From the first equation follows:
(a·r)³ = 27
a·r = 3
which, incidentally, is one of the solutions: b=3.

From this and the above equations connecting solutions to coefficients of an equation, we conclude
a·3·c = 27 and
a + 3 + c = −7
or
a·c = 9 and
a + c = −10
Therefore expressing c in terms of a from the second equation and substituting into the first, we obtain
c = −10 − a and
a·(−10−a)=9
or
a² + 10·a + 9 = 0
Solutions to this simple quadratic equations are
−1 and −9.
Putting all solutions into a geometric sequence,
a=−1, b=3, c=−9
or
a=−9, b=3, c=−1
The common ratio of these progressions are r=−3 for the first and r=−1/3 for the second sequence, but the set of solutions is the same.

Answer A
Solutions to a given equation are:
−1, 3, −9
They form a geometric progression with the first member a=−1 and the common ratio r=−3 or a geometric progression with the first member a=9 and the common ratio r=−1/3.


Problem B

Solve the following equation
X3−15·X2+26·X+120=0
if it's given that its three solutions form an arithmetic progression.

Solution B

Let's use the same relationship between the solutions to an equation of the 3rd power as above
a·b·c = −R = −120 and
a + b + c = −P = 15

Since it's given that three solutions of this equation form an arithmetic progression,
b = a+d and c = a+2d²
where d is a progression's common difference.
This allows us to represent two equations above in terms of a and d as follows
a·(a+d)·(a+2d) = −120
a + (a+d) + (a+2d) = 15
From the second equation follows:
3a+3d = 15
a+d = 5
which, incidentally, is one of the solutions: b=5.

From this and the above equations connecting solutions to coefficients of an equation, we conclude
a·5·c = −120 and
a + 5 + c = 15
or
a·c = −24 and
a + c = 10
Therefore expressing c in terms of a from the second equation and substituting into the first, we obtain
c = 10 − a and
a·(10−a) = −24
or
a² − 10·a − 24 = 0
Solutions to this simple quadratic equations are
−2 and 12.
Putting all solutions into an arithmetic sequence,
a=−2, b=5, c=12
The common difference of this progression is d=7.

Alternatively, using obvious relationships
a = b − d and c = b + d,
we can express the equation
a·5·c = −120
as
(5−d)·5·(5+d) = −120
or
25 − d2 = −24
from which we derive
d = ± 7,
which, in turn, leads to either
a = −2, c = 12
or
a = 12, c = −2
which is the same set of solutions in a different order.

Answer B
Solutions to a given equation are:
−2, 5, 12
They form an arithmetic progression with the first member a=−2 and the common difference d=7 or an arithmetic progression with the first member a=122 and the common difference d=−7.


Problem C
Given two progressions, arithmetic and geometric, that satisfy the following conditions:
(a) the first members of these progressions are the same and are not equal to zero;
(b) the sums of the first three members of these progressions are the same;
(c) the sum of the first two members of arithmetic progression is greater than the sum of the first two members of geometric progression by the triple value of the first member of arithmetic progression.
What is the common ratio of the geometric progression?

Solution C

Arithmetic progression can be represented as
{a+k·d}
where
a is the first member,
d is the common difference,
k∈[0,N] is a sequence number (N is greater than 3).

Geometric progression can be represented as
{b·rk}
where
b is the first member,
r is the common ratio,
k∈[0,M] is a sequence number (M is greater than 3).

Conditions specified in the problem can be represented as
(a) a = b
(b) a + (a+d) + (a+2d) =
= b + b·r + b·r2

(c) a + (a+d) = 3a + b + b·r

Condition (a) can be used to replace unknown b in conditions (b) and (c) to simplify them as follows:
(b) a + (a+d) + (a+2d) =
= a + a·r + a·r2

(c) a + (a+d) = 3a + a + a·r
which can be simplified further as
(b) 2a + 3d = a·r·(1+r)
(c) d = 2a + a·r

Now we can use condition (c) to substitute d in condition (b):
(b) 2a + 3·(2a+a·r) = a·r·(1+r)

We can reduce this equation by a getting a quadratic equation for unknown ratio r:
2 + 3·(2+·r) = r·(1+r)
or
r2 − 2r −8 = 0
with solutions
r1=4; r2=−2

Answer C
There are two possible values for the common ratio r:
r1=4; r2=−2