Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

define and prove properties of orthocenters with vector algebra #294

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

tonyxty
Copy link
Contributor

@tonyxty tonyxty commented Jan 18, 2024

The definition might not be "geometric" enough but takes care of all corner cases.

Even if we decide upon another definition later, this lemma should still be useful.

@@ -10,7 +11,15 @@ variable {P : Type _} [EuclideanPlane P]

def TriangleND.Height1 (tr_nd : TriangleND P) : SegND P := sorry

structure IsOrthocenter (tr_nd : TriangleND P) (H : P) : Prop where
-- this takes care of corner cases such as right triangles, where AH ⟂ BC runs into trouble since A = H
def IsOrthocenter (tr_nd : TriangleND P) (H : P) : Prop := inner (VEC tr_nd.point₁ H) (VEC tr_nd.point₂ tr_nd.point₃) = (0 : ℝ) ∧ inner (VEC tr_nd.point₂ H) (VEC tr_nd.point₃ tr_nd.point₁) = (0 : ℝ) ∧ inner (VEC tr_nd.point₃ H) (VEC tr_nd.point₁ tr_nd.point₂) = (0 : ℝ)
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

  1. Please write this as a structure
structure IsOrthocenter ... : Prop where

to avoid usage of plural and.

  1. Is it possible to use perpendicular, or perp foot or LiesOn Height1 to define orthocenter? I do hope that there will be a "uniform" way of defining each center of a triangle. This needs a further discussion.

Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

  1. Please write a plan file (possibly using overleaf) if you are going to build a whole new file, thank you! You may find some example of plan file in the folder PlanFiles.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LiesOn Height1 will work, but the necessary lemmas are not ready yet.

-- this takes care of corner cases such as right triangles, where AH ⟂ BC runs into trouble since A = H
def IsOrthocenter (tr_nd : TriangleND P) (H : P) : Prop := inner (VEC tr_nd.point₁ H) (VEC tr_nd.point₂ tr_nd.point₃) = (0 : ℝ) ∧ inner (VEC tr_nd.point₂ H) (VEC tr_nd.point₃ tr_nd.point₁) = (0 : ℝ) ∧ inner (VEC tr_nd.point₃ H) (VEC tr_nd.point₁ tr_nd.point₂) = (0 : ℝ)

theorem orthocenter_exists (tr : Triangle P) (H : P) (h₁ : inner (VEC tr.point₁ H) (VEC tr.point₂ tr.point₃) = (0 : ℝ)) (h₂ : inner (VEC tr.point₂ H) (VEC tr.point₃ tr.point₁) = (0 : ℝ)) : inner (VEC tr.point₃ H) (VEC tr.point₁ tr.point₂) = (0 : ℝ) := by
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This theorem could be instead stated as a def that takes in an triangle and output a point. Then check this def do satisfies IsOrthocenter

Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This strategy is used in the file AngBisector. Maybe first writing a plan file or discussing directly with me is more time-saving!

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Well, this can be implemented. But surely there is no need to complete everything in one commit?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants