%------------------------------------------------------------------------------
tff(person_type,type, person: $tType ).
tff(bob_decl,type, bob: person ).
tff(child_of_decl,type, child_of: person > person ).
tff(is_descendant_decl,type, is_descendant: (person * person) > $o ).
tff(descendents_different,axiom,
! [A: person,D: person] :
( is_descendant(A,D) => ( A != D ) ) ).
tff(descendent_transitive,axiom,
! [A: person,C: person,G: person] :
( ( is_descendant(A,C) & is_descendant(C,G) )
=> is_descendant(A,G) ) ).
tff(child_is_descendant,axiom,
! [P: person] : is_descendant(P,child_of(P)) ).
tff(all_have_child,axiom,
! [P: person] : ? [C: person] : C = child_of(P) ).
%------------------------------------------------------------------------------
tff(peano_type,type, peano: $tType).
tff(zero_decl,type, zero: peano ).
tff(s_decl,type, s: peano > peano ).
tff(peano2person_decl,type,peano2person: peano > person ).
tff(peano_less_decl,type,
peano_less: ( peano * peano ) > $o ).
tff(people,interpretation,
( ( ! [P: person] : ? [I: peano] : ( P = peano2person(I) )
& ! [I: peano] : ( I = zero | ? [P: peano] : I = s(P) )
& ! [I1: peano,I2: peano] :
( peano2person(I1) = peano2person(I2) => I1 = I2 )
& ! [I1: peano,I2: peano,I3: peano] :
( peano_less(I1,s(I1))
& ( ( peano_less(I1,I2) & peano_less(I2,I3) )
=> peano_less(I1,I3) )
& ( peano_less(I1,I2)
=> I1 != I2 ) ) )
& ( bob = peano2person(zero)
& ! [I: peano] :
child_of(peano2person(I)) = peano2person(s(I)) )
& ( ! [A: peano,D: peano] :
( is_descendant(peano2person(A),peano2person(D))
<=> peano_less(A,D) ) ) ) ).
tff(int2person_decl,type, int2person: $int > person ).
tff(people,interpretation,
( ! [P: person] : ? [I: $int] : P = int2person(I)
& ! [I1: $int,I2: $int] : ( int2person(I1) = int2person(I2) => I1 = I2 )
& bob = int2person(0)
& ! [I: $int] : child_of(int2person(I)) = int2person($sum(I,1))
& ! [A: $int,D: $int] :
( is_descendant(int2person(A),int2person(D)) <=> $less(A,D) ) ) ).
| Descendants Play the Peano | Infinite Term Model | |
|---|---|---|
%------------------------------------------------------------------------------
tff(person_type,type, person: $tType ).
tff(bob_decl,type, bob: person ).
tff(child_of_decl,type, child_of: person > person ).
tff(is_descendant_decl,type, is_descendant: (person * person) > $o ).
tff(descendents_different,axiom,
! [A: person,D: person] :
( is_descendant(A,D) => ( A != D ) ) ).
tff(descendent_transitive,axiom,
! [A: person,C: person,G: person] :
( ( is_descendant(A,C) & is_descendant(C,G) )
=> is_descendant(A,G) ) ).
tff(child_is_descendant,axiom,
! [P: person] : is_descendant(P,child_of(P)) ).
tff(all_have_child,axiom,
! [P: person] : ? [C: person] : C = child_of(P) ).
%------------------------------------------------------------------------------
|
%------------------------------------------------------------------------------
tff(person_type,type, person: $tType ).
tff(bob_decl,type, bob: person ).
tff(child_of_decl,type, child_of: person > person ).
tff(is_descendant_decl,type, is_descendant: ( person * person ) > $o ).
tff(peano_type,type, peano: $tType).
tff(zero_decl,type, zero: peano ).
tff(s_decl,type, s: peano > peano ).
tff(peano2person_decl,type, peano2person: peano > person ).
tff(peano_less_decl,type, peano_less: ( peano * peano ) > $o ).
tff(people,interpretation,
%----Domain for type person is the Peano numbers
( ! [P: person] : ? [I: peano] : P = peano2person(I)
& ! [I: peano] : ( I = zero | ? [P: peano] : I = s(P) )
%----The type promoter is a bijection (injective and surjective)
& ! [I1: peano,I2: peano] :
( peano2person(I1) = peano2person(I2) => I1 = I2 )
%----Relationships between Peano numbers
& ! [I1: peano,I2: peano,I3: peano] :
( peano_less(I1,s(I1))
& ( ( peano_less(I1,I2) & peano_less(I2,I3) )
=> peano_less(I1,I3) )
& ( peano_less(I1,I2)
=> I1 != I2 ) )
%----Mapping people to Peano numbers
& bob = peano2person(zero)
& ! [I: peano] :
child_of(peano2person(I)) = peano2person(s(I))
%----Interpretation of descendancy
& ! [A: peano,D: peano] :
( is_descendant(peano2person(A),peano2person(D))
<=> peano_less(A,D) ) ) ).
%------------------------------------------------------------------------------
|
| Descendants Count Forever | Infinite Integer Model | |
|---|---|---|
%------------------------------------------------------------------------------
tff(person_type,type, person: $tType ).
tff(bob_decl,type, bob: person ).
tff(child_of_decl,type, child_of: person > person ).
tff(is_descendant_decl,type, is_descendant: (person * person) > $o ).
tff(descendents_different,axiom,
! [A: person,D: person] :
( is_descendant(A,D) => ( A != D ) ) ).
tff(descendent_transitive,axiom,
! [A: person,C: person,G: person] :
( ( is_descendant(A,C) & is_descendant(C,G) )
=> is_descendant(A,G) ) ).
tff(child_is_descendant,axiom,
! [P: person] : is_descendant(P,child_of(P)) ).
tff(all_have_child,axiom,
! [P: person] : ? [C: person] : C = child_of(P) ).
%------------------------------------------------------------------------------
|
%------------------------------------------------------------------------------
tff(person_type,type, person: $tType ).
tff(bob_decl,type, bob: person ).
tff(child_of_decl,type, child_of: person > person ).
tff(is_descendant_decl,type, is_descendant: ( person * person ) > $o ).
tff(int2person_decl,type, int2person: $int > person ).
tff(people,interpretation,
%----Domain for type person is the integers
( ! [P: person] : ? [I: $int] : int2person(I) = P
%----The type promoter is a bijection (injective and surjective)
& ! [I1: $int,I2: $int] :
( int2person(I1) = int2person(I2) => I1 = I2 )
%----Mapping people to integers. Note that Bob's ancestors will be interpreted
%----as negative integers.
& bob = int2person(0)
& ! [I: $int] : child_of(int2person(I)) = int2person($sum(I,1))
%----Interpretation of descendancy
& ! [A: $int,D: $int] :
( is_descendant(int2person(A),int2person(D)) <=> $less(A,D) ) ) ).
%------------------------------------------------------------------------------
|