Monday, April 28, 2008

Common ancestors

In small towns, it is usual that almost everybody is a distant cousin of almost everybody else. What are the kinship statistics of a closed, homogeneous, stable population? The answer depends on the population size, the fertility distribution and mating customs. We will set up some terminology and define a very simplistic population model. The treatment is formally loose as we talk about sets and sequences of sets where we should be dealing with random variables and stochastic processes.

We denote the mother and father of x by m(x) and f(x), respectively. y is an ancestor of x if y = x or y is an ancestor of m(x) or f(x). Given two individuals x and y, their kinship proximity k(x,y) is defined as:

  • if y is an ancestor of x or x is an ancestor of y, k(x,y) is the number of generations between x and y,
  • else, k(x,y) := min{k(a,x) + k(a,y) : a is a common ancestor of x and y}.

A population X is stratified if it can be decomposed into a disjoint family of subsets or generations {Xi: i integer} such that for every x in Xi, {f(x),m(x)} is included in Xi−1. We define the kinship distribution at generation i as

Ki(n) := P(k(x,y) = n), x, y in Xi, n = 0,1,2,...

where P stands for "probability". Note that the stratification of X implies that k(x,y) is always even when x and y belong to the same generation (because two individuals of the same generation are always at the same distance to their common ancestor), so Ki(n) = 0 if n is odd. X is a stable population if Ki(n) = Kj(n) for every i, j; in this case we denote the kinship distribution simply by K(n). Let us define the fertility distribution at generation i as the following function:

ri(n) := P(x has exactly n children), x is a woman in Xi, n = 0,1,2,...

X is said to be homogeneous if ri(n) = rj(n) for every i, j, in which case we simply write the unique fertility distribution as r(n).

We will study a very simplified model of population dynamics. So, we require that our population X have the following properties:

  • X is stratified, stable and homogeneous.
  • The median value of r(n) is 2, i.e. the population size does not change over time.
  • X is a strict monogamy, i.e. any two individuals have the same mother if and only if they have the same father.
  • Siblings do not mate. As for intergenerational incest, it is automatically ruled out by the stratified nature of X.

In a later entry we will explore X kinship distribution by means of computer simulation.

Thursday, April 24, 2008

Convexity in (Zn,L): results

I have written an implementation of the wavefront algorithm for (Z2,L). You will need Boost to compile it. The mode of usage is the same as the algorithm for (Z2,L1). The figure shows the L wavefront hulls for several sets, confront them with the corresponding L1 hulls.

Note that there is no particular inclusion relationship between L1 and L wavefronts hulls: some times Hwave,L1(X) is included in Hwave,L∞(X), some other times it is the other way around, and in a third class of situations neither hull is included in the other. The union of both hulls seems to yield results closer to our geometric, "round" intuition of what convexity must look like; the question remains whether this operation defines a valid convexity operator.

Sunday, April 20, 2008

Children and siblings

Suppose the fertility rate in a given society is R. If one makes a poll among the adult population asking for the number of siblings each person has, including themselves, the estimated number, let us call it S, will certainly not be R: for one, women without children are nobody's mothers, so they are not affecting the poll result, unlike in the calculation of R. The question arises, what is the relationship between R and S? As it turns out, S is not a simple function of the fertility rate, but it depends on the exact fertility distribution.

To simplify things, let us only deal with mother-to-children relationships, i.e. if we say that two persons are siblings we mean that they are born to the same mother. Let r(n) be the probability that an arbitrary woman has n children; the fertility rate R is then the expected value of the fertility distribution r(n), that is, R = ∑ n·r(n). We now define:

s(n) = P(an arbitrary individual has n siblings, including herself)

(P stands for "probability"). Let us calculate s(n). Suppose we have a group of M women who collectively will give birth to N individuals during their lifetimes. We have then:

N = ∑ n·r(nM = RM,

with the individuals being distributed as follows:

r(1)·M individuals with 1 sibling (counting themselves),
2·r(2)·M individuals with 2 siblings (counting themselves),
r(nM individuals with n siblings (counting themselves)...

So, s(n) is simply the number of individuals in the n-th group, divided by N:

s(n) = n·r(nM/N = n·r(n)/R.

And S, the expected value of s(n), is

S = ∑ n2·r(n)/R,

which expresses the relationship between r(n) and S that we were looking for. Using Cauchy's Inequality and the fact that ∑ r(n) = 1, we have:

R2 = (∑ n·r(n))2 = (∑ (n·√r(n)) · √r(n))2
≤ (∑ n2r(n))(∑ r(n)) = ∑ n2r(n),

hence S = ∑ n2·r(n)/RR for every possible r(n).

A particularly simple case arises when the fertility follows a Poisson distribution with r(n) = RneR/n!. Simple formula manipulations show that in this situation r(n) = s(n + 1); hence S = ∑n ≥ 1 n·s(n) = n ≥ 1 n·r(n − 1)= n ≥ 0 n·r(n) + ∑n ≥ 0 r(n) = R + 1. The figure depicts a Poisson-distributed r(n) with R = 2.1, along with its associated s(n).

Wednesday, April 16, 2008

Origami hummingbird diagrams

These are the folding instructions for the origami sword-billed hummingbird shown in a prior entry (click on the images to enlarge):

You can also download the instructions as a PDF document: hummingbird.pdf.

The model can use some improving: for instance, the corner tucked at step 1 is basically unused, and could be pulled out and employed to enhance the bird tail. This is left as a challenge to the reader.

Saturday, April 12, 2008

Almost sure colearning

In a prior entry we defined the act of colearning between agents A and B as a special mode of acquiring knowledge such that when some proposition φ is colearnt by A it follows that the fact "A knows φ" is colearnt by B, and viceversa. If A and B communicate through a reliable channel, i.e. they both know that each message from one to the other is guaranteed to get across, then implementing colearning is simple: when A gets to know φ, she just has to send a message to B informing of this fact.

If the channel is unreliable with probability 0 < P < 1 that each message is succesfully delivered, colearning cannot be achieved, but we can get almost sure colearning, i.e. colearning with probability one, with the only prerequisite that A and B behave in the following manner:

  1. Every message is sent over and over (with some arbitrary delay between sends) until an acknowledgement is received.
  2. An acknowledgement is always sent to every message received.
  3. The fact that A and B follow rules 1 and 2 is coknown by A and B.

So, we have turned an unreliable channel into an almost surely reliable channel where each message is delivered with probability one; this is not the same as a reliable channel, though.

Almost sure colearning is directly applicable to the two-army problem previously discussed: we can have the armies reach an agreement on when to make a joint attack with probability one. This is not in contradiction with the proved unsolvability of the original problem. In particular, almost sure colearning cannot be achieved in bounded time.

Tuesday, April 8, 2008

Convexity in (Zn,L)

After having studied our generalized convexity concept for (Zn,L1), we investigate now the L metric:

dist((x1,...,xn),(y1,...,yn)) := max{|yixi|}.

As we will see, the analysis is entirely analogous as that of (Zn,L1).

Theorem. (Zn,L) is regular.

Proof. Let X, Y in Zn such that BrXBrY, sr. Similarly as how we saw in the L1 case, we can assume without loss of generality that r and s are nonnegative integers. If x belongs to BsX \ BrX there exists some x' in X such that r < dist(x',x) = |xkx'k| ≤ s, for some k in {1,...,n}. Let x'' be the point defined by x''k = x'k + sign(xkx'k) r, x''i = x'i for ik. Then, dist(x',x'') = r, dist(x'',x) = dist(x',x) − rsr, hence x belongs to BsrBrX. Since by hypothesis BrXBrY, we conclude that x also belongs to BsrBrYBsY.

The role played in (Zn,L1) by the set of extreme points of Brx, Vrx = {x+i, xi: i = 1,...,n}, and by separating half-spaces of the form H = {y in Zn : σyk b}, with σ in {+1,−1}, is played in (Zn,L) by correlates of these structures. We state the theorems without proof as they follow the same lines as the equivalent propositions for (Zn,L1).

Definition. A point of Zn is said to be a ±1-vector if all its coordinates are either +1 or −1.

Definition. Let x be a point of Zn, r ≥ 0. Let Vrx = {x+rv: v is a ±1-vector}. Vrx is the set of extreme points of Brx.

Lemma. x is in Hwave(X) iff VmxBmX for some nonnegative integer m.

Definition. We say that a point p lies beside a half-space H = {x in Zn : xv b}, where v is a ±1-vector, if pvb and (p v)v < b and , i.e. pv is in [b,b+n).

Note that the points lying beside a half-space H = {x in Zn : xv b} include, but are not limited to, those with pv = b. The figure shows the situation for Z2. The key property of this definition is that any point x in H will intersect one and only one point lying beside H when drawing a ray starting from x along the the normal direction to H, v.

Theorem. Let X be a subset of Zn completely contained in some half-space H = {x in Zn : xv b}, where v is a ±1-vector, and p a point lying beside H. The points piv, 0≤i<dist(p,X), do not belong to Hwave(X).

Theorem. Let X be a bounded subset of Zn and x a point outside Hwave(X). There is then a ±1-vector v such that for any half-space H = {y in Zn : yv b} enclosing XU{x}, dist(x,p) < dist(p,X) where p lies beside H and is of the form x + kv for some k ≥ 0.

If in the waterfront hull algorithm for (Zn,L1) we traversed the boundary of an enclosing prism P, here we must work with an enclosing rhombic prism with each of its 2n faces lying at a hyperplane of the form π = {x in Zn : xv = b}, with v a ±1-vector.

wavefront hull(X)
{determine the minimum X-enclosing rhombic prism P}
PHi, Hi = {x in Zn : xvi bi}, vi is a ±1-vector, i = 1,...,2n
for i = 1 to 2n
for every p in P with p beside Hi and p in Hj, ji
········for k = 0 to dist(p,X) − 1
········end for
····end for
end for
{return the points of P that have not been marked}

In a later entry we will provide an implementation of the algorithm for Z2 and compare the results with the L1 case.

Friday, April 4, 2008

Origami hummingbird

I designed this very simple model during the past Easter holidays. The extremely long beak allows us to identify this specimen as a sword-billed hummingbird. When time permits, I will sketch the folding diagrams and publish them here.