# How to catch a lion in the Sahara Desert

The Hilbert, or axiomatic method:
We place a locked cage at a given point of the desert. We then introduce the following logical system:
Axiom 1. The class of lions in the Sahara Desert is non-void
Axiom 2. If there is a lion in the Sahara Desert, there is a lion in the cage.
Rule of Procedure. If p is a theorem, and p implies q is a theorem, then q is a theorem.
Theorem 1. There is a lion in the cage

The Method of Inversive Geometry:
We place a spherical cage in the desert, enter it, and lock it. We perform an inverse operation with respect to the cage. The lion is then in the interior of the cage and we are outside.

The Method of Projective Geometry:
Without loss of generality, we may regard the Sahara Desert as a plane. Project the plane into a line, and then project the line into an interior point of the plane. The lion is projected into the same point.

The Bolzano-Weirstrauss Method
Bisect the desert by a line runing N-S. The lion is either in the E portion or in the W portion; let us suppose him to be in the W portion. Bisect this portion by a line running E-W. The lion is either in the N portion or in the S portion; let us suppose him to be in the N portion. We continue this process indefinitely, constructing a sufficiently strong fence about the chosen portion at each step. The diameter of the chosen portions approaches zero, so that the lion is ultimately surrounded by a fence of arbitrarily small perimeter.

The `Mengentheorisch' method
We observe that the desert is a separable space. It therefore contains an enumerable dense set of points, from which can be extracted a sequences having the lion as limit. We then approach the lion stealthily along this sequence, bearing with us suitable equipment.

The Peano Method
Construct, by standard methods, a continuous curve passing through every point of the desert. It has been remarked  that it is possible to traverse such a curve in an arbitrarily short time. Armed with a spear, we traverse the curve in a time shorter than that in which the lion can move his own length.

Topological Method
We observe that the lion has at least the connectivity of the torus. We transport the desert into four-space. It is then possible  to carry out such a deformation that the lion can be returned to three-space in a knotted condition. He is then helpless.

The Cauchy, or function theoretical, Method
We consider an analytic lion-valued function f(z). Let X be the cage. Consider the integral:
```        1/(2 * pi * i) integral over C of [f(z) / (z - X)]dz
```
where C is the boundary of the desert; its value is f(X), i.e., a lion in the cage.

The Dirac Method
We observe that wild lions are ipso facto not observable in the Sahara desert. Consequently, if there are any lions in the Sahara, then they are tame. The capture of a tame lion is left as an exercise for the reader.

The Thermodynamic Method
We construct a semi-permeable membrane which is permeable to everything except lions and sweep it across the desert.

The Wiener Tauberian method
We procure a tame lion, L0 of class L(-infinity, +infinity), whose Fourier transform nowhere vanishes, and release it in the desert. L0 then converges to our cage. By Wiener's General Tauberian Theorem, any other lion, L (say), will then converge to the same cage. Alternatively, we can approximate arbitrarily closely to L by translating L0 about the desert.

The Schrödinger Method
At any given moment there is a positive probability that there is a lion in the cage. Sit down and wait.

The Heisenberg Method
You will disturb the lion when you observe it before capturing. So keep your eyes closed.

The Einstein Method
Run in the direction opposite to that of the lion. The relative velocity makes the lion run faster and hence it feels heavier and gets tired.

Another Einstein Method
We distribute about the desert lion bait containing large portions of the Companion of Sirius. When enough bait has been taken, we project a beam of light across the desert. This will bend right around the lion, who will then become so dizzy that he can be approached with impunity.

The Magneto-Optical Method
We plant a large lenticular bed of catnip [Nepeta cataria], whose axis lies along the direction of the horizontal component as the earth's magnetic field, and place a cage at one of its foci. We distribute over the desert large quantities of magnetized spinach [Spinacia oleracea], which, as is well known, has a high ferric content. The spinach is eaten by the herbivorous denizens of the desert, which are in turn eaten by lions. the lions are then oriented parallel to the earth's magnetic field, and the resulting beam of lions is focused by the catnip upon the cage.

## 1 The search method

We assume that the lion is most likely to be found in the direction to the north of the point where we are standing. Therefore the REAL problem we have is that of speed, since we are only using a PC to solve the problem.

## 2 The parallel search method

By using parallelism we will be able to search in the direction to the north much faster than earlier.

## 3 The Monte-Carlo method

We pick a random number indexing the space we search. By excluding neighboring points in the search, we can drastically reduce the number of points we need to consider. The lion will according to probability appear sooner or later.

## 4 The practical approach

We see a rabbit very close to us. Since it is already dead, it is particularly easy to catch. We therefore catch it and call it a lion.

## 5 The common language approach.

If only everyone used ADA/Common Lisp/Prolog, this problem would be trivial to solve.

## 6 The standard approach

We know what a Lion is from ISO 4711/X.123. Since CCITT have specified a Lion to be a particular option of a cat we will have to wait for a harmonized standard to appear. \$20,000,000 have been funded for initial investigastions into this standard development.

## 7 Linear search

Stand in the top left hand corner of the Sahara Desert. Take one step east. Repeat until you have found the lion, or you reach the right hand edge. If you reach the right hand edge, take one step southwards, and proceed towards the left hand edge. When you finally reach the lion, put it the cage. If the lion should happen to eat you before you manage to get it in the cage, press the reset button, and try again.

## 8 The Dijkstra approach

The way the problem reached me was: catch a wild lion in the Sahara Desert. Another way of stating the problem is:

Axiom 1: Sahara elem deserts
Axiom 2: Lion elem Sahara
Axiom 3: NOT(Lion elem cage)

We observe the following invariant:

P1: C(L) v not(C(L))

where C(L) means: the value of "L" is in the cage.

Establishing C initially is trivially accomplished with the statement

;cage := {}

Note 0:

This is easily implemented by opening the door to the cage and shaking out any lions that happen to be there initially.
(End of note 0.)

The obvious program structure is then:

```        ;cage:={}
;do NOT (C(L)) ->
;"approach lion under invariance of P1"
;if P(L) ->
;"insert lion in cage"
[] not P(L) ->
;skip
;fi
;od
```

where P(L) means: the value of L is within arm's reach.

Note 1:
Axiom 2 esnures that the loop terminates.
(End of note 1.)

Exercise 0:
Refine the step "Approach lion under invariance of P1".
(End of exercise 0.)

Note 2:
The program is robust in the sense that it will lead to abortion if the value of L is "lioness".
(End of note 2.)

Remark 0:
This may be a new sense of the word "robust" for you.
(End of remark 0.)

Note 3:
From observation we can see that the above program leads to the desired goal. It goes without saying that we therefore do not have to run it.
(End of note 3.)
(End of approach.)

Thanks to Dushyanth Narayanan and Howard Cheng