Repository navigation
Math tools: a solver of triangles - #42
Open
simonebortolin wants to merge 1 commit into
Open
simonebortolin wants to merge 1 commit into
simonebortolin wants to merge 1 commit into
Conversation
Three of the sides and angles, at least one of them a side, give the others (SSS, SAS, SSA with its two triangles, one or none, ASA, AAS), the area, the perimeter and the radii of the circles, with the laws used written in UnicodeMath and the triangle drawn to scale. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01SyVio8afJsGwHW9i5v5HDs
|
Pre-release NuGet package of 96d6d7f. Updated on every push, deleted when this PR is closed. |
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Stacked on #41. This is the last page of the math tools (#39–#41): it adds a solver of triangles.
What it does
You give three of a, b, c, α, β and γ, at least one of them a side. The page finds:
MathView;It handles every case:
When there is no triangle, the page says why: three angles alone, the wrong number of values, angles of 180° or more, a side too long, or text that is not a number. The example buttons fill in each case.
Code
Triangles.csis the model, with no user interface.TrianglePage.csis the page. It is wired in as the "Triangles" tab.Tests
TrianglesTests:merrorand round-trip.TrianglesSolvecovers the example, the ambiguous case and a value that is not a number.Generated by Claude Code