[Math] coordinate geometry – find point in right-angled triangle

coordinate systemsgeometry

I'm making a map. I've come across a geometry problem, and I'm not so knowledgeable about maths! Let me illustrate with pictures. I am trying to plot flightpaths with a curved line, using a quadratic bezier curve as outlined here:

https://developer.mozilla.org/en-US/docs/Web/SVG/Tutorial/Paths#Bezier_Curves

So I need to calculate 1 control point, like this (red point):

enter image description here

I have already managed to calculate the midpoint of the line, and also the correct angle to project the control point perpendicular to the line. But how do I proceed from here? The problem can be boiled down as follows:

enter image description here

What are the coordinates of the red point? (I know the length of the hypotenuse as I define this elsewhere).

I'm sorry, I'm sure this is very basic geometry but I am unsure of the terms to search for and hence, haven't found anything on Google. I am working with GPS coordinates which are in decimal format, and can be negative. Thanks.

Best Answer

if $(a,b)$ is the cordinates of the known point. then unknown point is $(a+r\cos \theta,b+r\sin \theta)$ where $r$ is the known length and $\theta$ the angle.

Related Question