<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Good Math, Bad Math</title>
	<atom:link href="http://scientopia.org/blogs/goodmath/feed/" rel="self" type="application/rss+xml" />
	<link>http://scientopia.org/blogs/goodmath</link>
	<description>Just another Scientopia Blogs site</description>
	<lastBuildDate>Sun, 12 May 2013 23:33:18 +0000</lastBuildDate>
	<language>en-US</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.5.1</generator>
		<item>
		<title>Probability and Interpretations</title>
		<link>http://scientopia.org/blogs/goodmath/2013/05/12/probability-and-interpretations/</link>
		<comments>http://scientopia.org/blogs/goodmath/2013/05/12/probability-and-interpretations/#comments</comments>
		<pubDate>Sun, 12 May 2013 23:33:18 +0000</pubDate>
		<dc:creator>MarkCC</dc:creator>
				<category><![CDATA[probability]]></category>

		<guid isPermaLink="false">http://scientopia.org/blogs/goodmath/?p=2180</guid>
		<description><![CDATA[I'm going to do some writing about discrete probability theory. Probability is an extremely important area of math. We encounter aspects of it every day. It's also a very poorly understood area - it's one that we see abused or just fouled up every day. I'm going to focus on discrete probability theory. What that [...]]]></description>
				<content:encoded><![CDATA[<p> I'm going to do some writing about discrete probability theory.  Probability is an extremely important area of math. We encounter aspects of it every day. It's also a very poorly understood area - it's one that we see abused or just fouled up every day.</p>
<p> I'm going to focus on discrete probability theory. What that means is that we're going to look at things where the space containing the things that we're going to look at contains a countable number of elements. The probability of getting a certain sequence of coin flips, or of getting a certain hand of cards are described by discrete probability theory. On the other hand, the odds of a radioactive isotope decaying at a particular time requires continuous probability theory.</p>
<p> Before getting into the details, there's one important thing to mention. When you're talking about probability, there are two fundamental schools of interpretetation. There are frequentist interpretations, and there are Bayesian interpretations.</p>
<p> In a frequentist interpretation, when you say <em>the probability of an event is 0.6</em>, what you mean is that if you were to perform a series of experiments precisely reproducing the event,  then on average, if you did 100 experiments, the event would occur 60 times. In the frequentist interpretation, the probability is an intrinsic property of the event. For a frequentist, it makes sense to say that there is a "real" probability associated with an event.</p>
<p> In a Bayesian interpretation, when you say that the probability of an event is 0.6, what you mean is that based on your current state of knowledge about the event, you have a 60% certainty that the event will occur. In a strict Bayesian interpretation, the event doesn't have any kind of intrinsic probability associated with it. The specific event that you're interested in either will occur, or it won't. There's no real probability involved. What probability measures is how certain you are about whether or not it will occur.</p>
<p> For example, think about flipping a fair coin.</p>
<p> A frequentist would say that you can flip a coin many times, and half of the time, it will land on heads. So the probability of a coin flip landing on the head of the coin is 0.5. A Bayesian would say that the coin will land either on heads or on tails. Since you don't know which, and you have no other information to use to be able to make a better prediction, you can have a certainty of 0.5 that it will land on the head of the coin.</p>
<p> In the real world, I think that most people are really somewhere in between. </p>
<p> I think that all but the most fervent Bayesians do rely on an intuitive notion of the "intrinsic" probability of an event. They may describe it in different terms, but when it comes down to it, they're using the basic frequentist notion. And I don't think that you can find a sane frequentist anywhere who won't use Bayes theorem to update their priors in the face of new information - which is the most fundamental notion in the Bayesian interpretation.</p>
<p> One note before I finish this, and get started on the real meaty posts. In the past, when I've talked about probability, people have started stupid flamewars in the comments. People get downright religious about interpretations of probability. There are religious Bayesians, who think that all frequentists are stupid idiots who should be banished from the field of math; likewise, there are religious frequentists who think that Bayesians are all a crop of arrogant know-it-alls who should be sent to Siberia. I am <em>not</em> going to tolerate any of that nonsense. If you feel that you cannot read posts on probability without going into a diatribe about those stupid frequentists/Bayesians and their deliberately stupid ideas, please go away and don't even read these posts. If you do go into such a diatribe, I will delete your comments without any hesitation.</p>
<p><a class="a2a_dd a2a_target addtoany_share_save" href="http://www.addtoany.com/share_save#url=http%3A%2F%2Fscientopia.org%2Fblogs%2Fgoodmath%2F2013%2F05%2F12%2Fprobability-and-interpretations%2F&amp;title=Probability%20and%20Interpretations" id="wpa2a_2"><img src="http://scientopia.org/blogs/goodmath/wp-content/plugins/add-to-any/share_save_171_16.png" width="171" height="16" alt="Share"/></a></p>]]></content:encoded>
			<wfw:commentRss>http://scientopia.org/blogs/goodmath/2013/05/12/probability-and-interpretations/feed/</wfw:commentRss>
		<slash:comments>23</slash:comments>
		</item>
		<item>
		<title>Speed-Crankery</title>
		<link>http://scientopia.org/blogs/goodmath/2013/05/05/speed-crankery/</link>
		<comments>http://scientopia.org/blogs/goodmath/2013/05/05/speed-crankery/#comments</comments>
		<pubDate>Sun, 05 May 2013 14:11:28 +0000</pubDate>
		<dc:creator>MarkCC</dc:creator>
				<category><![CDATA[Bad Math]]></category>
		<category><![CDATA[Cantor Crankery]]></category>

		<guid isPermaLink="false">http://scientopia.org/blogs/goodmath/?p=2175</guid>
		<description><![CDATA[A fun game to play with cranks is: how long does it take for the crank to contradict themselves? When you're looking at a good example of crankery, it's full of errors. But for this game, it's not enough to just find an error. What we want is for them to say something so wrong [...]]]></description>
				<content:encoded><![CDATA[<p> A fun game to play with cranks is: how long does it take for the crank to contradict themselves?</p>
<p> When you're looking at a good example of crankery, it's full of errors. But for this game, it's not enough to just find an error. What we want is for them to say something so wrong that one sentence just totally tears them down and demonstrates that what they're doing makes no sense.</p>
<p> "The color of a clear sky is green" is, most of the time, wrong. If a crank makes some kind of argument based on the alleged fact that the color of a clear daytime sky is green, the argument is wrong. But as a statement, it's not nonsensical. It' just wrong. </p>
<p> On th other hand, "The color of a clear sky is steak frite with bernaise sauce and a nice side of roasted asparagus", well... it's not even wrong. It's just nonsense.</p>
<p> Today's crank is a great example of this. If, that is, it's legit. I'm not sure that this guy is serious. I think this might be someone playing games, pretending to be a crank. But even if it is, it's still fun.</p>
<p> About a week ago, I got en mail titled "I am a Cantor crank" from a guy named Chris Cuellar. The contents were:</p>
<blockquote>
<p>...AND I CHALLENGE YOU TO A DUEL!!  En garde!</p>
<p> Haha, ok, not exactly.  But you really seem to be interested in this stuff. And so am I.  But I think I've nailed Cantor for good this time. Not only have I come up with algorithms to count some of these "uncountable" things, but I have also addressed the proofs directly. The diagonalization argument ends up failing spectacularly, and I believe I have a good explanation for why the whole thing ends up being invalid in the first place.</p>
<p> And then I also get to the power set of natural numbers...  I really hope my arguments can be followed.  The thing I have to emphasize is that I am working on a different system that does NOT roll up cardinality and countability into one thing!  As it will turn out, rational numbers are bigger than integers, integers are bigger than natural numbers... but they are ALL countable, nonetheless!</p>
<p> Anyway, I had started a little blog of my own a while ago on these subjects.  The first post is here:</p>
<p>http://laymanmath.blogspot.com/2012/09/the-purpose-and-my-introduction.html</p>
<p> Have fun...  BWAHAHAHA</p>
</blockquote>
<p> So. We've got one paragraph of intro. And then everything crashes and burns in an instant.</p>
<p> "Rational numbers are bigger than integers, integers are bigger than natural numbers, but they are all countable". This is self-evident rubbish. The definition of "countable" say that an infinite set I is countable if, and only if, you can create a one-to-one mapping between the members of I and the natural numbers. The definition of cardinality says that if you can create a one-to-one mapping between two sets, the sets are the same size.</p>
<p> When Mr. Cuellar says that the set of rational numbers is bigger that the set of natural numbers, but that they are still countable... he's saying that there <em>is not</em> a one-to-one mapping between the two sets, but that there <em>is</em> a one-to-one mapping between the two sets. </p>
<p> Look - you don't get to redefine terms, and then pretend that your redefined terms mean the same thing as the original terms.</p>
<p> If you claim to be refuting Cantor's proof that the cardinality of the real numbers is bigger than the cardinality of the natural numbers, then you have to use Cantor's definition of cardinality.</p>
<p> You <em>can</em> change the definition of the size of a set - or, more precisely, you can propose an alternative metric for how to compare the sizes of sets. But any conclusions that you draw about your new metric are conclusions about your new metric - they're not conclusions about Cantor's cardinality. You can define a new notion of set size in which all infinite sets are the same size. It's entirely possible to do that, and to do that in a consistent way. But it will say nothing about Cantor's cardinality. Cantor's proof will still work.</p>
<p> What my correspondant is doing is, basically, what I did above in saying that the color of the sky is steak frites. I'm using terms in a completely inconsistent meaningless way.  Steak frites with bernaise sauce isn't a color. And what Mr. Cuellar does is similar: he's using the word "cardinality", but whatever he means by it, it's <em>not</em> what Cantor meant, and it's not what Cantor's proof meant. You can draw whatever conclusions you want from your new definition, but it has no bearing on whether or not Cantor is correct. I don't even need to visit his site: he's demonstrated, in record time, that he has no idea what he's doing.</p>
<p><a class="a2a_dd a2a_target addtoany_share_save" href="http://www.addtoany.com/share_save#url=http%3A%2F%2Fscientopia.org%2Fblogs%2Fgoodmath%2F2013%2F05%2F05%2Fspeed-crankery%2F&amp;title=Speed-Crankery" id="wpa2a_4"><img src="http://scientopia.org/blogs/goodmath/wp-content/plugins/add-to-any/share_save_171_16.png" width="171" height="16" alt="Share"/></a></p>]]></content:encoded>
			<wfw:commentRss>http://scientopia.org/blogs/goodmath/2013/05/05/speed-crankery/feed/</wfw:commentRss>
		<slash:comments>5</slash:comments>
		</item>
		<item>
		<title>The Gravitational Force of Rubbish</title>
		<link>http://scientopia.org/blogs/goodmath/2013/05/01/the-gravitational-force-of-rubbish/</link>
		<comments>http://scientopia.org/blogs/goodmath/2013/05/01/the-gravitational-force-of-rubbish/#comments</comments>
		<pubDate>Thu, 02 May 2013 01:10:38 +0000</pubDate>
		<dc:creator>MarkCC</dc:creator>
				<category><![CDATA[Bad Math]]></category>
		<category><![CDATA[Bad Physics]]></category>
		<category><![CDATA[crackpottery]]></category>
		<category><![CDATA[gravity]]></category>

		<guid isPermaLink="false">http://scientopia.org/blogs/goodmath/?p=2171</guid>
		<description><![CDATA[Imagine, for just a moment, that you were one a group of scientists that had proven the most important, the most profound, the most utterly amazing scientific discovery of all time. Where would you publish it? Maybe Nature? Science? Or maybe you'd prefer to go open-access, and go with PLOS ONE? Or more mainstream, and [...]]]></description>
				<content:encoded><![CDATA[<p> Imagine, for just a moment, that you were one a group of scientists that had proven the most important, the most profound, the most utterly amazing scientific discovery of all time. Where would you publish it?</p>
<p> Maybe Nature? Science? Or maybe you'd prefer to go open-access, and go with PLOS ONE? Or more mainstream, and send a press release to the NYT?</p>
<p> Well, in the case of today's crackpots, they bypassed all of those boring journals. They couldn't be bothered with a pompous rag like the Times. No, they went for the really <em>serious</em> press: <a href="http://www.americanownews.com/story/21351668/new-theory-challenges-existing-beliefs-about-gravity-positioning-solar-winds-as-the-force-that-moves-planets-governs-atomic-movement-and-creates">America Now with Leeza Gibbons</a>.</p>
<p> What did they go to this amazing media outlet to announce? The most amazing scientific discovery of all time: gravity is an illusion! There's no gravity. In fact, not just is there no gravity, but all of that quantum physics stuff? It's utter rubbish. You don't need any of that complicated stuff! No - you need only one thing: the solar wind.</p>
<blockquote>
<p> A new theory on the forces that control planetary orbit refutes the 400-year old assumptions currently held by the scientific community. Scientific and engineering experts Gerhard and Kevin Neumaier have established a relationship between solar winds and a quantized order in both the position and velocity of the solar system's planets, and movement at an atomic level, with both governed by the same set of physics.</p>
<p>The observations made bring into question the Big Bang Theory, the concept of black holes, gravitational waves and gravitons. The Neumaiers' paper, More Than Gravity, is available for review at MoreThanGravity.com</p>
</blockquote>
<p> Pretty damned impressive, huh? So let's follow their instructions, and go over to their <a href="http://morethangravity.com/wp-content/uploads/2013/02/More-Than-Gravity-Theory.pdf">website</a>.</p>
<blockquote>
<p> Ever since humankind discovered that the Earth and the planets revolved around the Sun, there was a question about what force was responsible for this. Since the days of Newton, science has held onto the  notion that an invisible force, which we have never been able to detect, controls planetary motion. There are complicated theories about black holes that have never been seen, densities of planets that have never been measured, and subatomic particles that have never been detected.
</p>
<p> However, it is simpler than all of that and right in front of us. The Sun and the solar wind are the most powerful forces in our solar system. They are physically moving the planets. In fact, the solar wind spins outward in a spiral at over a million miles per hour that controls the velocity and distances that planets revolve around the Sun. The Sun via the solar wind quantizes the orbits of the planets – their position and speed.</p>
<p> The solar wind also leads to the natural log and other phenomenon from the very large scale down to the atomic level. This is clearly a different idea than the current view that has been held for over 400 years. We have been working on this for close 50 years and thanks to satellite explorations of space have data that just was not available when theories long ago were developed. We think that we have many of the pieces but there are certainly many more to be found. We set this up as a web site, rather as some authoritative book so that there would be plenty of opportunity for dialog. The name for this web site, www.MorethanGravity.com was chosen because we believe there is far more to this subject than is commonly understood. Whether you are a scientific expert in your field or just have a general interest in how our solar system works, we appreciate your comments.
</p></blockquote>
<p> See, it's all about the solar wind. There's no such thing as gravity - that's just nonsense. The sun produces the solar wind, which does absolutely everything. The wind comes out of the sun, and <em>spirals</em> out from the sun. That spiral motion has eddies in it an quantized intervals, and that's where the planets are. Amazing, huh?</p>
<p> Remember my mantra: the worst math is no math. This is a beautiful demonstration<br />
of that.</p>
<p> Of course... why does the solar wind move in a spiral? Everything we know says that in the absence of a force, things move in a straight line. It can't be spiraling because of gravity, because there is no gravity. So why does it spiral? Our brilliant authors don't bother to say. What makes it spiral, instead of just move straight? Mathematically, spiral motion is very complicated. It requires a centripetal force which is smaller than the force that would produce an orbit. Where's that force in this framework? There isn't any. They just say that that's how the solar wind works, period. There are many possible spirals, with different radial velocities - which one does the solar wind follow according to this, and why? Again, no answer from the authors. </p>
<p> Or... why is the sun producing the solar wind at all? According to those old, stupid theories that this work of brilliance supercedes, the sun produces a solar wind because it's fusing hydrogen atoms into helium. That's happening because gravity is causing the atoms of the sun to be compressed together until they fuse. Without gravity, why is fusion happening at all? And given that it's happening, why does the sun not just explode into a supernova? We know, from direct observation, that the energy produced by fusion creates an outward force. But gravity can't be holding the sun together - so why is the sun there at all? Still, no answers.</p>
<p> They do, eventually, do some math. One of the big "results" of this hypothesis is about the "quantization" of the orbits of planets around the sun. They were able to develop a simple equation which predicts the locations where planets could exist in their "solar wind" system.</p>
<blockquote>
<p> Let’s start with the distance between the planets and the Sun. We guessed that if the solar system was like an atom, that planetary distance would be quantized. This is to say that we thought that the planets would have definite positions and that they would be either in the position or it would be empty. In a mathematical sense, this would be represented by a numerical integer ordering (0,1,2,3,…). If the first planet, Mercury was in the 0 orbital, how would the rest of the planets line up? Amazingly well we found.</p>
<p> If we predict the distance from the surface of the Sun to each planet in this quantized approach, the  results are astounding. If D equals the mean distance to the surface of the Sun, and d0 as the distance to Mercury, we can describe the relationship that orders the planets mathematically as:</p>
<p><p style='text-align:center;'><span class='MathJax_Preview'><img src='http://scientopia.org/blogs/goodmath/wp-content/plugins/latex/cache/tex_89c5f7e207a946e23b2096a4165d85e9.gif' style='' class='tex' alt=" D=d_0 S^n" /></span></p></p>
<p> Each planetary position can be predicted from this equation in a simple calculation as we increase the integer (or planet number) n. S is the solar factor, which equals 1.387. The solar factor is found in the differential rotation of the Sun and the profile of the solar wind which we will discuss later.</p>
<p> Similar to the quantized orbits that exist within an atom, the planetary bodies are either there or not. Mercury is in the zero orbital. The next orbital is missing a planet. The second, third, and fourth orbitals are occupied by Venus, Earth, and Mars respectively. The fifth orbital is missing. The sixth orbital is filled with Ceres. Ceres is described as either the largest of all asteroids or a minor planet (with a diameter a little less than half that of Pluto), depending on who describes it. Ceres was discovered in 1801 as astronomers searched for the missing planets that the Titius-Bode Law predicted would exist.</p>
</blockquote>
<p> So. What they found was an exponential equation which products very approximate versions of the size of first 8 planets' orbits, as well as a couple of missing ones.
</p>
<p> This is, in its way, interesting. Not because they found anything, but rather because they <em>think</em> that this is somehow profound. </p>
<p> We've got 8 data points (or 9, counting the asteroid belt). More precisely, we have 9 <em>ranges</em>, because all of the orbits are elliptical,but the authors of this junk are producing a single number for the size of the orbits, and they can declare success if their number falls anywherewithin the range from perihelion to aphelion in each of the orbits.</p>
<p> It would be <em>shocking</em> if there <em>weren't</em> any number of simple equations that described <em>exactly</em> the 9 data points of the planet's orbits. </p>
<p> But they couldn't even make that work directly. They only manage to get a partial hit - getting an equation that hits the right points, but which also generates a bunch of misses. There's nothing remotely impressive about that.</p>
<p> From there, they move on to the strawmen. For example, they claim that their "solar wind" hypothesis explains why the planets all orbit in the same  direction on the same plane. According to them, if orbits were really gravitational, then planets would orbit in random directions on random planes around the sun. But their theory is better than gravity, because it says why the planets are in the same plane, and why they're all orbiting in the same direction.</p>
<p> The thing is, this is a really stupid argument. Why are the planets in the same plane, orbiting in the same direction? Because the solar system was formed out of a rotating gas cloud. There's a really good, solid, well-supported explanation of why the planets exist, and why they orbit the sun the way they do. Gravity doesn't explain <em>all</em> of it, but gravity is a key piece of it.</p>
<p> What they don't seem to understand is how amazingly powerful the theory of gravity is as a predictive tool. We've sent probes to the outer edges of the solar system. To do that, we didn't just aim a rocket towards Jupiter and fire it off. We've done things like the Cassini probe, where we launched a rocket towards Venus. It used the gravitational field of Venus twice to accelerate it with a double-slingshot maneuver, and send it back towards earth, using the earth's gravity to slingshot it again, to give it the speed it needed to get to Jupiter.</p>
<p> This wasn't a simple thing to do. It required an extremely deep understanding of gravity, with extremely accurate predictions of exactly how gravity behaves.</p>
<p> How do our brilliant authors answer this? By handwaving. The extend of their response is:</p>
<blockquote><p>
Gravitational theory works for things like space travel because it empirically measures the force of a planet, rather than predicting it.
</p></blockquote>
<p> That's a <em>pathetic</em> handwave, and it's not even close to true. The gravitational slingshot is a perfect answer to it. A slingshot doesn't just use some "empirically measured" force of a planet. It's a very precise prediction of what the forces will be at different distances, how that force will vary, and what effects that force will have. </p>
<p> They do a whole lot more handwaving of very much the same order. Pure rubbish.</p>
<p><a class="a2a_dd a2a_target addtoany_share_save" href="http://www.addtoany.com/share_save#url=http%3A%2F%2Fscientopia.org%2Fblogs%2Fgoodmath%2F2013%2F05%2F01%2Fthe-gravitational-force-of-rubbish%2F&amp;title=The%20Gravitational%20Force%20of%20Rubbish" id="wpa2a_6"><img src="http://scientopia.org/blogs/goodmath/wp-content/plugins/add-to-any/share_save_171_16.png" width="171" height="16" alt="Share"/></a></p>]]></content:encoded>
			<wfw:commentRss>http://scientopia.org/blogs/goodmath/2013/05/01/the-gravitational-force-of-rubbish/feed/</wfw:commentRss>
		<slash:comments>18</slash:comments>
		</item>
		<item>
		<title>What the heck is a DNS amplification DoS attack?</title>
		<link>http://scientopia.org/blogs/goodmath/2013/04/08/what-the-heck-is-a-dns-amplification-dos-attack/</link>
		<comments>http://scientopia.org/blogs/goodmath/2013/04/08/what-the-heck-is-a-dns-amplification-dos-attack/#comments</comments>
		<pubDate>Mon, 08 Apr 2013 15:37:24 +0000</pubDate>
		<dc:creator>MarkCC</dc:creator>
				<category><![CDATA[Basics]]></category>
		<category><![CDATA[woo]]></category>
		<category><![CDATA[amplification]]></category>
		<category><![CDATA[ddos]]></category>
		<category><![CDATA[dos]]></category>
		<category><![CDATA[internet]]></category>
		<category><![CDATA[software]]></category>

		<guid isPermaLink="false">http://scientopia.org/blogs/goodmath/?p=2164</guid>
		<description><![CDATA[A couple of weeks ago, there was a bunch of news about a major DOS attack on Spamhaus. Spamhaus is an online service that maintains a blacklist of mail servers that are known for propagating spam. I've been getting questions about what a DoS attack is, and more specifically what a "DNS amplification attack" (the [...]]]></description>
				<content:encoded><![CDATA[<p> A couple of weeks ago, there was a bunch of news about a major DOS attack on Spamhaus. Spamhaus is an online service that maintains a blacklist of mail servers that are known for propagating spam.  I've been getting questions about what a DoS attack is, and more specifically what a "DNS amplification attack" (the specific attack at the heart of last week's news) is. This all became a bit more relevant to me last week, because some asshole who was offended by my post about the Adria Richards affair launched a smallish DoS attack against scientopia. (This is why we were interrmitently very slow last week, between tuesday and thursday. Also, to be clear, the DNS amplification attack was used on Spamhaus. Scientopia was hit by a good old fashioned DDoS attack.)</p>
<p> So what is a DoS attack? And what specifically is a DNS amplification attack?</p>
<p> Suppose that you're a nastly person who wants to take down a website like scientopia.  How could you do it? You could hack in to the server, and delete everything. That would kill it pretty effectively, right?</p>
<p> It certainly would. But from the viewpoint of an attacker, that's not a particularly easy thing to do. You'd need to get access to a privileged account on our server. Even if we're completely up to date on patches and security fixes, it's probably <em>possible</em> to do that, but it's still probably going to be a lot of work. Even for a dinky site like scientopia, getting that kind of access probably isn't trivial. For a big security-focused site like spamhaus, that's likely to be close to impossible: there are layers of security that you'd need to get through, and there are people constantly watching for attacks.  Even if you got through, if the site has reliable backups, it won't be down for long, and once they get back up, they'll patch whatever hole you used to get in, so you'd be back to square one. It's a lot of work, and there are much easier ways to take down a site. </p>
<p> What you, as an attacker, want is a way to take the site down <em>without</em> having any kind of access to the system. You want a way that keeps the site down for as long as you want it down. And you want a way that doesn't leave easily traced connections to you.</p>
<p> That's where the DoS attack comes in. DoS stands for "denial of service". The idea of a DoS attack is to take a site down without really taking it down. You don't actually kill the server; you just make it impossible for legitimate users to access it. If the sites users can't access the site even though the server is technically still up and running, you've still effectively killed it.</p>
<p> How do you do that? You overwhelm the server. You target some finite resource on the server, and force it to use up that resource just dealing with requests or traffic that you sent to the server, leaving it with nothing for its legitimate users.</p>
<p> In terms of the internet, the two resources that people typically target are CPU and network bandwidth.</p>
<p> Every time that you send a request to a webserver, the server has to do some computation to process that request. The server has a finite amount of computational capability. If you can hit it with enough requests that it spends all of its time processing your requests, then the site becomes unusable, and it effectively goes down.  This is the simplest kind of DoS attack. It's generally done in a form called a DDoS - <em>distributed</em> denial of server attack, where the attacker users thousands or millions of virus-infected computers to send requests. The server gets hit by a vast storm of requests, and it can't distinguish the legitimate requests from the ones generated by the attacker. This is the kind of attack that hit Scientopia last week. We were getting streams of a couple of thousands malformed requests per second. </p>
<p> This kind of attack can be very effective. It's hard - not impossible, but hard - to fight. You need to identify the common traits of the attackers, and set up some kind of filter to discard those requests. From the attacker's point of view, it's got one problem: price. Most people don't have a personal collection of virus-infected machines that they can use to mount an attack. What they actually do is rent machines! Virus authors run services where they'll use the machines that they've to run an attack for you, for a fee. They typically charge per machine-hour. So to keep a good attack going for a long time is expensive! Another problem with this kind of attack is that the amount of traffic that you can inflict on the server per attacker is also used by the client. The client needs to establish a connection to the server. That consumes CPU, network connections, and bandwidth on the client.  </p>
<p> The other main DoS vector is network bandwidth.  Every server running a website is connected to the network by a connection with a fixed capacity, called it's bandwidth. A network connection can only carry a certain quantity of information. People love to make fun of the congressman who said that the internet is like a series of tubes, but that's not really a bad analogy. Any given connection is a lot like a pipe. You can only cram so much information through that pipe in a given period of time.  If you can send enough traffic to completely fill that pipe, then the computer on the other end is, effectively, off the network. It can't receive any requests. </p>
<p> For a big site like spamhaus, it's very hard to get enough machines attacking to effectively kill the site. The amount of bandwidth, and the number of different network paths connecting spamhaus to the internet is huge! The number of infected machines available for an attack is limited, and the cost of using all of them is prohibitive.</p>
<p> What an attacker would like for killing something like Spamhaus is an attack where the amount of work/cpu/traffic used to generate the attack is much smaller than the amount of work/cpu/traffic used by the server to combat the attack. That's where <em>amplification</em> comes in. You want to find some way of using a small amount of work/traffic on your attacker machines to cause your target to lost a large amount of work/traffic.</p>
<p> In this recent attack on Spamhaus, they used an amplification attack, that was based on a basic internet infrastructure service called the Domain Name Service (DNS). DNS is the service which is used to convert between the name of a server (like scientopia.org), and its numeric internet address (184.106.221.182). DNS has some technical properties that make it idea for this kind of attack:</p>
<ol>
<li> It's not a connection-based service. In most internet services, you establish a connection to a server, and send a request on that connection. The server responds on the same connection.  In a connection-based service, that means two things. First, you need to use just as much bandwidth as the target, because if you drop the connection, the server sees the disconnect and stops processing your request. Second, the server knows who it's connected to, and it always sends the results of a request to the client that requested it. But DNS doesn't work that way. In DNS, you send a request without a connection, and in the request, you provide an address that the response should be sent to. So you can <em>fake</em> a DNS request, by putting someone else's address as the "respond-to" address in the request.</li>
<li> It's possible to set up DNS to create very large responses to very small requests. There are lots of ways to do this. The important thing is that it's really easy to use DNS in a way that allows you to amplify the amount of data being sent to a server by a factor of 100. In one common form of DNS amplification, you send 60 byte requests, which generate responses larger than 6,000 bytes.</li>
</ol>
<p> Put these two properties together, and you get a great attack vector: you can send tiny, cheap requests to a server, which don't cause <em>any</em> incoming traffic on your attacker machine, and which send large quantities of data to your target. Doing this is called a DNS amplification attack: it's an amplification attack which uses properties of DNS to generate large quantities of data send to your server, using small quantities of data sent by your attackers.</p>
<p> That's exactly what happened to Spamhaus last week. The attackers used a very common DNS extension, which allowed them to amplify 60 byte requests into 4,000 byte responses, and to send the responses to the spamhaus servers. </p>
<p> There are, of course, more details. (For example, when direct attacks didn't work, they tried an indirect attack that didn't target the spamhaus servers, but instead tried to attack other servers that spamhaus relied on.) But this is the gist.</p>
<p><a class="a2a_dd a2a_target addtoany_share_save" href="http://www.addtoany.com/share_save#url=http%3A%2F%2Fscientopia.org%2Fblogs%2Fgoodmath%2F2013%2F04%2F08%2Fwhat-the-heck-is-a-dns-amplification-dos-attack%2F&amp;title=What%20the%20heck%20is%20a%20DNS%20amplification%20DoS%20attack%3F" id="wpa2a_8"><img src="http://scientopia.org/blogs/goodmath/wp-content/plugins/add-to-any/share_save_171_16.png" width="171" height="16" alt="Share"/></a></p>]]></content:encoded>
			<wfw:commentRss>http://scientopia.org/blogs/goodmath/2013/04/08/what-the-heck-is-a-dns-amplification-dos-attack/feed/</wfw:commentRss>
		<slash:comments>6</slash:comments>
		</item>
		<item>
		<title>A White Boy&#039;s Observations of Sexism and the Adria Richards Fiasco</title>
		<link>http://scientopia.org/blogs/goodmath/2013/03/28/a-white-boys-observations-of-sexism-and-the-adria-richards-fiasco/</link>
		<comments>http://scientopia.org/blogs/goodmath/2013/03/28/a-white-boys-observations-of-sexism-and-the-adria-richards-fiasco/#comments</comments>
		<pubDate>Thu, 28 Mar 2013 16:04:33 +0000</pubDate>
		<dc:creator>MarkCC</dc:creator>
				<category><![CDATA[People]]></category>
		<category><![CDATA[sexism]]></category>

		<guid isPermaLink="false">http://scientopia.org/blogs/goodmath/?p=2156</guid>
		<description><![CDATA[I've been watching the whole Adria Richards fiasco with a sense of horror and disgust. I'm finally going to say something, but for the most part, it's going to be indirect. See, I'm a white guy, born as a member of an upper middle class white family. That means that I'm awfully lucky. I'm part [...]]]></description>
				<content:encoded><![CDATA[<p> I've been watching the whole Adria Richards fiasco with a sense of horror and disgust. I'm finally going to say something, but for the most part, it's going to be indirect.</p>
<p> See, I'm a white guy, born as a member of an upper middle class white family. That means that I'm awfully lucky. I'm part of the group that is, effectively, treated as the normal, default person in most settings. I'm also a guy who's married to a chinese woman, and who's learned a bit about how utterly clueless I am. </p>
<p> Here's the fundamental issue that underlies all of this, and many similar stories: our society is deeply sexist and racist. We are all raised in an environment in which mens voices are more important than womens. It's so deeply ingrained in us that we don't even notice it.</p>
<p> What this means is that we are <em>all</em> to some degree, sexist, and racist. When I point this out, people get angry. We also have learned that sexism is a bad thing. So when I say to someone that you are sexist, it's really easy to interpret that as me saying that you're a bad person: sexism is bad, if I'm sexist, them I'm bad. </p>
<p> But we really can't get away from this reality. We <em>are</em> sexists. For many of us, we're not <em>deliberately</em> sexist, we're not <em>consciously</em> sexist. But we <em>are</em> sexist.</p>
<p> Here's a really interesting experiment to try, if you have the opportunity. Visit an elementary school classroom. First, just watch the teacher interact with the students while they're teaching. Don't try to count interactions. Just watch. See if you think that any group of kids is getting more attention than any other. Most of the time, you probably will get a feeling that they're paying roughly equal attention to the boys and the girls, or to the white students and the black students.  Then, come back on a different day, and <em>count</em> the number of times that they call on boys versus calling on girls. I've done this, after having the idea suggested by a friend. The result was amazing. I really, honestly believed that the teacher was treating her students (the teacher I did this with was a woman) equally. But when I counted?She was calling on boys <em>twice as often</em> as girls.</p>
<p> This isn't an unusual outcome. Do some looking online for studies of classroom gender dynamics, and you'll find lots of structured observations that come to the same conclusion.</p>
<p> My own awakening about these kinds of things came from my time working at IBM. I've told this first story before, but it's really worth repeating.</p>
<p> One year, I managed the summer intership programs for my department. The previous summer, IBM research had wound up with an intership class consisting of 99% men. (That's not an estimate: that's a real number. That year, IBM research hired 198 summer interns, of whom 2 were women.) For a company like IBM, numbers like that are scary. Ignoring all of the social issues of excluding potentially great candidates, numbers like that can open the company up to gender discrimination lawsuits!</p>
<p> So my year, they decided to encourage the hiring of more diverse candidates. The way that they did that was by allocating each department a budget for summer interns. They could only hire up to their budgeted number of interns. Only women and minority candidates didn't count against the budget.</p>
<p> When the summer program hiring opened, my department was allocated a budget of six students. All six slots were gone within the first day. Every single one of them went to a white, american, male student.</p>
<p> The second day, the guy across the hall from me came with a resume for a student he wanted to hire. This was a guy who I really liked, and really respected greatly. He was not, by any reasonable measure, a bad guy - he was a really good person. Anyway, he had this resume, for yet another guy. I told him the budget was gone, but if he could find a good candidate who was either a woman or minority, that we could hire them. He exploded, ranting about how we were being sexist, discriminating against men. He just wanted to hire the best candidate for the job! We were demanding that he couldn't hire the best candidate, he had to hire someone less qualified, in order to satisfy some politically correct bureaucrat! There was nothing I could do, so eventually he stormed out.</p>
<p> Three days later, he came back to my office with another resume. He was practically bouncing off the walls he was so happy. "I found another student to hire. She's even better than the guy I originally came to you with! She's absolutely perfect for the job!". We hired her.</p>
<p> I asked him why he didn't find her before. He had no answer - he didn't know why he didn't find her resume of his first search.</p>
<p> This was a pattern that I observed multiple times that year. Looking through a stack of resumes, without deliberately excluding women, somehow, all of the candidates with female names wound up back in the slushpile. I don't think that anyone was deliberately saying "Hmm, Jane, that's a woman's name, I don't want to hire a woman". But I do think that in the process of looking through a file containing 5000 resumes, trying to select which ones to look at, on an unconscious level, they were more likely to look carefully at a candidate with a male name, because we all learn, from a young age, that men are smarter than women, men are more serious than women, men are better workers than women, men are more likely to be technically skilled than women. Those attitudes may not be part of our conscious thought, but they are part of the cultural background that gets drummed into us by school, by books, by movies, by television, by commercials.</p>
<p> As I said, that was a real awakening for me.</p>
<p> I was talking about this with my next-door office neighbor, who happened to be one of the only two women in my department (about 60 people) at the time. She was shocked that I hadn't noticed this before. So she pointed out to me that in meetings, she could say things, and everyone would ignore it, but if a guy said the same thing, they'd get listened to. We'd been in many meetings together, and I'd never noticed this!</p>
<p> So I started paying attention, and she was absolutely right.</p>
<p> What happened next is my second big awakening.</p>
<p> I started watching this in meetings, and when people brushed over something she'd said, I'd raise my voice and say "X just suggested blah, which I think is a really good idea. What about it?". I wanted to help get her voice listened to.</p>
<p> She was <em>furious</em> at me. This just blew my mind. I was really upset at her at first. Dammit, I was trying to <em>help</em>, and this asshole was yelling at me for it! She'd complained about how people didn't listen to her, and now when I was trying to help get her listened to, she was complaining again!</p>
<p> What I realized after I calmed down and listened to her was that I was wrong. I hadn't spoken to her about doing it. I didn't understand what it meant. But the problem was, people didn't take her seriously because she was a woman. People might listen to me, because I'm also a white guy. But when I spoke <em>for her</em>, I wasn't helping. When a man speaks on behalf of a woman, we're <em>reinforcing</em> the idea that a woman's voice isn't supposed to be heard. I was substituting my man's voice for her woman's, and by doing that, I was not just not helping her, but I was actively <em>hurting</em>, because the social interpretation of my action was that "X can't speak for herself". And more, I learned that by taking offense at her, for pointing out that I had screwed up, I was definitely in the wrong - that I had an instinct for reacting wrong.</p>
<p> What I learned, gradually, from watching things like this, from becoming more sensitive and aware, and by <em>listening</em> to what women said, was that this kind of thing is that I was completely clueless.</p>
<p> The fact is, I constantly benefit from a very strong social preference.  I don't <em>notice</em> that. Unless I'm really trying hard to pay attention, I'm not aware of all of the benefits that I get from that. I don't notice all of the times when I'm getting a benefit. Worse, I don't notice all of the times when my behavior is <em>asserting</em> that social preference as my right.</p>
<p> It's very easy for a member of an empowered majority to just take things for granted. We see the way that we are treated as a default, and assume that <em>everyone</em> is treated the same way. We don't perceive that we are being treated preferentially. We don't notice that the things that offend us are absolutely off limits to everyone, but that things that we do to offend   others are accepted as part of normal behavior. Most importantly, <em>we don't notice when our behavior is harmful to people who aren't part of our empowered group.</em> And when we do offend someone who isn't part of the empowered majority, we take offense at the fact that they're offended. Because they're saying that <em>we did something bad</em>, and we know that we aren't bad people!</p>
<p> The way that this comes back to the whole Adria Richards fiasco is very simple. Many people have looked at what happened at PyCon, and said something like "She shouldn't have tweeted their picture", or "She shouldn't have been offended, they didn't do anything wrong", or "She should have just politely spoken to them".</p>
<p> I don't know whether what she did was right or not. I wasn't there. I didn't hear the joke that the guys in question allegedly told.  What I do know is that for a member of the minority out-group, there is frequently <em>no action</em> that will be accepted as "right" if it includes the assertion that the majority did something offensive.</p>
<p> I've seen this phenomena very directly myself, not in the context of sexism, but in terms of antisemitism. There's an expression that I've heard multiple times in the northeast US, to talk about bartering a price for a car: "jewing the salesman down". I absolutely find that extremely offensive. And I've called people out on it. There is no response that's actually acceptable.</p>
<p> If I politely say "You know, that's relying on a stereotype of me and my ancestors that's really hurtful", the response is: "Oh, come on, it's just harmless. I'm not talking about you, it's just a word. You're being oversensitive". If I get angry, the response is "You Jews are so strident". If I go to an authority figure in the setting, "You Jews are so passive aggressive, why couldn't you just talk to me?". No matter what I do, I'm wrong. Women deal with this every day, only they're in a situation where the power dynamic is even less in their favor.</p>
<p> That's the situation that women - particularly women in tech - find themselves in every day. We <em>are</em> sexist. We <em>do</em> mistreat women in tech every day, without even knowing that we're doing it. And we're very likely to take offense if they mention that we did something wrong. Because we know that we're good people, and since we aren't deliberately doing something bad, they <em>must</em> be wrong.</p>
<p> For someone in Adria Richards' situation at PyCon, there is <em>no</em> course of action that can't be taken wrong. As a woman hearing the joke in question, she certainly knew whether or not it was offensive <em>to her</em>. But once she'd heard something offensive, there was nothing she could do that someone couldn't turn into a controversy.</p>
<p> Was the joke offensive? We don't know what, specifically, he said. The only fact that we're certain of is that in her judgement, it was offensive; that the authorities at PyCon agreed, and asked the gentleman in question to apologize.</p>
<p> Did the guy who made the joke deserve to be fired? I don't know. If this stupid joke were the first time he'd ever done something wrong, then he didn't deserve to be fired. But we don't know what his history is like. I know how hard it is to hire skilled engineers, so I'm very skeptical that any company would fire someone over one minor offense. It's possible that his company has a crazy hair-trigger HR department. But it's also possible that there's background that we don't know about. That he's done stuff before, and been warned. If that's the case, then his company could have decided that this was the last straw.</p>
<p> Did Adria Richards deserve to be fired? Almost certainly not. We know more about her case than we do about the guy who told the joke. We know that her company fired her <em>over this specific incident</em>, because in their announcement of her firing, <em>they told us the reason</em>. They didn't cite any past behavior - they just specifically cited this incident and its aftermath as the reason for firing her. It's possible that there's a history here that we don't know about, that she'd soured relations with customers of her company in incidents other than this, and that this was a last straw. But it doesn't seem likely, based on the facts that we're aware of.</p>
<p> Did either of them deserve to be threatened? Absolutely not.</p>
<p><a class="a2a_dd a2a_target addtoany_share_save" href="http://www.addtoany.com/share_save#url=http%3A%2F%2Fscientopia.org%2Fblogs%2Fgoodmath%2F2013%2F03%2F28%2Fa-white-boys-observations-of-sexism-and-the-adria-richards-fiasco%2F&amp;title=A%20White%20Boy%27s%20Observations%20of%20Sexism%20and%20the%20Adria%20Richards%20Fiasco" id="wpa2a_10"><img src="http://scientopia.org/blogs/goodmath/wp-content/plugins/add-to-any/share_save_171_16.png" width="171" height="16" alt="Share"/></a></p>]]></content:encoded>
			<wfw:commentRss>http://scientopia.org/blogs/goodmath/2013/03/28/a-white-boys-observations-of-sexism-and-the-adria-richards-fiasco/feed/</wfw:commentRss>
		<slash:comments>122</slash:comments>
		</item>
		<item>
		<title>Genius Continuum Crackpottery</title>
		<link>http://scientopia.org/blogs/goodmath/2013/03/21/genius-continuum-crackpottery/</link>
		<comments>http://scientopia.org/blogs/goodmath/2013/03/21/genius-continuum-crackpottery/#comments</comments>
		<pubDate>Fri, 22 Mar 2013 00:26:14 +0000</pubDate>
		<dc:creator>MarkCC</dc:creator>
				<category><![CDATA[Bad Algebra]]></category>
		<category><![CDATA[Bad Logic]]></category>
		<category><![CDATA[Bad Math]]></category>
		<category><![CDATA[Cantor Crankery]]></category>

		<guid isPermaLink="false">http://scientopia.org/blogs/goodmath/?p=2150</guid>
		<description><![CDATA[There's a lot of mathematical crackpottery out there. Most of it is just pointless and dull. People making the same stupid mistakes over and over again, like the endless repetitions of the same-old supposed refutations of Cantor's diagonalization. After you eliminate that, you get reams of insanity - stuff which is simply so incoherent that [...]]]></description>
				<content:encoded><![CDATA[<p> There's a lot of mathematical crackpottery out there. Most of it is just pointless and dull. People making the same stupid mistakes over and over again, like the endless repetitions of the same-old supposed refutations of Cantor's diagonalization.</p>
<p> After you eliminate that, you get reams of insanity - stuff which<br />
is simply so incoherent that it doesn't make any sense. This kind of thing is usually word salad - words strung together in ways that don't make sense.</p>
<p> After you eliminate that, sometimes, if you're really lucky, you'll come accross something truly special. Crackpottery as utter genius. Not genius in a good way, like they're an outsider genius who discovered something amazing, but genius in the worst possible way, where someone has created something so bizarre, so overwrought, so utterly ridiculous that it's a masterpiece of insane, delusional foolishness.</p>
<p> Today, we have an example of that: <a href="http://existics101.com"/><em>Existics!</em></a>. This is a body of work by a high school dropout named Gavin Wince with truly immense delusions of grandeur. Pomposity on a truly epic scale!</p>
<p> I'll walk you through just a tiny sample of Mr. Wince's genius. You can go look at his site to get more, and develop a true appreciation for this. He doesn't limit himself to mere mathematics: math, physics, biology, cosmology - you name it, Mr. Wince has mastered it and written about it!</p>
<p> The best of his mathematical crackpottery is something called <a href="http://existics101.com/wp-content/uploads/2012/01/C3-The-Canonized-Cardinal-Continuum.pdf">C3: the Canonized Cardinal Continuum</a>. Mr. Wince has created an algebraic solution to the continuum hypothesis, and along the way, has revolutionized number theory, algebra, calculus, real analysis, and god only knows what else!</p>
<p> Since Mr. Wince believes that he has solved the continuum hypothesis. Let me remind you of what that is:</p>
<ol>
<li> If you use Cantor's set theory to explore numbers, you get to the uncomfortable result that there are different sizes of infinity.</li>
<li> The smallest infinite cardinal number is called &aleph;<sub>0</sub>,<br />
  and it's the size of the set of natural numbers.</li>
<li> There are cardinal numbers larger than &aleph;<sub>0</sub>. The first<br />
one larger than &aleph;<sub>0</sub> is &aleph;<sub>1</sub>. </li>
<li> We know that the set of real numbers is the size of the powerset<br />
of the natural numbers - 2<sup>&alefsym;<sub>0</sub></sup> - is larger than the set of the naturals.</li>
<li> The question that the continuum hypothesis tries to answer is: is the size<br />
 of the set of real numbers equal to &alefsym;<sub>1</sub>? That is, is there<br />
 a cardinal number between &alefsym;<sub>0</sub> and |2<sup>&alefsym;<sub>0</sub></sup>|?</li>
</ol>
<p> The continuum hypothesis was "solved" in 1963. In 1940, G&ouml;del showed that you couldn't <em>disprove</em> the continuum hypothesis using ZFC. In 1963,<br />
another mathematician named Paul Cohen, showed that it couldn't be <em>proven</em> using ZFC. So - a hypothesis which is about set theory can be neither proven <em>nor</em> disproven using set theory. It's <em>independent</em> of the axioms of set theory. You can choose to take the continuum hypothesis as an axiom, or you can choose to take the negation of the continuum hypothesis as an axiom: either choice is consistent and valid!</p>
<p> It's not a happy solution. But it's solved in the sense that we've got a solid proof that you can't prove it's true, and another solid proof that you can't prove it's false. That means that given ZFC set theory as a basis, there is <em>no proof</em> either way that doesn't set it as an axiom.</p>
<p> But... Mr. Wince knows better.</p>
<p> The set of errors that Wince makes is really astonishing. This is really seriously epic crackpottery.</p>
<p> He makes it through one page without saying anything egregious. But then he makes up for it on page 2, by making multiple errors.</p>
<p> First, he pulls an Escultura:</p>
<blockquote>
<p> x<sub>1</sub> = 1/2<sup>1</sup> = 1/2 = 0.5</p>
<p> x<sub>2</sub> = 1/2<sup>1</sup> + 1/2<sup>2</sup> = 1/2 + 1/4 = 0.75</p>
<p> x<sub>3</sub> = 1/2<sup>1</sup> + 1/2<sup>2</sup> + 1/2<sup>3</sup> = 1/2 + 1/4 + 1/8 = 0.875</p>
<p>...</p>
<p>At the end or limit of the infinite sequence, the final term of the sequence is 1.0</p>
<p> ...</p>
<p> In this example we can see that as the number of finite sums of the sequence approaches the limit infinity, the last term of the sequence equals one. </p>
<p> x<sub>n</sub> = 1.0</p>
<p> If we are going to assume that the last term of the sequence equals one, it can be deduced that, prior to the last term in the sequence, some finite sum in the series occurs where:</p>
<p>x<sub>n-1</sub> = 0.999…</p>
<p>x<sub>n-1</sub> = 1/2<sup>1</sup> + 1/2<sup>2</sup> + 1/2<sup>3</sup> + 1/2<sup>4</sup> + … + 1/2<sup>n-1</sup> = 0.999…</p>
<p> Therefore, at the limit, the last term of the series of the last term of the sequence would be the term, which, when added to the sum 0.999… equals 1.0.</p>
</blockquote>
<p> There is no such thing as the <em>last term</em> of an infinite sequence. Even if there were, the number 0.999.... <em>is exactly the same</em> as 1. It's a notational artifact, not a distinct number.</p>
<p> But this is the least of his errors. For example, the first paragraph on the next page:</p>
<blockquote><p>
The set of all countable numbers, or natural numbers, is a subset of the continuum. Since the set of all natural numbers is a subset of the continuum, it is reasonable to assume that the set of all natural numbers is less in degree of infinity than the set containing the continuum.
</p></blockquote>
<p> We didn't need to go through the difficult of Cantor's diagonalization! We could have just blindly <em>asserted</em> that it's obvious!</p>
<p> or actually... The fact that there are multiple degrees of infinity is anything but obvious. I don't know anyone who wasn't surprised the first time they saw Cantor's proof. It's a really <em>strange</em> idea that there's something bigger than infinity. </p>
<p>  Moving on... the real heart of his stuff is built around some extremely strange notions about infinite and infinitessimal values. </p>
<p> Before we even look at what he says, there's an important error here<br />
which is worth mentioning. What Mr. Wince is trying to do is talk about the<br />
continuum hypothesis. The continuum hypothesis is a question about the cardinality of the set of real numbers and the set of natural numbers.<br />
<em>Neither infinites nor infinitessimals are part of either set</em>.
</p>
<p> Infinite values come into play in Cantor's work: the cardinality of the natural numbers and the cardinality of the reals are clearly infinite cardinal numbers. But &alefsym;<sub>0</sub>, the smallest infinite cardinal, is <emph>not</emph> a member of either set.</p>
<p> Infinitessimals are fascinating. You can reconstruct differential and integral calculus without using limits by building in terms of infinitessimals. There's some great stuff in surreal numbers playing with infinitessimals. But infinitessimals <em>are not real numbers</em>. You can't reason about them as if they were members of the set of real numbers, because they aren't.</p>
<p> Many of his mistakes are based on this idea. </p>
<p> For example, he's got a very strange idea that infinites and infinitessimals don't have fixed values, but that their values cover a range. The way that he gets to that idea is by asserting the existence<br />
of infinity as a specific, numeric value, and then using it in algebraic manipulations, like taking the "infinityth root" of a real number.</p>
<p>For example, on his way to "proving" that infinitessimals have this range property that he calls "perambulation", he defines a value that he calls &kappa;:</p>
<blockquote><p>
<p style='text-align:center;'><span class='MathJax_Preview'><img src='http://scientopia.org/blogs/goodmath/wp-content/plugins/latex/cache/tex_a4a6cb662e98cb2c7b4c34e4f2791ee1.gif' style='' class='tex' alt=" \sqrt[\infty]{\infty} = 1 + \kappa" /></span></p>
</p></blockquote>
<p> In terms of the theory of numbers, this is nonsense.  There is no such thing as an infinityth root. You can define an Nth root, where N is a real number, just like you can define an Nth power - exponents and roots are mirror images of the same concept. But roots and exponents aren't defined for infinity, because infinity <em>isn't a number</em>. There is no infinityth root. </p>
<p> You could, if you really wanted to, come up with a definition of exponents that that allowed you to define an infinityth root. But it wouldn't be very interesting.  If you followed the usual pattern for these things, it would be a limit:  <span class='MathJax_Preview'><img src='http://scientopia.org/blogs/goodmath/wp-content/plugins/latex/cache/tex_e7a76826bc2dd6a6d4e72f2d03fdb330.gif' style=' ' class='tex' alt="\sqrt[\infty]{x}  \lim_{n\rightarrow\infty} \sqrt[n]{x}" /></span>. That's clearly 1. Not 1 <em>plus</em> something: just exactly 1. </p>
<p> But Mr. Cringe doesn't let himself be limited by silly notions of consistency. No, he defines things his own way, and runs with it. As a result, he gets a notion that he calls <em>perambulation</em>. How?</p>
<p> Take the definition of &kappa;:</p>
<p><p style='text-align:center;'><span class='MathJax_Preview'><img src='http://scientopia.org/blogs/goodmath/wp-content/plugins/latex/cache/tex_a4a6cb662e98cb2c7b4c34e4f2791ee1.gif' style='' class='tex' alt=" \sqrt[\infty]{\infty} = 1 + \kappa" /></span></p></p>
<p> Now, you can, obviously, raise both sides to the power of infinity:</p>
<p><p style='text-align:center;'><span class='MathJax_Preview'><img src='http://scientopia.org/blogs/goodmath/wp-content/plugins/latex/cache/tex_bc76e83ff02e35f60de6abc9bcff6c28.gif' style='' class='tex' alt="\infty = (1 + \kappa)^{\infty}" /></span></p></p>
<p> Now, you can substitute &alefsym;<sub>0</sub> for <span class='MathJax_Preview'><img src='http://scientopia.org/blogs/goodmath/wp-content/plugins/latex/cache/tex_7ed9abff4dafd78d08e616c899412e92.gif' style=' padding-bottom:2px;' class='tex' alt="\infty" /></span>. (Why? Don't ask why. You just can.) Then you can factor it. His factoring makes no rational sense, so I won't even try to explain it. But he concludes that:</p>
<ul>
<li> Factored and simplified one way, you end up with <em>(&kappa;+1)<sup>&alefsym;</sup> = 1 + x</em>, where <em>x</em> is some infinitessimal number larger than &kappa;. (Why? Why the heck not?)</li>
<li> Factored and simplified another way, you end up with (&kappa;+1)<sup>&alefsym;</sup> = &alefsym;</li>
<li> If you take the mean of of all of the possible factorings and reductions, you get a third result, that   (&kappa;+1)<sup>&alefsym;</sup> = 2.</li>
</ul>
<p> He goes on, and on, and on like this. From perambulation to perambulating reciprocals, to subambulation, to ambulation. Then un-ordinals, un-sets... this is really an absolute masterwork of utter insane crackpottery. </p>
<p> Do download it and take a look. It's a masterpiece.</p>
<p><a class="a2a_dd a2a_target addtoany_share_save" href="http://www.addtoany.com/share_save#url=http%3A%2F%2Fscientopia.org%2Fblogs%2Fgoodmath%2F2013%2F03%2F21%2Fgenius-continuum-crackpottery%2F&amp;title=Genius%20Continuum%20Crackpottery" id="wpa2a_12"><img src="http://scientopia.org/blogs/goodmath/wp-content/plugins/add-to-any/share_save_171_16.png" width="171" height="16" alt="Share"/></a></p>]]></content:encoded>
			<wfw:commentRss>http://scientopia.org/blogs/goodmath/2013/03/21/genius-continuum-crackpottery/feed/</wfw:commentRss>
		<slash:comments>19</slash:comments>
		</item>
		<item>
		<title>Pi-day randomness</title>
		<link>http://scientopia.org/blogs/goodmath/2013/03/14/pi-day-randomness/</link>
		<comments>http://scientopia.org/blogs/goodmath/2013/03/14/pi-day-randomness/#comments</comments>
		<pubDate>Fri, 15 Mar 2013 01:04:57 +0000</pubDate>
		<dc:creator>MarkCC</dc:creator>
				<category><![CDATA[Bad Math]]></category>

		<guid isPermaLink="false">http://scientopia.org/blogs/goodmath/?p=2145</guid>
		<description><![CDATA[One of my twitter friends was complaining about something that's apparently making the rounds of Facebook for &#960;-day. It annoyed me sufficiently to be worth ranting about a little bit. Why isn't &#960; rational if &#960;=circumference/diameter, and both measurements are plainly finite? There's a couple of different ways of interpreting this question. The stupidest way [...]]]></description>
				<content:encoded><![CDATA[<p> One of my twitter friends was complaining about something that's apparently making the rounds of Facebook for &pi;-day. It annoyed me sufficiently to be worth ranting about a little bit.</p>
<blockquote><p>
Why isn't &pi; rational if &pi;=circumference/diameter, and both measurements are plainly finite?
</p></blockquote>
<p> There's a couple of different ways of interpreting this question.</p>
<p> The stupidest way of interpreting it is that the author didn't have any clue of what an irrational number is. An irrational number is a number which cannot be written as a ratio of two integers. Another way of saying essentially the same thing is that there's no way to create a finite representation of an irrational number. I've seen people get this wrong before, where they confuse <em>not having a finite representation</em> with <em>not being finite</em>.</p>
<p> &pi; doesn't have a finite representation. But it's very clearly finite - it's less that 3 1/4, which is obviously not infinite. Anyone who can look at &pi;, and be confused about whether or not it's finite is... well... there's no nice way to say this. If you think that &pi; isn't finite, you're an idiot.
</p>
<p> The other way of interpreting this statement is less stupid: it's a question of <em>measurement</em>. If you have a circular object in real life, then you can <em>measure</em> the circumference and the diameter, and do the division on the measurements. The measurements have <em>finite precision</em>. So how can the ratio of two measurements with finite precision be irrational?</p>
<p> The answer is, they can't. But perfect circles don't exist in the real world. Many mathematical concepts don't exist in the real world. In the real world, there's no such thing as a mathematical point, no such thing as a perfect line, no such thing as perfectly parallel lines.</p>
<p> &pi; isn't a measured quantity. It's a theoretical quantity, which can be computed <em>analytically</em> from the theoretical properties derived from the abstract properties of an ideal, perfect circle.</p>
<p> No "circle" in the real world has a perfect ratio of &pi; between its circumference and its diameter. But the theoretical circle does.</p>
<p> The facebook comments on this get much worse than the original question. One in particular really depressed me.</p>
<blockquote><p>
Just because the measurements are finite doesn't mean they're rational.<br />
Pi is possibly rational, we just haven't figured out where it ends.
</p></blockquote>
<p> Gah, no!</p>
<p> We know an awful lot about &pi;. And we know, with absolute, 100% perfect certainty that &pi; never ends.</p>
<p> We can define &pi; precisely as a series, and that series makes it abundantly clear that it never ends.</p>
<p><p style='text-align:center;'><span class='MathJax_Preview'><img src='http://scientopia.org/blogs/goodmath/wp-content/plugins/latex/cache/tex_bc3ba8986d66a51d7704808cd31bce09.gif' style='' class='tex' alt="\pi = \frac{4}{1} - \frac{4}{3} + \frac{4}{5} - \frac{4}{7} + \frac{4}{9} ..." /></span></p></p>
<p> That series goes on forever. &pi; can't ever end, because that series never ends.</p>
<p> Just for fun, here's a little snippet of Python code that you can play with. You can see how, up to the limits of your computer's floating point representation, that a series computation of &pi; keeps on going, changing with each additional iteration.
</p>
<pre>
def pi(numiter):
  val = 3.0
  sign = 1
  for i in range(numiter):
    term = ((i+1)*2) * ((i+1)*2 + 1) * ((i+1) *2 + 2)
    val = val + sign*4.0/term
    sign = sign * -1
  return val
</pre>
<p><a class="a2a_dd a2a_target addtoany_share_save" href="http://www.addtoany.com/share_save#url=http%3A%2F%2Fscientopia.org%2Fblogs%2Fgoodmath%2F2013%2F03%2F14%2Fpi-day-randomness%2F&amp;title=Pi-day%20randomness" id="wpa2a_14"><img src="http://scientopia.org/blogs/goodmath/wp-content/plugins/add-to-any/share_save_171_16.png" width="171" height="16" alt="Share"/></a></p>]]></content:encoded>
			<wfw:commentRss>http://scientopia.org/blogs/goodmath/2013/03/14/pi-day-randomness/feed/</wfw:commentRss>
		<slash:comments>18</slash:comments>
		</item>
		<item>
		<title>Finally: G&#246;del&#039;s Proof of Incompleteness!</title>
		<link>http://scientopia.org/blogs/goodmath/2013/03/12/finally-gdels-proof-of-incompleteness/</link>
		<comments>http://scientopia.org/blogs/goodmath/2013/03/12/finally-gdels-proof-of-incompleteness/#comments</comments>
		<pubDate>Tue, 12 Mar 2013 14:17:16 +0000</pubDate>
		<dc:creator>MarkCC</dc:creator>
				<category><![CDATA[Incompleteness]]></category>
		<category><![CDATA[godel]]></category>
		<category><![CDATA[incompleteness]]></category>
		<category><![CDATA[logic]]></category>

		<guid isPermaLink="false">http://scientopia.org/blogs/goodmath/?p=2141</guid>
		<description><![CDATA[Finally, we're at the end of our walkthrough of G&#246;del great incompleteness proof. As a refresher, the basic proof sketch is:]]></description>
				<content:encoded><![CDATA[<p> Finally, we're at the end of our walkthrough of G&ouml;del great incompleteness proof. As a refresher, the basic proof sketch is:</p.</p>
<ol>
<li> Take a simple logic. We've been using a variant of the Principia Mathematica's logic, because that's what Gödel used.</li>
<li> Show that any statement in the logic can be encoded as a number using an arithmetic process based on the syntax of the logic. The process of encoding statements numerically is called Gödel numbering.</li>
<li>Show that you can express meta-mathematical properties of logical statements in terms of arithemetic properties of their Gödel numbers. In particular, we need to build up the logical infrastructure that we need to talk about whether or not a statement is provable.</li>
<li> Using meta-mathematical properties, show how you can create an unprovable statement encoded as a Gödel number.  </li>
</ol>
<p> What came before:</p>
<ol>
<li> <a href="http://scientopia.org/blogs/goodmath/2013/02/07/gdel-numbering-encoding-logic-as-numbers/">G&ouml;del numbering:</a> The logic of the Principia, and how to encode it as numbers. This was step 1 in the sketch.</li>
<li> <a href="http://scientopia.org/blogs/goodmath/2013/02/11/defining-properties-arithmetically-part-1-gdel-and-primitive-recursion/">Arithmetic Properties:</a> what it means to say that a property can be expressed arithemetically. This set the groundwork for step 2 in the proof sketch.</li>
<li> <a href="http://scientopia.org/blogs/goodmath/2013/02/17/the-meta-of-gdel/">Encoding meta-math arithmetically:</a> how to take meta-mathematical properties of logical statements, and define them as arithmetic properties of the G&ouml;del numberings of the statements. This was step 2 proper.</li>
</ol>
<p> So now we can move on to step three, where we actually see why mathematical logic is necessarily incomplete.</p>
<p> When we left off with G&ouml;del, we'd gone through a very laborious process showing how we could express meta-mathematical properties of logical statements as primitive recursive functions and relations. We built up to being able to express one <em>non</em>-primitive recursive property, which describes the property that a given statement is provable:</p>
<pre>
pred provable(x) =
  some y {
    proofFor(y, x)
  }
}
</pre>
<p> The reason for going through all of that was that we really needed to show how we could capture all of the necessary properties of logical statements in terms of arithmetic properties of their G&ouml;del numbers.</p>
<p> Now we can get to the target of G&ouml;del's effort. What G&ouml;del was trying to do was show how to defeat the careful stratification of the Principia's logic. In the principia, Russell and Whitehead had tried to avoid problems with self-reference by creating a very strict stratification, where each variable or predicate had a numeric level, and could only reason about objects from lower levels. So if natural numbers were the primitive objects in the domain being reasoned about, then level-1 objects would be things like specific natural numbers, and level-1 predicates could reason about specific natural numbers, but not about sets of natural numbers or predicates over the natural numbers. Level-2 objects would be sets of natural numbers, and level-2 predicates could reason about natural numbers and sets of natural numbers, but not about predicates over sets of natural numbers, or sets of sets of natural numbers. Level-3 objects would be sets of sets of natural numbers... and so on.
</p>
<p> The point of this stratification was to make self-reference impossible. You couldn't make a statement of the form "This predicate is true": the predicate would be a level-N predicate, and only a level N+1 predicate could reason about a level-N predicate. </p>
<p> What G&ouml;del did in the laborious process we went through in the last<br />
  post is embed a model of logical statements in the natural numbers. That's the real trick: the logic is designed to work with a set of objects that are a model of the natural numbers. By embedding a model of logical statements in<br />
  the natural numbers, he made it possible for a level-1 predicate (a predicate about a specific natural number) to reason about <em>any</em> logical statement or object. A level-1 predicate can now reason about a level-7 object! A level-1 predicate can reason about the set defined by a level-1 predicate: a level-1 predicate can reason <em>about itself!</em>.
</p>
<p> Now, we can finally start getting to the point of all of this: incompleteness! We're going to use our newfound ability to nest logical statements into numbers to construct an unprovable true statement.</p>
<p> In the last post, one of the meta-mathematical properties that we defined for the G&ouml;del-numbered logic was <code>immConseq</code>, which defines when some statement <em>x</em> is an <em>immediate consequence</em> of a set of statements <em>S</em>. As a reminder, that means that <em>x</em> can be inferred from statements in <em>S</em> in one inferrence step.</p>
<p> We can use that property to define what it means to be a consequence of a set of statements: it's the closure of immediate consequence. We can define it in pseudo-code as:</p>
<pre>
def conseq(&kappa;) = {
  K = &kappa; + axioms
  added_to_k = false
  do {
    added_to_k = false
    for all c in immConseq(K) {
      if c not in K {
        add c to K
        added_to_k = true
      }
    }
  } while added_to_k
  return K
}
</pre>
<p> In other words, <em>Conseq(&kappa;)</em> is the complete set of everything that can possibly be inferred from the statements in &kappa; and the axioms of the system.  We can say that there's a proof for a statement <em>x</em> in &kappa; if and only if <em>x &isin; Conseq(&kappa;)</em>.</p>
<p> We can the idea of <em>Conseq</em> use that to define a strong version of what it means for a logical system with a set of facts to be consistent. A system is &omega;-consistent if and only if there is <em>not</em> a statement <em>a</em> such that: <em>a &isin; Conseq(&kappa;) &and; not(forall(v, a)) &isin; Conseq(&kappa;)</em>.
</p>
<p> In other words, the system is &omega;-consistent as long as it's never true that both a universal statement and it. But for our purposes, we can treat it as being pretty much the same thing. (Yes, that's a bit hand-wavy, but I'm not trying to write an entire book about G&ouml;del here!)</p>
<p> <em>(G&ouml;del's version of the definition of &omega;-consistency is  harder to read than this, because he's very explicit about the fact that <em>Conseq</em> is a property of the <em>numbers</em>. I'm willing to fuzz that, because we've shown that the statements and the numbers are interchangable.)</em></p>
<p> Using the definition of &omega;-consistency, we can <em>finally</em> get to the actual statement of the incompleteness theorem!</p>
<p> <b>G&ouml;del's First Incompleteness Theorem:</b> For every &omega;-consistent primitive recursive set &kappa; of formulae, there is a primitive-recursive predicate <em>r(x)</em> such that neither <em>forall(v, r)</em> nor <em>not(forall(v, r))</em> is provable.</p>
<p> To prove that, we'll construct the predicate <em>r</em>.</p>
<p> First, we need to define a version of our earlier <code>isProofFigure</code> that's specific to the set of statements &kappa;:</p>
<pre>
pred isProofFigureWithKappa(x, kappa) = {
  all n in 1 to length(x) {
    isAxiom(item(n, x)) or
    item(n, x) in kappa or
    some p in 0 to n {
      some q in 0 to n {
        immedConseq(item(n, x), item(p, x), item(q, x))
      }
    }
  } and length(x) > 0
}
</pre>
<p> This is the same as the earlier definition - just specialized so that it ensures that every statement in the proof figure is either an axiom, or a member of &kappa;.</p>
<p> We can do the same thing to specialize the predicate <code>proofFor</code> and <code>provable</code>:</p>
<pre>
pred proofForStatementWithKappa(x, y, kappa) = {
  isProofFigureWithKappa(x, kappa) and
  item(length(x), x) = y
}

pred provableWithKappa(x, kappa) = {
  some y {
    proofForStatementWithKappa(y, x, kappa)
  }
}
</pre>
<p> If &kappa; is the set of basic truths that we can work with, then<br />
provable in &kappa; is equivalent to provable. </p>
<p> Now, we can define a predicate <em>UnprovableInKappa</em>:</p>
<pre>
pred NotAProofWithKappa(x, y, kappa) = {
  not (proofForKappa(x, subst(y, 19, number(y))))
}
</pre>
<p> Based on everything that we've done so far, <em>NotAProofWithKappa</em> is primitive recursive. </p>
<p> This is tricky, but it's really important. We're getting very close to the goal, and it's subtle, so let's take the time to understand this.</p>
<ul>
<li> Remember that in a G&ouml;del numbering, each prime number is a variable. So 19 here is just the name of a free variable in <em>y</em>.</li>
<li> Using the Principia's logic, the fact that variable 19 is free means that the statement is parametric in variable 19. For the moment, it's an incomplete statement, because it's got an unbound parameter.</li>
<li>  What we're doing in <em>NotAProofWithKappa</em> is substituting the numeric coding of <em>y</em> for the value of <em>y</em>'s parameter. When that's done, <em>y</em> is no longer incomplete: it's unbound variable has been replaced by a binding.</li>
<li> With that substitution, <em>NotAProofWithKappa(x, y, kappa)</em> is true  when <em>x</em> <em>does not</em> prove that <em>y(y)</em> is true.</li>
</ul>
<p> What <em>NotAProofWithKappa</em> does is give us a way to check whether a specific sequence of statements <em>x</em> is <b>not</b> a proof of <em>y</em>.
</p>
<p> We want to expand <em>NotAProofWithKappa</em> to something universal.  Instead of just saying that a specific sequence of statements <em>x</em> isn't a proof for <em>y</em>, we want to be able to say that <em>no possible sequence of statements</em> is a proof for <em>y</em>. That's easy to do in logic: you just wrap the statement in a "&forall; x ( )". In G&ouml;del numbering, we defined a function that does exactly that. So the universan form of provability is:<br />
<em>&forall; a (NotAProofWithKappa(a, y, kappa))</em>.</p>
<p>  In terms of the G&ouml;del numbering, if we assume that the G&ouml;del number for the variable <em>a</em> is 17, and the variable <em>y</em> is  numbered as 19, we're talking about the statement <em>p = forall(17, ProvableInKappa(17, 19, kappa)</em>. </p>
<p> <em>p</em> is the statement that for some logical statement (the value of variable 19, or y in our definition), there is no possible value for variable 17 (a) where <em>a</em> proves <em>y</em> in &kappa;.</p>
<p> All we need to do now is show that we can make <em>p</em> become self-referential. No problem: we can just put <em>number(p)</em> in as the value of <em>y</em> in <em>UnprovableInKappa</em>. If we let <em>q</em> be the numeric value of the statement <em>UnprovableInKappa(a, y)</em>, then:</p>
<p> r = subst(q, 19, p)</p>
<p> i = subst(p, 19, r)</p>
<p> <em>i</em> says that there is no possible value <em>x</em> that proves <em>p(p)</em>. In other words, <em>p(p)</em> is unprovable: there exists no possible proof that there is no possible proof of p!</p>
<p> This is what we've been trying to get at all this time: self-reference! We've got a predicate <em>y</em> which is able to express a property <em>of itself</em>. Worse, it's able to express a <em>negative property</em> of itself!</p>
<p> Now we're faced with two possible choices. Either <em>i</em> is provable - in which case, &kappa; is inconsistent! Or else <em>i</em> is unprovable - in which case &kappa; is incomplete, because we've identified a true statement that can't be proven!</p>
<p> That's it: we've shown that in the principia's logic, using nothing but arithmetic, we can create a true statement that cannot be proven. If, somehow, it were to be proven, the entire logic would be inconsistent. So the principia's logic is incomplete: there are true statements that cannot be proven true.</p>
<p> We can go a bit further: the process that we used to produce this result about the Principia's logic is actually applicable to other logics. There's no magic here: if your logic is powerful enough to do Peano arithmetic, you can use the same trick that we demonstrated here, and show that the logic must be either incomplete or inconsistent. (G&ouml;del proved this formally, but we'll just handwave it.) </p>
<p> Looking at this with modern eyes, it doesn't seem quite as profound as it did back in G&ouml;del's day.</p>
<p> When we look at it through the lens of today, what we see is that in the Principia's logic, proof is a mechanical process: a computation. If every true statement was provable, then you could take any statement <em>S</em>, and write a program to search for a proof of either <em>S</em> or <em>&not; S</em>, and eventually, that program would find one or the other, and stop. </p>
<p> In short, you'd be able to solve the halting problem. The proof of the halting problem is really an amazingly profound thing: on a very deep level, it's the same thing as incompleteness, only it's easier to understand.</p>
<p> But at the time that G&ouml;del was working, Turing hadn't written his paper about the halting problem. Incompletess was published in 1931; Turing's halting paper was published in 1936. This was a totally unprecedented idea when it was published. G&ouml;del produced one of the most profound and surprising results in the entire history of mathematics, showing that the efforts of the best mathematicians in the world to produce the perfection of mathematics were completely futile.</p>
<p><a class="a2a_dd a2a_target addtoany_share_save" href="http://www.addtoany.com/share_save#url=http%3A%2F%2Fscientopia.org%2Fblogs%2Fgoodmath%2F2013%2F03%2F12%2Ffinally-gdels-proof-of-incompleteness%2F&amp;title=Finally%3A%20G%C3%B6del%27s%20Proof%20of%20Incompleteness%21" id="wpa2a_16"><img src="http://scientopia.org/blogs/goodmath/wp-content/plugins/add-to-any/share_save_171_16.png" width="171" height="16" alt="Share"/></a></p>]]></content:encoded>
			<wfw:commentRss>http://scientopia.org/blogs/goodmath/2013/03/12/finally-gdels-proof-of-incompleteness/feed/</wfw:commentRss>
		<slash:comments>5</slash:comments>
		</item>
		<item>
		<title>Passwords, Hashing, and Salt</title>
		<link>http://scientopia.org/blogs/goodmath/2013/03/02/passwords-hashing-and-salt/</link>
		<comments>http://scientopia.org/blogs/goodmath/2013/03/02/passwords-hashing-and-salt/#comments</comments>
		<pubDate>Sat, 02 Mar 2013 20:08:12 +0000</pubDate>
		<dc:creator>MarkCC</dc:creator>
				<category><![CDATA[Cryptography]]></category>

		<guid isPermaLink="false">http://scientopia.org/blogs/goodmath/?p=2137</guid>
		<description><![CDATA[Over on twitter, some folks were chatting about the latest big security botch. A major service, called Evernote, had a security breach where a password file was stolen. Evernote has handled the situation quite well, being open about what happened, and explaining the risks. In their description of the breach, they said that the stolen [...]]]></description>
				<content:encoded><![CDATA[<p> Over on twitter, some folks were chatting about the latest big security botch. A major service, called Evernote, had <a href="http://www.theverge.com/2013/3/2/4056704/evernote-password-reset">a security breach where a password file was stolen</a>. Evernote has handled the situation quite well, being open about what happened, and explaining the risks. </p>
<p> In their description of the breach, they said that the stolen passwords were "both hashed and salted". Apparently this sounds funny to people outside of software. (Amazing how jargon becomes so ingrained that I didn't even notice the fact that it could be interpreted in a funny way until it was pointed out to me!)</p>
<p> Anyway, since discussion of this is going around, I thought I'd explain just what password hashing and salting means.</p>
<p> Let's start at the beginning. You're some kind of system that wants to have password security. Obviously, you need to save the passwords somewhere, right?</p>
<p> As we'll see, that's only partially correct - but let's go with it for now. You need to store <em>something</em> that lets you check if a user supplied the right password, so you need to store something.</p>
<p> The most naive approach is create a file (or database, or whatever) that contains the usernames and passwords of all of your users. Something like:</p>
<pre> 
alice:abc
mark:pass
joe:123
jen:hello
</pre>
<p> Suppose you were a thief, and you wanted to crack this password file, what would you do? You'd try to steal that file! If you can get hold of that password file, then you'd have all of the passwords for all of the users of the system. </p>
<p> That means that this is a terrible way of storing the passwords. One step, and a thief has completely breached your system. We don't want that. So what should we do?</p>
<p> First, we could encrypt the file. </p>
<p> This might seem like a good idea at first. If a thief were the steal the file, the wouldn't be able to find your user's passwords without figuring out the encryption key! It's going to take a <em>lot</em> of work to figure out that key!</p>
<p> The first problem with this is that any password can be cracked given enough time and power. If there's only one encryption key for the entire file, then it's worth investing a lot of time and power into breaking it - and once it's broken, then <em>everything</em> is revealed.</p>
<p> The second problem is: how does your system check a user's password? It needs to decrypt the file! That means that the encryption key must be available to your system! So all that a thief needs to do is figure out where your system is getting the key from. You've got your entire security system for all of your users set up with a single point of protection, and somewhere in your system, everything that you need to break that protection is available!</p>
<p> What can we do to improve this? The answer is something called <em>crypto graphic hashing</em>. </p>
<p> Cryptographic hashing is a combination of two concepts: hashing, and one-way functions.</p>
<p> A really simple example of a not-very-good hash function of a string would be something like: convert all of the characters in the string to their numeric values, and exclusive-or the binary representation of those bits. With that hash function, you could take a string like "ABCD", and convert it to the numeric values of the characters ([65, 66, 67, 68]), and then x-or them together (1000001 xor 1000010 xor 1000011 xor 1000100 = 0000100) for a result of 4. Real practical hash functions are more complicated.</p>
<p> For example, at least some versions of Java use the following as the default hash for a string of characters:</p>
<p>	<p style='text-align:center;'><span class='MathJax_Preview'><img src='http://scientopia.org/blogs/goodmath/wp-content/plugins/latex/cache/tex_c695557c241b2235f253a1cbd4c931b5.gif' style='' class='tex' alt="\text{hash}(s) = \left(\sum_{i \in \text{length}(s)} 31^{length(s) - i - 1}*s[i] \right) \mod 2^{32}" /></span></p></p>
<p> There's a class of mathematical functions called <em>one-way functions</em>. A one way function is a function <span class='MathJax_Preview'><img src='http://scientopia.org/blogs/goodmath/wp-content/plugins/latex/cache/tex_8fa14cdd754f91cc6554c9e71929cce7.gif' style=' padding-bottom:1px;' class='tex' alt="f" /></span>,  where given <span class='MathJax_Preview'><img src='http://scientopia.org/blogs/goodmath/wp-content/plugins/latex/cache/tex_9dd4e461268c8034f5c8564e155c67a6.gif' style=' padding-bottom:2px;' class='tex' alt="x" /></span>, it's easy to compute <span class='MathJax_Preview'><img src='http://scientopia.org/blogs/goodmath/wp-content/plugins/latex/cache/tex_50bbd36e1fd2333108437a2ca378be62.gif' style=' ' class='tex' alt="f(x)" /></span>, but given <span class='MathJax_Preview'><img src='http://scientopia.org/blogs/goodmath/wp-content/plugins/latex/cache/tex_50bbd36e1fd2333108437a2ca378be62.gif' style=' ' class='tex' alt="f(x)" /></span> it's extremely difficult (or even impossible) to compute <span class='MathJax_Preview'><img src='http://scientopia.org/blogs/goodmath/wp-content/plugins/latex/cache/tex_9dd4e461268c8034f5c8564e155c67a6.gif' style=' padding-bottom:2px;' class='tex' alt="x" /></span>.</p>
<p> If we combine those two, we have what's called a <em>crpytogrphic hash function</em>: a function that takes an arbitrary input string, and converts it to a number, in a way where it's very difficult to figure out what the input string that produced the number was. That's great for storing passwords! We don't store the password <em>at all</em>. We just store the hash-value produced from the password. Then when a user comes and logs in, we take their password, hash it, and compute the result to the stored hash.</p>
<p> Instead of the file with explicit passwords, we get something like:</p>
<pre>
alice:7a2d28fc
mark:dfd4e1c6 
joe:ed849ee1
jen:bb76e739
</pre>
<p> This is <em>much</em> better than storing the encrypted password. There is no encryption key that a thief can use to decrypt the password. Even if a thief knows the hash values of your user's passwords, they can't get in to the system! And your system actually never stores the actual values of the user's passwords - just their hashcodes! </p>
<p> So again, let's look at this from the perspective of a thief. How can a thief break into a system with hashed passwords?</p>
<p> If they don't know what hash function you're using, then they're completely stuck. Sadly, they can probably figure it out. Designing new crpytographic hash functions is hard. Implementing cryptographic hash functions correctly is hard. As a result, most people just use a hash function from a library. That means that for a thief, it's usually pretty easy to figure out what hash function is being used by a system.</p>
<p> Once they know what hash function you used, their only choice to break your system is to try to guess the passwords. That is, they can guess passwords, compute their hash codes, and search through your password file to see if any of the users password hashes matches. If they find one, they're gold!</p>
<p> In fact, there's a common strategy based on this idea called a <em>rainbow table</em>.  A rainbox table is a list of common passwords, and the numeric value that they hash to with a common crptographic hash value. Something like:</p>
<table border="1">
<tr>
<th>Password String</th>
<th>Hash value</th>
</tr>
<tr>
<td>pass</td>
<td>1b93eb12</td>
</tr>
<tr>
<td>password</td>
<td>a4532c47</td>
</tr>
<tr>
<td>abc</td>
<td>7a2d28fc</td>
</tr>
<tr>
<td>...</td>
<td>...</td>
</tr>
</table>
<p> If you can somehow steal the passwords file, then with a rainbow table, you can find users with common passwords. For example, in the table above, you can see that the hashcode "7a2d28fc" occurs in the passwords file for the username "alice", and it's also in the rainbow table for the password "abc". So a thief could determing that alice's password was "abc". Even with the best crpytographic hash, all it takes is one idiot user who uses "password" as their password, and your system's security is breached.</p>
<p> Salting passwords addresses that problem. In a salting strategy, you don't hash a user's password by itself: you combine it with some additional data, and then hash that combination. The additional information is called the <em>salt.</em>.</p>
<p> You can use lots of different things for the salt. There's a complex set of tradeoffs in the exact salting strategy, which are beyond the scope of this post, but a few examples include:</p>
<ol>
<li> Always use a fixed salt string. This is weak, but better than nothing. It's got a similar weakness to the encrypted password system: you only need one salt to give you a handle on breaking all of the passwords, and that one salt needs to be in the system.</li>
<li> Add a random piece of data for each password. The catch here is that you need to store the salt data for each password. This is what unix passwords used to use. They added 12 random bits to each password. In the passwords file, they stored the salt and the hashed password. The weakness of this is that the salt is right there	with the password entry. But because each user has a different salt, that means that any attempt to breach the system needs to look at each user separately.</li>
<li> Salt on metadata: that is, take information about the user that isn't part of their username, and use that as the salt. For example, you could use a person's birthday as the salt for their account.</li>
</ol>
<p> If each user has a different salt, then even if you've got terrible passwords, a thief needs to do a lot of work to try to break your system. Even with a rainbow-table like strategy, they can't compute the hashcode for a given common password once, and then search the password hash list for that code - they need to recompute it for each possible salt value!</p>
<p> What salting does is, effectively, increase the amount of effort needed to break the passwords.  If you add 12 bits of salt, then a rainbow table needs 4096 times more entries to find common passwords! If your salt is long enough, then it can make it effectively impossible to create a rainbox table at all. If they try to attack you without a rainbow table, a 12 bit salt means that your attacker needs to attack the passwords of each of your users seperately! Even if they know the value of the salt, you've made it much harder for them to breach your security.</p>
<p><a class="a2a_dd a2a_target addtoany_share_save" href="http://www.addtoany.com/share_save#url=http%3A%2F%2Fscientopia.org%2Fblogs%2Fgoodmath%2F2013%2F03%2F02%2Fpasswords-hashing-and-salt%2F&amp;title=Passwords%2C%20Hashing%2C%20and%20Salt" id="wpa2a_18"><img src="http://scientopia.org/blogs/goodmath/wp-content/plugins/add-to-any/share_save_171_16.png" width="171" height="16" alt="Share"/></a></p>]]></content:encoded>
			<wfw:commentRss>http://scientopia.org/blogs/goodmath/2013/03/02/passwords-hashing-and-salt/feed/</wfw:commentRss>
		<slash:comments>15</slash:comments>
		</item>
		<item>
		<title>New Dimensions of Crackpottery</title>
		<link>http://scientopia.org/blogs/goodmath/2013/02/26/new-dimensions-of-crackpottery/</link>
		<comments>http://scientopia.org/blogs/goodmath/2013/02/26/new-dimensions-of-crackpottery/#comments</comments>
		<pubDate>Tue, 26 Feb 2013 15:06:32 +0000</pubDate>
		<dc:creator>MarkCC</dc:creator>
				<category><![CDATA[Bad Physics]]></category>

		<guid isPermaLink="false">http://scientopia.org/blogs/goodmath/?p=2131</guid>
		<description><![CDATA[I have, in the past, ranted about how people abuse the word "dimension", but it's been a long time. One of my followers on twitter sent me a link to a remarkable piece of crackpottery which is a great example of how people simply do not understand what dimensions are. There are several ways of [...]]]></description>
				<content:encoded><![CDATA[<p> I have, in the past, ranted about how people abuse the word "dimension", but it's been a long time. One of my followers on twitter sent me a link to a <a href="http://www.mikeelias.com/2013/02/10/why-emc2-is-just-the-beginning/">remarkable piece of crackpottery</a> which is a great example of how people simply do not understand what dimensions are.</p>
<p> There are several ways of defining "dimension" mathematically, but they all come back to one basic concept. A dimension an abstract concept of a <em>direction</em>. We can use the number of dimensions in a space as a way of measuring properties of that space, but those properties all come back to the concept of direction. A dimension is neither a place nor a state of being: it is a direction.</p>
<p> Imagine that you're sitting in an abstract space. You're at one point. There's another point that I want you to go to. In order to uniquely identify your destination, how many directions do I need to mention?</p>
<p> If the space is a line, you only need one: I need to tell you the distance. There's only one possible direction that you can go, so all I need to tell you is how far. Since you only need one direction, the line is one-dimensional.</p>
<p> If the line is a plane, then I need to tell you two things. I could do that by saying "go right three steps then up 4 steps", or I could say "turn 53 degrees clockwise, and then walk forward 5 steps." But there's no way I can tell you how to get to your destination with less than two directions. You need two directions, so the plane is two dimensional.</p>
<p> If the space is the interior of a cube, then you'll need three directions, which means that the cube is three dimensional.</p>
<p> On to the crackpottery!</p>
<blockquote>
<p>E=mc2 represents a translation across dimensions, from energy to matter.</p>
</blockquote>
<p> No, it does not. Energy and matter are <em>not</em> dimensions. <span class='MathJax_Preview'><img src='http://scientopia.org/blogs/goodmath/wp-content/plugins/latex/cache/tex_8105cc0386e42f3a4c62834c0dc86eb7.gif' style=' ' class='tex' alt="e=mc^2" /></span> is a statement about the fundamental relation between energy and matter, not a statement about dimensions. Our universe could be 2 dimensional, 3 dimensional, 4 dimensional, or 22 dimensional: relativity would still mean the same thing, and it's not a statement about a "translation across dimensions".</p>
<blockquote>
<p>Energy can travel at the speed of light, and as Special Relativity tells us, from the perspective of light speed it takes no time to travel any distance. In this way, energy is not bound by time and space the way matter is. Therefore, it is in a way five-dimensional, or beyond time.</p>
</blockquote>
<p> Bzzt, no. </p>
<p> Energy does not travel. <em>Light</em> travels, and light can transmit energy, but light isn't energy. Or, from another perspective, light is energy: but <em>so is everything else</em>. Matter and energy are the same thing.</p>
<p> From the perspective of light speed time most certainly does pass, and it does take plenty of time to travel a distance. Light takes roughly 6 minutes to get from the sun to the earth. What our intrepid author is trying to talk about here is the idea of time dilation. Time dilation describes the behavior of particles <em>with mass</em> when they move at high speeds. As a massive particle moves faster and approaches the speed of light, the mass of the particle increases, and the particle's experience of time slows. <em>If</em> you could accelerate a massive particle to the speed of light, its mass would become infinite, and time would stop for the particle. "If" is the key word there: it can't. It would require an infinite amount of energy to accelerate it to the speed of light.</p>
<p> But light has no mass. Relativity describes a strange property of the universe, which is hard to wrap your head around. Light <em>always</em> moves at the same speed, no matter your perspective. Take two spacecraft in outer space, which are completely stationary relative to each other. Shine a laser from one, and measure how long it takes for the light to get to the other. How fast is it going? Roughly 186,000 miles/second. Now, start one ship moving away from the other at half the speed of light. Repeat the experiment. One ship is moving away from the other at a speed of 93,000 miles/second. From the perspective of the moving ship, how fast is the light moving away from it towards the other ship? 186,000 miles/second. From the perspective of the stationary ship, how fast is the laser light approaching it? 186,000 miles/second.</p>
<p> It's not that there's some magic thing about light that makes it move while time stops for it. Light is massless, so it can move at the speed of light. Time dilation doesn't apply because it has no mass.</p>
<p> But even if that weren't the case, that's got nothing to do with dimensionality. Dimensionality is a direction: what does this rubbish have to do with the different directions that light can move in? Absolutely nothing: the way he's using the word "dimension" has nothing to do with what dimensions mean.</p>
<blockquote>
<p>All “objects” or instances of matter are time-bound; they change, or die, or dissolve, or evaporate. Because they are subject to time, objects can be called four-dimensional.</p>
</blockquote>
<p> Nope.</p>
<p> Everything in our universe is subject to time, because <em>time is one of the dimensions in our universe</em>. Time is a direction that we move.  We don't have direct control over it - but it's still a direction. When and where did I write this blog post compared to where I am when you're reading it? The only way you can specify that is by saying how far my position has changed in <em>four</em> directions: 3 spatial directions, and time. Time is a dimension, and everything in our universe needs to consider it, because you can't specify anything in our universe without all four dimensions.</p>
<blockquote>
<p>The enormous energy that can be released from a tiny object (as in an atomic bomb) demonstrates the role dimensions play in constructing reality.</p>
</blockquote>
<p> No: the enormous energy that can be released from a tiny object demonstrates the fact that a small quantity of matter is equivalent to a large quantity of energy. As you'd expect if you look at that original equation: <span class='MathJax_Preview'><img src='http://scientopia.org/blogs/goodmath/wp-content/plugins/latex/cache/tex_8105cc0386e42f3a4c62834c0dc86eb7.gif' style=' ' class='tex' alt="e=mc^2" /></span>. A gram of mass - something the size of a paperclip - is equivalent to about 25 <em>million</em> kilowatt-hours of energy - or more than the total yearly energy use of 1,200 average americans. That's damned impressive and profound, without needing to draw in any mangled notions of dimensions or magical dimensional powers.</p>
<blockquote>
<p>Higher dimensions are mind-blowingly powerful; even infinitely so. Such power is so expansive that it can’t have form, definition, or identity, like a ball of uranium or a human being, without finding expression in lower dimensions. The limitations of time and space allow infinite power to do something other than constantly annihilate itself.</p>
</blockquote>
<p> Do I even need to respond to this?</p>
<blockquote>
<p>Einstein’s equation E=mc2 bridges the fourth and the fifth dimensions, expressed as matter and energy. Imagine a discovery that bridges expressions of the fifth and sixth dimensions, such as energy and consciousness. Consciousness has the five-dimensional qualities of energy, but it can’t be “spent” in the way energy can because it doesn’t change form the way energy does. Therefore, it’s limitless.</p>
</blockquote>
<p> And now we move from crackpottery to mysticism. Einstein's mass-energy equation doesn't bridge dimensions, and dimensionality has nothing do with mass-energy equivalence. And now our crackpot friend suddenly throws in another claim, that consciousness is the sixth dimension? Or consciousness is the bridge between the fifth and sixth dimensions? It's hard to figure out just what he's saying here, except for the fact that it's got nothing to do with actual <em>dimensions</em>.</p>
<p> Is there a sixth dimension? Who knows? According to some modern theories, our universe actually has many more than the 4 dimensions that we directly experience. There could be 6 or 10 or 20 dimensions. But if there are, those dimensions are just other directions that things can move. They're not abstract concepts like "consciousness".</p>
<p> And of course, this is also remarkably sloppy logic:</p>
<ol>
<li> Consciousness has the 5-dimensional qualities of energy</li>
<li> Consciousness can't be spent.</li>
<li> Consciousness can't change form.</li>
<li> Therefore consciousness is unlimited.</li>
</ol>
<p> The first three statements are just blind assertions, given without evidence or argument. The fourth is presented as a conclusion drawn from the first three - but it's a non-sequitur. There's no real way to conclude the last statement given the first three. Even if you give him all the rope in the world, and accept those three statements as axioms - it's still garbage.</p>
<p><a class="a2a_dd a2a_target addtoany_share_save" href="http://www.addtoany.com/share_save#url=http%3A%2F%2Fscientopia.org%2Fblogs%2Fgoodmath%2F2013%2F02%2F26%2Fnew-dimensions-of-crackpottery%2F&amp;title=New%20Dimensions%20of%20Crackpottery" id="wpa2a_20"><img src="http://scientopia.org/blogs/goodmath/wp-content/plugins/add-to-any/share_save_171_16.png" width="171" height="16" alt="Share"/></a></p>]]></content:encoded>
			<wfw:commentRss>http://scientopia.org/blogs/goodmath/2013/02/26/new-dimensions-of-crackpottery/feed/</wfw:commentRss>
		<slash:comments>33</slash:comments>
		</item>
	</channel>
</rss>
