直角三角形构造器:已知一角一边或两边快速作图
几何画板及绘图内容加载中,请稍等……
该范例演示了如何通过输入一个锐角及一条边,或直接输入两条边,快速构造一个直角三角形,并支持翻转三角形方向以及选择显示单位。核心数学概念包括直角三角形的边角关系、勾股定理、三角函数(正弦、余弦、正切)以及角度与边长之间的相互推导。作图要点方面,范例使用了GeoGebra的Corner、Polygon、If、Text、Textfield等命令,并涉及大量对象如ViewOption、ParseTest、ZoomCushion、屏幕角点坐标、三角形顶点A、B、C及边长a、b、c,通过动态文本框输入参数,利用条件判断(If)确定直角位置(右下、左下、右上、左上),并自动调整缩放范围(ZoomMinY、ZoomMaxY等)以适配图形。该范例适合初中至高中阶段学生学习直角三角形性质、三角函数应用以及动态几何作图,也可作为教师课堂演示工具,帮助学生直观理解已知条件与图形构造之间的逻辑关系。
GeoGebra 命令及参数
Corner(2) → ScreenBottomRightCornerCorner(1) → ScreenBottomLeftCornerCorner(5) → ScreenPixelSizePolygon(A, C, B) → Triangle, b, a, cIf(b ≥ a, ((b + ((2 * ZoomCushion) * b)) * ScreenPixelHeightOverPixelWidth), a + ((2 * ZoomCushion) * a)) → ZoomHeightYIf((x(A) < x(C)) ∧ (y(C) < y(B)), true, false) → RightAngleIsBottomRightIf((x(A) > x(C)) ∧ (y(C) < y(B)), true, false) → RightAngleIsBottomLeftIf((y(C) > y(B)) ∧ (x(C) > x(A)), true, false) → RightAngleIsTopRightIf((x(C) < x(A)) ∧ (y(C) > y(B)), true, false) → RightAngleIsTopLeftIf(x(C) > x(A), true, false) → RightAngleIsOnRightIf(y(C) > y(B), true, false) → RightAngleIsOnTopIf(RightAngleIsBottomRight ∨ RightAngleIsTopLeft, Angle[C, A, B], Angle[B, A, C]) → AngleAIf(RightAngleIsBottomRight ∨ RightAngleIsTopLeft, Angle[A, B, C], Angle[C, B, A]) → AngleBIf(RightAngleIsBottomRight ∨ RightAngleIsTopLeft, Angle[B, C, A], Angle[A, C, B]) → AngleCText("a") → FirstInputText("b") → SecondInputIf(FirstInput ≟ "A" ∨ FirstInput ≟ "B", true) → FirstInputIsAnAngleIf(FirstInput ≟ "a" ∧ SecondInput ≟ "b" ∨ FirstInput ≟ "b" ∧ SecondInput ≟ "a", true, false) → abIf(FirstInput ≟ "b" ∧ SecondInput ≟ "c" ∨ FirstInput ≟ "c" ∧ SecondInput ≟ "b", true, false) → bcIf(FirstInput ≟ "a" ∧ SecondInput ≟ "c" ∨ FirstInput ≟ "c" ∧ SecondInput ≟ "a", true, false) → acIf(FirstInput ≟ "A" ∧ SecondInput ≟ "a" ∨ FirstInput ≟ "a" ∧ SecondInput ≟ "A", true, false) → aAIf(FirstInput ≟ "a" ∧ SecondInput ≟ "B" ∨ FirstInput ≟ "B" ∧ SecondInput ≟ "a", true, false) → aBIf(FirstInput ≟ "b" ∧ SecondInput ≟ "A" ∨ FirstInput ≟ "A" ∧ SecondInput ≟ "b", true, false) → bAIf(FirstInput ≟ "b" ∧ SecondInput ≟ "B" ∨ FirstInput ≟ "B" ∧ SecondInput ≟ "b", true, false) → bBIf(FirstInput ≟ "c" ∧ SecondInput ≟ "A" ∨ FirstInput ≟ "A" ∧ SecondInput ≟ "c", true, false) → cAIf(FirstInput ≟ "c" ∧ SecondInput ≟ "B" ∨ FirstInput ≟ "B" ∧ SecondInput ≟ "c", true, false) → cBIf(11 ≤ ViewOption ≤ 12, true, false) → ShowAllValuesTextfield(Unitstext) → UnitstextInputBoxIf(7 ≤ ViewOption ≤ 10, true, false) → ShowSomeVariablesCorner(3) → ScreenTopRightCornerCorner(4) → ScreenTopLeftCornerIf(b ≥ a, b + ((2 * ZoomCushion) * b), ((ZoomMaxY - ZoomMinY) * ScreenPixelWidthOverPixelHeight)) → ZoomWidthXIf(FirstInput ≟ "A" ∨ SecondInput ≟ "A", true, false) → AIsAnInputIf(FirstInput ≟ "c" ∨ SecondInput ≟ "c", true, false) → cIsAnInputIf(FirstInput ≟ "b" ∨ SecondInput ≟ "b", true, false) → bIsAnInputIf(FirstInput ≟ "a" ∨ SecondInput ≟ "a", true, false) → aIsAnInputIf(FirstInput ≟ "B" ∨ SecondInput ≟ "B", true, false) → BIsAnInputTextfield(cVariableTextTemp) → cVariableTextInputBoxTextfield(aInputText) → aInputBoxTextfield(bInputText) → bInputBoxTextfield(cInputText) → cInputBoxIf(2 < ViewOption < 5, true, false) → ShowAllVariablesIf(4 < ViewOption < 9, true, false) → ShowSomeValuesPolygon(ScreenBottomLeftCorner, ScreenBottomRightCorner, ScreenTopRightCorner, ScreenTopLeftCorner) → MainBackground, screenbottomleftcorner, screenbottomrightcorner, screentoprightcorner, screentopleftcornerCorner(2, 1) → ConsoleBLCorner(2, 2) → ConsoleBRCorner(2, 3) → ConsoleTRCorner(2, 4) → ConsoleTLPolygon(ConsoleBL, ConsoleBR, ConsoleTR, ConsoleTL) → ConsoleBackground, consolebl, consolebr, consoletr, consoletlIf(Mod[ViewOption, 2] ≟ 0, true, false) → ShowPointLabelsIf(9 ≤ ViewOption ≤ 10, true, false) → ShowSomeVariablesAndValuesIf(13 ≤ ViewOption ≤ 14, true, false) → ShowAllVariablesAndValues