File: 4.6g.txt

package info (click to toggle)
gap-hap 1.70%2Bds-1
  • links: PTS
  • area: main
  • in suites: forky, sid
  • size: 56,612 kB
  • sloc: xml: 16,139; sh: 216; javascript: 155; makefile: 126; ansic: 47; perl: 36
file content (27 lines) | stat: -rw-r--r-- 1,057 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
gap> file:=Filename(DirectoriesPackageLibrary("HAP"),"../tutorial/images/3096b.jpg");;
gap> F:=ReadImageAsFilteredPureCubicalComplex(file,30);;
gap> F:=ComplementOfFilteredPureCubicalComplex(F);;
gap> M:=FiltrationTerm(F,27);;  #Thickening chosen based on degree 0 barcode
gap> Display(M);;
gap> P:=List([1..BettiNumber(M,0)],n->PathComponentOfPureComplex(M,n));;
gap> P:=Filtered(P,m->Size(m)>10);;
gap> M:=P[1];;
gap> for m in P do
> M:=PureComplexUnion(M,m);;
> od;
gap> T:=ThickeningFiltration(M,50);;
gap> BettiNumber(FiltrationTerm(T,11),0);
1
gap> BettiNumber(FiltrationTerm(T,11),1);
1
gap> BettiNumber(FiltrationTerm(T,12),1);
0
gap> #Confirmation that 11-th filtration term has one hole and the 12-th term is contractible.
gap> C:=FiltrationTerm(T,11);;
gap> for n in Reversed([1..10]) do
> C:=ContractedComplex(C,FiltrationTerm(T,n));
> od;
gap> C:=PureComplexBoundary(PureComplexThickened(C));;
gap> H:=HomotopyEquivalentMinimalPureCubicalSubcomplex(FiltrationTerm(T,12),C);;
gap> B:=ContractedComplex(PureComplexBoundary(H));;
gap> Display(B);