
While recently writing code to render the Mandelbrot set, a notorious fractal, when plotted on the complex plane, I made an error in my code, and came up with the exceedingly odd image above. It looked similar enough to what I was aiming for that I knew I hadn’t utterly screwed up, but something was obviously wrong. Looking over my code, I realized that I had used the new x (or a, as the case may be) value in the recursion to determine the y (or b) value, instead of the old one, as should have been so (instead of y=2*x*y+b, I was accidentally using y=2*(x^2-y^2+a)*y+b). This was easy to fix (so I can now generate the intended fractal), and it made the above image so much cooler, once I knew what was generating it. The gray area in the middle would be black with an greater number of possible recursions or a slightly different coloring scheme (I only used 100 recursions), but I thought it looked cooler this way. Feel free to generate your own. Larger image of mine here.
My most recent project in physics class was to build a water rocket, demonstrating the ideas of force, mass, and acceleration (yes, Newton’s 2nd law). Though mine was not the best by far, it performed substantially above average, reaching a little over 40 meters vertically and staying aloft for about six seconds (bottle initially pressurized at 50 psi, 23% full of water). You can see in the picture that it was going fast enough upon landing to though roughly mangle the nose cone. We obtained the height measure using a bit of trigonometry; we had people who measured the angle between the ground and the rocket at its apogee (positioned a known distance on four sides of the “launch pad”), and later averaged the results obtained by this (height=distance*tan(angle)).
I had much less time to build my rocket than I would have liked, being flooded with other homework the weekend I chose to do so. So I had to scale back some, not building the parachute apparatus that I had conceived, and going with a generic but nice design. I made the fins out of card stock coated in duct tape, with a wire spine running along the edge. The latter provided me the ability to bend the fins at will, so I could induce substantial spin upon the rocket (which I did). I weighted the nose cone with colored gravel, and left strips of the 2 liter bottle uncovered so it could be seen how much water was inside (roughly 460 ml is the optimal amount).
Through watching other rockets, I got some ideas to improve my design if I am ever to make one of these things again. First, I will make a parachute, and not connect the nose cone to the rocket, so I still get much height if the parachute deploys early (the cone will keep going). I will also use shorter, thinner, stiffer, less angled fins for less drag. I found this project quite fun, and, if I have the time (unlikely), I may construct my own launch pad so I can continue to build and test new designs.
At the very beginning of summer, a friend of mine and I were musing about creating an algorithm for generating player ratings from the results of series of games of table tennis that we intended to play. Well, we have not got around to much of the playing yet, but we did develop a functional equation for the determination of player ratings. It seems to me that it may prove to be useful for generating player ratings for any game, not just table tennis. Here is the equation:

P1 is one player, and P2 is the other. R() defines the rating of the player passed to it, and S() is the score in the most recent game of the player. As you can see, the equation uses the previously determined ratings of the players to calculate the new ratings, so there must have been an original rating. I think that 50 is a good place to start for both players, but that is up to the user of the equation. Some features of the equation are as follows:
- It incorporates the rating of the other player into the mix, so if a very talented player is playing one who is not so good, the winning of the worse player will be worth more to his or her rating than the winning of the other.
- The distance between the scores has an effect on how much the ratings change, thus a close loss is less damaging to your rating than getting totally owned.
- There is a constant which can be used to modify what effect the discrepancy in scores has on the ratings. I used 2, but you can, of course, use whatever you want
I may eventually write a Python program to keep track of games and player ratings based on the results of the games, once I learn how to make nice looking GUIs. Until then, you’re on your own. Hope you can use it.
So, a week into summer, the kid is already looking into obscure mathematical functions with absolutely no apparent use, just for the heck of it? Yes, granted, there are better things I should be doing (like getting better at ping-pong). But how can I resist exploring new math stuff when I run across it?
The story goes like this. I was reading xkcd web comics (I consider these to be the best humor on the web), and I happened upon a reference to A(g64, g64) (an incredibly huge number, as you will know once you understand all concepts involved). Of course, I had to Wikipedia the Ackermann function, a recursive function that grows exponentially (in figurative terms, not mathematical) as its two variables increase. You can check out its definition here. Then, of course, I decided to write some code to calculate Ackermann numbers, so I did, using Python. It is as follows:

Well, yes, that is just an image of my code, strictly because it looks cooler with the syntax highlighting. And no, I didn’t just copy this from Wikipedia, I came up with it myself. Now, as soon as I figure out what to use Ackermann numbers for, I am ready to do something that will certainly prove to be interesting and educational…any ideas?
Published at June 26, 2007
in Math.
I was recently toying with my graphing calculator (yes, I toy with mathematical tools), and I found anther item to add to my list of things that are weird/cool about the Euler number. By the way, if you don’t know calculus, you might as well disregard this post, as the key weirdness involved is one that contains integral calculus.
Anyway, I was calculating random definite integrals of the function ex, and I noticed that
I says to my self, I says, this is very strange! But then I realized that it is just an excellent demonstration of the first part of the fundamental theorem at work. By said theorem, the above integral is equal to the antiderivative of ex evaluated at 1 minus the antiderivative of ex evaluated at 0. Yielding e-1. Cool, eh?
No, sorry, this post does not address math in a different coordinate system. It does, however, address the unfortunate reality that math is becoming a more and more polarizing subject: either a student is very good or is but dull normal.
I have heard (from those older than myself) that in the olden days one had to be exceptional to advance beyond high school math in high school. Now it is commonplace to find people taking Calculus (technically college math) in senior year, if not even earlier. But it also seems that there a greater number of people who are falling below the established mathematical standard. In Washington, over half of students taking last year’s standardized mathematics exam failed it. This is no difficult math folks. And Washington students are supposed to be above average as a whole.
So what do these conflicting data mean? Must be that a greater number of students are good at math, but at the same time a greater number are exceedingly lacking in mathematical skill. This leaves a much smaller middle ground, those who are just okay at math, not great, not terrible. This is bad because it turns math into a kind of elitist subject, where those who aren’t awesome think that they are utterly terrible and get demoralized, and as a result sink into the ranks of those who are utterly terrible. This means even less people who are mathematically competent, an important group for this age of developing technology and ideas. Bad news my friends.
So how do we fix this grave dilemma? Make our math education better! This way, there will be no one that really can’t do math for beans. I think some schools are taking initiative in this direction, though it may come too little too late (the case of many educational improvements in the US). I hope not. Cross your fingers, and support those attempting to better math education.
Published at May 4, 2007
in Math.
We all know about square numbers, but did you know that some numbers are triangular? You can visualize a square number like so:
+++
+++
+++
(being 32). You may have seen this coming: a triangular number could be represented like this:
+
++
+++
Nice! A triangle! Must be the triangle of three (=6). But while squaring a number is easy, how the heck can you “triangle” a number? Well, a little thought produces a simple solution. The following arrangement may assist:
+##
++#
+++
The pluses represent the numbers of the square of three that are included in its triangle, while the pound signs are those that are not. Check it out: the equation
n(n+1)
2
will give the triangle of any number n, as according to the area of a triangle: base * height / 2. You are just including the areas (the numbers) that make up the hypotenuse (if visualized as a right triangle), thus included in the area (by multiplying by n+1 as the width instead of n). The first few triangular numbers are as follows:
1, 3, 6, 10, 15, 21, 28…
The idea of triangular numbers can be used for a cool math trick: quickly taking the sum of the first n integers. What is the sum of the first 50 integers? 50*(50+1)/2=1275. Sweet!