My question is how does google map or mobile GPS able to find mine current location ?
My high level understanding after reading this article is , GPS receiver gets the location coordinates through these satellites and this location is further passed to Google Map(or any other client) API which then locates the exact location on map. Is it correct ?
Somewhere i also read that Mobile towers also plays the role. But my unserstanding is that this can be used to track the mobile location if required but mobile apps or Google maps uses the satellite approach. Right ?
It's a bit inaccurate question to ask "How does google map location works", because Google Maps app (as well as any application leveraging google maps API) is just a consumer of location services on your device and is not used to determine the current location itself.
Because Google Maps is just an application, it can be run inside browser, or as native application. Depending on that, the way how it gets to your location information may also vary.
If you run the Google Maps from web browser (or WebView, or UIWebView,..) it usually uses HTML 5 geolocation API to determine your location and then use that to show your position on Google Maps. HTML5 geolocation then uses some lower level services to get your location, like GPS sensor, WIFI, network etc. There are already questions on how HTML 5 geolocation determines your position on SO, like this one or this one.
If your app is run as standalone application, it depends on your platform, your device sensors, your network,.. how the location is determined. So for example on Android with GPS sensor, LocationManager is used, which retrieves the location again using GPS, or from network provider, or returns last known location, etc. There's a lot of various interesting techniques behind this, which you can look up yourself (For example to determine your location using Wifi, Google has a database of WIFI SSIDs and their locations retrieved using anonymous device tracking and is able to roughly tell your location only from Wifi networks around you.)
来源:https://stackoverflow.com/questions/37894741/how-does-google-map-location-works