Quellcodebibliothek Statistik Leitseite products/Sources/formale Sprachen/GAP/pkg/hap/tst/examples/   (Algebra von RWTH Aachen Version 4.15.1©)  Datei vom 19.6.2025 mit Größe 594 B image not shown  

Quelle  1.3.4   Sprache: unbekannt

 
#The example uses GraphViz software.
file:=HapFile("data134.txt");
Read(file);
dx:=EuclideanApproximatedMetric;;
dz:=EuclideanApproximatedMetric;;
L:=List(S,x->Maximum(List(S,y->dx(x,y))));;
n:=Position(L,Minimum(L));
f:=function(x); return [dx(S[n],x)]; end;;
P:=30*[0..100];; P:=List(P, i->[i]);;
r:=29;;
epsilon:=75;
 cluster:=function(S)
  local Y, P, C;
  if Length(S)=0 then return S; fi;
  Y:=VectorsToOneSkeleton(S,epsilon,dx);
  P:=PiZero(Y);
  C:=Classify([1..Length(S)],P[2]);
  return List(C,x->S{x});
 end;;
M:=Mapper(S,dx,f,dz,P,r,cluster);
Display(GraphOfSimplicialComplex(M));


[ Dauer der Verarbeitung: 0.21 Sekunden  (vorverarbeitet)  ]