algorithms

Algorithms in English

If the rightmost point of one interval is to the right of the leftmost point of the other interval, and if the leftmost point of the first interval is to the left of the rightmost point of the other interval, then and only then do those two intervals overlap.

There are some assumptions, however. There are always some assumptions, even when dealing with the most rigorous of mathematics. It’s time to finally admit this fact of life.

The assumptions here are that intervals are collinear and closed, so that the rightmost and the leftmost points exist. And that “to overlap” means to have more than one common point. Which are all very reasonable.

We can name one interval “alice” and the other one “bob”. Then we can write it as follows:

If the rightmost point of alice is to the right of the leftmost point of bob, and if the leftmost point of alice is to the left of the rightmost point of bob, then and only then do alice and bob overlap.

If we call  the leftmost point “tail” and the rightmost point “head” as they are lying there in such an orientation and if we then substitute “to the left” with “smaller” and “to the right” with “greater”  we obtain:

If alice’s head is greater than bob’s tail, and if alice’s tail is smaller than bob’s head, then and only then do alice and bob overlap.

or even better:

If alice’s head is greater than bob’s tail, and bob’s head is greater than alice’s tail, then and only then do alice and bob overlap.

or:

If the head of both is greater than the tail of the other one, then and only then do alice and bob overlap.

or even:

If every head is greater than every tail, then and only then do alice and bob overlap.

or:

If there is no head bellow any tail, then and only then do alice and bob overlap. (1)

with the:

If there is no interval’s supremum smaller of any interval’s infimum there, then and only then two intervals do overlap. 

the assumption of the closed intervals is no more needed. Any combination of closed, semi-closed or open intervals now works. Our assumption moved to the infimum/supremum concept. Fortunately, quite a fundamental one in mathematics.

Usually we say:

If A2>B1 && B2>A1 overlaping=true Else overlaping=false   (2)

The assumption of what A1 and A2 and B1 and B2 are, as well as every other assumption, must be first handled somehow. Otherwise some defaults may be understood by the compiler and only if we are lucky, will everything work well after compiling.

The formula (2) is a free gift to your machine compiler, when the formula (1) is the most understandable for us. Isn’t it? You and your machine compiler are meeting at the midpoint between the natural language expression from the beginning and the binary code it will eventually produce. You are just to soft with your machine. Therefore too harsh to yourself.

You are born to think in some human language, where you can really understand things. Don’t worry about computers, they are perfectly capable of understanding English (or Slovenian). At least in principle.

The English language is a perfect engine. It can run all the logics, mathematics, physics and all the programming languages, including assembly. All. You can enrich the English language with formulae and pictures, but you don’t need to. Every single picture is perfectly describable in English.

Just imagine a superintelligent machine running on Latin! Holly apparatus! Machina Sancta.

Advertisements
Standard
physics

Colliding Steel Spheres

In a central collision of two 1 gram steel balls with a relative speed of 1 meter per second, nothing much would happen.

If the collision speed were much greater, say a few kilometres per second, they would, of course, evaporate.

Then, we also have the case where the relative speed is 99 percent of the speed of light. The collision is indistinguishable from an A bomb detonation. Entirely understandable and comprehensible.

However in the case where their relative velocity is almost the speed of light, where maybe an entire star or galaxy mass has been used for the acceleration, those two spheres will go through each other virtually intact!

Why do you think, this is?

Standard
astrophysics, geology

Water on Earth

It is from Earth, not from comets, not from asteroids.

There’s more than one million cups of water of it on our planet. Cups as large as the comet was 65 or 66 million years ago. There wasn’t enough time for all our water to be delivered this way. Where in time are you going to put all those alleged events?

None of the latter big bombardment were nearly big enough.

Almost all of our water for the last 4.5 billion years has always been with us. Just as all the sulphur has.

Chemically recombined who knows how, but all the water is originally from here.

(I won a bet on the Extropy mailing list, what Rosetta was about to say, a few days ago. It is in a perfect accordance with what I have written above.)

Standard