calculate the area of an irregular polygon given latitude and longitude coordinates

Got a LiveCode personal license? Are you a beginner, hobbyist or educator that's new to LiveCode? This forum is the place to go for help getting started. Welcome!

Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller

Post Reply
danielrr
Posts: 140
Joined: Mon Mar 04, 2013 4:03 pm

calculate the area of an irregular polygon given latitude and longitude coordinates

Post by danielrr » Sat May 25, 2019 10:34 am

I have the geographic coordinates of a large collection of places on Earth. I am trying to determine which the area covered by each one of them.

For example:

GroupA: "35.4042","33.7833"; "35.4042","33.7833"; "38.3937","23.7931"
GroupB: "38.4625","23.5907"; "35.4042","33.7833"; "38.3937","23.7931";"38.5833","22.6667"
GroupC: "37.3991","25.2664"; "35.4042","33.7833"; "38.3937","23.7931"; "37.8531","15.2879"

etc.

Do you know how to solve this math problem with LC?

[-hh]
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 2262
Joined: Thu Feb 28, 2013 11:52 pm
Location: Göttingen, DE

Re: calculate the area of an irregular polygon given latitude and longitude coordinates

Post by [-hh] » Sat May 25, 2019 2:12 pm

You could use the answer from here
https://stackoverflow.com/questions/478 ... -longitude

This is Java (SphericalUtil.ComputeSignedArea method from Google's Maps Utils) or C# and is easily translated to LC.
shiftLock happens

Post Reply

Return to “Getting Started with LiveCode - Complete Beginners”