Outline Kolmogorov Complexity Gambling
Information-Theoretic Modeling
Lecture 11: Further Topics
Jyrki Kivinen
Department of Computer Science, University of Helsinki
Autumn 2012
Outline Kolmogorov Complexity Gambling
Lecture 11: Further Topics
(Peter Falk asColumbo, NBC)
Outline Kolmogorov Complexity Gambling
1 Kolmogorov Complexity Definition
Basic Properties
2 Gambling
Gambler’s Ruin Kelly Criterion
Outline Kolmogorov Complexity Gambling
1 Kolmogorov Complexity Definition
Basic Properties
2 Gambling
Gambler’s Ruin Kelly Criterion
Outline Kolmogorov Complexity Gambling
Definition Basic Properties
Kolmogorov Complexity
We probably agree that the string
10101010101010101010. . .10
| {z }
10 million characters
is “simple”.
Why?
(One) Solution: The string has a short description:
“10 repeated 5 000 000 times”.
Remark: “Description” should be understood to mean a code that can be decoded by some algorithm (a formal procedure that halts).
Outline Kolmogorov Complexity Gambling
Definition Basic Properties
Kolmogorov Complexity
We probably agree that the string
10101010101010101010. . .10
| {z }
10 million characters
is “simple”.
Why?
(One) Solution: The string has a short description:
“10 repeated 5 000 000 times”.
Remark: “Description” should be understood to mean a code that can be decoded by some algorithm (a formal procedure that halts).
Outline Kolmogorov Complexity Gambling
Definition Basic Properties
Kolmogorov Complexity
We probably agree that the string
10101010101010101010. . .10
| {z }
10 million characters
is “simple”.
Why?
(One) Solution: The string has a short description:
“10 repeated 5 000 000 times”.
Remark: “Description” should be understood to mean a code that can be decoded by some algorithm (a formal procedure that halts).
Outline Kolmogorov Complexity Gambling
Definition Basic Properties
Turing machines
To precisely define Kolmogorov complexity we need to fix a formal notion of algorithm.
Following tradition, we use here Turing Machine (TM), but any other universal model of computation could be used as well. For simplicity, we assume that the inputs and outputs are strings over the binary alphabet{0,1}.
If TMU on input p ∈ {0,1}∗ halts and outputs x∈ {0,1}∗, we writeU(p) =x.
IfU does not halt on inputp, we say that U(p) in undefined and writeU(p) =∅.
We use|p|to denote the length of string x.
Outline Kolmogorov Complexity Gambling
Definition Basic Properties
Turing machines
To precisely define Kolmogorov complexity we need to fix a formal notion of algorithm.
Following tradition, we use here Turing Machine (TM), but any other universal model of computation could be used as well. For simplicity, we assume that the inputs and outputs are strings over the binary alphabet{0,1}.
If TMU on input p ∈ {0,1}∗ halts and outputs x∈ {0,1}∗, we writeU(p) =x.
IfU does not halt on inputp, we say that U(p) in undefined and writeU(p) =∅.
We use|p|to denote the length of string x.
Outline Kolmogorov Complexity Gambling
Definition Basic Properties
Turing machines
To precisely define Kolmogorov complexity we need to fix a formal notion of algorithm.
Following tradition, we use here Turing Machine (TM), but any other universal model of computation could be used as well. For simplicity, we assume that the inputs and outputs are strings over the binary alphabet{0,1}.
If TMU on input p ∈ {0,1}∗ halts and outputsx ∈ {0,1}∗, we writeU(p) =x.
IfU does not halt on inputp, we say that U(p) in undefined and writeU(p) =∅.
We use|p|to denote the length of stringx.
Outline Kolmogorov Complexity Gambling
Definition Basic Properties
Kolmogorov Complexity
Kolmogorov Complexity
TheKolmogorov complexity of stringx ∈ {0,1}∗ with respect to a Turing machineU is defined as the length of shortest input on whichU outputsx:
KU(x) = min{ |p| |U(p) =x} .
Notice thatKU(x) depends on our choice ofU, which at this stage is abritrary. However, we can remove most of this dependence by limiting the set of machinesU we consider.
Turing machine U is a prefix machineif the set of inputs on which U halts is prefix-free.
Turing machine U isuniversal if for any other TMV there is a stringqV such that V(p) =U(qvp) for allp ∈ {0,1}∗. Hereqp means concatenation of stringsq andp.
Outline Kolmogorov Complexity Gambling
Definition Basic Properties
Kolmogorov Complexity
Kolmogorov Complexity
TheKolmogorov complexity of stringx ∈ {0,1}∗ with respect to a Turing machineU is defined as the length of shortest input on whichU outputsx:
KU(x) = min{ |p| |U(p) =x} .
Notice thatKU(x) depends on our choice ofU, which at this stage is abritrary. However, we can remove most of this dependence by limiting the set of machinesU we consider.
Turing machine U is a prefix machineif the set of inputs on which U halts is prefix-free.
Turing machine U isuniversal if for any other TMV there is a stringqV such that V(p) =U(qvp) for allp ∈ {0,1}∗. Hereqp means concatenation of stringsq andp.
Outline Kolmogorov Complexity Gambling
Definition Basic Properties
Kolmogorov Complexity
Kolmogorov Complexity
TheKolmogorov complexity of stringx ∈ {0,1}∗ with respect to a Turing machineU is defined as the length of shortest input on whichU outputsx:
KU(x) = min{ |p| |U(p) =x} .
Notice thatKU(x) depends on our choice ofU, which at this stage is abritrary. However, we can remove most of this dependence by limiting the set of machinesU we consider.
Turing machine U is a prefix machineif the set of inputs on which U halts is prefix-free.
Turing machine U isuniversal if for any other TMV there is a stringqV such that V(p) =U(qvp) for allp ∈ {0,1}∗. Hereqp means concatenation of stringsq andp.
Outline Kolmogorov Complexity Gambling
Definition Basic Properties
Kolmogorov Complexity
Kolmogorov Complexity
TheKolmogorov complexity of stringx ∈ {0,1}∗ with respect to a Turing machineU is defined as the length of shortest input on whichU outputsx:
KU(x) = min{ |p| |U(p) =x} .
Notice thatKU(x) depends on our choice ofU, which at this stage is abritrary. However, we can remove most of this dependence by limiting the set of machinesU we consider.
Turing machine U is a prefix machineif the set of inputs on which U halts is prefix-free.
Turing machine U isuniversal if for any other TMV there is a stringqV such that V(p) =U(qvp) for all p ∈ {0,1}∗.
Hereqp means concatenation of stringsq andp.
Outline Kolmogorov Complexity Gambling
Definition Basic Properties
Kolmogorov Complexity
Kolmogorov Complexity
TheKolmogorov complexity of stringx ∈ {0,1}∗ with respect to a Turing machineU is defined as the length of shortest input on whichU outputsx:
KU(x) = min{ |p| |U(p) =x} .
Notice thatKU(x) depends on our choice ofU, which at this stage is abritrary. However, we can remove most of this dependence by limiting the set of machinesU we consider.
Turing machine U is a prefix machineif the set of inputs on which U halts is prefix-free.
Turing machine U isuniversal if for any other TMV there is a stringqV such that V(p) =U(qvp) for all p ∈ {0,1}∗. Hereqp means concatenation of stringsq andp.
Outline Kolmogorov Complexity Gambling
Definition Basic Properties
Prefix property in practice
Requiring prefix property may seem a bit technical, but intuitively it just means we must be able to tell when the input ends.
In practical programming, this is done by methods such as end-of-file markers, or having the operating system keep track of file lengths.
End-of-file markers actually are a way of keeping the input set prefix free. However reserving one symbol for this special use is not generally acceptable if we are interested in optimal code lengths. Theoretically more satisfying way to make a set of inputs
prefix-free is to include the lenght of (the rest of) the input string using some prefix code.
Outline Kolmogorov Complexity Gambling
Definition Basic Properties
Prefix property in practice
Requiring prefix property may seem a bit technical, but intuitively it just means we must be able to tell when the input ends.
In practical programming, this is done by methods such as end-of-file markers, or having the operating system keep track of file lengths.
End-of-file markers actually are a way of keeping the input set prefix free. However reserving one symbol for this special use is not generally acceptable if we are interested in optimal code lengths. Theoretically more satisfying way to make a set of inputs
prefix-free is to include the lenght of (the rest of) the input string using some prefix code.
Outline Kolmogorov Complexity Gambling
Definition Basic Properties
Prefix property in practice
Requiring prefix property may seem a bit technical, but intuitively it just means we must be able to tell when the input ends.
In practical programming, this is done by methods such as end-of-file markers, or having the operating system keep track of file lengths.
End-of-file markers actually are a way of keeping the input set prefix free. However reserving one symbol for this special use is not generally acceptable if we are interested in optimal code lengths.
Theoretically more satisfying way to make a set of inputs
prefix-free is to include the lenght of (the rest of) the input string using some prefix code.
Outline Kolmogorov Complexity Gambling
Definition Basic Properties
Prefix property in practice
Requiring prefix property may seem a bit technical, but intuitively it just means we must be able to tell when the input ends.
In practical programming, this is done by methods such as end-of-file markers, or having the operating system keep track of file lengths.
End-of-file markers actually are a way of keeping the input set prefix free. However reserving one symbol for this special use is not generally acceptable if we are interested in optimal code lengths.
Theoretically more satisfying way to make a set of inputs
prefix-free is to include the lenght of (the rest of) the input string using some prefix code.
Outline Kolmogorov Complexity Gambling
Definition Basic Properties
Prefix code for integers
A straighforward prefix code for integers is the following:
Consider integerx with n bit binary representationx1x2x3. . .xn. We encodex asx1x1x2x2x3x3. . .xnxn01.
We denode this code forx byhxi.
For example, forx = 19 = 100112 we gethxi= 110000111101. The lenght of the prefix-free encoding is| hxi |= 2n+ 2 bits, wheren=dlog2(x+ 1)e ≤log2x+ 1 is the length of the original binary representation.
Outline Kolmogorov Complexity Gambling
Definition Basic Properties
Prefix code for integers
A straighforward prefix code for integers is the following:
Consider integerx with n bit binary representationx1x2x3. . .xn. We encodex asx1x1x2x2x3x3. . .xnxn01.
We denode this code forx byhxi.
For example, forx = 19 = 100112 we gethxi= 110000111101.
The lenght of the prefix-free encoding is| hxi |= 2n+ 2 bits, wheren=dlog2(x+ 1)e ≤log2x+ 1 is the length of the original binary representation.
Outline Kolmogorov Complexity Gambling
Definition Basic Properties
Prefix code for integers
A straighforward prefix code for integers is the following:
Consider integerx with n bit binary representationx1x2x3. . .xn. We encodex asx1x1x2x2x3x3. . .xnxn01.
We denode this code forx byhxi.
For example, forx = 19 = 100112 we gethxi= 110000111101.
The lenght of the prefix-free encoding is| hxi |= 2n+ 2 bits, wheren=dlog2(x+ 1)e ≤log2x+ 1 is the length of the original binary representation.
Outline Kolmogorov Complexity Gambling
Definition Basic Properties
Prefix property for Turing Machines
We can now make the set of inputs prefix-free by inserting before each inputx its length encoded ash|x|i.
For example, input 1000100101101, which has 13 bits, becomes 1111001101
| {z }
code for 13 = 11012
1000100101101
| {z }
actual input
.
More generally, an input ofn bits gets code length of at most n+ 2 log2n+ 2 bits.
For largen this is much better than 2n+ 2 we would get by applying the prefix-free encoding from previous slide directly tox. To summarize, the prefix property is reasonable from a practical point of view, and from a theoretical point of view can be assumed without increasing input lengths too much.
Outline Kolmogorov Complexity Gambling
Definition Basic Properties
Prefix property for Turing Machines
We can now make the set of inputs prefix-free by inserting before each inputx its length encoded ash|x|i.
For example, input 1000100101101, which has 13 bits, becomes 1111001101
| {z }
code for 13 = 11012
1000100101101
| {z }
actual input
.
More generally, an input ofn bits gets code length of at most n+ 2 log2n+ 2 bits.
For largen this is much better than 2n+ 2 we would get by applying the prefix-free encoding from previous slide directly tox. To summarize, the prefix property is reasonable from a practical point of view, and from a theoretical point of view can be assumed without increasing input lengths too much.
Outline Kolmogorov Complexity Gambling
Definition Basic Properties
Prefix property for Turing Machines
We can now make the set of inputs prefix-free by inserting before each inputx its length encoded ash|x|i.
For example, input 1000100101101, which has 13 bits, becomes 1111001101
| {z }
code for 13 = 11012
1000100101101
| {z }
actual input
.
More generally, an input ofn bits gets code length of at most n+ 2 log2n+ 2 bits.
For largen this is much better than 2n+ 2 we would get by applying the prefix-free encoding from previous slide directly tox. To summarize, the prefix property is reasonable from a practical point of view, and from a theoretical point of view can be assumed without increasing input lengths too much.
Outline Kolmogorov Complexity Gambling
Definition Basic Properties
Prefix property for Turing Machines
We can now make the set of inputs prefix-free by inserting before each inputx its length encoded ash|x|i.
For example, input 1000100101101, which has 13 bits, becomes 1111001101
| {z }
code for 13 = 11012
1000100101101
| {z }
actual input
.
More generally, an input ofn bits gets code length of at most n+ 2 log2n+ 2 bits.
For largen this is much better than 2n+ 2 we would get by applying the prefix-free encoding from previous slide directly tox.
To summarize, the prefix property is reasonable from a practical point of view, and from a theoretical point of view can be assumed without increasing input lengths too much.
Outline Kolmogorov Complexity Gambling
Definition Basic Properties
Prefix property for Turing Machines
We can now make the set of inputs prefix-free by inserting before each inputx its length encoded ash|x|i.
For example, input 1000100101101, which has 13 bits, becomes 1111001101
| {z }
code for 13 = 11012
1000100101101
| {z }
actual input
.
More generally, an input ofn bits gets code length of at most n+ 2 log2n+ 2 bits.
For largen this is much better than 2n+ 2 we would get by applying the prefix-free encoding from previous slide directly tox.
To summarize, the prefix property is reasonable from a practical point of view, and from a theoretical point of view can be assumed without increasing input lengths too much.
Outline Kolmogorov Complexity Gambling
Definition Basic Properties
Universal Turing Machines
For any fixedx, there are Turing machines that output x with empty input, and other Turing machines that don’t outputx with any input.
Similarly, for any pair of different stringsx 6=y, there are Turing machines U andV such thatKU(x)KU(y) but
KV(x)KV(y).
For comparisons of Kolmogorov complexities to be meaningful, we requireU to beuniversal.
Outline Kolmogorov Complexity Gambling
Definition Basic Properties
Universal Turing Machines
For any fixedx, there are Turing machines that output x with empty input, and other Turing machines that don’t outputx with any input.
Similarly, for any pair of different stringsx 6=y, there are Turing machinesU andV such thatKU(x)KU(y) but
KV(x)KV(y).
For comparisons of Kolmogorov complexities to be meaningful, we requireU to beuniversal.
Outline Kolmogorov Complexity Gambling
Definition Basic Properties
Universal Turing Machines
For any fixedx, there are Turing machines that output x with empty input, and other Turing machines that don’t outputx with any input.
Similarly, for any pair of different stringsx 6=y, there are Turing machinesU andV such thatKU(x)KU(y) but
KV(x)KV(y).
For comparisons of Kolmogorov complexities to be meaningful, we requireU to beuniversal.
Outline Kolmogorov Complexity Gambling
Definition Basic Properties
Universal Turing Machines
Universality
A Turing MachineU is said to be universal, if forany other Turing MachineV there is a string qV ∈ {0,1}∗ (which depends onV) such that for all stringsp we have
U(qVp) =V(p) .
That is when given the concatenated inputqp, TMU outputs the same string as TMV when given inputp.
If we think of stringsp as programs in the “machine language” of V, then qv is an “interpreter” or “compiler” for V’s machine language, written for machineU (in the machine language ofU).
Outline Kolmogorov Complexity Gambling
Definition Basic Properties
Universal Turing Machines
Universality
A Turing MachineU is said to be universal, if forany other Turing MachineV there is a string qV ∈ {0,1}∗ (which depends onV) such that for all stringsp we have
U(qVp) =V(p) .
That is when given the concatenated inputqp, TMU outputs the same string as TMV when given inputp.
If we think of stringsp as programs in the “machine language” of V, then qv is an “interpreter” or “compiler” for V’s machine language, written for machineU (in the machine language ofU).
Outline Kolmogorov Complexity Gambling
Definition Basic Properties
Examples
Examples of (virtually) universal ‘computers’:
1 C (compiler + operating system + computer),
2 Java (compiler + operating system + computer),
3 your favorite programming language (compiler/interpreter + OS + computer),
4 Universal Turing machine,
5 Universal recursive function,
6 Lambda calculus,
7 Arithmetics,
8 Game of Life
9 ...
Each of the above can mimic all the others.
Outline Kolmogorov Complexity Gambling
Definition Basic Properties
Examples
Examples of (virtually) universal ‘computers’:
1 C (compiler + operating system + computer),
2 Java (compiler + operating system + computer),
3 your favorite programming language (compiler/interpreter + OS + computer),
4 Universal Turing machine,
5 Universal recursive function,
6 Lambda calculus,
7 Arithmetics,
8 Game of Life
9 ...
Each of the above can mimic all the others.
Outline Kolmogorov Complexity Gambling
Definition Basic Properties
Examples
Examples of (virtually) universal ‘computers’:
1 C (compiler + operating system + computer),
2 Java (compiler + operating system + computer),
3 your favorite programming language (compiler/interpreter + OS + computer),
4 Universal Turing machine,
5 Universal recursive function,
6 Lambda calculus,
7 Arithmetics,
8 Game of Life
9 ...
Each of the above can mimic all the others.
Outline Kolmogorov Complexity Gambling
Definition Basic Properties
Examples
Examples of (virtually) universal ‘computers’:
1 C (compiler + operating system + computer),
2 Java (compiler + operating system + computer),
3 your favorite programming language (compiler/interpreter + OS + computer),
4 Universal Turing machine,
5 Universal recursive function,
6 Lambda calculus,
7 Arithmetics,
8 Game of Life
9 ...
Each of the above can mimic all the others.
Outline Kolmogorov Complexity Gambling
Definition Basic Properties
Examples
Examples of (virtually) universal ‘computers’:
1 C (compiler + operating system + computer),
2 Java (compiler + operating system + computer),
3 your favorite programming language (compiler/interpreter + OS + computer),
4 Universal Turing machine,
5 Universal recursive function,
6 Lambda calculus,
7 Arithmetics,
8 Game of Life
9 ...
Each of the above can mimic all the others.
Outline Kolmogorov Complexity Gambling
Definition Basic Properties
Examples
Examples of (virtually) universal ‘computers’:
1 C (compiler + operating system + computer),
2 Java (compiler + operating system + computer),
3 your favorite programming language (compiler/interpreter + OS + computer),
4 Universal Turing machine,
5 Universal recursive function,
6 Lambda calculus,
7 Arithmetics,
8 Game of Life
9 ...
Each of the above can mimic all the others.
Outline Kolmogorov Complexity Gambling
Definition Basic Properties
Examples
Examples of (virtually) universal ‘computers’:
1 C (compiler + operating system + computer),
2 Java (compiler + operating system + computer),
3 your favorite programming language (compiler/interpreter + OS + computer),
4 Universal Turing machine,
5 Universal recursive function,
6 Lambda calculus,
7 Arithmetics,
8 Game of Life
9 ...
Each of the above can mimic all the others.
Outline Kolmogorov Complexity Gambling
Definition Basic Properties
Examples
Examples of (virtually) universal ‘computers’:
1 C (compiler + operating system + computer),
2 Java (compiler + operating system + computer),
3 your favorite programming language (compiler/interpreter + OS + computer),
4 Universal Turing machine,
5 Universal recursive function,
6 Lambda calculus,
7 Arithmetics,
8 Game of Life
9 ...
Each of the above can mimic all the others.
Outline Kolmogorov Complexity Gambling
Definition Basic Properties
Examples
Examples of (virtually) universal ‘computers’:
1 C (compiler + operating system + computer),
2 Java (compiler + operating system + computer),
3 your favorite programming language (compiler/interpreter + OS + computer),
4 Universal Turing machine,
5 Universal recursive function,
6 Lambda calculus,
7 Arithmetics,
8 Game of Life
9 ...
Each of the above can mimic all the others.
Outline Kolmogorov Complexity Gambling
Definition Basic Properties
Examples
Examples of (virtually) universal ‘computers’:
1 C (compiler + operating system + computer),
2 Java (compiler + operating system + computer),
3 your favorite programming language (compiler/interpreter + OS + computer),
4 Universal Turing machine,
5 Universal recursive function,
6 Lambda calculus,
7 Arithmetics,
8 Game of Life
9 ...
Each of the above can mimic all the others.
Outline Kolmogorov Complexity Gambling
Definition Basic Properties
Examples
Examples of (virtually) universal ‘computers’:
1 C (compiler + operating system + computer),
2 Java (compiler + operating system + computer),
3 your favorite programming language (compiler/interpreter + OS + computer),
4 Universal Turing machine,
5 Universal recursive function,
6 Lambda calculus,
7 Arithmetics,
8 Game of Life
9 ...
Each of the above can mimic all the others.
Outline Kolmogorov Complexity Gambling
Definition Basic Properties
Kolmogorov Complexity
For anyuniversalcomputer U, and any other computerV, we have KU(x)≤KV(x) +C ,
whereC is a constant independent ofx.
Proof: Let qV be such thatU(qVp) =V(p) for all p. Letp∗V(x) be the shortest program for which V(pV∗(x)) =x. Then
U(qVp∗V(x)) =x, so
KU(x)≤ |qVp∗V(x)|=|pV∗(x)|+|qV|=KV(x) +|qV| . Since we are restricting ourselves to prefix machines, we don’t need to worry about any overhead caused by encoding the pair (qV,p), we can just concatenate them.
Outline Kolmogorov Complexity Gambling
Definition Basic Properties
Kolmogorov Complexity
For anyuniversalcomputer U, and any other computerV, we have KU(x)≤KV(x) +C ,
whereC is a constant independent ofx.
Proof: Let qV be such thatU(qVp) =V(p) for all p. Letp∗V(x) be the shortest program for whichV(p∗V(x)) =x. Then
U(qVp∗V(x)) =x, so
KU(x)≤ |qVp∗V(x)|=|p∗V(x)|+|qV|=KV(x) +|qV| .
Since we are restricting ourselves to prefix machines, we don’t need to worry about any overhead caused by encoding the pair (qV,p), we can just concatenate them.
Outline Kolmogorov Complexity Gambling
Definition Basic Properties
Kolmogorov Complexity
For anyuniversalcomputer U, and any other computerV, we have KU(x)≤KV(x) +C ,
whereC is a constant independent ofx.
Proof: Let qV be such thatU(qVp) =V(p) for all p. Letp∗V(x) be the shortest program for whichV(p∗V(x)) =x. Then
U(qVp∗V(x)) =x, so
KU(x)≤ |qVp∗V(x)|=|p∗V(x)|+|qV|=KV(x) +|qV| . Since we are restricting ourselves to prefix machines, we don’t need to worry about any overhead caused by encoding the pair (qV,p), we can just concatenate them.
Outline Kolmogorov Complexity Gambling
Definition Basic Properties
Invariance Theorem
From now on we restrict the choice of the computerU in KU to universalcomputers.
Invariance Theorem
Kolmogorov complexity is invariant (up to an additive constant) under a change of the universal computer. In other words, for any two universal computers,U andV, there is a constantC such that
|KU(x)−KV(x)| ≤C for all x ∈ {0,1}∗ .
Proof: Since U is universal, we have KU(x)≤KV(x) +C1. Since V is universal, we haveKV(x)≤KU(x) +C2. The theorem follows by settingC = max{C1,C2}.
Outline Kolmogorov Complexity Gambling
Definition Basic Properties
Invariance Theorem
From now on we restrict the choice of the computerU in KU to universalcomputers.
Invariance Theorem
Kolmogorov complexity is invariant (up to an additive constant) under a change of the universal computer. In other words, for any two universal computers,U andV, there is a constantC such that
|KU(x)−KV(x)| ≤C for all x ∈ {0,1}∗ .
Proof: Since U is universal, we have KU(x)≤KV(x) +C1. Since V is universal, we haveKV(x)≤KU(x) +C2. The theorem follows by settingC = max{C1,C2}.
Outline Kolmogorov Complexity Gambling
Definition Basic Properties
Invariance Theorem
From now on we restrict the choice of the computerU in KU to universalcomputers.
Invariance Theorem
Kolmogorov complexity is invariant (up to an additive constant) under a change of the universal computer. In other words, for any two universal computers,U andV, there is a constantC such that
|KU(x)−KV(x)| ≤C for all x ∈ {0,1}∗ .
Proof: Since U is universal, we have KU(x)≤KV(x) +C1. Since V is universal, we haveKV(x)≤KU(x) +C2. The theorem follows by settingC = max{C1,C2}.
Outline Kolmogorov Complexity Gambling
Definition Basic Properties
Kolmogorov Complexity
Upper Bound
We have the following upper bound onKU(x):
KU(x)≤ |x|+ 2 log2|x|+C
for some constantC which depends on the computerU but not on the stringx.
Proof: Remember that we have a prefix code where the code length forx is
`(x) =|x|+ 2 log2|x|+ 2.
LetV be a TM that decodes this encoding. Then KV(x) =`(x). Therefore, for universalU we haveKU(x)≤`(x) +C.
Outline Kolmogorov Complexity Gambling
Definition Basic Properties
Kolmogorov Complexity
Upper Bound
We have the following upper bound onKU(x):
KU(x)≤ |x|+ 2 log2|x|+C
for some constantC which depends on the computerU but not on the stringx.
Proof: Remember that we have a prefix code where the code length forx is
`(x) =|x|+ 2 log2|x|+ 2.
LetV be a TM that decodes this encoding. Then KV(x) =`(x).
Therefore, for universalU we haveKU(x)≤`(x) +C.
Outline Kolmogorov Complexity Gambling
Definition Basic Properties
Kolmogorov Complexity
Conditional Kolmogorov Complexity
Theconditional Kolmogorov complexityis defined as the length of the shortest program to printx when y is given:
KU(x|y) = min{ |p| |U(¯y p) =x} , where ¯y is a prefix-encoded representation ofy.
Upper Bound 2
We have the following upper bound onKU(x | |x|): KU(x | |x|)≤ |x|+C for some constantC independentx.
Outline Kolmogorov Complexity Gambling
Definition Basic Properties
Kolmogorov Complexity
Conditional Kolmogorov Complexity
Theconditional Kolmogorov complexityis defined as the length of the shortest program to printx when y is given:
KU(x|y) = min{ |p| |U(¯y p) =x} , where ¯y is a prefix-encoded representation ofy. Upper Bound 2
We have the following upper bound onKU(x | |x|):
KU(x | |x|)≤ |x|+C for some constantC independentx.
Outline Kolmogorov Complexity Gambling
Definition Basic Properties
Examples
Letn=|x|.
1 KU(0101010101...01|n) =C. Program: print n/2 times 01.
2 KU(π1π2 . . . πn|n) =C.
Program: print the first n bits of π.
3 KU(English text|n)≈1.3×n+C. Program: Huffman code.
(Entropy of English is about 1.3 bits per symbol.)
4 KU(fractal) =C.
Program: print # of iterations until zn+1=zn2+c >T.
Outline Kolmogorov Complexity Gambling
Definition Basic Properties
Examples
Letn=|x|.
1 KU(0101010101...01|n) =C. Program: print n/2 times 01.
2 KU(π1π2 . . . πn|n) =C.
Program: print the first n bits of π.
3 KU(English text|n)≈1.3×n+C. Program: Huffman code.
(Entropy of English is about 1.3 bits per symbol.)
4 KU(fractal) =C.
Program: print # of iterations until zn+1=zn2+c >T.
Outline Kolmogorov Complexity Gambling
Definition Basic Properties
Examples
Letn=|x|.
1 KU(0101010101...01|n) =C. Program: print n/2 times 01.
2 KU(π1π2 . . . πn|n) =C.
Program: print the first n bits of π.
3 KU(English text|n)≈1.3×n+C. Program: Huffman code.
(Entropy of English is about 1.3 bits per symbol.)
4 KU(fractal) =C.
Program: print # of iterations until zn+1=zn2+c >T.
Outline Kolmogorov Complexity Gambling
Definition Basic Properties
Examples
Letn=|x|.
1 KU(0101010101...01|n) =C. Program: print n/2 times 01.
2 KU(π1π2 . . . πn|n) =C.
Program: print the first n bits of π.
3 KU(English text|n)≈1.3×n+C. Program: Huffman code.
(Entropy of English is about 1.3 bits per symbol.)
4 KU(fractal) =C.
Program: print # of iterations until zn+1=zn2+c >T.
Outline Kolmogorov Complexity Gambling
Definition Basic Properties
Examples
Letn=|x|.
1 KU(0101010101...01|n) =C. Program: print n/2 times 01.
2 KU(π1π2 . . . πn|n) =C.
Program: print the first n bits of π.
3 KU(English text|n)≈1.3×n+C. Program: Huffman code.
(Entropy of English is about 1.3 bits per symbol.)
4 KU(fractal) =C.
Program: print # of iterations until zn+1=zn2+c >T.
Outline Kolmogorov Complexity Gambling
Definition Basic Properties
Examples
Outline Kolmogorov Complexity Gambling
Definition Basic Properties
Martin-L¨ of Randomness
Examples (contd.):
5 KU(x |n)≈n, for almost allx ∈ {0,1}n.
Proof: Upper bound KU(x |n)≤n+C. Lower bound by a counting argument: less than 2−k of strings compressible by more thank bits (Lecture 1).
Martin-L¨of Randomness
Stringx is said to beMartin-L¨of randomiff Ku(x|n)≥n. Consequence of point 5 above: An i.i.d. sequence of unbiased coin flips is with high probability Martin-L¨of random.
Outline Kolmogorov Complexity Gambling
Definition Basic Properties
Martin-L¨ of Randomness
Examples (contd.):
5 KU(x |n)≈n, for almost allx ∈ {0,1}n.
Proof: Upper bound KU(x |n)≤n+C. Lower bound by a counting argument: less than 2−k of strings compressible by more thank bits (Lecture 1).
Martin-L¨of Randomness
Stringx is said to beMartin-L¨of randomiff Ku(x|n)≥n. Consequence of point 5 above: An i.i.d. sequence of unbiased coin flips is with high probability Martin-L¨of random.
Outline Kolmogorov Complexity Gambling
Definition Basic Properties
Martin-L¨ of Randomness
Examples (contd.):
5 KU(x |n)≈n, for almost allx ∈ {0,1}n.
Proof: Upper bound KU(x |n)≤n+C. Lower bound by a counting argument: less than 2−k of strings compressible by more thank bits (Lecture 1).
Martin-L¨of Randomness
Stringx is said to beMartin-L¨of randomiff Ku(x|n)≥n.
Consequence of point 5 above: An i.i.d. sequence of unbiased coin flips is with high probability Martin-L¨of random.
Outline Kolmogorov Complexity Gambling
Definition Basic Properties
Martin-L¨ of Randomness
Examples (contd.):
5 KU(x |n)≈n, for almost allx ∈ {0,1}n.
Proof: Upper bound KU(x |n)≤n+C. Lower bound by a counting argument: less than 2−k of strings compressible by more thank bits (Lecture 1).
Martin-L¨of Randomness
Stringx is said to beMartin-L¨of randomiff Ku(x|n)≥n.
Consequence of point 5 above: An i.i.d. sequence of unbiased coin flips is with high probability Martin-L¨of random.
Outline Kolmogorov Complexity Gambling
Definition Basic Properties
Universal Prediction
Since the set of valid (halting) programs is required to be prefix-freewe can consider the probability distributionpnU:
pnU(x) = 2−KU(x|n)
C , whereC = X
x∈Xn
2−KU(x|n).
Universal Probability Distribution
The distributionpUn is universal in the sense that for any other computable distributionq, there is a constantC >0 such that
pUn(x)≥C q(x) for allx ∈ Xn. Proof idea: The universal computerU can imitate the Shannon-Fano prefix code with codelengths
log2 1 q(x)
.
Outline Kolmogorov Complexity Gambling
Definition Basic Properties
Universal Prediction
Since the set of valid (halting) programs is required to be prefix-freewe can consider the probability distributionpnU:
pnU(x) = 2−KU(x|n)
C , whereC = X
x∈Xn
2−KU(x|n).
Universal Probability Distribution
The distributionpUn is universal in the sense that for any other computable distributionq, there is a constantC >0 such that
pUn(x)≥C q(x) for allx ∈ Xn.
Proof idea: The universal computerU can imitate the Shannon-Fano prefix code with codelengths
log2 1 q(x)
.
Outline Kolmogorov Complexity Gambling
Definition Basic Properties
Universal Prediction
Since the set of valid (halting) programs is required to be prefix-freewe can consider the probability distributionpnU:
pnU(x) = 2−KU(x|n)
C , whereC = X
x∈Xn
2−KU(x|n).
Universal Probability Distribution
The distributionpUn is universal in the sense that for any other computable distributionq, there is a constantC >0 such that
pUn(x)≥C q(x) for allx ∈ Xn. Proof idea: The universal computerU can imitate the Shannon-Fano prefix code with codelengths
log2 1 q(x)
.
Outline Kolmogorov Complexity Gambling
Definition Basic Properties
Universal Prediction
The universal probability distributionpnU is a good predictor.
This follows from the relationship between codelengths and probabilities (Kraft!):
KU(x) is small ⇒ pUn(x) is large
⇒
n
Y
i=1
pUn(xi |x1, . . . ,xi−1) is large
⇒ pnU(xi |x1, . . . ,xi−1) is large for most i ∈ {1, . . . ,n}, wherexi denotes theith bit in stringx.
Outline Kolmogorov Complexity Gambling
Definition Basic Properties
Universal Prediction
The universal probability distributionpnU is a good predictor.
This follows from the relationship between codelengths and probabilities (Kraft!):
KU(x) is small ⇒ pUn(x) is large
⇒
n
Y
i=1
pUn(xi |x1, . . . ,xi−1) is large
⇒ pnU(xi |x1, . . . ,xi−1) is large for most i ∈ {1, . . . ,n}, wherexi denotes theith bit in stringx.
Outline Kolmogorov Complexity Gambling
Definition Basic Properties
Universal Prediction
The universal probability distributionpnU is a good predictor.
This follows from the relationship between codelengths and probabilities (Kraft!):
KU(x) is small ⇒ pUn(x) is large
⇒
n
Y
i=1
pUn(xi |x1, . . . ,xi−1) is large
⇒ pnU(xi |x1, . . . ,xi−1) is large for most i ∈ {1, . . . ,n}, wherexi denotes theith bit in stringx.
Outline Kolmogorov Complexity Gambling
Definition Basic Properties
Universal Prediction
The universal probability distributionpnU is a good predictor.
This follows from the relationship between codelengths and probabilities (Kraft!):
KU(x) is small ⇒ pUn(x) is large
⇒
n
Y
i=1
pUn(xi |x1, . . . ,xi−1) is large
⇒ pUn(xi |x1, . . . ,xi−1) is large for most i ∈ {1, . . . ,n}, wherexi denotes theith bit in stringx.
Outline Kolmogorov Complexity Gambling
Definition Basic Properties
Berry Paradox
The smallest integer that cannot be described in ten words?
Whatever this number is, we have just described (?) it in ten words.
The smallest uninteresting number?
Whatever this number is, it is quite interesting!
Outline Kolmogorov Complexity Gambling
Definition Basic Properties
Berry Paradox
The smallest integer that cannot be described in ten words?
Whatever this number is, we have just described (?) it in ten words.
The smallest uninteresting number?
Whatever this number is, it is quite interesting!
Outline Kolmogorov Complexity Gambling
Definition Basic Properties
Berry Paradox
The smallest integer that cannot be described in ten words?
Whatever this number is, we have just described (?) it in ten words.
The smallest uninteresting number?
Whatever this number is, it is quite interesting!
Outline Kolmogorov Complexity Gambling
Definition Basic Properties
Berry Paradox
The smallest integer that cannot be described in ten words?
Whatever this number is, we have just described (?) it in ten words.
The smallest uninteresting number?
Whatever this number is, it is quite interesting!
Outline Kolmogorov Complexity Gambling
Definition Basic Properties
Non-computability
It is impossible to construct a general procedure (algorithm) to computeKU(x).
Non-Computability
Kolmogorov complexityKU : {0,1}∗→Nis non-computable.
Proof: Assume, by way of contradiction, that it would be possible to computeKU(x). Then for anyM >0, the program
print a string x for which KU(x)>M.
would print a string withKU(x)>M. A contradiction follows by lettingM be larger than the Kolmogorov complexity of this program. Hence, it cannot be possible to computeKU(x).
Outline Kolmogorov Complexity Gambling
Definition Basic Properties
Non-computability
It is impossible to construct a general procedure (algorithm) to computeKU(x).
Non-Computability
Kolmogorov complexityKU : {0,1}∗→Nis non-computable.
Proof: Assume, by way of contradiction, that it would be possible to computeKU(x).
Then for any M >0, the program print a string x for which KU(x)>M.
would print a string withKU(x)>M. A contradiction follows by lettingM be larger than the Kolmogorov complexity of this program. Hence, it cannot be possible to computeKU(x).
Outline Kolmogorov Complexity Gambling
Definition Basic Properties
Non-computability
It is impossible to construct a general procedure (algorithm) to computeKU(x).
Non-Computability
Kolmogorov complexityKU : {0,1}∗→Nis non-computable.
Proof: Assume, by way of contradiction, that it would be possible to computeKU(x). Then for anyM >0, the program
print a string x for which KU(x)>M. would print a string withKU(x)>M.
A contradiction follows by lettingM be larger than the Kolmogorov complexity of this program. Hence, it cannot be possible to computeKU(x).
Outline Kolmogorov Complexity Gambling
Definition Basic Properties
Non-computability
It is impossible to construct a general procedure (algorithm) to computeKU(x).
Non-Computability
Kolmogorov complexityKU : {0,1}∗→Nis non-computable.
Proof: Assume, by way of contradiction, that it would be possible to computeKU(x). Then for anyM >0, the program
print a string x for which KU(x)>M.
would print a string withKU(x)>M. A contradiction follows by lettingM be larger than the Kolmogorov complexity of this program. Hence, it cannot be possible to computeKU(x).
Outline Kolmogorov Complexity Gambling
Definition Basic Properties
Summary: Kolmogorov complexity and MDL
Universal codes (or models) in MDL were defined to be universal with respect tosome model classM, which from an application point of view is “user-specified”.
There are universal codes with respect to quite general model classes (such as Lempel-Ziv for finite-order Markov models), but still this may feel a bit unsatisfactory from a philosophical point of view.
Kolmogorov complexity gives a code that is universal with respect to any computable model class, which seems the best we can hope for.
Outline Kolmogorov Complexity Gambling
Definition Basic Properties
Summary: Kolmogorov complexity and MDL
Universal codes (or models) in MDL were defined to be universal with respect tosome model classM, which from an application point of view is “user-specified”.
There are universal codes with respect to quite general model classes (such as Lempel-Ziv for finite-order Markov models), but still this may feel a bit unsatisfactory from a philosophical point of view.
Kolmogorov complexity gives a code that is universal with respect to any computable model class, which seems the best we can hope for.
Outline Kolmogorov Complexity Gambling
Definition Basic Properties
Summary: Kolmogorov complexity and MDL
Universal codes (or models) in MDL were defined to be universal with respect tosome model classM, which from an application point of view is “user-specified”.
There are universal codes with respect to quite general model classes (such as Lempel-Ziv for finite-order Markov models), but still this may feel a bit unsatisfactory from a philosophical point of view.
Kolmogorov complexity gives a code that is universal with respect to any computable model class, which seems the best we can hope for.
Outline Kolmogorov Complexity Gambling
Definition Basic Properties
Summary: Kolmogorov complexity and MDL
Unfortunately Kolmogorov complexity itself is not computable, limiting its applicability in practive. However Kolmogorov complexity is useful as an idealization and for understanding our limitations.
One should also remember that even in principle, Kolmogorov complexity is defined only up to an additive constant (depending on the choice ofU).
Outline Kolmogorov Complexity Gambling
Definition Basic Properties
Summary: Kolmogorov complexity and MDL
Unfortunately Kolmogorov complexity itself is not computable, limiting its applicability in practive. However Kolmogorov complexity is useful as an idealization and for understanding our limitations.
One should also remember that even in principle, Kolmogorov complexity is defined only up to an additive constant (depending on the choice ofU).
Outline Kolmogorov Complexity Gambling
Gambler’s Ruin Kelly Criterion
1 Kolmogorov Complexity Definition
Basic Properties
2 Gambling
Gambler’s Ruin Kelly Criterion
Outline Kolmogorov Complexity Gambling
Gambler’s Ruin Kelly Criterion
Gambling
Bet moneybx on horsex. Get moneyαxbx ifx wins (odds). Expected winE[bxαx] =P
pxαxbx.
Maximized by betting everything on arg maxpxαx.
Outline Kolmogorov Complexity Gambling
Gambler’s Ruin Kelly Criterion
Gambling
Bet moneybx on horsex. Get money αxbx ifx wins (odds).
Expected winE[bxαx] =P
pxαxbx.
Maximized by betting everything on arg maxpxαx.
Outline Kolmogorov Complexity Gambling
Gambler’s Ruin Kelly Criterion
Gambling
Bet moneybx on horsex. Get money αxbx ifx wins (odds).
Expected winE[bxαx] =P
pxαxbx.
Maximized by betting everything on arg maxpxαx.
Outline Kolmogorov Complexity Gambling
Gambler’s Ruin Kelly Criterion
Gambling
Bet moneybx on horsex. Get money αxbx ifx wins (odds).
Expected winE[bxαx] =P
pxαxbx.
Maximized by betting everything on arg maxpxαx.
Outline Kolmogorov Complexity Gambling
Gambler’s Ruin Kelly Criterion
Gambling
If odds are “fair”, thenαx = 1 px
, and hence pxαxbx =bx for all i.
Assume now that we haveinside informationabout the winning horse.
Insider X Noisy Channel X^ Gambler
In the extreme case, ˆX =X, we know the outcome: Vn=αxiαx2· · ·αxnV0
= 2Gn
V0 exponential rate of growth, G
whereVt is the capital on tth step
, andG = log
Pαxi
n .