Course Test · School: high school
Geometry (high school): 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, symbolic, 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.MidpointAgreesFind the midpoint of and .Independent answer.RatMath code
geo.midpoint([-4, 7], [6, -1])Output(1, 3)
- 2.Perpendicular bisectorAgreesFind the perpendicular bisector of the segment from to .Independent answerMidpoint , slope : .RatMath code
geo.perpendicularBisector([1, 2], [5, 6])Outputx + y - 7 = 0
- 3.Classifying a triangleAgreesClassify the triangle with vertices , , by its sides and angles, and find its area.Independent answerSides 6, , : scalene. Largest side squared : acute. Area .RatMath code
const T = geo.triangle([0, 0], [6, 0], [2, 4]); [T.classify(), T.area]Output[{ angles: "acute", sides: "scalene" }, 12] - 4.Polygon anglesAgreesFind the sum of the interior angles of an octagon, and each angle of a regular octagon.Independent answer; .RatMath code
[geo.angleSum(8), geo.interiorAngle(8)]Output[1080, 135]
angleSumandinteriorAngle, in degrees.Fix: ratmath/geo#11, measurement helpers, 3Dvectorandplane,conicProperties; topology:surface,simplicialComplex, finite spaces - 5.Similar trianglesAgreesA triangle has sides 4, 6 and 8. A similar triangle has longest side 12. Find its other sides.Independent answerScale factor : sides 6 and 9.RatMath code
const k = R`12/8`; [R`4`.multiply(k), R`6`.multiply(k)]Output[6, 9]
- 6.Special right trianglesAgreesA 30–60–90 triangle has hypotenuse 10. Find the legs.Independent answerShort leg 5, long leg .RatMath code
[symbolic.simplify("10*sin(pi/6)"), symbolic.simplify("10*sin(pi/3)")]Output[5, 5*sqrt(3)]
- 7.Right-triangle trigonometryAgreesIn a right triangle, an acute angle is and its adjacent leg is 12. Find the opposite leg to two decimal places.Independent answer.RatMath code
symbolic.evaluate(symbolic.parse("12*tan(35*pi/180)"))Output8.40249045851651735249:8.4024904585165173538
- 8.Law of cosinesAgreesTwo sides of a triangle are 7 and 8, with an included angle of . Find the third side.Independent answer, .RatMath code
symbolic.simplify("sqrt(7^2 + 8^2 - 2*7*8*cos(pi/3))")Outputsqrt(57)
- 9.Law of sinesAgreesIn triangle , , and . Find to two decimals.Independent answer.RatMath code
symbolic.evaluate(symbolic.parse("10*sin(65*pi/180)/sin(40*pi/180)"))Output14.0996461876204866[8525:9046]
- 10.Equation of a circleAgreesWrite the equation of the circle with centre and radius 5. Is on it?Independent answer. Yes: .RatMath code
const C = geo.circle([-2, 3], [3, 3]); [C, C.contains ? C.contains([1, 7]) : geo.distance([-2, 3], [1, 7])]Output[circle, centre (-2, 3), radius 5, true]
- 11.Centre and radiusAgreesFind the centre and radius of .Independent answer: centre , radius 5.RatMath code
const c = geo.circleFromEquation("x^2 + y^2 - 6x + 4y - 12 = 0"); [String(c.center), c.radius]Output["(3, -2)", 5]
circleFromEquationcompletes the square.Fix: ratmath/geo#11, measurement helpers, 3Dvectorandplane,conicProperties; topology:surface,simplicialComplex, finite spaces - 12.Arcs and sectorsAgreesA circle has radius 9. Find the length of an arc and the area of a sector with central angle .Independent answerArc ; sector .RatMath code
[symbolic.simplify("80/360*2*pi*9"), symbolic.simplify("80/360*pi*9^2")]Output[4*pi, 18*pi]
- 13.Inscribed anglesAgreesAn inscribed angle intercepts an arc of . What is the angle?Independent answer.RatMath code
R`110/2`Output55
The inscribed angle theorem is in geo (geo.proofs.inscribedAngle()proves it), but using it here is just halving. - 14.Tangent lengthAgreesA point is 13 units from the centre of a circle of radius 5. How long is a tangent segment from the point to the circle?Independent answerRadius ⟂ tangent: .RatMath code
geo.tangentLength(geo.circle([0, 0], [5, 0]), [13, 0])Output12
tangentLengthis the square root of the point's power.Fix: ratmath/geo#11, measurement helpers, 3Dvectorandplane,conicProperties; topology:surface,simplicialComplex, finite spaces - 15.SphereAgreesFind the volume and surface area of a sphere of radius 6, in terms of .Independent answer; .RatMath code
[symbolic.simplify("4/3*pi*6^3"), symbolic.simplify("4*pi*6^2")]Output[288*pi, 144*pi]
- 16.RotationAgreesRotate by counterclockwise about the origin.Independent answer: .RatMath code
geo.rotation([0, 0], "1/4").apply([4, 1])Output(-1, 4)
- 17.DilationAgreesDilate by scale factor 3 about .Independent answer.RatMath code
geo.dilation([1, 1], 3).apply([3, 2])Output(7, 4)
- 18.CentroidAgreesFind the centroid of the triangle .Independent answer.RatMath code
geo.triangle([0, 0], [6, 0], [3, 9]).centroidOutput(3, 3)
- 19.CircumcircleAgreesFind the centre and radius of the circle through .Independent answerRight angle at the origin, so the centre is the midpoint of the hypotenuse, ; radius .RatMath code
const T = geo.triangle([0, 0], [4, 0], [0, 6]); [T.circumcenter, T.circumradius]Output[(2, 3), 3.605551275463…]
- 20.ProofAgreesProve that the diagonals of a parallelogram bisect each other.Independent answerWith , , , : the midpoint of and of are both . (Or by congruent triangles ASA.)RatMath code
const p = geo.proofs.parallelogram(); [p.proved, p.statement]Output[true, "the diagonals of a parallelogram bisect each other"]