FredixBlog


Just my log about anything I could find enjoyable.



Coordinates of the third point

author Posted by: fredometro on date Jan 6th, 2004 | filed Filed under: MS-Access

Quertion: Hi!
How would you calculate the coordinate of a third point I have already two points, distances and angles from these points to the third point. I want to do triangulation and I don’t know which formula to apply.
Thanks

Hi!

Try the function below:


Global Const PI = 3.14159265358979

Public Function calRayonnement(Xa, Ya, DistanceAC, AngleInDegrees, OutputsXcOrNotXcAsResult As Boolean)
' Ray calculate next point coordinates from angle & distance.
' Xa , Xb are the coordinnates for starting point
' DistanceAC : Distance to measured point
' AngleInDegrees : as named
' OutputsXcOrNotXcAsResult = True, function will return Xc otherwise Yc, the coordinates of measures point

Dim Xc, Yc, glAB, lnV, lnH, lnD
Dim AngleInGradient

     AngleInGradient = AngleInDegrees / 180 * PI

     Xc = Xa + DistanceAC * Sin(AngleInGradient)
     Yc = Ya + DistanceAC * Cos(AngleInGradient)

     Debug.Print
     Debug.Print "Xc = " & Xc
     Debug.Print "Yc = " & Yc

     If OutputsXcOrNotXcAsResult Then calRayonnement = Xc Else calRayonnement = Yc

End Function

Output of these functions:

No related posts.

     Add A Comment

You must be logged in to post a comment.


Warning: include(/home/www/web421/html/phpTraffic/write_logs.php) [function.include]: failed to open stream: No such file or directory in /home/websitef/public_html/fredometro.com/wp-content/themes/blueshadow/footer.php on line 15

Warning: include() [function.include]: Failed opening '/home/www/web421/html/phpTraffic/write_logs.php' for inclusion (include_path='.:/usr/lib/php:/usr/local/lib/php') in /home/websitef/public_html/fredometro.com/wp-content/themes/blueshadow/footer.php on line 15