Archive:
In this section:
Subtopics:
Comments disabled |
Wed, 12 Aug 2015
Another solution to Tuesday's git problem
On Tuesday I discussed an interesting solution to the problem of turning this:
into this:
Dave Du Cros has suggested an alternative solution: Make the changes required to turn off feature X, and commit them as B, as in my solution:
Then use
C' and C have identical trees. Then use
This has the benefit of not requiring anything strange. I think my solution is more general, but it's also weird, and it's not clear that the increased generality is useful. However, what if there were a
This last command would mean that the previous two commits, normally
into
one would use
I think [ Addendum 20200531: Curtis Dunham suggested a much better interface to this functionality
than my [Other articles in category /prog] permanent link
A message to the aliens, part 1/23 (numbers)
Earlier articles: Introduction Common features This is page 1 of the Cosmic Call message. An explanation follows. This page, headed with the glyph for “mathematics” The page is in three sections. The first section explains the individual digit symbols. A typical portion looks like this:
Here the number 7 is written in three ways: first, as seven dots,
probably unmistakable. Second, as a 4-bit binary number, using the
same bit symbols that are used in the page numbers. The three forms
are separated by the glyph
The authors did a great job selecting glyphs that resemble the numerals they represent. All have some resemblance except for 4, which has 4 horizontal strokes. Watch out for 4; it's easy to confuse with 3. The second section serves two purposes. It confirms the meaning of the ten digits, and it also informs the aliens that the rest of the message will write numerals in base ten. For example, the number 14:
Again, there are 14 dots, an equal sign, and the numeral 14, this time
written with the two glyphs People often ask why the numbers are written in base 10, rather than say in base 2. One good answer is: why not? We write numbers in base 10; is there a reason to hide that from the aliens? The whole point of the message is to tell the aliens a little bit about ourselves, so why disguise the fact that we use base-10 numerals? Another reason is that base-10 numbers are easier to proofread for the humans sending the message. The third section of the page is a list of prime numbers from 2 to 89:
and finally the number !!2^{3021377}-1!!
I often wonder what the aliens will think of the !!2^{3021377}-1!!. Will they laugh at how cute we are, boasting about the sweet little prime number we found? Or will they be astounded and wonder why we think we know that such a big number is prime? The next article, to appear 2015-08-12, will discuss page 2, shown at right. (Click to enlarge.) Try to figure it out before then.[Other articles in category /aliens/dd] permanent link
A message to the aliens, part 2/23 (arithmetic)
Earlier articles: Introduction Common features Page 1 (numerals) This is page 2 of the Cosmic Call message. An explanation follows. Reminder: the previous page explained the ten digits:
This page, headed with the glyph for “mathematics” The page is in five sections, three on top and two below. The subtraction sign actually appeared back on page 1
in the Mersenne prime !!2^{3021377}-1!! The negative sign Note that the negative-number sign is not the same as the subtraction sign. The decimal point There is also an attempt to divide by zero: It's not clear what the authors mean by this; the mysterious glyph
For some reason, perhaps because of space limitations, the authors have stuck the equation !!0-1 = {}^-1!! at the bottom of the division section. The fifth section, at lower right, displays some nonterminating decimal fractions and introduces
I would have put !!2÷27 = 0.0740…!! here instead of !!2\div 3!!, which I think is too similar to the other examples. The next article, to appear 2015-08-14, will discuss page 3, shown at right. (Click to enlarge.) Try to figure it out before then.[Other articles in category /aliens/dd] permanent link |