{"id":124,"date":"2006-08-21T08:30:00","date_gmt":"2006-08-21T08:30:00","guid":{"rendered":"http:\/\/scientopia.org\/blogs\/goodmath\/2006\/08\/21\/arithmetic-with-surreal-numbers\/"},"modified":"2006-08-21T08:30:00","modified_gmt":"2006-08-21T08:30:00","slug":"arithmetic-with-surreal-numbers","status":"publish","type":"post","link":"http:\/\/www.goodmath.org\/blog\/2006\/08\/21\/arithmetic-with-surreal-numbers\/","title":{"rendered":"Arithmetic with Surreal Numbers"},"content":{"rendered":"<p>Last thursday, I introduced the construction of John Conway&#8217;s beautiful surreal numbers. Today I&#8217;m going to show you how to do arithmetic using surreals. It&#8217;s really quite amazing how it all works! If you haven&#8217;t read the original post introducing surreals, you&#8217;ll definitely want to [go back and read that][surreals] before looking at this post!<\/p>\n<p><!--more--><br \/>\nTransfinite Induction and &le;<br \/>\n&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8211;<br \/>\nI&#8217;m going to start off by working through the way that the recursive<br \/>\ndefinition of the surreals and the &#8220;&le;&#8221; operator work. It&#8217;s based on<br \/>\nsomething called *transfinite induction*.<br \/>\nTransfinite induction is based on the use of *ordinals*. The idea is to use the basic technique of mathematical induction &#8211; only instead of doing induction over the numbers themselves, you&#8217;re doing induction over the *ordinals* associated with sets of numbers.<br \/>\nSo, the way that we make &#8220;&le;&#8221; work is induction over the ordinals. Ordinal N is the set of surreal numbers whose birthday is N.<br \/>\nThe set containing the surreal 0 has ordinal 0 in the surreals. 0 &le; 0 is true, because there is nothing in its right set (&empty;) that is not less than or equal to anything in its left set; and there&#8217;s nothing in its left set that is greater than or equal to anything in its right set.<br \/>\nOrdinal 1 for the surreals is the set { -1, 1 }. Does &le; work for -1, 0, and 1? Check it through; it does.<br \/>\nSince each new ordinal introduces a set of numbers constructed from the previous ordinals; and the construction rule requires the values in a new ordinal to be built from valid values of *previous* ordinals, then the new values will *also* work correctly with &#8220;&le;&#8221;.<br \/>\nAll of the other arithmetic on surreals works using definitions that similarly depend on transfinite induction.<br \/>\nAddition with Surreal Numbers<br \/>\n&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8211;<br \/>\nAddition for surreals is pretty straightforward:<br \/>\nIf x = { X<sub>L<\/sub> | X<sub>R<\/sub> } and y = { Y<sub>L<\/sub> | Y<sub>R<\/sub> } are surreal numbers, then<br \/>\nx + y = {X<sub>L<\/sub> + y &cup; x + Y<sub>L<\/sub> | X<sub>R<\/sub>+y &cup; x + Y<sub>R<\/sub>} where<br \/>\n* if X is a set of surreal numbers, and y is a surreal number, then X+y = {x+y|x &isin; X}.<br \/>\nOnce again, take note of the fact that this definition is recursive, and applies to all surreal numbers by transfinite induction.<br \/>\nSo, to translate into english a bit: to add two surreals x and y, take the left side of x, and add it each member of it to y; take the left side of y, and add each member of it to X. Same basic idea for the right side.<br \/>\nSo, for example, let&#8217;s look at 2 + 3.<br \/>\n* {1|} + {2|} = {{1}+{2|} &cup; {1|}+2 | &empty; &cup; &empty; } =<br \/>\n* {{{0|}}+{2|}) &cup; {{0|}+{1|}} |} = {{3|}} &cup; {2|}|} = {3,4|} = {4|} = 5.<br \/>\nTo get subtraction into the picture, we need to define *negation* for surreal numbers:<br \/>\n* -0 = 0;<br \/>\n* if x={ X<sub>L<\/sub> | X<sub>R<\/sub> }, then -x = { {-xr | xr &isin; X<sub>R<\/sub>} | {-lx | xl &isin; X<sub>L<\/sub>}}<br \/>\nAnd now, we can say:<br \/>\n* For any two surreal numbers x and y, x &#8211; y = x + (-y)<br \/>\nMultiplication with Surreal Numbers<br \/>\n&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;<br \/>\nThe definition of multiplication is very similar to the definition for addition:<br \/>\nIf x = {X<sub>L<\/sub> | X<sub>R<\/sub> } and y = {Y<sub>L<\/sub> | Y<sub>R<\/sub> }, then:<br \/>\nz = x &times; y = { Z<sub>L<\/sub> | Z<sub>R<\/sub> } where:<br \/>\n* Z<sub>L<\/sub> = (X<sub>L<\/sub>&times; y + x&times;Y<sub>L<\/sub> &#8211; X<sub>L<\/sub>&times;Y<sub>L<\/sub>) &cup; (X<sub>R<\/sub>&times;y + x&times;Y<sub>R<\/sub> &#8211; X<sub>R<\/sub>&times;Y<sub>R<\/sub>)<br \/>\n* Z<sub>R<\/sub> = (X<sub>L<\/sub>&times; y + x&times;Y<sub>R<\/sub> &#8211; X<sub>L<\/sub>&times;Y<sub>R<\/sub>) &cup; (X<sub>R<\/sub>&times;y + x&times;Y<sub>L<\/sub> &#8211; X<sub>R<\/sub>&times;Y<sub>L<\/sub>); and<br \/>\n* if S and T are sets of surreals (e.g., X<sub>L<\/sub> above), then S&times;T= { s&times;t | s &isin; S, t &isin; T };<br \/>\n* if t is a surreal and S is a set of surreals, then t &times; S = S &times; t = { t }&times;S. (Note that this implies that if S is &empty;, then t&times;S={&empty;|&empty;} = 0; and therefore S&times;T=0 if S or T = &empty;.)<br \/>\nTo make it easier to write things out, we can write x&times;y as four components: l<sub>1<\/sub>, l<sub>2<\/sub>, r<sub>1<\/sub>, and r<sub>2<\/sub>, where:<br \/>\n* l<sub>1<\/sub> = X<sub>L<\/sub>&times; y + x&times;Y<sub>L<\/sub> &#8211; X<sub>L<\/sub>&times;Y<sub>L<\/sub><br \/>\n* l<sub>2<\/sub> = X<sub>R<\/sub>&times;y + x&times;Y<sub>R<\/sub> &#8211; X<sub>R<\/sub>&times;Y<sub>R<\/sub><br \/>\n* r<sub>1<\/sub>=X<sub>L<\/sub>&times; y + x&times;Y<sub>R<\/sub> &#8211; X<sub>L<\/sub>&times;Y<sub>R<\/sub><br \/>\n* r<sub>2<\/sub> = X<sub>R<\/sub>&times;y + x&times;Y<sub>L<\/sub> &#8211; X<sub>R<\/sub>&times;Y<sub>L<\/sub><br \/>\n* x&times;y = {l<sub>1<\/sub> &cup; l<sub>2<\/sub> | r<sub>1<\/sub> &cup; r<sub>2<\/sub> }<br \/>\nMultiplication is a bit hard to follow, so we&#8217;ll work through a couple of examples.<br \/>\nLet&#8217;s start with 0&times;1. In surreal format, that&#8217;s:  0 &times; {0|}.<br \/>\nWe&#8217;ll look at l<sub>1<\/sub> first:<br \/>\n1. l<sub>1<\/sub> = &empty;&times;{0|} + 0&times;{0} &#8211; &empty;&times;{0} =<br \/>\n2. &empty; + 0&times;{0} &#8211; &empty;&times;{0} = &empty;<br \/>\nThe same thing happens to all four terms: 0 always contributes an &empty; component, which turns every term it&#8217;s a part of into &empty;. In fact, the above works for any number multiplied with zero: zero&#8217;s part of every combination is always &empty;, which eliminates the contribution from the other number, so the result will always end up being {&empty; | &empty;} = 0.<br \/>\nHow about 1&times;1 =<br \/>\n{0|}&times;{0|} =<br \/>\n* l1 = {0}&times;{0|} + {0|}&times;{0} &#8211; {0}&times;{0} = {0} + {{0|}&times;0} &#8211; {0} = {{0|} &times; 0} = {0}.<br \/>\n* l2 = &empty;&times;{0|} + {0|}&times;&empty; &#8211; &empty;&times;&empty; = &empty;<br \/>\n* r1 = {0}&times;{0|} + {0|}&times;&empty; &#8211; {0};&times;&empty; = {0} + &empty; &#8211; &empty; = &empty;.<br \/>\n* r2 = &empty;&times;{0|} + {0|}&times;{0} &#8211; &empty;&times;&empty; = &empty; + 0 + &empty; = &empty;<br \/>\nSo 1&times;1 = { {0} &cup; &empty; | &empty; &cup; &empty; } = {0|} = 1.<br \/>\nOne last example: 2 &times; 2, aka {1|} &times; {1|}. I&#8217;m actually going to cheat with this one. I&#8217;ve written some Java code to do basic surreal manipulations, so I&#8217;m going to let it spit out the pieces.<br \/>\n1. L1 = { {{{{{|0}|{0|}}|{{0|}|}}|{{{0|}|}|}}|{{{{0|}|}|}|}} }<br \/>\n2. L2 = &empty;<br \/>\n3. R1 = &empty;<br \/>\n4. R2 = &empty;<br \/>\nSo 2&times;2 = { {{{{{|0}|{0|}}|{{0|}|}}|{{{0|}|}|}}|{{{{0|}|}|}|}} | } =<br \/>\n* {{{{{-1|1}|{1|}}|{{1|}|}}|{{{1|}|}|}}|} =<br \/>\n* {{{{0|2}|{2|}}|{{2|}|}}|} =<br \/>\n* {{{1|3}|{3|}}|} =<br \/>\n* {{2|4}|} =<br \/>\n* {3|} =<br \/>\n* 4.<br \/>\nSee, it works!<br \/>\nWhy should I care?<br \/>\n&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;-<br \/>\nThe thing about surreal numbers that&#8217;s fascinating is that they&#8217;re such a simple construction &#8211; and yet they manage to capture the richness of behavior of the real numbers, while also giving us a handle on playing with infinitely large and infinitely small values. They&#8217;re a lot like Church numerals in lambda calculus, where you start with one trivial little thing &#8211; nothing but two empty sets in the surreal numbers! &#8211; and you can create *everything*.<br \/>\nUltimately, all of the definitions of arithmetic reduce to nothing more than a bunch of recursive set unions; and yet, somehow, using nothing but those set unions, we can get absolutely everything to work exactly the way we expect real numbers to work.<br \/>\nWhen you think about it that way &#8211; we&#8217;ve built  up everything we need to be able to do any algebraic operation, using nothing but the empty set and set unions &#8211; it&#8217;s just amazing.<br \/>\n[surreals]: http:\/\/scienceblogs.com\/goodmath\/2006\/08\/introducing_the_surreal_number.php<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Last thursday, I introduced the construction of John Conway&#8217;s beautiful surreal numbers. Today I&#8217;m going to show you how to do arithmetic using surreals. It&#8217;s really quite amazing how it all works! If you haven&#8217;t read the original post introducing surreals, you&#8217;ll definitely want to [go back and read that][surreals] before looking at this post!<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"jetpack_post_was_ever_published":false,"_jetpack_newsletter_access":"","_jetpack_dont_email_post_to_subs":false,"_jetpack_newsletter_tier_id":0,"_jetpack_memberships_contains_paywalled_content":false,"_jetpack_memberships_contains_paid_content":false,"footnotes":"","jetpack_publicize_message":"","jetpack_publicize_feature_enabled":true,"jetpack_social_post_already_shared":false,"jetpack_social_options":{"image_generator_settings":{"template":"highway","default_image_id":0,"font":"","enabled":false},"version":2}},"categories":[24,43],"tags":[],"class_list":["post-124","post","type-post","status-publish","format-standard","hentry","category-goodmath","category-numbers"],"jetpack_publicize_connections":[],"jetpack_featured_media_url":"","jetpack_shortlink":"https:\/\/wp.me\/p4lzZS-20","jetpack_sharing_enabled":true,"jetpack_likes_enabled":true,"_links":{"self":[{"href":"http:\/\/www.goodmath.org\/blog\/wp-json\/wp\/v2\/posts\/124","targetHints":{"allow":["GET"]}}],"collection":[{"href":"http:\/\/www.goodmath.org\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/www.goodmath.org\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/www.goodmath.org\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"http:\/\/www.goodmath.org\/blog\/wp-json\/wp\/v2\/comments?post=124"}],"version-history":[{"count":0,"href":"http:\/\/www.goodmath.org\/blog\/wp-json\/wp\/v2\/posts\/124\/revisions"}],"wp:attachment":[{"href":"http:\/\/www.goodmath.org\/blog\/wp-json\/wp\/v2\/media?parent=124"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/www.goodmath.org\/blog\/wp-json\/wp\/v2\/categories?post=124"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/www.goodmath.org\/blog\/wp-json\/wp\/v2\/tags?post=124"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}