Archive:
In this section: Subtopics:
Comments disabled |
Sun, 31 May 2020
Reordering git commits (not patches) with interactive rebase
This is the third article in a series. ([1] [2]) You may want to reread the earlier ones, which were in 2015. I'll try to summarize. The original issue considered the implementation of some program feature X. In commit A, the feature had not yet been implemented. In the next commit C it had been implemented, and was enabled. Then there was a third commit, B, that left feature X implemented but disabled it:
but what I wanted was to have the commits in this order:
so that when X first appeared in the history, it was disabled, and then a following commit enabled it. The first article in the series began:
Using interactive rebase here “to reorder B and C” will not work
because My original articles described a way around this, using the plumbing
command Recently, Curtis Dunham wrote to me with a much better idea that uses the
interactive rebase UI to accomplish the same thing much more cleanly.
If we had B checked out and we tried
As I said before, just switching the order of these two M. Dunham's suggestion is to use
But what's
That is, “take a snapshot of that commit”. It's simple to implement:
There needs to be a bit of cleanup to get the working tree back into
sync with the new index.
M. Dunham's actual implementation
does this with I hadn't know about the Thank you again, M. Dunham! [Other articles in category /prog] permanent link Sat, 30 May 2020Rob Hoelz mentioned that (one of?) the Nenets languages has different verb moods for concepts that in English are both indicated by “should” and “ought”:
Examples of the former being:
and of the latter:
I have often wished that English were clearer about distinguishing these. For example, someone will say to me
and it is not always clear whether they are advising me how to fix the problem, or lamenting that it won't. A similar issue applies to the phrase “ought to”. As far as I can tell the two phrases are completely interchangeable, and both share the same ambiguities. I want to suggest that everyone start using “should” for the deontic version (“you should go now”) and “ought to” for the predictive verion (“you ought to be able to see the lighthouse from here”) and never vice versa, but that's obviously a lost cause. I think the original meaning of both forms is more deontic. Both words originally meant monetary debts or obligations. With ought this is obvious, at least once it's pointed out, because it's so similar in spelling and pronunciation to owed. (Compare pass, passed, past with owe, owed, ought.) For shall, the Big Dictionary has several citations, none later than 1425 CE. One is a Middle English version of Romans 13:7:
As often with Middle English, this is easier than it looks at first. In fact this one is so much easier than it looks that it might become my go-to example. The only strange word is schuleþ itself. Here's my almost word-for-word translation:
The NIV translates it like this:
Anyway, this is a digression. I wanted to talk about different kinds of should. The Big Dictionary distinguishes two types but mixes them together in its listing, saying:
The first of these seems to correspond to what I was calling the deontic form (“people should be kinder”) and the second (“you should be able to catch that train”.) But their quotations reveal several other shades of meaning that don't seem exactly like either of these:
This is not any of duty, obligation, propriety, expectation, likelihood, or prediction. But it is exactly M. Hoelz’ “state of the world as it currently isn't”. Similarly:
Again, this isn't (necessarily) duty, obligation, or propriety. It's just a wish contrary to fact. The OED does give several other related shades of “should” which are not always easy to distinguish. For example, its definition 18b says
and gives as an example
Compare “We should be able to see Barbados from here”. Its 18c is “you should have seen that fight!” which again is of the wish-contrary-to-fact type; they even gloss it as “I wish you could have…”. Another distinction I would like to have in English is between “should” used for mere suggestion in contrast with the deontic use. For example
(suggestion) versus
(obligation). Say this distinction was marked in English. Then your mom might say to you in the morning
and later, when you still haven't washed the dishes:
meaning that you'll be in trouble if you fail in your dish washing duties. When my kids were small I started to notice how poorly this sort of thing was communicated by many parents. They would regularly say things like
(the second one in particular) when what they really meant, it seemed to me, was “I want you to be quiet now”. [ I didn't mean to end the article there, but after accidentally publishing it I decided it was as good a place as any to stop. ] [Other articles in category /lang] permanent link [ Previously ] John Gleeson points out that my optical illusion (below left) appears to be a variation on the classic Poggendorff illusion (below right): [Other articles in category /brain] permanent link Fri, 29 May 2020
Infinite zeroes with one on the end
I recently complained about people who claim:
When I read something like this, the first thing that usually comes to mind is the ordinal number !!\omega+1!!, which is a canonical representative of this type of ordering. But I think in the future I'll bring up this much more elementary example: $$ S = \biggl\{-1, -\frac12, -\frac13, -\frac14, \ldots, 0\biggr\} $$ Even a middle school student can understand this, and I doubt they'd be able to argue seriously that it doesn't have an infinite sequence of elements that is followed by yet another final element. Then we could define the supposedly problematic !!0, 0, 0, \ldots, 1!! thingy as a map from !!S!!, just as an ordinary sequence is defined as a map from !!\Bbb N!!. [ Related: A familiar set with an unexpected order type. ] [Other articles in category /math] permanent link A couple of years ago I wrote an article about a topological counterexample, which included this illustration: Since then, every time I have looked at this illustration, I have noticed that the blue segment is drawn wrong. It is intended to be a portion of a radius, so if I extend it toward the center of the circle it ought to intersect the center point. But clearly, the slope is too high and the extension passes significantly below the center. Or so it appears. I have checked the original SVG, using Inkscape to extend the blue segment: the extension passes through the center of the circle. I have also checked the rendered version of the illustration, by holding a straightedge up to the screen. The segment is pointing in the correct direction. So I know it's right, but still I'm jarred every time I see it, because to me it looks so clearly wrong. [ Addendum 20200530: John Gleeson has pointed out the similarity to the Poggendorff illusion. ] [Other articles in category /brain] permanent link Thu, 21 May 2020There have been several reports of the theft of catalytic converters in our neighborhood, the thieves going under the car and cutting the whole thing out. The catalytic converter contains a few grams of some precious metal, typically platinum, and this can be recycled by a sufficiently crooked junk dealer. Why weren't these being stolen before? I have a theory. The catalytic converter contains only a few grams of platinum, worth around $30. Crawling under a car to cut one out is a lot of trouble and risk to go to for $30. I think the stay-at-home order has put a lot of burglars and housebreakers out of work. People aren't leaving their houses and in particular they aren't going on vacations. So thieves have to steal what they can get. [ Addendum 20200522: An initial glance at the official crime statistics suggests that my theory is wrong. I'll try to make a report over the weekend. ] [Other articles in category /misc] permanent link Thu, 07 May 2020Yesterday I went through the last few months of web server logs, used them to correct some bad links in my blog articles. Today I checked the logs again and all the "page not found" errors are caused by people attacking my WordPress and PHP installations. So, um, yay, I guess? [Other articles in category /meta] permanent link Tue, 05 May 2020
Article explodes at the last moment
I wrote a really great blog post over the last couple of days. Last year I posted about the difference between !!\frac10!! and !!\frac00!! and this was going to be a followup. I had a great example from linear regression, where the answer comes out as !!\frac10!! in situations where the slope of computed line is infinite (and you can fix it, by going into projective space and doing everything in homogeneous coordinates), and as !!\frac00!! in situations where the line is completely indeterminite, and you can't fix it, but instead you can just pick any slope you want and proceed from there. Except no, it never does come out !!\frac10!!. It always comes out !!\frac00!!, even in the situations I said were !!\frac10!!. I think maybe I can fix it though, I hope, maybe. If so, then I will be able to write a third article. Maybe. It could have been worse. I almost published the thing, and only noticed my huge mistake because I was going to tack on an extra section at the end that it didn't really need. When I ran into difficulties with the extra section, I was tempted to go ahead and publish without it. [Other articles in category /oops] permanent link Fri, 01 May 2020
More about Sir Thomas Urquhart
I don't have much to add at this point, but when I looked into Sir Thomas Urquhart a bit more, I found this amazing article by Denton Fox in London Review of Books. It's a review of a new edition of Urquhart's 1652 book The Jewel (Ekskybalauron), published in 1984. The whole article is worth reading. It begins:
and then oh boy, does it deliver. So much of this article is quotable that I'm not sure what to quote. But let's start with:
Some excerpts will follow. You may enjoy reading the whole thing. TrissotetrasI spent much way more time on this than I expected. Fox says:
Thanks to the Wonders of the Internet, a copy is available, and I have been able to glance at it. Urquhart has invented a microlanguage along the lines of Wilkins’ philosophical language, in which the words are constructed systematically. But the language of Trissotetras has a very limited focus: it is intended only for expressing statements of trigonometry. Urquhart says:
The sentence continues for another 118 words but I think the point is made: the idea is not obviously terrible. Here is an example of Urquhart's trigonometric language in action:
A person skilled in the art might be able to infer the meaning of this axiom from its name:
That is, a side (of a triangle) is proportional to the sine of the opposite angle. This principle is currently known as the law of sines. Urquhart's idea of constructing mnemonic nonsense words for basic laws was not a new one. There was a long-established tradition of referring to forms of syllogistic reasoning with constructed mnemonics. For example a syllogism in “Darii” is a deduction of this form:
The ‘A’ in “Darii” is a mnemonic for the “all” clause and the ‘I’s for the “some” clauses. By memorizing a list of 24 names, one could remember which of the 256 possible deductions were valid. Urquhart is following this well-trodden path and borrows some of its terminology. But the way he develops it is rather daunting:
I think that ‘Pubkegdaxesh’ is compounded from the initial syllables of the seven enodandas, with p from upalem, ub from ubamen, k from ekarul, eg from egalem, and so on. I haven't been able to decipher any of these, although I didn't try very hard. There are many difficulties. Sometimes the language is obscure because it's obsolete and sometimes because Urquhart makes up his own words. (What does “enodandas” mean?) Let's just take “Upalem”. Here are Urquhart's glosses:
I believe “a tangent complement” is exactly what we would now call a cotangent; that is, the tangent of the complementary angle. But how these six items relate to one another, I do not know. Here's another difficulty: I'm not sure that ‘al’ is one component or two. It might be one:
Either way I'm not sure what is meant. Wait, there is a helpful diagram, and an explanation of it:
This is unclear but tantalizing. Urquhart is solving a problem of elementary plane trigonometry. Some of the sides and angles are known, and we are to find one of the unknown ones. I think if if I read the book from the beginning I think I might be able to make out better what Urquhart was getting at. Tempting as it is I am going to abandon it here. Trissotetras is dedicated to Urquhart's mother. In the introduction, he laments that
He must have been an admirer of Alexander Rosse, because the front matter ends with a little poem attributed to Rosse. PantochronachanonFox again:
This is Pantochronachanon, which Wikipedia says “has been the subject of ridicule since the time of its first publication, though it was likely an elaborate joke”, with no citation given. Fox mentions that Urquhart claims Alcibiades as one of his ancestors. He also claims the Queen of Sheba. According to Pantochronachanon the world was created in 3948 BC (Ussher puts it in 4004), and Sir Thomas belonged to the 153rd generation of mankind. The JewelDenton Fox:
Wowzers. Fox claims that the title Εκσκυβαλαυρον means “from dung, gold” but I do not understand why he says this. λαύρα might be a sewer or privy, and I think the word σκυβα means garden herbs. (Addendum: the explanation.)
Fox says that in spite of the general interest in universal languages, “parts of his prospectus must have seemed absurd even then”, quoting this item:
Urquhart boasts that where other, presumably inferior languages have only five or six cases, his language has ten “besides the nominative”. I think Finnish has fourteen but I am not sure even the Finns would be so sure that more was better. Verbs in Urquhart's language have one of ten tenses, seven moods, and four voices. In addition to singular and plural, his language has dual (like Ancient Greek) and also ‘redual’ numbers. Nouns may have one of eleven genders. It's like a language designed by the Oglaf Dwarves. A later item states:
and another item claims that a word of one syllable is capable of expressing an exact date and time down to the “half quarter of the hour”. Sir Thomas, I believe that Entropia, the goddess of Information Theory, would like a word with you about that. Wrapping upOne final quote from Fox:
Fox says “Nothing much came of this, either.”. I really wish I had made a note of what I had planned to say about Urquhart in 2008. [ Addendum 20200502: Brent Yorgey has explained Εκσκυβαλαυρον for me. Σκύβαλα (‘skubala’) is dung, garbage, or refuse; it appears in the original Greek text of Philippians 3:8:
And while the usual Greek word for gold is χρῡσός (‘chrysos’), the word αύρον (‘auron’, probably akin to Latin aurum) is also gold. The screenshot at right is from the 8th edition of Liddell and Scott. Thank you, M. Yorgey! ] [Other articles in category /book] permanent link |