Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

GPS Inaccuracy in Cell Phones

72 views
Skip to first unread message

Tom Kunich

unread,
Apr 11, 2020, 8:56:36 PM4/11/20
to
After trying to use these cell phone apps that us GPS to give distance traveled I've looked up data trying to discover why these apps are so far out of kilter.

This isn't just my assessment, before when my friend still lived in Castro Valley he was using some app that always had noticeably less mileage than my or his wife's speedometers.

As I said before, Strava was consistently 6% shorter than my speedo. MapMyRide wasn't even in the same ballpark. At first I attempted to explain the 6% loss on the climbing and descending but this course is so flat that there isn't a total of 100 feet change in altitude over the entire course. This would make a maximum error of about a 1/10th of a percent.

Then I figured that it had to do with latitude corrections not being properly made. While that may be part of the problem it isn't very likely since rather than the old geosynchronous orbits that were originally used, they are using an entire spate of GPS satellites that are in all sorts of orbits and at a distance that allows them to make complete orbits twice a day. They sent out their precise point in the orbit and if you have exact time and several satellites you can calculate (triangulate if you will) your position. The best GPS units can handle 20 satellites at once and can get your position down to mm.

Question: could this error be due to time since the time of the GPS apps is derived not internally but from the cell phone center which can be several miles from you and transferred through several cell towers?

This seems pretty likely to be the problem to me. Being just one microsecond off could increase the error band to 1131 feet on a single satellite and it is unlikely that that apps track more than two or three satellites at a time. On a 3 satellite lock this would interestingly enough give an error band of about 6%.

Since this ride is local it would always be using the same cell CPU to be getting the time and so you would expect a pretty consistent error always in the same direction while on a long distance ride the errors would be divided between plus and minus errors and would average out to little or no discernable errors.

Likewise the error on my friend's app for the Palomares ride always gave approximately the same sort of error relatively reliably.

Military grade GPS that has an entirely different approach to getting time. I have designed clocks that lost one microsecond in a week. This requires a crystal oven that can regulate crystal oscillator temperatures to within a tenth of a degree C or better per 24 hour time period. The crystal is cut on a particular bias of the grain which I cannot remember. Crystals grow like a tree with a grain. This high accuracy crystal is frequency controlled by its size, the placement of the electrodes and temperature. The highest accuracy ones are extremely wasteful of these crystal structures. If you have precise location of where your position is you can use this to get precise time from your transmissions from the satellites and set the time precisely the first time. From that point you can find your exact position and then again with multiple satellites reset your timer as often as you find a significant timing error. These GPS systems use up to 20 satellites encoded in a manner that commercial devices cannot unlock. This is how you can target any location from any other location with mm distance errors. This means that the ONLY accurate means of touching that spot is from perfectly vertical from the target. Also since all of these satellites pass an un-named precisely known point at a precisely known distance you can reset the satellite timers which are necessary for this system.

This is the sort of thing I was paid to know and use. This was why I could get a quarter of a million bucks a year and have people standing in line for my services. Too bad about the concussion which caused me a couple of years out of the field at just exactly the wrong time - when one generation of managers that knew me were retiring and another which didn't took over. Resume's mean very little in the immediate area you're looking, because most of the hiring is done from recommendations of high level managers. But the resume alone is enough to get me jobs in Illinois or Texas or Arizona or Florida (???) were I willing to relocate. Last week I had two offers from aerospace firms in San Diego but I can't get the wife to move away from her children and grandchildren. And I really don't care to go back through the effort of showing boards of directors and CEO's what I can do. When I first recovered I should have immediately taken the jobs I was offered as some of these managers were still working and wanted me at places like Lawrence Labs in Berkeley and Sandia in Livermore. But quite frankly with my spotty memory I didn't think I still had it. Finally I was talked into taking a job for a friend and I told him that I would not allow him to pay me. But as soon as I sat down with the schematic and idiot code that the previous programmer had made it was all as fresh as yesterday. My total pay for 8 months was gas money to the job location and a $2,000 H-P laptop which I haven't even opened since the end of that job.



Ralph Barone

unread,
Apr 11, 2020, 9:49:59 PM4/11/20
to
Tom Kunich <cycl...@yahoo.com> wrote:
> After trying to use these cell phone apps that us GPS to give distance
> traveled I've looked up data trying to discover why these apps are so far out of kilter.
>
> This isn't just my assessment, before when my friend still lived in
> Castro Valley he was using some app that always had noticeably less
> mileage than my or his wife's speedometers.
>
> As I said before, Strava was consistently 6% shorter than my speedo.
> MapMyRide wasn't even in the same ballpark. At first I attempted to
> explain the 6% loss on the climbing and descending but this course is so
> flat that there isn't a total of 100 feet change in altitude over the
> entire course. This would make a maximum error of about a 1/10th of a percent.
>
> Then I figured that it had to do with latitude corrections not being
> properly made. While that may be part of the problem it isn't very likely
> since rather than the old geosynchronous orbits that were originally
> used, they are using an entire spate of GPS satellites that are in all
> sorts of orbits and at a distance that allows them to make complete
> orbits twice a day. They sent out their precise point in the orbit and if
> you have exact time and several satellites you can calculate (triangulate
> if you will) your position. The best GPS units can handle 20 satellites
> at once and can get your position down to mm.
>
> Question: could this error be due to time since the time of the GPS apps
> is derived not internally but from the cell phone center which can be
> several miles from you and transferred through several cell towers?
>
No. GPS predates cell phone systems that send out time. GPS receivers get
their time signal from the satellites themselves.

Tom Kunich

unread,
Apr 12, 2020, 11:09:00 AM4/12/20
to
Palph, what in the hell are you talking about? If you don't understand how GPS works please don't tell me how you think it works. There is a large difference between a commercial GPS that has an internal reference clock and a military grade GPS which can derive its time in several ways.

While talking about how GPS predates cell phones explain my Sony watch which always has the correct time which I bought in the 70's and is still working today.

Ralph Barone

unread,
Apr 12, 2020, 12:50:47 PM4/12/20
to
OK, let me try this in more detail. GPS satellites send out a data packet
which contains the satellite’s x, y and z position, as well the the time
from the satellite’s internal atomic clock. If your receiver can get
signals from four satellites, then it can solve the equations to determine
the receiver’s x, y, z and t. If you can see more than four satellites, the
receiver then does a weighted least squares type of fit to get a more
accurate position signal. Look it up if you don’t believe me. The main
difference between civilian and military GPS units is that the military
units have the capability of using the SA (selective availability) signal,
which is a higher accuracy code which is broadcast along with the regular
“low accuracy” signal. There are numerous other small, but important
differences between the two, but SA is the big one.


> While talking about how GPS predates cell phones explain my Sony watch
> which always has the correct time which I bought in the 70's and is still working today.
>

Your Sony watch probably receives a WWVB signal (transmitted at 60 kHz)
containing time code, so it is not a GPS device (nor a cell phone, which
makes it a weak counter argument to a statement about GPS and cell phones).
Secondly, my statement was not that GPS predates cell phones. It was that
GPS predates cellular services which transmitted accurate time. TDMA
required (by definition), the receiver to switch at accurate times,
therefore a time signal was added to the protocol to sync the receivers.
TDMA rolled out circa 1990. Civilian GPS receivers came out in the 80s.

PS: I used to sit next to the guy who rolled out GPS enabled fault location
in our utility, and who also tested the accuracy of GPS time receivers
using our own cesium clock.


Tom Kunich

unread,
Apr 12, 2020, 4:27:49 PM4/12/20
to
On Sunday, April 12, 2020 at 9:50:47 AM UTC-7, Ralph Barone wrote:
>
> OK, let me try this in more detail. GPS satellites send out a data packet
> which contains the satellite’s x, y and z position, as well the the time
> from the satellite’s internal atomic clock. If your receiver can get
> signals from four satellites, then it can solve the equations to determine
> the receiver’s x, y, z and t. If you can see more than four satellites, the
> receiver then does a weighted least squares type of fit to get a more
> accurate position signal. Look it up if you don’t believe me. The main
> difference between civilian and military GPS units is that the military
> units have the capability of using the SA (selective availability) signal,
> which is a higher accuracy code which is broadcast along with the regular
> “low accuracy” signal. There are numerous other small, but important
> differences between the two, but SA is the big one.

Cesium "clocks" are not clocks at all. They are an extremely accurate frequency standard. You still have to use digital electronics around it to make it into a clock.

And every single satellite has to have synchronized clocks. This accuracy has to be so accurate that not only to you have to take into account the distance that the signal has to travel at the speed of light, but the actual location in its orbit which gives you relative speed hence giving you the ability to measure the shift in time due to relativity.

In the normal speed regimes it isn't much but it is enough that military GPS must account for it.

With a somewhat faulty memory I don't believe that they send X,Y, and Z because they don't know it. Then send a satellite ID and their time. Your GPS looks up that satellite and its supposed location at that time (with all of the time corrections) which gives you their position. Comparing that distance with your clock give you a distance.

So now you have a satellite and its distance from you. That circumscribes and entire circle that is that distance from that satellite at that time.

Doing this for at least three satellites up to I believe as many as 20 gives you and increasingly accurate position.

Remember not only do you have to correct for speed and distance but actual processing time in the electronics which includes counting actual operations.

I remember actually writing this stuff but damned if I can remember who for or when.

I also remember that the satellites have to have their clocks corrected because their orbits are not stable because of atmospheric drag and a change in relative velocities.

This crap can get so complicated that you could spend your entire life on nothing else but GPS. There is a lot more that comes into play such as updating GPS files which hold the exact position at the exactly time. This is most easily done on ground files. I can't remember if a GPS receiver keeps the data in files or perhaps like you said that they are transmitted with the time signal and ID. There would be a hell of a lot of problems with that. It would mean updating satellite position files virtually twice a day to keep the satellite correct.

Normal GPS probably doesn't need an accuracy of better than 10 feet or so.

Ralph Barone

unread,
Apr 12, 2020, 6:28:28 PM4/12/20
to
So to summarize, GPS location from your phone does does not depend on the
clock in the phone (although in urban areas where view of the GPS
satellites may be spotty, phones can get a position fix by triangulation
from (known location) cell phone towers.

John B.

unread,
Apr 12, 2020, 6:56:12 PM4/12/20
to
A delusion is a false belief that is not subject to reason or
contradictory evidence which may be firmly maintained in the face of
incontrovertible evidence that it is false. Delusions are common
psychotic disorders and can also be a feature of brain damage or
disorders.Examples of delusions include the sufferer believing that
one has an unusual power or talent.
--
cheers,

John B.

John B.

unread,
Apr 12, 2020, 6:56:42 PM4/12/20
to

Radey Shouman

unread,
Apr 12, 2020, 7:19:04 PM4/12/20
to
Tom Kunich <cycl...@yahoo.com> writes:

> On Sunday, April 12, 2020 at 9:50:47 AM UTC-7, Ralph Barone wrote:
>>
>> OK, let me try this in more detail. GPS satellites send out a data packet
>> which contains the satellite’s x, y and z position, as well the the time
>> from the satellite’s internal atomic clock. If your receiver can get
>> signals from four satellites, then it can solve the equations to determine
>> the receiver’s x, y, z and t. If you can see more than four satellites, the
>> receiver then does a weighted least squares type of fit to get a more
>> accurate position signal. Look it up if you don’t believe me. The main
>> difference between civilian and military GPS units is that the military
>> units have the capability of using the SA (selective availability) signal,
>> which is a higher accuracy code which is broadcast along with the regular
>> “low accuracy” signal. There are numerous other small, but important
>> differences between the two, but SA is the big one.
>
> Cesium "clocks" are not clocks at all. They are an extremely accurate
> frequency standard. You still have to use digital electronics around
> it to make it into a clock.

Pendulum "clocks" are not clocks at all. They are a moderately accurate
frequency standard. You still have to use mechanical parts around it to
make it into a clock.

Sorry, no opinion on GPS, just had to point that out.

news18

unread,
Apr 12, 2020, 8:20:28 PM4/12/20
to
On Sun, 12 Apr 2020 08:08:57 -0700, Tom Kunich wrote:


> Palph, what in the hell are you talking about? If you don't understand
> how GPS works please don't tell me how you think it works. There is a
> large difference between a commercial GPS that has an internal reference
> clock and a military grade GPS which can derive its time in several
> ways.

Wow, how is your foot little Tommy.

news18

unread,
Apr 12, 2020, 8:25:25 PM4/12/20
to
On Sun, 12 Apr 2020 13:27:46 -0700, Tom Kunich wrote:


> Normal GPS probably doesn't need an accuracy of better than 10 feet or
> so.

Too funny by half.

Jeff Liebermann

unread,
Apr 12, 2020, 8:39:50 PM4/12/20
to
On Sat, 11 Apr 2020 17:56:33 -0700 (PDT), Tom Kunich
<cycl...@yahoo.com> wrote:

>Strava was consistently 6% shorter than my speedo. MapMyRide wasn't
>even in the same ballpark. At first I attempted to explain the
>6% loss on the climbing and descending but this course is so flat
>that there isn't a total of 100 feet change in altitude over the
>entire course. This would make a maximum error of about a 1/10th
>of a percent.

In my limited experience, the GPS derived distance traveled is greater
than what is indicated by a cycling computah. My guess(tm) is the
algorithm employed by the GPS software was over-compensating for GPS
errors. Not so short explanation:

If you log the NMEA-0183 GGA and GLL position reports produced by a
commodity GPS, and plot all the points on a map, you'll see a not very
good approximation of a curve or straight line. If you connect each
point in the order in which they are logged (time sequential), the
length of the resultant zig-zag line will be MUCH longer than the path
traveled. At best, any given point is accurate to within a 4.9 meter
(16ft) radius circle. Imagine yourself riding down a straight road,
where the position reports can be randomly placed anywhere within this
circle. That's not going to be even close to a straight line.

However, that's the worst case and without any attempt at error
reduction, error correction, line smoothing, etc. The simplest form
of smoothing the line of travel is to first throw out any wildly
erroneous position reports (usually caused by reflections, diffraction
around buildings, or ground bounce). Next, connect the remaining line
segments, divide each segment in half, and connect all the mid-points
together. Do that a few dozen times, and you will get a fairly smooth
curve. However, since the points can be both ahead and behind the
actually position, the order in which the midpoints are connected is
switched from ordered by time, to ordered by position along the
estimate path traveled. From here, there are a large number of
statistical tweaks that can be used to improve the accuracy. The
resultant smoothed path will be less than the original jagged path (as
long as the path of travel is roughly a straight line). When
smoothing can no longer reduce the path length, then you've done as
much smoothing as possible.

Making 90 degree turns is another interesting problem. If you take
the raw NMEA-0183 data, and plot a path of travel that has a 90 degree
turn, the GPS will usually produce an overshoot on the straight path
before making the turn. It will eventually return to the correct path
of travel, but only after wandering around and adding additional
length too the path of travel. There are processors that look for
such turns and compensate.

That should be enough for now. If you have any questions, feel free
to ask AFTER you've provided my previously requested retraction to
your "nearly 100%" positive test rate claim for Alameda County:
<https://groups.google.com/d/msg/rec.bicycles.tech/EuiU0nkYAVM/7M0k1cdxAAAJ>


--
Jeff Liebermann je...@cruzio.com
150 Felker St #D http://www.LearnByDestroying.com
Santa Cruz CA 95060 http://802.11junk.com
Skype: JeffLiebermann AE6KS 831-336-2558

Frank Krygowski

unread,
Apr 12, 2020, 11:03:36 PM4/12/20
to
I've also observed a simple trick built in to our GPS. When we enter a
long tunnel, our position is still shown changing on the screen, despite
the lack of satellite data. The system is smart enough to extrapolate
from our speed when entering. I've seen it demonstrate an error when
I've had to slow down significantly in a tunnel.


--
- Frank Krygowski

Tom Kunich

unread,
Apr 13, 2020, 12:26:01 AM4/13/20
to
There is no clock per se in your phone. If you power down your phone, wait ten minutes and start it again it comes up with the correct time to the minute. Most phones have an app that mimics a clock. It is set from your nearest cell phone tower.

Tom Kunich

unread,
Apr 13, 2020, 12:28:08 AM4/13/20
to
Why don't you tell us how old you are and what you've ever done for a living?

Ralph Barone

unread,
Apr 13, 2020, 2:23:23 AM4/13/20
to
Tom, please note that it was YOUR hypothesis that GPS path length errors in
phone mapping applications might be the result of the GPS using “its
internal clock” instead of GPS time.

Secondly, your pedantic assertions that neither a cesium clock nor a cell
phone are a clock because they need to be set also apply for pretty much
any other device which humans call clocks.

Ralph Barone

unread,
Apr 13, 2020, 2:23:25 AM4/13/20
to
Surveying. GPS guided tractors and bulldozers.

Ralph Barone

unread,
Apr 13, 2020, 10:32:03 AM4/13/20
to
Shouldn’t have written this while on my way to bed. The first sentence
should have read:

Tom, please note that it was YOUR hypothesis that GPS path length errors in
phone mapping applications might be the result of the cell phone using

Ralph Barone

unread,
Apr 13, 2020, 10:32:07 AM4/13/20
to
Pretty much all clocks consist of an oscillator (eg: the earth’s rotation),
coupled to a decoding device (eg: a stick casting a shadow onto a dial),
with a means to set the clock to conform to some arbitrary standard of when
“now” is (eg: rotating the dial), so calling out our HP cesium clock as
“not a clock” seemed weird, since it did have all three.

As an interesting sideline, we purposely set our HP 100 ns earlier than GPS
time so that when we were comparing the accuracy of the 1 PPS output of the
cesium to the GPS time receiver under test, we could trigger the scope/time
interval counter from the HP and always be guaranteed that the GPS 1 PPS
would show up around 100 ns later. We would then log the delay between the
two signals, subtract 100 ns, and have a plot of the accuracy and jitter of
the device under test.

Andy

unread,
Apr 19, 2020, 6:22:07 PM4/19/20
to
> While talking about how GPS predates cell phones explain my Sony watch which always has the correct time which I bought in the 70's and is still working today.

That is quite funny.

You made my day. :-)

Andy

Jeff Liebermann

unread,
Apr 20, 2020, 12:29:26 AM4/20/20
to
Probably not an "atomic clock".
"Radio Controlled Clocks"
<https://tf.nist.gov/general/pdf/1877.pdf>
It gives a tolerable history of radio clocks.
"Laboratory type receivers for the LF signals appeared in
both the United States and Europe during the 1960s and 1970s..."
From about 1973 to 1981, I was working for a marine radio
manufacturer. Some of my tinkering included Loran C, NAVSAT (early
doppler), NAVSTAR (now GPS). The 100KHz Loran C receiver morphed into
a 60KHz WWVB receiver. However, the project died when we discovered
that a rather complicated decoder was required, and that a rather high
(at the time) license fee would need to be paid to the license holder.
Incidentally, the same thing happened in 2010, when WWVB added BPSK
modulation. No chips, no license, no service, and one giant step
backwards:
WWVB BPSK Modulation Remover - the "Dephaser"
<http://www.californiahistoricalradio.com/wp-content/uploads//2017/02/CHRS-Construction-BPSK-Dephaser-John-Staples.pdf>

Anyway, back on topic, Sony or any other Japanese company would have
little reason to produce a LF wristwatch without a domestic market.
See table 1 in the NIST document above, Pg 5 for the dates that
various transmitter were put into service:
WWVB US 1965
MSF UK 1974
DCF Germany 1973
JJY Japan 1999 (and 2001 for 60KHz)
BPC China 2002
We were watching the radio clock market during the 1970's. All I saw
were very large "instruments" made for laboratories and scientific
expeditions. The NIST article above mentions some of the early
devices which includes LF watches starting in 1990:
"The first radio controlled wrist watch is believed to be
the Junghans MEGA 1, which debuted in 1990, an introduction
that was hailed by one reviewer as 'one of the most momentous
horological events ever'. This digital watch synchronized to
signals from station DCF77 in Germany. Figure 9 shows the
watch and its internal clockwork, including the antenna
embedded inside the wrist band."
In other words, there were no consumer wristwatch atomic clocks in the
1970's.

>Secondly, my statement was not that GPS predates cell phones. It was that
>GPS predates cellular services which transmitted accurate time. TDMA
>required (by definition), the receiver to switch at accurate times,
>therefore a time signal was added to the protocol to sync the receivers.
>TDMA rolled out circa 1990. Civilian GPS receivers came out in the 80s.

Sorta-maybe. GPS was first used in 1.9GHz PCS (TDMA) base stations to
synchronize the SONET clocks starting in 1995. GPS deployment
starting in 1978. The full 24 satellite constellation was ready for
general consumption in 1993. There were also some GPS modules crammed
into trunk mounted analog cellular phones and in some analog "bag
phones". However, these were rare and lacking a suitable display,
were only used for tracking.

>PS: I used to sit next to the guy who rolled out GPS enabled fault location
>in our utility, and who also tested the accuracy of GPS time receivers
>using our own cesium clock.

I was the guy who, after seeing an early GPS receiver, declared that
such a receiver would never be smaller or weigh less than two bricks.

pH

unread,
Apr 20, 2020, 7:07:36 PM4/20/20
to
<snip>

>
> OK, let me try this in more detail. GPS satellites send out a data packet
> which contains the satellite’s x, y and z position, as well the the time
> from the satellite’s internal atomic clock. If your receiver can get
> signals from four satellites, then it can solve the equations to determine
> the receiver’s x, y, z and t. If you can see more than four satellites, the

<snip>
...not trying to be troll here, but x, y and z relative to WHERE?

What is the standard origin used with a rotating ball traveling through space?
Does it go back to the Prime Meridian and Greenwhich Main Time in some manner?

url to some basic primer appreciated.

pH in Aptos


Ralph Barone

unread,
Apr 20, 2020, 9:14:18 PM4/20/20
to
I’ll be honest here. I’ve got no clue. I can only imagine that the math
would be easier if the satellites broadcast their position in the same
coordinate system that the GPS eventually outputs. It can’t be more than
two Google searches away.

And it’s probably not x, y, z, t, but altitude, longitude, latitude, t, or
some similar spherical coordinate system

0 new messages