A Programmer’s Introduction to Mathematics
Part III<p>(8) High School Plane Geometry<p>High school plane geometry contains some
nice, useful math and an excellent first
lesson in mathematical proofs.<p>(9) Abstract Algebra<p>In grade school, we learned that<p>2 + 3 = 5<p>Abstract algebra calls the +, addition, an
<i>operation</i>.  Multiplication is also an
operation.<p>We learned that for real numbers a and b<p>a + b = b + a<p>So, addition is a <i>commutative</i> operation.
It is also <i>associative</i>:  For real
numbers a, b, c we have<p>a + (b + c) = (a + b) + c<p>Multiplication is also commutative and
associative.<p>For addition, 0 is the <i>identity</i> element
since for any number a we have<p>a + 0 = 0 + a = a<p>And -a is the <i>inverse</i> of a since<p>a + -a = 0.<p>Etc. with the rest of the usual properties
of the operations of addition and
multiplication we knew in grade school.<p>Well, abstract algebra studies operations
on sets more general than the numbers we
have considered so far.  So, there are
groups, rings, fields, etc.  The
rationals, reals, and complex numbers are
all examples of <i>fields</i>.<p>E.g., a <i>group</i> is a nonempty set with
just one operation.  The operation is
associative and there is an <i>identity</i>
element and inverses.<p>Some groups are commutative, and some are
not.  Some groups are on a set that is
infinite and some are on a set that is
finite.<p>Given a common definition of vectors, with
vector addition the set of all the vectors
forms a commutative group.<p>Similarly for the rings, fields, etc.  --
that is, we have sets with operations and
properties.<p>There are some important applications,
e.g., in error correcting coding.<p>(10) Calculus<p>Calculus was invented mostly by Newton and
mostly for understanding the motions of
the planets etc.<p>The first part of calculus has to do with
<i>derivatives</i>. So, suppose we have an
object that for each time t is at distance
t^2. Then the speed of the object at time
t is 2t and the acceleration is 2. The
acceleration is directly proportional to
the force on the object.<p>We got 2 and 2t from t^2 by taking
calculus <i>derivatives.</i><p>We write<p>d&#x2F;dt t^2 = 2t<p>d&#x2F;dt 2t = 2<p>So at time t, consider increment in time
h.  Then at time t + h, the object is at
position (t + h)^2. So in time h, the
object has moved from t^2 to (t + h)^2,
that is, has moved distance<p>(t + h)^2 - t^2<p>= t^2 + 2th + h^2 - t^2<p>= 2th + h^2<p>Since speed is distance divided by time,
the object has moved at speed<p>(2th + h^2) &#x2F; h<p>= 2t + h<p>Then as h is made small and moves to 0,
the speed moves to just<p>2t<p>So for very small h, the speed is
approximately just 2t, and as h moves to 0
the speed is exactly 2t.<p>So, 2t is the <i>instantaneous</i> speed at
time t.<p>So, 2t is the calculus <i>derivative</i> of
t^2.<p>To reverse differentiation we can do the
second half of calculus, do <i>integration</i>,
start with the 2t and get back to t^2.<p>Calculus is the most important math in
physics.<p>Later chapters in a calculus book show how
to find various areas, arc lengths, and
surface areas.<p>Calculus with vectors is crucial for heat
flow, fluid flow, electricity and
magnetism, and much more.<p>Einstein&#x27;s E = mc^2 can be derived from
just some <i>thought experiments</i> and the
first parts of calculus.  There is an
amazing video at<p><a href="https:&#x2F;&#x2F;www.youtube.com&#x2F;watch?v=KZ8G4VKoSpQ" rel="nofollow">https:&#x2F;&#x2F;www.youtube.com&#x2F;watch?v=KZ8G4VKoSpQ</a><p>Calculus is a pillar of civilization.<p>(11) Linear Algebra<p>This topic starts with systems of linear
equations in several variables, e.g., for
two equations in three variables:<p><pre><code>     2x + 5y - 2z = 21

     3x - 2y + 2z = 12
</code></pre>
The system has none, one, or infinitely
many solutions.  To see this, we can use
<i>Gauss elimination</i>.  To justify that,
multiplying one of the equations by a
non-zero number does not change the set of
solution.  Neither does adding a copy of
one of the equations to another.  So, with
these two tools, we just rewrite the
equations so that the set of solutions is
obvious.
To save space here,
I will leave the rest of the
details to the Internet.<p>A solution can be regarded as a <i>vector</i>,
e.g.,<p>(x, y, z)<p>A function f is <i>linear</i> provided for x
and y in the domain of f and numbers a and
b we have<p>f(ax + by) = af(x) + bf(y)<p>It can be claimed that the two pillars of
the <i>analysis</i> part of math are continuity
and linearity.<p>Linearity is enormously important,
essentially because it is such a powerful
simplification.<p>The linear equations of linear algebra are
<i>linear</i> in this sense.<p>Differentiation and integration in
calculus are linear.<p>Linearity is a key assumption in physics
and engineering, especially signals and
signal processing.<p>In linear algebra we take the two
equations in two unknowns and define
<i>matrices</i> so that we can write the
equations as<p><pre><code>     &#x2F; 2  5 -2 \ &#x2F; x \   &#x2F; 21 \
     |         | |   | = |    |
     \ 3 -2  2 &#x2F; | y |   \ 12 &#x2F;
                 |   |
                 \ z &#x2F;
</code></pre>
So, left to right, we have three matrices.
The first one has 2 rows and three columns
and, thus, is a 2 x 3 (read, 2 by 3)
matrix.  The second one is 3 x 1. The
third one is 2 x 1.<p>We define <i>matrix multiplication</i> so that
multiplying the first and second matrix
gives the same results as in the linear
equations:<p><pre><code>     2x + 5y - 2z = 21

     3x - 2y + 2z = 12
</code></pre>
In principle could do all of linear
algebra with just such linear equations
and without matrices, but the effort would
be very clumsy.  Matrix notation,
multiplication, etc. are terrific
simplifications.<p>The 3 x 1 and 2 x 1 matrices are examples
of <i>vectors</i>.<p>Matrix multiplication is linear.<p>The known properties of matrices and their
multiplication and addition and of
associated vectors are amazing, profound,
and enormously powerful.<p>There is a joke, surprisingly close to
true, that all math, once applied, becomes
linear algebra.<p>(12) Differential Equations<p>In the subject <i>differential equations</i>,
we are given some equations satisfied by
some function and its derivatives and
asked to find the function.<p>The classic application was for the motion
of a planet:  Newton&#x27;s laws of motion
specified the derivatives of the position
of the planet as a function of time, and
the goal was to find the function, that
is, predict where the planet would be.<p>Science and engineering have many
applications of differential equations.<p>Some of the models for the spread of a
disease are differential equations.<p>We have seen that<p>d&#x2F;dx t^2 = 2t<p>Well, we may have
function<p>f(s, t) = st^2<p>We can still write<p>d&#x2F;dx f(s, t) = d&#x2F;dx st^2 = 2st<p>but usually we say that we are taking the
<i>partial</i> derivative of f(s, t) with
respect to x.<p>(13) Mathematical Analysis<p>This topic is really part of calculus and
has the fine details on the assumptions
that guarantee that calculus works.  The
main important assumption is <i>continuity.</i>
The next most important assumption is that
the function has domain a <i>closed</i>
interval or a generalization to what is
called a <i>compact</i> set; a <i>closed
interval</i> is, for real numbers a and b,<p>{x| a &lt;= x &lt;= b}<p>Also important are <i>infinite sequences and
series</i> that make approximations as close
as we please to something we want.  So, in
this way we define sine, cosine, etc.