Correctly draw on Google Maps a point which exceeds 90 degrees of latitude - google-maps

I'm working on a simulator that plots the flight path of an aircraft on Google Maps.
The simulator is not aware that the latitude is only defined between -90 and +90 degrees and the longitude between -180 and +180 deg. As a result of this, the flight path may include points beyond the map boundaries. Exceeding in longitude is not an issue as it still plots correctly (a point at longitude x and x+360 is the same), but the latitude is a problem.
Is there any way of telling Google Maps to keep the points between the correct boundaries and plot them correctly?
Otherwise, do you have any ideas of where to find functions that do so?

Longitude, latitude and elevation are a bad coordinate system for a flight simulator, because the mapping presents singularities i.e. there are points infinitely close on the earth that have very different coordinates. For example where you're close to one of the poles longitude variation speed can become arbitrarily big compared to airplane speed. When standing exactly on the pole the longitude doesn't even make sense.
A better solution is to use an XYZ coordinate system for the simulator and only convert to longitude/latitude and elevation for plotting. If you can approximate the earth to a sphere for your use case the computation of this transformation is trivial... otherwise things can get much more complex depending on how accurate you want it to be.
That said it's still possible to give "a" meaning to a point with latitude slightly outside the range -90...90 by extending it over the pole...
if latitude < -90:
latitude = -180 - latitude
longitude = longitude + 180
if latitude > 90:
latitude = 180 - latitude
longitude = longitude + 180
but using this coordinate system for navigating is a very bad idea (the same point in space can have multiple triplets of coordinates).

If your simulator doesn't know that the maximum value for latitude is 90 degrees it is broken and needs to be fixed. Google Maps works correctly for valid/possible values of latitude and longitude.

Related

What is maximum points limit for Google's heatmap feature?

Hello there's I am use google's Heatmap feature in my project. I do not know whats the maximum points (latitude ,longitude )limit for google's heatmap to visualization.
There is no limit to the number of points added to the heatmap, but there are practical constraints (the memory of the device displaying them, the time to load them, etc.)
Longitude is in the range -180 and +180 specifying coordinates west and east of the Prime Meridian, respectively. For reference, the Equator has a latitude of 0°, the North pole has a latitude of 90° north (written 90° N or +90°), and the South pole has a latitude of -90°.
The limit is for longitude and latitude not for google heatmap feature for using latitude or longitude. If your latitude/longitude is in valid range , it will work.

Greater latitude and longitude values

I came across a dataset which has Latitude values in the range (0,181.763) i.e. minimum latitude is 0 degree and maximum latitude is 181.763 degree and Longitude values in the range (228.722,242.008) i.e. minimum latitude is 228.722 degree and maximum latitude is 242.008 degree. Is there some way by which I may confine the latitude and longitude's to correct boundaries?
well if they are spherical coordinates, long 181.763deg points in the same direction as -178.237deg or 361.763deg, depending on the conventions used
to transform latitude ranges of (228.722,242.008) to (-90,90) the transformation matrix to use is ((x-228.722)/0.073811)-90 for each point x. for example 229.3deg gives -82.169deg
it could be that you are using slightly scaled (elliptical) polar coordinates and you can transform them back by division...

NOAA's GIS Polygons - How to use them?

NOAA gives a Polygon area for plotting shapes on a map. The only thing I can find in google maps is to use a lat/lon to create a shape.
You can view the warnings here with their polygons:
http://www.nws.noaa.gov/regsci/gis/last10.html
Can somebody please tell me what these 4 digit numbers represent and if it's possible to convert them to a latitude / longitude.
The numbers are hundredths of degrees. A 4-digit number is latitude, so for instance 3503 represents 35.03 degrees North latitude. A 5-digit number is longitude, so 10581 would be 105.81 degrees West longitude.

Why is this lat lng coordinate is split into 2 halfs?

I have this file from tsp.gatech but the lat lng coordinate is divide into two half. Why is this?
COMMENT: Created July 7, 2012, www.tsp.gatech.edu/data/usa/
1 33613.158800 86118.306100
2 33100.954000 85529.675300
3 31571.835200 85250.489300
For example the first coordinate should be 33.613158800 86.118306100.
Update: I searched for New York City and I found it lat lng coordinate to be similar.
Update 2: I think it's incorrect formated see this image of points: http://www.tsp.gatech.edu/data/usa/img/usa115475_large.jpg. I get the points from a file from this website: http://www.tsp.gatech.edu/data/usa/index.html. The site is about a challenge and the file I downloaded is usa115475.tsp.
Euclidean Distance would tend to suggest the values are X,Y distances from a reference point (in feet, meters, kilometers, miles, ...). But this is normally reserved for small scale mapping where the effects of the curvature of the earth can be considered minor.
If the data seems to correspond to decimal degrees that are incorrectly formatted, there could be an error in whatever system is returning the data. But its better to review your own processes before pointing the finger. What query/process/code are you doing to obtain this data?

How do I convert from this weird Coordinate unit to LngLat for use in Google Maps?

I have a database full of rows if coordinate pairs like this:
ux: 6643641
uy: 264274
uz: NULL
I have been tasked to make all these coordinates appear on google maps as points of interest, but nobody could tell me what the hell those coordinates were.
What I need for Google Maps is longitude and lengtitude coordinates. I know the one can be converted to the other, but nothing more.
I realize this might not be the correct place to ask about coordinate systems, but I honestly couldn't think of any other place to state the question.
Thanks for any help!
That's my bad, I now see that there is more data for each row:
CoordSystemNumber: 23
CoordSystemName: EUREF89 UTM Sone 33
I think that format is called UTM. You need to know the Zone and Hemisphere to complete the conversion. Is there other data associated with this?
Tell me if this seems helpful :
x = 882880 meters
y = -4924482 meters
z = 3944130 meters
Geocentric latitude and longitude are not commonly used, but they are defined by
latitude = arctan( z / sqrt( x^2 + y^2 ) )
longitude = arctan( y / x )
Taken from here :
http://www.cv.nrao.edu/~rfisher/Ephemerides/earth_rot.html
see this too :
http://en.wikipedia.org/wiki/Geographic_coordinate_system
This wikipedia article might offer some help.
The coordinates are often chosen such that one of the numbers represent vertical position, and two or three of the numbers represent horizontal position. A common choice of coordinates is latitude, longitude and elevation.