Sunday, August 10, 2008

Robo Bobo and the Complaint

Well, people, such as myself and Mathimoto, have been insanely busy of late. Yet, occasionally time and space conspire that posting might be made.

So let me share with you one of the reasons I've been with the busy-ness, the web and its various technologies. Now while this sounds like a simple matter, it's actually insanely complicated. But I can give you a preview:

Now the essence of the web is run on servers, most notably Apache. There are other servers with various specialties, like Jaxer's Javascript-specialized server, and Microsoft, in its fierce insistence not to be compatible with anything else has its own server, Microsoft Server. However, all of these servers in the end run on your standard compiled languages, such as Java, C++, C, or Microsoft's C# (I mean there are other possibilities like Delphi (a variant of Object-Oriented Pascal) or something along those lines, but why would you do such a thing?)).

However, not everyone actually has a server, due to expense, complexity of set-up (the #1 limiting factor on web serving in my mind), and so there are alternatives, such as serving by the domain name company that gave you the domain name, or using a web app service such as Google App Engine. The upside is usually this is less money (usually), the downside is usually this is more complex (usually), and your choice of technologies is often limited, for example Google App Engine relies on Python.

Taking a step up from the server, you got the pages. This is what comes back after a request by a user. There's a variety of technologies out there, which fall into a couple categories. Mainly, the big two are CGI, where a http request (ie, a page URL) runs a script, in theory written in anything, but usually written in a scripting language, like Javascript, VBScript, Actionscript, Perl, or Python, XML/HTML pages, with possibly embedded scripts (like the first three of the CGI languages, PHP (although that can also be run for CGI)) (in a variety of forms like ASP (Active Server Pages), ASP.Net (a variant with more Microsoft-specialty tech), JSP (Java Server Pages), or JSF (Java Server Faces)). There's also a variety of media that could come back with the page, but that's a bit more than I care to get into, although I should note that Media and such is often best caught up with Actionscript in a whole Adobe Flash mesh-up, but that tech is proprietary and may cost the money.

And once you get the pages, sometimes there's more stuff going on, like client-side scripting languages, such as Javascript and Actionscript, sometimes there's Flash Players and stuff playing the media or something, and more there's also Java applet tech, Java web start up, and the like.

I'm sure there's more and more with more combinations. I mean some people like throwing in Groovy and Common Lisp into there, because they're insane. But the web's a complicated place, with complicated people and no one understands him but his woman...

A summary of a brief overview of web tech:

Sever-program: Apache, Jaxer, Microsoft Server, etc.
Written-in: C, C++, Java, C#, etc.

Returned Page: HTML, XML, media, image, PDF, txt, etc.
Produced-by: Javascript, Actionscript, VBScript, PHP, Python, etc.

Client-side: Browser-processing, Client-side script, Media
Produced-by:
Browsers written in C, C++, Java, C#, etc., primarily with the Geko (Mozilla) engine, Internet Explorer engine, or Opera engine
Client-side scripts in Javascript, Actionscript, etc. (based on DOM events, DOM model, SAX events, ah, my mind hurts too many techs!)

And the web keeps on trucking.

Wednesday, July 23, 2008

Or do it the sensible way: Top 5 tips

Since the last post was all about the potential madness of computer cleaning, I thought I might give some saner tips, indeed, here are the top 5 (as ranked by Robo-Bobo) more safe tips for cleaning your computer, chosen for the cleaner who wants a lighter touch:

1. GET A SPYWARE SCANNER!

(And don't just download the one that comes in a pop-up ad, those usually have spyware attached to them, there a couple legitimate free ones (most famously Spybot Search and Destroy), although they tend to be less effective than the more expensive ones (although they are free), but whenever you download free software GO TO THE COMPANY OR FOUNDATION'S HOMEPAGE. Many times malware will be bundled with free-ware, but well-respected foundations and companies tend to avoid that (with some exceptions like some music companies (cough, cough, Sony BMG), it's best also to search the web for info about anything you download before you put it on your computer.)

I personally use Webroot's Spyware Sweeper

2. GET A VIRUS SCANNER!

(Same warnings as with the spyware scanner, although the truth is virus scanners often have limited effectiveness once the virus is on your computer (especially since the scanner is usually the first target of the virus). However, the best virus scanners also give you warnings about when you're about to download, open, install or transfer virus-infected items (one of the reasons I like my current sweeper).)

I personally use Eset's Nod32

3. USE THE SCANNERS!

The scanners sometimes have some automatic warnings even without being used, but not scanning is just a waste of good software! And also your computer will get infected, oh yeah, that too. Doesn't matter if you think your safe or you think you have good computer practices, spyware (and to a lesser extent viruses), happen (in fact, if your spyware sweeper is turning up nothing constantly, that probably means that the sweeper is infected).

4. Clear privacy info off your browsers.

Companies, even ones that pledge to do no evil (I have mixed feelings about Google, especially now that a friend works there (shout-out to Jean Hsu!) and especially since I use a lot of google tech which alternately impresses and frustrates me, but that's another session), will attempt to track your web-habits. This is a fact of life. Moreover, sometimes companies (a more rare happening, but sometimes, especially with some of the more unscrupulous background checkers for employment) will go a little further and try to actually connect your real-world identity to what you do on the web and what you have on your computer. It sucks, but that's how the internet is. So go to Tools or Options or whatever, and clear your privacy data, including (actually, although by default this usually isn't selected, it is the most vulnerable area) cookies.

5. Clear out your "temp" and "temporary internet files" folders.

Most of this ought to have been cleaned out by clearing privacy data, but it usually isn't. Finding these folders is a bit tricky for newbies (I've been assuming Windows throughout, especially since most spyware and viruses are designed for Windows, but this particular matter is Windows-specific. I'm a newbie at Linux, and while I'm capable in Mac OS (and actually have a certain preference for it), it has been a while since I've cracked into the nitty-gritty of how to clean Macs (beyond the previous steps)).

Essentially this is what you must do:

First, you need to enable viewing hidden folders:
1. Open "My Computer" from the "Start" menu
2. Go to "Tools" (in the top menu bar)
3. Click on "Folder Options"
4. Click on "View"
5. Find the "Hidden Folders" folder in the scroll bar, click on it to open it, if it isn't opened already.
6. Click on "Show hidden files and folders"
7. Click "Apply" in the bottom right corner
8. Close the the "Folder Options" menu, now you should be able to see all your folders and files

Second, you need to go to the user profiles:
1. Open the "Local Disk (C:)" folder (I'm assuming your still in the "My Computer" window, if not, get back to it)
2. Open "Documents and Settings"

Third, for each of the profile folders, you need to do the temp file cleaning, but here's the essential pattern:
1. Open the profile folder (ie, the folder with the name of one of the profiles on your computer)
2. Open "Local Settings" (you may notice that this folder is semi-faded, that's because usually it's hidden)
3. Open "Temp"
4. Delete all the files in that folder (though do not delete the folder itself, it is a natural part of your computer, however if you mess up and do delete it, the folder should regenerate naturally)

(note sometimes you might not be able to delete some of these temp files, usually it will say file is being used. You should then try closing some applications and trying again, or trying again on a different day, but sometimes there will be files you just can't delete. Sometimes that is just a harmless fact of how your applications work, but often it signals that there are processes that you didn't start in the background which might be problematic)

5. Go back to "Local Settings"
6. Open "Temporary Internet Files"
7. Delete everything in that folder (same warnings as with the "Temp" folder
8. Repeat for each of the profiles

Now deleting these temp files can sometimes free up a huge amount of disk space, but even if it doesn't it makes your computer more secure. However, the files will naturally regenerate with time, so continue to get rid of them.

6. Don't accumulate junk it the first place

I know this was supposed to be top 5 cleaning tips, but here's a bonus tip, practice safe internet! Avoid downloads from sites you don't know or which have suspicious reputations (cough, cough Download.com). Don't accumulate excess software (and if you do, remove some via your control panel's Add/Remove Programs). Do not open emails from people you don't know (even if it says charity this, or job offer that). Do not click on links to sites you don't know or if you're in a suspicious site to start with.

(actually avoid suspicious sites in general, that means you free porn sites (if you must have porn, go to a legitimate porn company with a respectable (relatively) reputation (and no I'm not going to list any of those companies)

(the less reputable ones also have the ugly habit of taking over your browser, if this happens, go to the task manager (Ctrl-Alt-Del) and click on the process that matches your browser (say firefox.exe) and end it (actually this might not in Internet Explorer (I don't usually use it so I haven't tried), since IE is hard-wired into the Windows Operating System (in a rather monopolistic move, which if not illegal, is at least supremely a douche-move)))

(this is where I feel Apple's Safari Browser, despite its easy-of-use and speed, falls short of the Firefox Browser, since Firefox allows you to see where a link leads by just leaving the mouse over the link, whereas Safari (at least, last time I checked it out, which to be truthful was sometime ago, so updates may have changed things), does not. Internet Explorer also has this feature, but IE is so bug-ridden, so security-problematic, so violating-of-all-sensible-web-standards (although IE is getting better in this respect), that I don't even consider it as an alternative in web browser choices. However, Opera Browser is always a reliable second in my book to Firefox, although it is a bit feature-heavy with some unfamiliar-quirks for my taste, but it is a nice browser indeed.)

Anywho, the basic law of preventing junk from cluttering up and undermining the security of your computer is... be cautious and use common sense. There are a lot of tricky and hidden ways to attack a computer, but most malware goes through the front door, so shut it. Or in less-metaphorical terms, if there's some action which seems like it would make your computer vulnerable, DON'T DO IT!

And if you do do it anyways, well, don't blame a certain robotic koala for not warning you.

Cleaning out with Robo-Bobo

Now a little advice from Robo-Bobo: cleaning and maintaining your computer is the route of all madness. So easily can you delete some essential file. So easily can you completely and utterly ruin your perfectly good machine. That said, I periodically like to clean out my machine of all suspicious files and processes to kill any potential viruses and spyware. Why? Because I can.

But I'll admit I do so with care. The biggest guideline for cleaning with care is whenever you have a file or process (if you don't know what I'm talking about what I say process, press Ctrl - Alt - Del to get your task manager up and running and click on the processes tab. Basically this will show you all the stuff, the good, the bad, the necessary, that is running on your computer) you don't recognize DO NOT IMMEDIATELY DELETE IT!!! Just because you don't recognize it doesn't mean it's not supposed to be there, especially since many software vendors, including old Billy Gates's Microsoft, set up new processes and files in new versions.

So how to handle the cleaning then?

Search the web.

The beauty of the internet is that it can harness all the previous frustrations of computer users around the world. You search the web with just the name of the file and process and you should be able to get someone, somewhere, who was also wondering what that item was, and who probably posted that question on an internet forum or asked an expert or something like that, and then got an answer. (although there are some processes and items that still end up being mysterious)

But sometimes it's nice to avoid slogging through tons of forum results, and luckily there are a number of organized process and file identification databases, which usually have readable and search-friendly reports. My favorite is The Process Library, which gets high marks for presentation and understandability, however I'll admit it's not the most extensive of the databases out there. I've found Neuber Software has perhaps a broader selection of information, however, you're best off going directly to its Window Processes Index, since navigating between its product-centric main-pages is a bit unwieldy.

But sometimes you're going to have to search.

And sometimes you're going to have to call Dell, or HP, or some other company that you notice comes up a lot in the unanswered questions about a process or item and demand they explain what this process does (and be forewarned they will resist telling you and likely will try to get you to purchase their expensive customer-care packages).

But as I said before, cleaning a computer is the way of all madness, doing it with care does not change that fact.

Yet, fear of viruses, malware, spyware, and other unpleasantries, combined with an almost compulsive cheapness, compels some, like a certain robotic koala bear you know, to press onward nonetheless. And to those brave and foolhardy individuals, I have but two words:

Good Hunting.

Friday, July 11, 2008

We're all quadratics too

So let's do it as they do it in the quadratic formula.

Behold:

x = (-b +/-b2 - 4ac)/(2a)



Now Mathimoto's Complaint aims to cover a wide range of fans of math and today I'd like to reach out to the younger crowd. That precious younger crowd undoubtedly have seen the beauty of the quadric equation. But they and probably some older folks as well have never given an effort at deriving it. Well, I thought I'd give it a shot and show you the awesomeness of figuring out these formulas. Because Math rocks, it really does.

First start out with the generalized form of a basic quadratic equation (ie any equation with 1 variable (let's say x) and some instance of that variable raised to power 2 and possibly some instance of that variable raised to power 1. Okay, so it was harder to describe things rather than write it out, so let's do that)

Let a, b, and c be constants and x be a variable.

A basic general quadratic equation is:

ax2 + bx + c = 0


Now it helps then to know one particular quadratic equation, that is what happens when you have

(x + b)2 = 0

this can be expanded to

x2 + 2bx + b2 = 0



(Don't believe me, just use the distributive property of multiplication, ie,

(x+b)2 = (x + b)(x + b) =

x (x + b) + b (x + b) = x2 + bx + bx + b2 =

x2 + 2bx + b2

Ta-da)

Okay, now if you got a quadratic equation of the form

x2 + 2bx + b2 = 0


And you know

(x + b)2 = x2 + 2bx + b2

You can then say

(x + b)2 = 0

and with an equation like that, the only time you have a number that can match the value of x (and still give you 0, ie, the solution of the equation) is

x = -b


Back to the general basic quadratic equation:

ax2 + bx + c = 0


At this point we don't know how to find the solution value of x here, but since we know the solution for

(x + b)2

we can reconfigure our general equation to fit our particular equation. Just follow along.

If

ax2 + bx + c = 0

then we can play around with this, our goal equation doesn't have a c, so let's just subtract it from both sides.

ax2 + bx = -c

Well, our target equation doesn't have an &lsquot;a&rsquot; so let's get rid of the a by dividing it from both sides.

x2 + bx/a = -c/a

Okay let's remember our target equation (or the essentials of it)

(x + b)2 = x2 + 2bx + b2

now let's make a little pretending. Let's say instead that the b in our target equation is really say some other letter, say d. Then:

(x + d)2 = x2 + 2dx + d2

And if the current state of our manipulation of the general equation is:

x2 + bx/a = -c/a

we can get to our target a little easier if we say that

d = b/2a

alright now let's take it up a notch by throwing in the new d, then we get

x2 + 2dx = -c/a

well now all we need is the d2 and we can just add that to both sides, so:

x2 + 2dx + d2= -c/a + d2

Well, we can use our old target equation:

(x + d)2 = x2 + 2dx + d2

to simplify this:

(x + d)2= -c/a + d2

Now remember, with a situation like this, the name of the game is find the x, and currently our x is trapped in a term that's raised to a power, so let's get rid of that with a little friend called the square root (but remember that with real square roots you have a positive root and a negative root, since the negative goes away from the squaring).

x + d = +/-d2 - c/a

Now, now, now, we can FIND THE X (by subtracting d from each side)

x = -d +/-d2 - c/a

now just one more step to define the x in the a, b, c constants we started out with, just reverse the d insertion with our

d = b/2a

and we can get...

x = -b/2a +/-(b/2a)2 - c/a

so there we go, we've found the x, but it's kind of ugly so let's simplify things a little by doing some expansion and some common denominator and essentially simple algebra which I'm going to skim over a little:

x = (-b +/-b2 - 4ac)/(2a)



And there we go, we've got the quadratic formula! Yaaaah!!!! Behold it and be amazed!!!

x = (-b +/-b2 - 4ac)/(2a)



MATH RULES!!!! WOOOOO!!!!

Wednesday, July 9, 2008

Mathimoto's Revamp

As things have suggested Mathimoto is still doing changes of many types. First I have added good old Robo-Bobo as my partner, and now I'm doing some redesign of the layout and such. So prepare yourself, for awesomeness, brought forth through the power of MATH!!!

Monday, July 7, 2008

Welcome now to the Robo-Bobo report

As said before, due to Mathimoto's insane busy-ness. I'm adding my two cents to things around here.

And as a robotic-kola bear, it's about time for me to get some talking time. Of course I'll make sure not to overstep on Mathimoto's property, but Robo-Bobo's in the house now and he's about to add a little razz-ma-tazz.

But first of all, as things go, since this is Mathimoto's Complaint, I'd like to add my own complaint.

How come we're using XML for everything nowadays. Now I'm not saying XML isn't great, I actually like it a lot. I'm not so crazy about XSL, but I think ideally you could use XSLT to turn XML to HTML and then pop in some CSS to cap things off (now XSL and XSLT might do things alone, but for real formatting you'd have to throw in XFO or whatever and that's just annoying and Robo-Bobo don't do annoying).

XML's a beautiful concept for data-display and manipulation, basically you mark-up everything with the category or purpose it has, and then you use different transformation and formatting technologies to set things up into a full display, but since the transformation and formatting are separate from the data you can write data down and then decide all that, or you can take data and use several different ways to display things.

However, at the core of it all, XML's a data mark-up language and all the technologies associated with it are data display tech.s. Even if you throw in scripting languages like PHP or Javascript you still have essentially a matter of data display, and currently that's all the web is set up for.

The data display could be dynamic or static, but data display is what the internet was designed for.

And that's not enough.

Because already we have word-processors, games, and all sorts of applications that are used on the web. However, since things are used to data-displays, all the applications must be bastardized into dynamic data collection and display sets. Now overall, GUI's can be pigeon-holed into data-displays (in fact, GUI's are essentially data-collection and displays, and especially if you added a few more features, basically all GUI's come easily be easily created through a XML/XSL/XSLT/HTML/CSS-like technology), but applications? Applications in the most abstract sense can be said to be data collection and display, but to really do things like that is really, really, really asinine.

It's time to say no more! I will not make applications in XML!

But of course I will, because honestly, I'm a bit of a moderate with internet-tech (despite my robotic kola-ness), and I have not the yet the skill or prestige to revolutionize the internet world by myself.

But I shouldn't have to!

Applications should be written in an application-manner, and they should exchange data in an application way. Java Server Pages and such are a little better since there we're actually using application tech, and XUL is a step in the right direction, but it is not enough!

There must be a revolution!

We must!

We must!

We must revolutionize the internet by making it application-friendly!

To me, nerds of Silicon-valley!

To me, Indian sweat-shop engineers!

To me, other people who do other stuff!

Come, let's change the internet, under the grand banner of...

ROBO-BOBO!!!

And so on...

Thursday, July 3, 2008

lots of change = good, net-wise at least

So good old Mathimoto has been going through some changes, and with these changes has come much busy-ness, but do not fret! The math continues, and indeed will improve...

For example, soon this blog will utilize the very useful technology of math markup languages. Which exactly, I'm not sure at the moment, but it will be done! And then you'll have nice little graphics here with all the equations and such.

But perhaps most dramatically, joining the crew will be segments by Mathimoto's good friend, a robot-man whose name escapes me at the moment (if he was a kill-bot I would be much scared by this development but fortunately he is not).

Now this blog was initially envisioned as a math blog above and beyond CS, but this is also a blog on the internet so it is natural that CS developments be of some concern. Yet do not fear, the math will not be enveloped, and to protect the math, Mathimoto's posts and his robot friend's will be kept separate. The math will go on!

Because Math rules!

Wednesday, June 11, 2008

Because Math rocks... and Raps

Now ever since Pythagoras, and indeed even before, math and music have been intimately linked. Yet in modern times we seem to have forgotten that. Well, here are some rappers bringing back the math... old school style.

What You Know About Math (Caution: the video has something like 20 seconds of dead air at the end, still awesome though) by TI-84

Math Rap 2007 by Billy Spivey

Show me a Sine by Franklin Gervacio

Math Rap 2008 by JD Freak Daddy

Calculatin' by Mr. Dobleman's Math Class, 2007 Deer Valley High School

Because Math is just that awesome, rap on!

Friday, June 6, 2008

Mathimoto's Real Complaint

My real complaint is I haven't been able to post more.

Alack, alack, alack. And the real victims are you good folk. But even Mathimoto needs a job, and rest assured once the job situation is stabilized, posts will come once more!!!

But in lack of that, let me give you a little play with number, related by the way, to some secret math speculation I'm doing.

If you want to find if a number is divisible by:

2, check if it's even. (Simple enough)

3, add all the digits and see if the sum is divisible by 3, if it is then the actual number is divisible by 3. (That's one of the cooler tricks)

4, if the last two digits are divisible by 4, then the whole thing is divisible by 4.

9, add the digits, and if the sum is divisible by 9, then the actual number is divisible by 9.

Do you see the suggestion here? Maybe there's a relation between numbers and their base 10-representation. Maybe... and maybe I'm getting close to it... maybe...

But what we do know for sure (to quote my good friend Kendrick), is that numbers are awesome.

NUMBERS RULE!!!!!!!!!
WOOOOO!!!!!!!!

Sunday, June 1, 2008

Let me hear you say math... MATH!!!

A friend of mine once noted that it's a shame that math theory is becoming too complicated for normal people to play with.

But I don't think that it's a necessity, I think mathematicians just accept that this is the way the world must be, and thus refuse to take any effort to simplify mathematical theory.

And perhaps more importantly, new areas in math theory which might be more accessible to amateur innovation aren't being explored as vigorously as they should, largely because mathematicians are starting to forget what math is really about...

Playing with numbers.

Because numbers rock.

In that spirit, look at a list of squares
1
4
9
16
25
...

If you look at the differences between consecutive squares, you'll see a pattern and if you play with that pattern a little, you get...

n^2 = Sum from i=1 to n (2i - 1).

Think about it...

Tuesday, May 27, 2008

Primes, they aren't just for Transformers

It has to be said.
There is just something magical about primes.

I mean they are numbers that represent something basic. Multiplicatively, they can't be broken down and they end up becoming the special cases upon which every mathematical theory must be tried. And yet once you throw them into the world of math theory you get all sorts of weird math facts, that are just undeniably cool.

Like the fact that (p-1)! + 1 is divisible by p, if and only if, p is a prime.

Dude, like awesome.

And yet primes remain mysterious. It was only a few years ago people learned how to test if a number was prime within polynomial time (see here), people still can't prove that there are an infinite number of primes where p and p+2 are prime. And there's the fact that as you go to infinity, the number of primes approaches the function x/ln(x). Zuh?!

I say zuh not because prime numbers are hard to understand, although sometimes they are, but because their wonder and bounty are just mind-boggling.

So let it be understood then, primes are awesome.

And since primes are awesome, math is awesome.

Of course, this is but one of the proofs of math's awesomeness, which are as numerous as prime numbers themselves, and thus proven to be infinite.

Tuesday, April 8, 2008

Tiding over the Tides

So again I must profess myself to be negligent in posting, but as a succor to all my math-starved public, I give you:

Vaguely math related youTube clips.

Because I'm lazy but still love my math.

Here's some funny math problems

Here's Ma and Pa Kettle tackling division

Here's Abbot and Costello showing how it's done right

And here are two songs with math in their titles. They're only about math about the same amount music is about math inherently (which is considerably) and perhaps they're about math in a metaphorical sense, but they're by cool bands so anyways:

The Never-Ending Math Equation by Modest Mouse

Black Math by The White Stripes

Ah, I regret that this is not as much Mathimoto as you deserve, but I must be going, stay strong, math-lovers, stay strong!

Tuesday, March 25, 2008

Even Mathimoto Loves Quotes

Now man can subsist on Math alone, after all is not math the word of God?

(More or less)

But it does not harm things to check out the literate world, especially when it deals with Math. Now while I may have recommended you, my dear readers, to this site before, I'd like to make a second strong recommendation for the site, the site with the might of what's right:

Professor Matthias Beck's Mathematical Quotes Page!!!

And let me share with you a couple of the highlights:

"It is my experience that proofs involving matrices can be shortened by 50% if one throws the matrices out."
E. Artin (Geometric Algebra, p. 14)

"If things are nice there is probably a good reason why they are nice: and if you do not know at least one reason for this good fortune, then you still have work to do."
Richard Askey (Ramanujan and Important Formulas, p. 32, in Srinivasa Ramanujan (1887-1920), a Tribute, K.R. Nagarajan and T. Soundarajan, eds., Madurai Kamaraj University, 1987)

"Quapropter bono christiano, sive mathematici, sive quilibet impie divinantium, maxime dicentes vera, cavendi sunt, ne consortio daemoniorum animam deceptam, pacto quodam societatis irretiant."
("Thus the good christian should beware of mathematicians and all those who make false prophecies, however much they may in fact speak the truth; lest, being in league with the devil, they may deceive errant souls into making common cause.")
Augustinus (De genesis ad literam, Liber 2, Caput XVII, Nr. 37)

"If a 'religion' is defined to be a system of ideas that contains unprovable statements, then Gödel taught us that mathematics is not only a religion, it is the only religion that can prove itself to be one."
John Barrow

"Obvious is the most dangerous word in mathematics."
E. T. Bell

"Mathematics is a collection of cheap tricks and dirty jokes."
Lipman Bers

"We all agree that your theory is crazy, but is it crazy enough?"
Niels Bohr (1885-1962)

"5 out of 4 people have trouble with fractions."
Board in Danby, NY

"There are three kinds of people: those who can count and those who can't."
Bumpersticker on a car in Ithaca, NY

"The essense of mathematics resides in its freedom."
"To ask the right question is harder than to answer it."
G. Cantor

"Alice laughed: 'There's no use trying,' she said; 'one can't believe impossible things.' 'I daresay you haven't had much practice,' said the Queen. 'When I was younger, I always did it for half an hour a day. Why, sometimes I've believed as many as six impossible things before breakfast.' "
"Where shall I begin" he asked. "Begin at the beginning", the king said, "and stop when you get to an end."
L. Carroll (Alice in Wonderland)

"I'm a mathematical optimist: I deal only with positive integers."
"The hardest thing being with a mathematician is that they always have problems."
Tendai Chitewere

"I saw, as one might see the transit of Venus, a quantity passing through infinity and changing its sign from plus to minus. I saw exactly how it happened... but it was after dinner and I let it go."
Winston Churchill (My early life, 1930)

"The mathematical phenomenon always develops out of simple arithmetic, so useful in everyday life, out of numbers, those weapons of the gods: the gods are there, behind the wall, at play with numbers."
Le Corbusier

"A mathematician is a blind man in a dark room looking for a black cat which isn't there."
Charles R. Darwin

"The grand thing is to be able to reason backwards."
Arthur Conan Doyle (A study in scarlet)

"Apu: In fact I can recite pi to 40000 places. The last digit is one!
Homer: Mmmm, pie."

"Homer: This time tomorrow, you'll be wearing high heels!
Ned: Nope, you will.
Homer: 'Fraid not.
Ned: 'Fraid so!
Homer: 'Fraid not.
Ned: 'Fraid so!
Homer: 'Fraid not infinity!
Ned: 'Fraid so infinity plus one!
Homer: D'oh!"

"Internet Guy: Your stock is at zero.
Bart: But I have 52 million shares! What's 52 million times zero?! And don't tell me it's zero!"
"(Homer has disappeared into a wall in the living room.)
Lisa: Well, where's my dad?
Frink: Well, it should be obvious to even the most dimwitted individual who holds an advanced degree in hyperbolic topology, n'gee, that Homer Simpson has stumbled into...[the lights go off] the third dimension.
Lisa: [flips the light switch back] Sorry.
Frink: [drawing on a blackboard] Here is an ordinary square....
Wiggum: Whoa, whoa--slow down, egghead!
Frink: ... but suppose we extend the square beyond the two dimensions of our universe, along the hypothetical z-axis, there.
Everyone: [gasps]
Frink: This forms a three-dimensional object known as a "cube," or a "Frinkahedron" in honor of its discoverer, n'hey, n'hey.
Homer's voice: Help me! Are you helping me, or are you going on and on?
Frink: Oh, right. And, of course, within, we find the doomed individual."
Matt Groening (Be sure to check out Andrew Nestler's Guide to Mathematics and Mathematicians on The Simpsons!)

Sunday, March 23, 2008

Easter!!! Wooo!!!

Sorry for the gap between posts, but I'm going to have to make you wait a little longer. Because it's Easter! Wooo!!!

Tuesday, March 4, 2008

Cause Math don't stop

Now I will admit I have been somewhat negligent about posting. But let that not deter you from seeking the great works of Math yourself. Because even when I slow or stutter, the Math don't stop:

And here's some places to get more math between my most informative posts:

Here's a nice source of Math Quotes with some cool comic excerpts to boot!

Here's a nice little blog from a Math undergrad (although not as nice as this blog):) called Me Or My Maths.

Beautiful thing about math is it transcends languages, so while there's a lot on this site (let's call it Germanio-Math) which I don't understand (including its title), there's still a lot an English-speaking pursuer of math can take from it.

Here's a quite useful site especially reference-wise: Math.com

And if you want to get even more official-ianated with your math, here's the homepage for the American Mathematical Society

They also have a nice run down of Math in the News in their Math Digest

And there's so much more. For math is limitless in its potentials, and while this blog is limitless in its own ways, I hope for the true seeker of math this blog and all these sites are only the beginning.

Sunday, February 24, 2008

That's what I get for all that Scheming

So I know that I have sang the praises of Scheme in several posts now, but let me get to some of the downsides:

First of all, it's insane. No control structures. No local variables. THE MADNESS!!!

But more importantly for me, because it uses exact numbers (ie fractions), the numbers can quickly become to large for the interpreter to handle within reasonable amounts of time. In many cases having exact numbers is ideal for math, but when your using mathematical estimates based on numerical analysis that is iterated many, many times, well, things get ugly.

So I'm putting out this question: Does anyone know of a way to turn off exact numbers in Scheme. I realize that you can just use the function (inexact->exact num), but that only turns it off for one instance, what I'm looking for is a more general purpose off switch.

Because of this difficulty, for some of the more advanced numerical methods I'm handling I'm switching to OpenOffice Spreadsheet. It's not a perfect system, but if properly used the spreadsheet can be a mighty powerful tool of data manipulation.

And I shall also see if I can design functions that get around the inexact/exact difficulty even if it is with the inexact->exact function, because I dream, I dream of the day when once more I can Scheme.

Sunday, February 17, 2008

MC Esher be mathin' out

It's hard exactly to say how MC Escher relates to math. Now certainly MC Escher studied math, and certainly he was inspired by math. But what do the weirdness of his drawings have to do with math?

Well, by all means, the weirdness of his drawings were a matter of creative impulse, but there is a mathematical essence to them. The regularity of his pattern manipulation, the way he defies and distorts perspective, the angles of light bouncing and readjusting. There be math in those hills.

And with that in mind, I direct you The MC Esher Official Website with all sorts of good MC Escher stuff:

http://www.mcescher.com

Go there now... Mathimoto commands it!

Thursday, February 14, 2008

Happy St. Valentine's Day

Ah, St.Valentine's Day, a day of love, a day of romance, a day of... MATH!!!

Since I have spent much energy elsewhere, I cannot explain the full dimensions of St.Valentine's Day mathematical importance, but I can share with you a Valentine's Day treat.

Want to make your sweetie's heart swoon, give here the formula for Cardioids, vaguely heart shaped graphs using polar coordinates!

(just to refresh you, polar coordinates use distance from the origin (the center of the graph) as r, combined with an angle Θ (it's hard to represent it on a computer, but its basically an O with a line in the middle, or sometimes just a cursive-ish O) to form a location for a point)



or if you're feeling more sine-y



(formulas courtesy of Paul's Online Calc. II Notes, which is itself courtesy of and property of Professor Paul Dawkins of Lamar University)

But if you've messed up former Valentine's Day gifts, perhaps you need something a little bit more spectacular, well then I direct you to this fantastic site:

All About Heart Curves! (not it's actual name)

From the mind of Professor Jürgen Köller.

Well, I think that's a heart healthy start to Valentine's Day. But you can't slack off, after all, you still need to give Valentines to people. Just don't forget to give a Valentine to one very special girl, Math!!!

Wednesday, February 13, 2008

Time keeps on Schemin'

So one thing I'm a little bit worried about with this blog is the temptation to turn it into a semi-computer science blog. I want to keep things well rooted in math here, because math is awesome. I mean computer science is cool and all, but math is awesome, and also I think there are more computer science blogs out there than math blogs.

Still, I'm dealing with a lot of numerical analysis stuff now, the line between math and computer science is a little bit blurry. Still, because this blog is mine, I'll walk that line.

And so in the interest of math, I will now reveal to you some really cool Scheme code (just to refresh your memories, I'm using Dr. Scheme, a free Scheme interpreter, and I've been consulting The Scheme Programming Language by R. Kent Dybvig for reference) I wrote to deal with numerical analysis problems. Many people have said that Scheme should not be used for numerical analysis hw, and they are right, but that's why it's ultra-cool when you get it right.

So here's some functions:

General method applier for numerical methods requiring iteration (for generating a list of the value at several different iterations, largely for hw purposes but also so you can look at how it is converging).

(define (applymthd method fun initx tol)
(
map (lambda (iter) (method fun initx tol iter)) '(1 5 10 20 50 100 1000)
)
)

So this obviously is a pretty rough function, but I can tweak it into shape and if I do, I'll pass it along.

Here's a cheeky little function for forward distance:

(define (fordist fun n)
(
(- (fun (+ n 1)) (fun n))
)
)

Here's a less cheeky function for Aiken's terms given a function:

(define (Aitkens fun n)

(- (fun n) (/ (expt (- (fun (+ n 1)) (fun n)) 2) (+ (fun (+ n 2)) (* -2 (fun (+ n 1))) (fun n))))

)

But moving on to more sizable methods, here's an implementation of Steffensen's method:

(define (Steffensens fun initx tol iter)
(if (< iter 1)
initx
(
if

(< (abs (/ (expt (- (fun initx) initx) 2) (+ (fun (fun initx)) (* -2 (fun initx)) initx))) tol)

(- initx (/ (expt (- (fun initx) initx) 2) (+ (fun (fun initx)) (* -2 (fun initx)) initx)))

(Steffensens fun
(- initx (/ (expt (- (fun initx) initx) 2) (+ (fun (fun initx)) (* -2 (fun initx)) initx)))
tol (- iter 1))
)
)
)

More stuff: An implementation of Fixed Point Iteration:

(define (fixedpnt fun initx tol iter)
(if (< iter 1)
initx
(if (< (abs (- (fun initx) initx)) tol)
(fun initx)
(fixedpnt fun (fun initx) tol (- iter 1))
)
)
)

So that's that for now. And I'd say that's a good chunk of stuff, so that's some Scheme, but really, it's all about how to deal with numerical analysis in a quick and painless fashion made slightly more insane by using Scheme instead of any number of more saner tools.

Friday, February 8, 2008

Why plan when you can scheme?

Let me make a pitch for programming in scheme for math purposes.

Why is Scheme good for programming numerical methods and other math brick and brack?

Because it is so gloriously insane!

Scheme is a language without local variables, without control structures, without global constants, it uses reverse-Polish notation (those crazy Poles!) run usually by an interpreter... basically to the layman, let me say that it makes no sense.

But the advantage to Scheme is it fits very well with the idea of constructing logical algorithms and basing your math around that. Scheme strips algorithms down to their basic components, the procedures, and doesn't allow you to go any further than that. There's a ruthlessness to this restriction and enough power in this limited space that you end up being able to do a lot of math stuff simply and in a manner which illuminates the heart of the algorithm.

But it remains insane.

That said here's a good Scheme implementation:

Dr. Scheme

And here's a good guide to the language (note the implementation and this guide are not related, so some aspects of the guide may not work with this implementation):

The Scheme Programming Language by Kent Dybvig

Now I don't want this math blog to go all computer sciency, but it must be admitted that comp. sci. has some math overlap, especially when it comes to doing programming to make math easier. So look out in the future for some bursts of code for math-based functions, most likely in Scheme.

Keep on Scheming!

Thursday, January 31, 2008

Five Def. of Pi's

Ah Pi, that elusive impossible goal. It has driven many to madness (especially the guy in this movie), but many also to great feats.

And so unsurprisingly it has a special place in the hearts of many mathematicians. The 16th century German mathematician Ludoph van Ceulen even had his tombstone engraved with his 32 decimal place estimations of pi.

Ah, Pi!

Fiercely irrational, blissfully transcendent, and so essential to the universe and how it works...

But it's so tricky. Oh course, I know how to write Pi's true form, but instead of revealing that truth to you and thus blowing your minds, I'll just share with you some other def.s of pi, beyond just the ratio of the perimeter of a circle and its diameter (meter! meter!) (all better than the old stand-by 3.14).

1. Good old Archimedes came up with a rough estimate: π is between 223/71 and 22/7

He figured this by drawing a circle, drawing a polygram inside the circle, touching all the sides, and then drawing a polygram outside the circle where the circle touched all of its sides. Then he compared the two polygrams, and by making more and more sides... and this is how you get the rough estimate 22/7 which I used through much of elementary school.

2. Here's one an Indian did write up in the 15th century AD:
and so on... FOREVER!!!


Pretty damn awesome. INFINITE SERIES RULE!!!
Good work Madhava of Sangamagrama! It would take until the 17th century for the series to be rediscovered through the hearty work of James Gregory and Gottfried Leibniz.

3. And if you like your arctangents (and who doesn't?), how about this def. of pi:


Kudos John Machin!

And if you don't like your arctans, well,
and so on, still FOREVER!!!
At least according to a nice little Taylor expansion of arctangent.

4. Well, to take Pi to the next level, another Indian had to get into the game. And so in the early 19th century another Indian did (actually Indians had been working all along, but this 5 def.s not a total history). I'm talking about the one, the only Srinivāsa Rāmānujan!!!
Check out his method for finding Pi, derived from the highest halls of Number Theory:


While that method didn't hit the big time till 1985, in that year William Gosper used it to calculate Pi to 17 million digits. Dude, sweet.

5. But if you want to go a little ways by the abstract route. Well, remember that Euler with some Taylor formulization of e^(ix), sin x and cos x, came up with

which when x = pi leads to a nice little identity involving pi:


Ah, Euler, you may have lived in the 18th century and pronounced your name like a greaser, but you're still one of the best.

So in conclusion let me give you one more def. of pi:

Pi = Awesome

Exactly

Tuesday, January 29, 2008

Archimedes Rules!!! Woo!!!

I'm not a Hellenophile, I have a good taste for the Classics mind you, but I'm not one of those who say the Greeks invented everything. With Math, for example, despite the immense Greek influence (often not done by actual Greeks but by Egyptians or Syrians who spoke Greek), but India, Arabia, and China also had a huge impact on the history of Math. And yet, there is one Greek, who's outstanding enough that I can never get tired of hearing about him.

ARCHIMEDES!!!

So we have a man who created ancient war machines that matched even the Romans for years. Yet despite the mountains of gold that earned him, the war machines were a distraction. His love was Math. Pure Math. And it was there he performed miracles. Mechanics of Floating Objects. Combinatric speculation. Areas of curves and spheres. And the number of grains of sands that it would take to fill up the universe.

He was so high up the math ladder he had to invent his own number system. He dabbled with the basics of integral calculus and said that they weren't rigorous enough for him.

And the man doesn't stop giving. The Archimedes Palimpsest, the best collection of Archimedes writings despite being buried under layers of rewritten parchment, has never been in the best condition, having been mold encrusted, painted over, and scraped apart. Yet with a little patience, a little hard work, and some ultra-fancy X-rays, the Palimpsest is still giving up new texts by, about, or unrelated to Archimedes. As late as April 2007, a new commentary about Archimedes was discovered.

Check out more info about the Archimedes Palimpsest.

Mathimoto Speaks!!!

I, John Thomas, on behalf of Mathimoto, man of math, air his complaint: People do not know enough about math!!!

And thus, I have been commanded to share with the people the world of math!!!

So stay tuned for:

Math History
Mini-math Lessons
Cool Math Facts
Math News

And MATH ULTRA-AWESOMENESS!!!

Math rules!!!