Course Test · University: upper level
Topology: RatMath answers
The same twenty exercises, answered with RatMath Core and the Shelf libraries only. The code below was run when this page was built; its output is shown as printed, and compared with the independent answer.
Agrees 17 Partly 1 Can't yet 2
Libraries used here: core, analytic, structures, complex, discrete, chaos, geo. In this code each library is in scope under its own name (linalg.det, stats.tTest), and Core's names (R, Rational, …) are in scope directly.
- 1.Finite topologiesAgreesHow many topologies are there on a three-point set?Independent answerTopologies on a finite set correspond to preorders (reflexive, transitive relations), via iff every open set containing contains . On 3 points there are 29.RatMath code
[geo.countTopologies(3), geo.countTopologies(3, { t0: true })]Output[29, 19]
countTopologiescounts the preorders on 3 points (the open sets of a finite space are the up-sets of its specialisation preorder); 19 of the 29 are T₀.finiteSpacealso checks the axioms, closure, bases and continuity directly.Fix: ratmath/geo#11, measurement helpers, 3Dvectorandplane,conicProperties; topology:surface,simplicialComplex, finite spaces - 2.MetricsAgreesDescribe the unit ball of the taxicab metric in the plane. What is its "" (half the perimeter of the unit circle, measured in the same metric)?Independent answerThe square with vertices , . Each side has taxicab length 2, so the perimeter is 8 and .RatMath code
const m = geo.metric("taxicab"); [String(m.circle([0, 0], 1)), m.pi]Output["(1, 0),(0, 1),(-1, 0),(0, -1)", 4]
- 3.A bounded metricCan't yetShow is a metric on giving the same topology.Independent answeris increasing, subadditive and zero only at 0, so the triangle inequality passes from to . Small balls of the two metrics nest inside each other, so the open sets agree.RatMath code
// No proof tool. A spot check of the triangle inequality on rationals: const d = (x, y) => { const a = x.subtract(y).abs(); return a.divide(a.add(R`1`)); }; const xs = ["-3", "-1/2", "0", "2/3", "5"].map((s) => R`${s}`); xs.every((x) => xs.every((y) => xs.every((z) => !d(x, z).greaterThan(d(x, y).add(d(y, z))))))Outputtrue
Independent answer, in RatMath's notationa proof
Proofs are out of reach; the code only spot-checks the triangle inequality on a few rationals (it holds). - 4.Connectedness and compactnessCan't yetIs compact? Is ? Is connected?Independent answeris compact (Heine–Borel); is not (the cover has no finite subcover). is not connected: and separate it. It is even totally disconnected: between any two distinct rationals lies an irrational (such as ), and the same cut at puts and in different pieces, so no connected subset has two points.RatMath code
"no computation"Outputno computation
Independent answer, in RatMath's notationproofs
These are statements about all open covers and all separations; nothing in RatMath decides them. - 5.Winding numbersAgreesFind the winding number about 0 of the closed polygon , of the same path traversed twice, and of the triangle .Independent answerOnce round counter-clockwise: 1. Twice: 2. The triangle does not surround 0: 0.RatMath code
const W = complex.winding; [W(["1", "i", "-1", "-i", "1"]), W(["1", "i", "-1", "-i", "1", "i", "-1", "-i", "1"]), W(["3", "3+i", "2+i", "3"])]Output[1, 2, 0]
- 6.Degree of a mapAgreesWhat is the degree of on the unit circle (how many times does the image wind round 0)?Independent answerwinds three times: degree 3, equal to the number of zeros inside (argument principle).RatMath code
complex.argumentPrinciple("z^3", complex.Contour.circle(0, 1))Output3
- 7.Fixed point theoremPartlyShow every continuous has a fixed point, and find the fixed point of on .Independent answerhas , so vanishes by the intermediate value theorem. For : .RatMath code
analytic.fixedPoint("cos(x)", "1/2").rootOutput0.7390851332151606416[5:6]
The certified fixed point of is found (since the analytic fix the exact start"1/2"works). The general statement is a proof by the intermediate value theorem, given in the answer; RatMath does not check proofs, so this counts as partial.Fix: ratmath/analytic#18, exact starting values,pointwiselimits,sec/csc/cot, integrating factors with ,ODESolutionexported - 8.Euler characteristic of polyhedraAgreesCompute for the tetrahedron, cube and icosahedron.Independent answer, , : all 2, the Euler characteristic of the sphere.RatMath code
["tetrahedron", "cube", "icosahedron"].map((n) => geo.solids[n]().euler)Output[2, 2, 2]
- 9.Euler characteristic of a graphAgreesFor the Petersen graph as a 1-dimensional complex, find and the rank of .Independent answer. It is connected, so and independent cycles.RatMath code
const P = geo.simplicial.fromGraph(discrete.petersen()); [P.eulerCharacteristic, P.betti()[1]]Output[-5, 6]
The graph as a 1-dimensional simplicial complex; comes from its homology, not from the formula.Fix: ratmath/geo#11, measurement helpers, 3Dvectorandplane,conicProperties; topology:surface,simplicialComplex, finite spaces - 10.Homology of the torusAgreesThe torus has a cell structure with one 0-cell, two 1-cells and one 2-cell attached along . Find .Independent answerand , so .RatMath code
String(geo.surface("a b a^-1 b^-1").homology(1))OutputZ^2
surfacereads the cell structure from the edge word (one vertex, two edges, one face) and structures'chainComplexcomputes the homology.Fix: ratmath/geo#11, measurement helpers, 3Dvectorandplane,conicProperties; topology:surface,simplicialComplex, finite spaces - 11.Homology of the projective planeAgreeshas one cell in each dimension 0, 1, 2, the 2-cell attached along . Find .Independent answer, : .RatMath code
String(geo.surface("a a").homology(1))OutputZ/2
is read from the worda a.Fix: ratmath/geo#11, measurement helpers, 3Dvectorandplane,conicProperties; topology:surface,simplicialComplex, finite spaces - 12.Homology of the Klein bottleAgreesThe Klein bottle is one 0-cell, 1-cells , and a 2-cell attached along . Find .Independent answer: .RatMath code
String(geo.surface("a b a^-1 b").homology(1))OutputZ/2 × Z
From the word: .Fix: ratmath/geo#11, measurement helpers, 3Dvectorandplane,conicProperties; topology:surface,simplicialComplex, finite spaces - 13.Smith normal form and torsionAgreesA cell complex has (in bases of 2-cells and 1-cells) and . Find .Independent answerThe Smith form of is (gcd of entries 2, ). .RatMath code
[structures.smithForm([[2, 4], [6, 8]]).diagonal, String(structures.integerModule([[2, 4], [6, 8]], 2))]Output[[2n, 4n], "Z/2 × Z/4"]
- 14.Classification of surfacesAgreesA closed orientable surface has a triangulation with 10 vertices, 36 edges and 24 triangles. Check that these counts are possible, and say which surface it is.Independent answerIn a closed triangulated surface every triangle has 3 edges and every edge lies on exactly 2 triangles, so : . Then : genus 2, the double torus. (This is the f-vector of a minimal genus-2 triangulation.)RatMath code
const [V, E, F] = [10, 36, 24]; const s = geo.classifySurface({ euler: V - E + F, orientable: true }); [3 * F === 2 * E, s.eulerCharacteristic, s.genus]Output[true, -2, 2]
The incidence count is checked first (the earlier version of this exercise used 8, 24, 14, for which : no such triangulation exists).classifySurfacethen applies the classification theorem: orientable with is the connected sum of 2 tori.Fix: ratmath/geo#11, measurement helpers, 3Dvectorandplane,conicProperties; topology:surface,simplicialComplex, finite spaces - 15.Genus of a graphAgreesWhat is the genus of (the least genus of a surface it embeds in)?Independent answerIt is not planar, and it embeds in the torus: genus 1. (.)RatMath code
const t = discrete.genus(discrete.complete(5)); [discrete.isPlanar(discrete.complete(5)), t.genus, t.proven, discrete.embeddingGenus(discrete.complete(5), t.blocks[0].rotation).faces.length]Output[false, 1, true, 5]
genussearches rotation systems: it returns an embedding of with 5 faces, so and the surface is a torus; not planar gives the lower bound.Fix: ratmath/discrete#8,genusof a graph by rotation systems - 16.The Cantor setAgreesWhat is the total length of the th stage of the Cantor construction? What is the measure of the Cantor set?Independent answerintervals of length : , e.g. at stage 3. The limit is 0, yet the set is uncountable.RatMath code
[chaos.cantor().measure(3), chaos.cantor().stage(2).length]Output[8/27, 4]
- 17.Fractal dimensionAgreesFind the similarity dimension of the Sierpinski carpet.Independent answer8 copies at scale : .RatMath code
const d = chaos.attractors.carpet().similarityDimension(); [d.formula, d.interval[0]]Output["log(8)/log(3)", 136389840147905979/72057594037927936]
- 18.Fundamental groupsAgreesWhat are the fundamental groups of the circle, the torus and ?Independent answer, , .RatMath code
[geo.simplicial.sphere(1), geo.surface("a b a^-1 b^-1"), geo.surface("a a")].map((X) => String(X.fundamentalGroup()))Output["⟨e3 | ⟩", "⟨a, b | aba⁻¹b⁻¹⟩", "⟨a | a²⟩"]
fundamentalGroup()contracts a spanning tree and reads one relator per face (van Kampen), returning a presentation: free on one generator for the circle, for the torus, for (structures confirms the orders and abelianisations).Fix: ratmath/geo#11, measurement helpers, 3Dvectorandplane,conicProperties; topology:surface,simplicialComplex, finite spaces - 19.Stereographic projectionAgreesUnder stereographic projection from the north pole of the unit sphere, where does the point go?Independent answer. The sphere minus a point is homeomorphic to the plane.RatMath code
String(geo.spoint("3/5", 0, "4/5").stereographic)Output(3, 0)
- 20.A triangulated torusAgreesMöbius and Császár's minimal triangulation of the torus has 7 vertices, 21 edges and 14 triangles. Check its Euler characteristic.Independent answer, as it must be for a torus. (Every pair of the 7 vertices is an edge: .)RatMath code
const T = geo.simplicial.torus(); [T.fVector, T.eulerCharacteristic, String(T.homology(1)), T.classify().name]Output[[7, 21, 14], 0, "Z^2", "torus"]
The triangulation itself is built from its 14 triangles; the f-vector, χ, homology and the surface recognition all come from it.Fix: ratmath/geo#11, measurement helpers, 3Dvectorandplane,conicProperties; topology:surface,simplicialComplex, finite spaces