Finance, Mathematics, Software

Using mathematics and software to model financial concepts


Lines

It is not the case PQ is the line segement from the point P to the point Q. It is more like the line containing P and Q having magnitude Q – P. If PQ = ST, then PQS = 0 and so S = P + s(Q – P) for some s. Likewise, T = Q + t(Q – P) for some t. Hence ST = PQ + (t – s)PQ so s = t and Q – P = T – S.

This gives the first example of the boundary operator, . It shows PQ = Q – P is well defined.

Published by kal, on July 10th, 2009 at 3:42 pm. Filled under: Uncategorized8 Comments

What’s the vector, Victor?

Math is all about following your nose. Grassman had the notion that P2 = 0, where P is a point, was how to detect intersections and somehow that idea generalized to higher dimensions. Don’t forget that in Grassmann’s time the of notion working in general n-dimensional space was a novelty. He ran into trouble when he tried to define a product that went beyond the dimension of the space. We’ll get back to that later.

Given points P and Q, what is Q – P? Note that Q – P is not equal to R(t) = (1 – t)P + tQ for any t. Since PQ(Q – P) = 0, it should be on the line determined by P and Q. In this sense, it has a direction. If Q – P = T – S, then T = S + (Q – P). In this sense, it has a magnitude. Differences of points are vectors.

Published by admin, on July 6th, 2009 at 9:31 am. Filled under: mathematics2 Comments

Plugging my Plugin

I tried various LaTeX WordPress math plugins and didn’t like any of them. In fact, I thought they were all pretty awful. Wedging ancient TeX technology into the world of HTML seems to be an impedance mismatch. Don’t get me started on MathML. That is a nonstarter.

Every time I tried a new WordPress theme things turned ugly so I rolled my own that uses straight HTML. I’m no Donald Knuth, but it does what I need. Here are some tests:

Use standard HTML entities for anything other than sub and superscripts

α^2^ + β^2^ = γ^2^

α2 + β2 = γ2

Use curly braces for grouping

a_{b_1_ + 2}_

ab1 + 2

Feel free to hardwire standard HTML if you think that will make things look better.

∫_a_^b^ f(x) dx

ab f(x) dx

Published by kal, on July 2nd, 2009 at 6:05 pm. Filled under: UncategorizedNo Comments

Grassmann Algebra

Hermann Grassmann had the notion that it was possible to use algebra to prove geometric facts. Instead of using scalar Cartesian coordinates, he used actual points in space. Let E be Euclidean space and call the elements of E points. If P and Q are two points then PQ should represent something like the line from P to Q. If P, Q, and R are three points then PQR should resemble the triangle having vertices P, Q, and R. And so on.

If t is a scalar tP is the point P with weight t. Let R(t) = (1 – t)P + tQ, where P and Q are points and t is a scalar, then R(0) = P and R(1) = Q. In general aP + bQ is the point (a/(a + b) P + b/(a + b) Q = R(b/(a + b)) having weight a + b.

What is PQ if P = Q? If PQ resembles the line segment from P to Q, then the line from P to P is the point P. Assuming P = P2 we have P + Q = (P + Q)(P + Q) = PP + PQ + QP + QQ = P + PQ + QP + Q so 0 = PQ + QP and hence  0 = PP + PP = 2P for any point P. That might have been the first theory Hermann discarded before he came up with the idea PQ = 0 if P = Q. We have 0 = (P + Q)(P + Q) = PQ + QP so PQ = -QP. Since 0 = -0 we don’t have to discard this theory yet.

Note that  PQR = 0 if P = Q or Q = R or R = P. More generally PQR(t) = 0 for all t with R(t) as above. In general, PQR = 0 if and only if the three points are colinear.

For example, P(Q + R) is the median of the triangle PQR from P to the midpoint of QR. The barycenter of the triangle is P + Q + R. Note P(Q + R)(P + Q + R) = PQP + PQQ + PQR + PRP + PRQ + PRR = PQR + PRQ = 0. This proves the medians of any triangle meet at a point, if you think about the symmetry for a second.

Grassman’s rule that P2 = 0 enables the detection of points not being in general position, i.e., they don’t determine an n – 1 dimensional object. If n points belong to a subspace of dimension less than n – 1 their product vanishes, not just for n = 2

Published by admin, on July 1st, 2009 at 8:51 am. Filled under: mathematics Tags: , , , , 2 Comments