Showing posts with label expressions. Show all posts
Showing posts with label expressions. Show all posts

Friday, July 31, 2009

Is there a connection between Mathematical Writing and Fractal Geometry?

When it comes to math formulas, and equations, is it possible to assign to them some sort of measure similar to a fractal dimension?

For the above question to even start to make sense, let’s make one main assumption: let’s say that plain text has dimension one, whereas pictures of faces, landscapes, and other objects, have dimension two. Here is the case for assigning dimension one to plain text. In English, and other European languages, verbal information is encoded in written form by means of the alphabet, writing down one character at a time, in a linear sequence. We create words by placing letter after letter in a given sequence. We create phrases, and sentences by placing word after word in a given sequence. In practice, text lines are broken according to the width of each page, and pages are filled with many lines of text. However, in the abstract model for this way of encoding information, we can consider each text document as a single, long, uninterrupted line of text. To read text, we only need the basic linear connection from each letter to the next one, and from each word to the next one. Any text document can be considered as a sequence of characters, however long it may be.
On the other hand, when we look at images in the real world, like homes, people, faces, mountains, trees, animals, and so on, we process this visual information in a very different way. We see color, shades of color, light, texture, and a multitude of details that can only make sense when we consider them embedded in the full three-dimensional space around us. However, our retina is pretty much a flat surface, and our brains have to imagine the three-dimensional world based on the two-dimensional information our flat retina collects from the incoming light. So, the raw material our brain uses to process visual information is nearly two-dimensional in nature. When looking at an image, if we consider a little part of it, there is no such thing as “the next pixel,” because that could be located above, or below, or to the right, or to the left, or in any diagonal direction. Often we can find linear patterns inside some images but the whole image is fully two-dimensional.
So, where does this basic assumption about dimensions leave the written representation of mathematical expressions?
In a recent math tutoring session, I was helping a student prepare for the SAT, and we came across a problem that involved the expression a(1/2). However, we got confused for a couple minutes because there were no parenthesis around the fractional exponent, the exponent was in a font size as big as that of the variable, and the fraction bar was too close to the variable. It looked something like this:

So, at first we thought the book meant 1/(a2). We momentarily (and incorrectly) interpreted the expression as if it had looked like this instead:


We were trying to solve the problem doing the calculations with that interpretation, and we were getting nowhere near the answer, until we realized the book meant a(1/2), not 1/(a2).
The expression should have looked more like this:

This simple example shows that, when reading mathematical expressions, we process the information in a way that seems like a hybrid of how we read text, and how we look at two-dimensional images. In reading math expressions, it is very important to take into account visual clues like the size of each symbol, and the relative position they hold to each other, their spatial arrangement in the page, and how close or far away they are from each other. This is essential because mathematical notation implicitly uses our instinctive understanding of two-dimensional images to convey the fine details of each expression’s precise, hierarchical structure. This also has to do with the familiar PEMDAS rules of evaluation, and is key to getting the problems right. Correctly applying the PEMDAS rules is relatively easy when a particular expression is all contained in a line of text. However, when we start dealing with sub-indexes, summation notation, roots, integrals, derivatives, rational functions, powers of powers, upper and lower limits, fractions of fractions (and especially with combos of all of the above); deciphering an expression's structure requires a visually detailed inspection of the two-dimensional arrangement of all the different symbols making up the expression.

As opposed to a line of text, the structure of a mathematical expression is not necessarily linear. Most often than not, the hierarchy branches out. Mathematical expressions include symbols for operations. Operations usually are functions of two arguments, or parameters. These are called "binary" operations, like addition, or multiplication. Often we work with "unary" operations, or functions of only one argument, like the square of a number, or its absolute value. Sometimes we work with operations that take more than two arguments. The basic fact is that functions have input arguments, and produce output values that can, in turn, be used as inputs by other functions. A mathematical expression has a hierarchical structure given by all the connections between input values, and the functions using them. The written representation of a math expression has to present all these connections unambiguously. The set of all these connections between symbols constitutes a hierarchy that we call a rooted tree. This term (bear with me) denotes an acyclic, connected, directed graph with a finite set of nodes, including one main node (the tree’s “root”). Upon this underlying structure, each node gets associated with a particular symbol representing either a constant, a variable, or an operation. Let’s look, for example, at the quadratic formula (the formula used to solve quadratic equations):


Below we show the rooted-tree that is the foundation for the hierarchical structure of the quadratic formula (not including the equal sign, just the right-hand side); along with the constants, variables, or operations that are associated to each node in the graph. Looking at the arrows, you can see each individual symbol is connected to the one directly “above it” in this hierarchical structure:



In the diagram above, I use the square shape to represent the application of the function "taking the square of b." Note we are still making an implicit assumption based on our visual processing of images. We are relying on the left-right distinction to implicitly give the correct ordering for the arguments of division, and subtraction, the two operations used here that are not commutative.
The rooted tree makes apparent the formula's underlying, hierarchical structure, it shows all its components, and their individual connections. We could philosophically argue that this structure is what the quadratic formula "really is," independently of the format we choose to represent it. My purpose here, in showing the rooted tree associated with the formula's structure, is to make the point that the linear simplicity of written text falls short when it comes to encoding complex mathematical expressions. True, with suitable conventions, and enough parenthesis, you can make almost any math expression fit into a line of text but that does not make its structural complexity go away one bit. For example, you can write the quadratic formula like this:

x = (-b [+/-] sqrt(b^2-4ac))/(2a)

It is all written in a line of text but the hierarchical, branching order of its operations is still the same. Many students (and, consequently their math instructors) deal all the time with the relative difficulty of correctly deciphering the hidden structure of mathematical formulas based on its written representation. This is a fundamental skill that heavily affects students' performance in math, and therefore, their grades, and their future career choices.
Not long ago I wrote a related post in this blog, titled "Math is not English."

People who are not "math-oriented" may find this hard to believe but actually, the mathematical syntax, symbols, notation and conventions currently in use (at least up to Calculus and Linear Algebra) are pretty much the easiest, clearest, simplest, most convenient way mathematicians have found (laboriously through the centuries) for writing and reading mathematical formulas. Believe me, the guessing and reasoning behind the formulas is hard enough. No mathematician is interested in making the notation artificially complicated, quite the contrary.

This finally leads me to the reason why I wrote this post in the first place. I recently attended an online get together of fellow Twitter math enthusiasts. The discussion centered on the large gap between text editors, and math equation editors; particularly with the purpose of publishing, storing, and searching mathematical expressions on the Internet. Compared to the wide availability of high-quality word processors, text editors, and text-based search engines, there seems to be a perceived scarcity of free, online tools for authoring and delivering math expressions online, as well as for searching math documents by their mathematical formulas, not by keywords. These topics immediately made me think of the fundamental structural difference between text and math I mention above because, as a math tutor, I have to help my students deal with this chasm practically every day.
Mathematicians would absolutely love a software package capable of identifying, and extracting the hidden, hierarchical structure of a math formula from the handwriting they could do on an electronic tablet with an electronic pen. My contention is that one of the main reasons this type of software does not yet exist, is because of the large extent to which the conventions of current mathematical notation rely on our unconscious, instinctive, biologically hard-wired, visual processing of images to convey mathematical meaning. As crazy as it sounds, and no matter how many of my students I know would disagree with this statement, we have come a long way in making math very easy to read and write on a piece of paper. However, we have done so by tapping into our biological processing of images, and this has inevitably put us at a disadvantage when it comes to entering that information into a digital format.

Anyway, the question in the title of this post: "Is there a connection between Mathematical Writing and Fractal Geometry?" is motivated by the non-linearity (branching out) of hierarchical math expressions, on one hand, and our hybrid way of reading them, on the other; as something between dimension one (plain text), and dimension two (full images).

Wednesday, January 28, 2009

Ubiquitous Numbers

One and Zero are always everywhere

The more you tutor math, the more skilled you become in finding good, clear ways to explain all types of math concepts to students. However, some concepts are more elusive than others. The difficulty of grasping a concept depends not only on the concept itself but also on the student who is assimilating it. One person, for example, can easily understand polynomial multiplication, and struggle with percentages, while someone else can find percentages very easy but have trouble with polynomials. There are also some concepts or topics that seem to be hard for a significant majority of students, like word problems for instance.
Substitution is a very powerful problem-solving technique, and it is widely used in a variety of situations. Students who find substitution easy have a clear advantage over students who have trouble understanding it. Substitution comes up in many different ways, some more complex than others. Some students understand the more basic forms of substitution but have problems applying the same techniques when dealing with more complex expressions. In fact, a very consistent general trend is the host of negative reactions students tend to show in varying degrees when facing bigger, longer, more complicated expressions. The more complex the expression, the more likely that students will get confused, or feel overwhelmed by it.
There is a particular way of using substitution to which most students react with a strong resistance: It involves transforming a given expression into another one that is equivalent in value but looks more complicated. This is done with the ultimate goal of simplifying the expression but it starts out by complicating it a little more. It is like climbing up a hill to find a way down the mountain.
The most common way of using this technique is by introducing a representation of the numbers Zero or One into the given expression.
Zero and One are very special numbers. They implicitly are everywhere in any given algebraic expression, even when we do not see them written out.
Zero is called the additive identity because zero plus any number is that same number ( x + 0 = x ).
One is called the multiplicative identity because one times any number equals that same number ( x∙1 = x ).
These two properties make Zero and One algebraically omnipresent in an implicit way.
Further, we have the following properties:
A number subtracted from itself equals zero ( x – x = 0 ).
A number different from zero, when divided by itself gives us one as the result ( x/x = 1 ).
These last two properties give Zero and One an infinite number of representations (“disguises” if you will) to show up in a formula. So, not only are Zero and One ubiquitous, they can come in a dizzying multiplicity of seemingly different forms.
The above properties of Zero and One, and their consequences, make them extremely useful in solving equations, and in manipulating algebraic expressions in general.
However, as I mentioned before, many students present a strong resistance to the idea of making an expression more complicated to be able to reduce it later. This is partly because they do not see the point of multiplying a number times one, or adding zero to it; partly because doing so seems to increase the problem in size and complexity; partly because they feel we are working backwards into some uncalled-for calculation, and finally because they believe they would not know what particular form of Zero or One they are supposed to introduce into the expression if they were doing the problem on their own.
Sometimes, when working with a student on a given problem, it is very easy for me to see a path to the solution using these types of techniques but I have learned to make sure the student does not feel like I was expecting him or her to be able to solve the problem in the same way. I only use these techniques when the student is completely stuck in the problem, not making any progress at all. When they see one possible solution, it gives them some perspective on the different factors playing a role in the problem. After showing them one possible solution method, if they do not feel comfortable that they would be able to successfully use the same method on their own, we focus on finding an alternate method that works better for them.

Wednesday, December 10, 2008

Math is not English

The order of operations messes with our reading habits.

The mathematical order of operations seems to be a source of confusion for some students, sometimes even frustration. For example, when presented with the expression
3 + 4(x-1)
some students ask: “Why can’t we just start by adding 3 + 4, and then multiplying 7 times (x-1)?”
My short answer is: “Because math is not English.” Then I ask: “Is there any parenthesis around the 3 + 4 sum?” When they say “no” I continue: “Then the parenthesis that is there right after the 4 claims that 4 for itself, for multiplication purposes. It will not let the 4 run away with the 3, oh no sir, no way! The multiplication operation has title to that 4, and to that (x-1) as well, and it does not care about the 3 the slightest bit. The addition operation holds a lesser priority than multiplication does, so it has to wait for its turn.”
I explain the PEMDAS rules using action verbs commonly applied to human situations, thus making the math symbols play the role of active, independent characters with human-like behaviors. This type of explanation makes my students understand the mathematical structure of the expression at hand but still some seem puzzled, or surprised, or even bothered by the fact that the applicable sequence of operation does not necessarily follow the simple left-to-right order. So in those cases I proceed with the following explanation:
There is a crucial difference between the way we read math, and the way we read English. This is very important. We always read English from left to right. Such a simple, linear, unidirectional way does not do it for math. It does not work. Reading math from left to right only, is insufficient, and inadequate. In math we have to read formulas and expressions not just from left to right but from right to left; from the top down; from the bottom up; from the inside out; from the outside in; and even around in circles. In short, every which way, else we run the risk of missing essential information about the structure of the thing. Reading math is not reading. Reading math is much more similar to what the eyes of a helicopter pilot do when they are flying over a mountain terrain, looking for a spot to safely land the helicopter. You look at everything, everywhere.
Written language mimics spoken language, going along with the flow of the story. English is perfect for telling stories. Math describes structures. It has an altogether different goal, so it cannot work the same way English does. Mathematical expressions do not resemble stories nearly enough the way they resemble gizmos, appliances, devices, or cars, objects made out of parts. The parts are connected to each other in a very specific way. Each part has its own function, and its own place within the whole thing. So, really, reading math from left to right only, makes as much sense as trying to “read a car” from left to right only.

Saturday, December 22, 2007

Find and Replace

The substitution method

Most students understand the concept of substitution when the task is to plug in a plain numerical value for a variable in a formula.
A typical example would be to evaluate y = 3x^2 - 5x + 2
when x = -1
Things change dramatically when the task involves plugging in an algebraic expression to replace a variable in another expression, even when the expression we are plugging in is of small complexity.
For example, from y = 3x + 5 plugging in the value 3x + 5 instead of y into the equation 2x - y + 4 = x + 3y - 1.
In the past I often had trouble explaining the process to some students. In my experience, a significant fraction of students taking the tutoring have some difficulties mastering this process. They get the concept in theory, and they are able to apply it in simple examples, but as the replacing expression grows in complexity, they quickly get stuck.
Lately though, I have dramatically increased my success rate for teaching this concept by using the following analogy. I go:
"O.K., time out. I have a question. Are you familiar with the computer program MS Word, the word processor? Have you used it to type some letters?"
They look at me as if I was asking them whether they are from this planet, and they say "Yeah..." Then I continue:
"Have you seen that little binoculars button that says Search and Replace? You know, when you have just finished writing a letter, but you are not very happy with a particular word you used several times, and all of a sudden you think of a better word. Then you click on that Search and Replace button, right? Instead of reading over the whole letter, looking for the word you want to change, and manually typing the new word over and over."
Then their eyes light up and they say: "Oh, yeah! And it gives you the total count for how many replacements were made!"
At this point I say: "Exactly! That is what we are doing here, search and replace. This equation is the letter and this other equation is the Search and Replace button." They silently look at me with a face that yells, "What are you talking about?" Then I proceed:
"Look, this is the letter, O.K.? Our document, from here to here, this equation: 2x - y + 4 = x + 3y - 1 . That is the whole document. And we are the program. This other equation here: y = 3x + 5, that is the Search and Replace button that says:
'Search the document for the letter y and every time you find it, replace it for this other phrase: 3x + 5.' So we perform the instruction, right? We go over the document, symbol by symbol. we copy the 2, we copy the x, we copy the '-' sign, and then we find a 'y.' Well, instead of 'y,' we write this other thing, we write '3x + 5' right? And then we just keep copying the symbols from the original equation until we find another 'y' and we keep doing that search and replace thing until we reach this last '1' here at the end, the last symbol in the original equation."
They totally get it! For confirmation, I ask: "Does that make sense?" They usually say: "Yes, perfect sense! I mean, I get it. Is that all there is to it?" I look them in the eye and I say: "Yeah, that's it" Then they go: "Gosh, let me do the next one!" And they normally get it right in the first try or at most two tries with almost no exception. I am very happy I found this analogy.