Course Test · University: upper level

College geometry: 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 20

Libraries used here: core, 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. 1.Triangle centresAgrees
    For the triangle A(0,0)A(0,0), B(4,0)B(4,0), C(0,3)C(0,3), find the circumcentre and circumradius, the incentre and inradius, the orthocentre and the centroid.
    Independent answer
    Right angle at AA: the circumcentre is the midpoint of the hypotenuse, (2,32)(2, \tfrac32), radius 52\tfrac52. Inradius r=3+4−52=1r = \tfrac{3 + 4 - 5}{2} = 1, incentre (1,1)(1, 1). The orthocentre is the right-angle vertex (0,0)(0, 0). Centroid (43,1)(\tfrac43, 1).
    RatMath code
    const T = geo.triangle([0, 0], [4, 0], [0, 3]);
    [T.circumcenter, T.circumradius, T.incenter, T.inradius, T.orthocenter, T.centroid].map(String)
    Output
    ["(2, 3/2)", "5/2", "(1, 1)", "1", "(0, 0)", "(4/3, 1)"]
  2. 2.The Euler lineAgrees
    For the same triangle, show the circumcentre OO, centroid GG and orthocentre HH are collinear with HG=2 GOHG = 2\,GO, and find the line.
    Independent answer
    H=(0,0)H = (0,0), G=(43,1)G = (\tfrac43, 1), O=(2,32)O = (2, \tfrac32) all lie on 3x−4y=03x - 4y = 0. HG=53HG = \tfrac53, GO=56GO = \tfrac56.
    RatMath code
    const T = geo.triangle([0, 0], [4, 0], [0, 3]);
    [geo.collinear(T.circumcenter, T.centroid, T.orthocenter), geo.distance(T.orthocenter, T.centroid), geo.distance(T.centroid, T.circumcenter), String(T.eulerLine)]
    Output
    [true, 5/3, 5/6, "3·x - 4·y = 0"]
  3. 3.Nine-point circleAgrees
    Find the centre and radius of the nine-point circle of the same triangle.
    Independent answer
    Its centre is the midpoint of OHOH, (1,34)(1, \tfrac34), and its radius is half the circumradius, 54\tfrac54.
    RatMath code
    String(geo.triangle([0, 0], [4, 0], [0, 3]).ninePointCircle)
    Output
    circle, centre (1, 3/4), radius 5/4
  4. 4.InversionAgrees
    Find the images of (2,0)(2, 0) and (1,1)(1, 1) under inversion in the unit circle.
    Independent answer
    P↦P/∣P∣2P \mapsto P/|P|^2: (12,0)(\tfrac12, 0) and (12,12)(\tfrac12, \tfrac12).
    RatMath code
    const inv = geo.inversion(geo.circle([0, 0], [1, 0]));
    [inv.apply(geo.point(2, 0)), inv.apply(geo.point(1, 1))].map(String)
    Output
    ["(1/2, 0)", "(1/2, 1/2)"]
  5. 5.Cross ratioAgrees
    Find the cross ratio (A,B;C,D)=AC⋅BDBC⋅AD(A, B; C, D) = \dfrac{AC\cdot BD}{BC\cdot AD} of the points 0, 1, 2, 3 on a line.
    Independent answer
    2⋅21⋅3=43\dfrac{2\cdot2}{1\cdot3} = \dfrac43.
    RatMath code
    const p = (x) => geo.point(x, 0);
    geo.crossRatio(p(0), p(1), p(2), p(3))
    Output
    4/3
  6. 6.Harmonic conjugatesAgrees
    On a line, A=0A = 0, B=3B = 3, C=1C = 1. Find the harmonic conjugate DD of CC with respect to A,BA, B.
    Independent answer
    CACB=−DADB\dfrac{CA}{CB} = -\dfrac{DA}{DB}: 1−2=−DD−3\dfrac{1}{-2} = -\dfrac{D}{D - 3}, so D−3=2DD - 3 = 2D, D=−3D = -3.
    RatMath code
    String(geo.harmonicConjugate(geo.point(0, 0), geo.point(3, 0), geo.point(1, 0)))
    Output
    [-3 : 0 : 1]
    The answer is in homogeneous coordinates [x:y:1][x : y : 1].
  7. 7.Conic through five pointsAgrees
    Find the conic through (±1,0)(\pm1, 0), (0,±2)(0, \pm2) and (35,85)(\tfrac35, \tfrac85), and classify it.
    Independent answer
    Symmetry suggests x2+y24=1x^2 + \tfrac{y^2}{4} = 1; (35,85)(\tfrac35, \tfrac85): 925+1625=1\tfrac9{25} + \tfrac{16}{25} = 1. An ellipse.
    RatMath code
    const c = geo.conicThrough([geo.point(1, 0), geo.point(-1, 0), geo.point(0, 2), geo.point(0, -2), geo.point("3/5", "8/5")]);
    [String(c), c.classify()]
    Output
    ["−x² − 1/4y² + 1 = 0", "ellipse"]
  8. 8.Composing reflectionsAgrees
    Reflect in the line y=xy = x, then in the xx-axis. What single isometry is this?
    Independent answer
    (x,y)↦(y,x)↦(y,−x)(x, y) \mapsto (y, x) \mapsto (y, -x): rotation about the origin by −90∘-90^\circ, twice the angle between the mirrors.
    RatMath code
    const r = (p, q) => geo.reflection(geo.line(geo.point(...p), geo.point(...q)));
    const T = r([0, 0], [1, 0]).compose(r([0, 0], [1, 1]));   // x-axis after y = x
    const c = T.classify();
    [c.kind, String(c.center), String(c.degrees)]
    Output
    ["rotation", "(0, 0)", "-90"]
  9. 9.Pick's theoremAgrees
    The rectangle with vertices (0,0)(0,0), (4,0)(4,0), (4,3)(4,3), (0,3)(0,3) has how many interior lattice points? Check Pick's theorem.
    Independent answer
    Boundary points B=2(4+3)=14B = 2(4 + 3) = 14, interior I=3⋅2=6I = 3\cdot2 = 6. I+B2−1=6+7−1=12I + \tfrac B2 - 1 = 6 + 7 - 1 = 12, the area.
    RatMath code
    const p = geo.pick([[0, 0], [4, 0], [4, 3], [0, 3]]);
    [p.interior, p.boundary, p.area, p.holds]
    Output
    [6, 14, 12, true]
  10. 10.Regular polygonsAgrees
    Find the interior angle of a regular 12-gon, as a fraction of a full turn and in degrees.
    Independent answer
    (12−2)⋅180∘12=150∘=512\dfrac{(12 - 2)\cdot180^\circ}{12} = 150^\circ = \tfrac{5}{12} of a turn.
    RatMath code
    const a = geo.polygonAngle(12);
    [a, a.multiply(R`360`)]
    Output
    [5/12, 150]
  11. 11.Spherical trianglesAgrees
    On the unit sphere, take the north pole and the equator points at longitudes 0° and 90°. Find the angle sum, excess and area of the triangle.
    Independent answer
    Three right angles: sum 3π2\tfrac{3\pi}2, excess π2\tfrac\pi2, area = excess =π2= \tfrac\pi2, one eighth of the sphere's 4π4\pi.
    RatMath code
    const T = geo.striangle(geo.northPole(), geo.latLon(0, 0), geo.latLon(0, "1/4"));
    [T.angleSum, T.excess, T.area, T.fractionOfSphere].map(String)
    Output
    ["3π/2", "π/2", "π/2", "1/8"]
    latLon takes fractions of a full turn, not degrees: latLon(0, 90) is 90 whole turns, the same point as latLon(0, 0).
  12. 12.Great-circle distanceAgrees
    On the unit sphere, how far apart are the points at latitude 0°, longitudes 0° and 90°?
    Independent answer
    The central angle is 90∘90^\circ: distance π2\tfrac\pi2.
    RatMath code
    String(geo.latLon(0, 0).distanceTo(geo.latLon(0, "1/4")))
    Output
    π/2
  13. 13.Hyperbolic distanceAgrees
    In the Poincaré disc, find the distance from the centre to the point (12,0)(\tfrac12, 0).
    Independent answer
    d=2artanh⁡12=ln⁡1+1/21−1/2=ln⁡3≈1.0986d = 2\operatorname{artanh}\tfrac12 = \ln\dfrac{1 + 1/2}{1 - 1/2} = \ln 3 \approx 1.0986.
    RatMath code
    String(geo.horigin().distanceTo(geo.hpoint("1/2", 0)))
    Output
    ln(3)
  14. 14.Hyperbolic trianglesAgrees
    In the Poincaré disc, find the angle sum and area of the triangle with vertices 00, (12,0)(\tfrac12, 0), (0,12)(0, \tfrac12).
    Independent answer
    Sides cosh⁡=53,53\cosh = \tfrac53, \tfrac53 (from 0) and cosh⁡=1+2⋅12(3/4)2=259\cosh = 1 + \dfrac{2\cdot\frac12}{(3/4)^2} = \tfrac{25}9. The angle at 0 is π2\tfrac\pi2; by the hyperbolic law of cosines the other two are arccos⁡0.857493≈0.540421\arccos 0.857493 \approx 0.540421 each. Sum ≈2.651635\approx 2.651635, area = defect ≈0.489957\approx 0.489957.
    RatMath code
    const T = geo.htriangle(geo.horigin(), geo.hpoint("1/2", 0), geo.hpoint(0, "1/2"));
    [T.angleSum, T.defect]
    Output
    [2.6516353273…, 0.4899573262…]
  15. 15.Ideal trianglesAgrees
    What is the area of a hyperbolic triangle whose three vertices are on the boundary circle?
    Independent answer
    All three angles are 0, so the area is the defect π−0=π\pi - 0 = \pi.
    RatMath code
    const T = geo.htriangle(geo.ideal(1, 0), geo.ideal(-1, 0), geo.ideal(0, 1));
    [T.angleSum, T.area].map(String)
    Output
    ["0", "π"]
  16. 16.Finite projective planesAgrees
    The Fano plane is the projective plane of order 2. How many lines does it have? How many points has the projective plane of order 3?
    Independent answer
    Order nn gives n2+n+1n^2 + n + 1 points and lines: 7 for n=2n = 2, 13 for n=3n = 3.
    RatMath code
    const F = geo.fano();
    [F.order, F.lines.length, F.isProjectivePlane(), geo.projectivePlane(3).lines.length]
    Output
    [2, 7, true, 13]
  17. 17.Euler's formula for polyhedraAgrees
    Check Euler's formula for the icosahedron.
    Independent answer
    20 triangular faces, E=20⋅3/2=30E = 20\cdot3/2 = 30, five faces at each vertex so V=20⋅3/5=12V = 20\cdot3/5 = 12. 12−30+20=212 - 30 + 20 = 2.
    RatMath code
    const P = geo.solids.icosahedron();
    [P.V, P.E, P.F, P.euler]
    Output
    [12, 30, 20, 2]
  18. 18.Taxicab geometryAgrees
    Find the taxicab and Euclidean distances between (1,2)(1, 2) and (4,6)(4, 6).
    Independent answer
    Taxicab: ∣4−1∣+∣6−2∣=7|4 - 1| + |6 - 2| = 7. Euclidean: 9+16=5\sqrt{9 + 16} = 5.
    RatMath code
    [geo.metric("taxicab").distance([1, 2], [4, 6]), geo.distance(geo.point(1, 2), geo.point(4, 6))]
    Output
    [7, 5]
  19. 19.Euclidean theorem provingAgrees
    Prove that the nine-point circle passes through the midpoints of the sides, the feet of the altitudes, and the midpoints from the orthocentre to the vertices, for every triangle.
    Independent answer
    Classical proof: the midpoints and the midpoints of AH,BH,CHAH, BH, CH form two rectangles with a common diagonal set, all inscribed in the circle on NN, the midpoint of OHOH; the feet see these diameters at right angles.
    RatMath code
    const p = geo.proofs.ninePointCircle;
    const r = typeof p === "function" ? p() : p;
    [r.proved ?? r.holds ?? r.ok, String(r).slice(0, 40)]
    Output
    [true, "Nine-point circle: proved (wu)"]
  20. 20.Sides and anglesAgrees
    For the triangle A(0,0)A(0,0), B(4,0)B(4,0), C(0,3)C(0,3), find the side lengths and the angle at BB in degrees.
    Independent answer
    AB=4AB = 4, AC=3AC = 3, BC=5BC = 5. cos⁡B=45\cos B = \tfrac45, B=arccos⁡45≈36.8699∘B = \arccos\tfrac45 \approx 36.8699^\circ.
    RatMath code
    const T = geo.triangle([0, 0], [4, 0], [0, 3]);
    [Object.values(T.sides).map(String), String(T.cosines.B), T.degrees.B]
    Output
    [["5", "3", "4"], "4/5", 36.86989764584401]