Editing
Topology
(section)
Jump to navigation
Jump to search
Warning:
You are not logged in. Your IP address will be publicly visible if you make any edits. If you
log in
or
create an account
, your edits will be attributed to your username, along with other benefits.
Anti-spam check. Do
not
fill this in!
== <span style="color: #FFFFFF;">Applying</span> == '''Computational topology β persistent homology:''' <syntaxhighlight lang="python"> import numpy as np from itertools import combinations # Persistent homology computes topological features (connected components, # loops, voids) at multiple scales β used in topological data analysis (TDA) def build_vietoris_rips_complex(points: np.ndarray, epsilon: float) -> dict: """ Build Vietoris-Rips complex at scale Ξ΅: Add simplex {v0, v1, ..., vk} if all pairwise distances β€ Ξ΅. """ n = len(points) complex_dict = {'0-simplices': list(range(n)), '1-simplices': [], '2-simplices': []} # 1-simplices: edges for i, j in combinations(range(n), 2): if np.linalg.norm(points[i] - points[j]) <= epsilon: complex_dict['1-simplices'].append((i, j)) # 2-simplices: triangles for i, j, k in combinations(range(n), 3): if (np.linalg.norm(points[i] - points[j]) <= epsilon and np.linalg.norm(points[j] - points[k]) <= epsilon and np.linalg.norm(points[i] - points[k]) <= epsilon): complex_dict['2-simplices'].append((i, j, k)) return complex_dict def euler_characteristic(complex_dict: dict) -> int: """Ο = V - E + F (Euler-PoincarΓ© formula).""" V = len(complex_dict['0-simplices']) E = len(complex_dict['1-simplices']) F = len(complex_dict['2-simplices']) return V - E + F # Create point cloud: circle in 2D angles = np.linspace(0, 2*np.pi, 12, endpoint=False) circle_points = np.column_stack([np.cos(angles), np.sin(angles)]) circle_points += np.random.normal(0, 0.1, circle_points.shape) # Add noise # Build complexes at multiple scales for eps in [0.3, 0.6, 1.0, 2.0]: cpx = build_vietoris_rips_complex(circle_points, eps) chi = euler_characteristic(cpx) n_edges = len(cpx['1-simplices']) print(f"Ξ΅={eps}: V={len(cpx['0-simplices'])}, E={n_edges}, " f"F={len(cpx['2-simplices'])}, Ο={chi}") # At the right scale, Ο=0 β we detect the circle (1 connected component, 1 loop) # Ο(circle) = 0; Ο(disk) = 1; Ο(sphere) = 2 # In practice, use Gudhi or ripser for efficient persistent homology # import gudhi; rips = gudhi.RipsComplex(points=circle_points, max_edge_length=1.0) </syntaxhighlight> ; Key results and areas : '''Point-set topology''' β Hausdorff separation, Tychonoff theorem, Urysohn metrization : '''Algebraic topology''' β Euler characteristic, fundamental group, homology/cohomology, homotopy groups : '''Classification theorems''' β Surfaces by genus; 3-manifolds (geometrization, Thurston/Perelman) : '''Differential topology''' β Morse theory, cobordism, Whitney embedding theorem : '''Applied topology (TDA)''' β Persistent homology, mapper algorithm, topological data analysis </div> <div style="background-color: #8B4500; color: #FFFFFF; padding: 20px; border-radius: 8px; margin-bottom: 15px;">
Summary:
Please note that all contributions to BloomWiki may be edited, altered, or removed by other contributors. If you do not want your writing to be edited mercilessly, then do not submit it here.
You are also promising us that you wrote this yourself, or copied it from a public domain or similar free resource (see
BloomWiki:Copyrights
for details).
Do not submit copyrighted work without permission!
Cancel
Editing help
(opens in new window)
Navigation menu
Personal tools
Not logged in
Talk
Contributions
Create account
Log in
Namespaces
Page
Discussion
English
Views
Read
Edit
View history
More
Search
Navigation
Main page
Recent changes
Random page
Help about MediaWiki
Tools
What links here
Related changes
Special pages
Page information