Rocksolid Light

Welcome to novaBBS (click a section below)

mail  files  register  newsreader  groups  login

Message-ID:  

Those who can, do; those who can't, write. Those who can't write work for the Bell Labs Record.


devel / comp.sys.hp48 / Re: is it a bug or don't I get it?

SubjectAuthor
* is it a bug or don't I get it?Marc Tee
`* Re: is it a bug or don't I get it?druid.bernard@gmail.com
 `* Re: is it a bug or don't I get it?Irl
  `* Re: is it a bug or don't I get it?Marc Tee
   +* Re: is it a bug or don't I get it?Richard Mitchell
   |`- Re: is it a bug or don't I get it?Marc Tee
   `- Re: is it a bug or don't I get it?Irl

1
is it a bug or don't I get it?

<9efc5fbb-0bdb-433b-9027-e17d33ab3e4dn@googlegroups.com>

 copy mid

https://www.novabbs.com/devel/article-flat.php?id=66&group=comp.sys.hp48#66

 copy link   Newsgroups: comp.sys.hp48
X-Received: by 2002:ac8:5555:0:b0:2ef:ec30:b65a with SMTP id o21-20020ac85555000000b002efec30b65amr6219575qtr.287.1649837670132;
Wed, 13 Apr 2022 01:14:30 -0700 (PDT)
X-Received: by 2002:a05:6870:d5a2:b0:de:f682:6c4d with SMTP id
u34-20020a056870d5a200b000def6826c4dmr3623304oao.283.1649837669683; Wed, 13
Apr 2022 01:14:29 -0700 (PDT)
Path: i2pn2.org!i2pn.org!weretis.net!feeder6.news.weretis.net!news.misty.com!border2.nntp.dca1.giganews.com!nntp.giganews.com!news-out.google.com!nntp.google.com!postnews.google.com!google-groups.googlegroups.com!not-for-mail
Newsgroups: comp.sys.hp48
Date: Wed, 13 Apr 2022 01:14:29 -0700 (PDT)
Injection-Info: google-groups.googlegroups.com; posting-host=129.205.170.0; posting-account=EPrxEwkAAAB22oFzC3sfI0xtN_t2NShK
NNTP-Posting-Host: 129.205.170.0
User-Agent: G2/1.0
MIME-Version: 1.0
Message-ID: <9efc5fbb-0bdb-433b-9027-e17d33ab3e4dn@googlegroups.com>
Subject: is it a bug or don't I get it?
From: marc.tan...@gmail.com (Marc Tee)
Injection-Date: Wed, 13 Apr 2022 08:14:30 +0000
Content-Type: text/plain; charset="UTF-8"
Lines: 3
 by: Marc Tee - Wed, 13 Apr 2022 08:14 UTC

Hello all
I just wiped the dust off my old HP48GX in order to do some celestial navigation calculations. I like the function to convert HHMMSS into decimal hours, or degrees, if you will.
Everything works fine, I can convert back and forth. But this morning I found a result that was obviously fairly off.
When I calculate 11:54:54 minus 11:52:54 it should give me exactly 2 minutes, easy to see. But the operation on the HP results in 11.915 - 11.8816666667 = 0.333333333. This converted back to HHMMSS equals 0.015999999988, ie. 4 seconds off. Why?

Re: is it a bug or don't I get it?

<80884186-3e0f-404d-9645-1cb186884aden@googlegroups.com>

 copy mid

https://www.novabbs.com/devel/article-flat.php?id=67&group=comp.sys.hp48#67

 copy link   Newsgroups: comp.sys.hp48
X-Received: by 2002:a05:620a:4309:b0:67b:3fc1:86eb with SMTP id u9-20020a05620a430900b0067b3fc186ebmr6791357qko.495.1649856748592;
Wed, 13 Apr 2022 06:32:28 -0700 (PDT)
X-Received: by 2002:a05:6808:1904:b0:2da:2f99:bed8 with SMTP id
bf4-20020a056808190400b002da2f99bed8mr4265581oib.244.1649856748335; Wed, 13
Apr 2022 06:32:28 -0700 (PDT)
Path: i2pn2.org!i2pn.org!weretis.net!feeder6.news.weretis.net!news.misty.com!border2.nntp.dca1.giganews.com!nntp.giganews.com!news-out.google.com!nntp.google.com!postnews.google.com!google-groups.googlegroups.com!not-for-mail
Newsgroups: comp.sys.hp48
Date: Wed, 13 Apr 2022 06:32:28 -0700 (PDT)
In-Reply-To: <9efc5fbb-0bdb-433b-9027-e17d33ab3e4dn@googlegroups.com>
Injection-Info: google-groups.googlegroups.com; posting-host=131.202.65.45; posting-account=iN7EhQkAAAAmxEbh7oLIW0fjdluGeFiP
NNTP-Posting-Host: 131.202.65.45
References: <9efc5fbb-0bdb-433b-9027-e17d33ab3e4dn@googlegroups.com>
User-Agent: G2/1.0
MIME-Version: 1.0
Message-ID: <80884186-3e0f-404d-9645-1cb186884aden@googlegroups.com>
Subject: Re: is it a bug or don't I get it?
From: druid.be...@gmail.com (druid.bernard@gmail.com)
Injection-Date: Wed, 13 Apr 2022 13:32:28 +0000
Content-Type: text/plain; charset="UTF-8"
Lines: 7
 by: druid.bernard@gmail. - Wed, 13 Apr 2022 13:32 UTC

> Hello all
> I just wiped the dust off my old HP48GX in order to do some celestial navigation calculations. I like the function to convert HHMMSS into decimal hours, or degrees, if you will.
> Everything works fine, I can convert back and forth. But this morning I found a result that was obviously fairly off.
> When I calculate 11:54:54 minus 11:52:54 it should give me exactly 2 minutes, easy to see. But the operation on the HP results in 11.915 - 11.8816666667 = 0.333333333. This converted back to HHMMSS equals 0.015999999988, ie. 4 seconds off. Why?

What is the actual code that you are using to make the calculation?

Re: is it a bug or don't I get it?

<48f9c8c8-2167-4b3a-81bc-6a9e70613784n@googlegroups.com>

 copy mid

https://www.novabbs.com/devel/article-flat.php?id=68&group=comp.sys.hp48#68

 copy link   Newsgroups: comp.sys.hp48
X-Received: by 2002:a05:620a:29cb:b0:699:fee3:265a with SMTP id s11-20020a05620a29cb00b00699fee3265amr297260qkp.513.1649901449395;
Wed, 13 Apr 2022 18:57:29 -0700 (PDT)
X-Received: by 2002:a05:6820:1a0b:b0:329:91ef:1e36 with SMTP id
bq11-20020a0568201a0b00b0032991ef1e36mr161143oob.68.1649901449080; Wed, 13
Apr 2022 18:57:29 -0700 (PDT)
Path: i2pn2.org!i2pn.org!weretis.net!feeder6.news.weretis.net!news.misty.com!border2.nntp.dca1.giganews.com!nntp.giganews.com!news-out.google.com!nntp.google.com!postnews.google.com!google-groups.googlegroups.com!not-for-mail
Newsgroups: comp.sys.hp48
Date: Wed, 13 Apr 2022 18:57:28 -0700 (PDT)
In-Reply-To: <80884186-3e0f-404d-9645-1cb186884aden@googlegroups.com>
Injection-Info: google-groups.googlegroups.com; posting-host=172.110.62.70; posting-account=BZgMCQkAAAB5crGlnJa7n74IkW8Ogg8E
NNTP-Posting-Host: 172.110.62.70
References: <9efc5fbb-0bdb-433b-9027-e17d33ab3e4dn@googlegroups.com> <80884186-3e0f-404d-9645-1cb186884aden@googlegroups.com>
User-Agent: G2/1.0
MIME-Version: 1.0
Message-ID: <48f9c8c8-2167-4b3a-81bc-6a9e70613784n@googlegroups.com>
Subject: Re: is it a bug or don't I get it?
From: opticsm...@mindspring.com (Irl)
Injection-Date: Thu, 14 Apr 2022 01:57:29 +0000
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
Lines: 16
 by: Irl - Thu, 14 Apr 2022 01:57 UTC

Roundoff error. If you follow discussions of the cardinality of the reals or other such topics, you may recognize that 0.015999999999999999... is equivalent to .0160, i.e., 1 minute 60 seconds, i.e., 2 minutes. 0.015999999988 is a decent numerical approximation to that repeating decimal.
On Wednesday, April 13, 2022 at 9:32:29 AM UTC-4, druid.bernard@gmail.com wrote:
> > Hello all
> > I just wiped the dust off my old HP48GX in order to do some celestial navigation calculations. I like the function to convert HHMMSS into decimal hours, or degrees, if you will.
> > Everything works fine, I can convert back and forth. But this morning I found a result that was obviously fairly off.
> > When I calculate 11:54:54 minus 11:52:54 it should give me exactly 2 minutes, easy to see. But the operation on the HP results in 11.915 - 11.8816666667 = 0.333333333. This converted back to HHMMSS equals 0.015999999988, ie. 4 seconds off. Why?
> What is the actual code that you are using to make the calculation?

Re: is it a bug or don't I get it?

<f0c90463-353c-4a17-902f-66518167a1ffn@googlegroups.com>

 copy mid

https://www.novabbs.com/devel/article-flat.php?id=69&group=comp.sys.hp48#69

 copy link   Newsgroups: comp.sys.hp48
X-Received: by 2002:ac8:578b:0:b0:2e2:324a:7b6c with SMTP id v11-20020ac8578b000000b002e2324a7b6cmr5687173qta.267.1650038500746;
Fri, 15 Apr 2022 09:01:40 -0700 (PDT)
X-Received: by 2002:a05:6808:2115:b0:2fa:6cbd:f156 with SMTP id
r21-20020a056808211500b002fa6cbdf156mr1877515oiw.16.1650038500323; Fri, 15
Apr 2022 09:01:40 -0700 (PDT)
Path: i2pn2.org!i2pn.org!weretis.net!feeder6.news.weretis.net!news.misty.com!border2.nntp.dca1.giganews.com!nntp.giganews.com!news-out.google.com!nntp.google.com!postnews.google.com!google-groups.googlegroups.com!not-for-mail
Newsgroups: comp.sys.hp48
Date: Fri, 15 Apr 2022 09:01:40 -0700 (PDT)
In-Reply-To: <48f9c8c8-2167-4b3a-81bc-6a9e70613784n@googlegroups.com>
Injection-Info: google-groups.googlegroups.com; posting-host=129.205.170.0; posting-account=EPrxEwkAAAB22oFzC3sfI0xtN_t2NShK
NNTP-Posting-Host: 129.205.170.0
References: <9efc5fbb-0bdb-433b-9027-e17d33ab3e4dn@googlegroups.com>
<80884186-3e0f-404d-9645-1cb186884aden@googlegroups.com> <48f9c8c8-2167-4b3a-81bc-6a9e70613784n@googlegroups.com>
User-Agent: G2/1.0
MIME-Version: 1.0
Message-ID: <f0c90463-353c-4a17-902f-66518167a1ffn@googlegroups.com>
Subject: Re: is it a bug or don't I get it?
From: marc.tan...@me.com (Marc Tee)
Injection-Date: Fri, 15 Apr 2022 16:01:40 +0000
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
Lines: 30
 by: Marc Tee - Fri, 15 Apr 2022 16:01 UTC

optic...@mindspring.com schrieb am Donnerstag, 14. April 2022 um 03:57:30 UTC+2:
> Roundoff error. If you follow discussions of the cardinality of the reals or other such topics, you may recognize that 0.015999999999999999... is equivalent to .0160, i.e., 1 minute 60 seconds, i.e., 2 minutes. 0.015999999988 is a decent numerical approximation to that repeating decimal.
> On Wednesday, April 13, 2022 at 9:32:29 AM UTC-4, druid....@gmail.com wrote:
> > > Hello all
> > > I just wiped the dust off my old HP48GX in order to do some celestial navigation calculations. I like the function to convert HHMMSS into decimal hours, or degrees, if you will.
> > > Everything works fine, I can convert back and forth. But this morning I found a result that was obviously fairly off.
> > > When I calculate 11:54:54 minus 11:52:54 it should give me exactly 2 minutes, easy to see. But the operation on the HP results in 11.915 - 11.8816666667 = 0.333333333. This converted back to HHMMSS equals 0.015999999988, ie. 4 seconds off. Why?
> > What is the actual code that you are using to make the calculation?
Hello

I guess so. However, with all the calculations I have done so far, this has never occurred. When I convert HHMMSS into Decimals and add or subtract, then convert it back again into HHSSMM it is exact to the split second. But not in the specific example below. Moreover, on a HP41 it gives the proper result of 2 minutes..

Here is what I do: Enter, for example, 3:55:59 (3.5559 ENTER, convert to decimals with the built in function (Time, HMS->) add 1:59:20 (1.5920) by converting and convert the result back (->HMS) I get 5:11:19 which is correct. So, I don’t get that rounding part, really.

Re: is it a bug or don't I get it?

<7ffe7bda-5339-449c-9ec9-ff45ee45686cn@googlegroups.com>

 copy mid

https://www.novabbs.com/devel/article-flat.php?id=70&group=comp.sys.hp48#70

 copy link   Newsgroups: comp.sys.hp48
X-Received: by 2002:a05:622a:5d1:b0:2e0:70c7:1678 with SMTP id d17-20020a05622a05d100b002e070c71678mr1797045qtb.43.1650102966026;
Sat, 16 Apr 2022 02:56:06 -0700 (PDT)
X-Received: by 2002:a05:6870:45a5:b0:e1:f27d:d1c8 with SMTP id
y37-20020a05687045a500b000e1f27dd1c8mr2722449oao.60.1650102965758; Sat, 16
Apr 2022 02:56:05 -0700 (PDT)
Path: i2pn2.org!i2pn.org!weretis.net!feeder6.news.weretis.net!news.misty.com!border2.nntp.dca1.giganews.com!nntp.giganews.com!news-out.google.com!nntp.google.com!postnews.google.com!google-groups.googlegroups.com!not-for-mail
Newsgroups: comp.sys.hp48
Date: Sat, 16 Apr 2022 02:56:05 -0700 (PDT)
In-Reply-To: <f0c90463-353c-4a17-902f-66518167a1ffn@googlegroups.com>
Injection-Info: google-groups.googlegroups.com; posting-host=73.180.236.213; posting-account=VSu0AgoAAAB3OHyFQdpG1hq9eTtIXXN_
NNTP-Posting-Host: 73.180.236.213
References: <9efc5fbb-0bdb-433b-9027-e17d33ab3e4dn@googlegroups.com>
<80884186-3e0f-404d-9645-1cb186884aden@googlegroups.com> <48f9c8c8-2167-4b3a-81bc-6a9e70613784n@googlegroups.com>
<f0c90463-353c-4a17-902f-66518167a1ffn@googlegroups.com>
User-Agent: G2/1.0
MIME-Version: 1.0
Message-ID: <7ffe7bda-5339-449c-9ec9-ff45ee45686cn@googlegroups.com>
Subject: Re: is it a bug or don't I get it?
From: rwmitch...@gmail.com (Richard Mitchell)
Injection-Date: Sat, 16 Apr 2022 09:56:06 +0000
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
Lines: 35
 by: Richard Mitchell - Sat, 16 Apr 2022 09:56 UTC

On Friday, April 15, 2022 at 12:01:41 PM UTC-4, marc....@me.com wrote:
> optic...@mindspring.com schrieb am Donnerstag, 14. April 2022 um 03:57:30 UTC+2:
> > Roundoff error. If you follow discussions of the cardinality of the reals or other such topics, you may recognize that 0.015999999999999999... is equivalent to .0160, i.e., 1 minute 60 seconds, i.e., 2 minutes. 0.015999999988 is a decent numerical approximation to that repeating decimal.
> > On Wednesday, April 13, 2022 at 9:32:29 AM UTC-4, druid....@gmail.com wrote:
> > > > Hello all
> > > > I just wiped the dust off my old HP48GX in order to do some celestial navigation calculations. I like the function to convert HHMMSS into decimal hours, or degrees, if you will.
> > > > Everything works fine, I can convert back and forth. But this morning I found a result that was obviously fairly off.
> > > > When I calculate 11:54:54 minus 11:52:54 it should give me exactly 2 minutes, easy to see. But the operation on the HP results in 11.915 - 11.8816666667 = 0.333333333. This converted back to HHMMSS equals 0.015999999988, ie. 4 seconds off. Why?
> > > What is the actual code that you are using to make the calculation?
> Hello
>
> I guess so. However, with all the calculations I have done so far, this has never occurred. When I convert HHMMSS into Decimals and add or subtract, then convert it back again into HHSSMM it is exact to the split second. But not in the specific example below. Moreover, on a HP41 it gives the proper result of 2 minutes..
>
> Here is what I do: Enter, for example, 3:55:59 (3.5559 ENTER, convert to decimals with the built in function (Time, HMS->) add 1:59:20 (1.5920) by converting and convert the result back (->HMS) I get 5:11:19 which is correct. So, I don’t get that rounding part, really.

How is the original question/answer _4_ seconds off? Isn't 0.015999999988 almost 0.02 ...which is 2 minutes?

Re: is it a bug or don't I get it?

<46d8c3b0-eed4-4d8a-95ff-a9188237c931n@googlegroups.com>

 copy mid

https://www.novabbs.com/devel/article-flat.php?id=71&group=comp.sys.hp48#71

 copy link   Newsgroups: comp.sys.hp48
X-Received: by 2002:a0c:f8ca:0:b0:444:41e8:89b1 with SMTP id h10-20020a0cf8ca000000b0044441e889b1mr2805465qvo.22.1650124676445;
Sat, 16 Apr 2022 08:57:56 -0700 (PDT)
X-Received: by 2002:a05:6870:420a:b0:e2:62ac:bfc8 with SMTP id
u10-20020a056870420a00b000e262acbfc8mr1469629oac.77.1650124676226; Sat, 16
Apr 2022 08:57:56 -0700 (PDT)
Path: i2pn2.org!i2pn.org!aioe.org!news.uzoreto.com!news-out.netnews.com!news.alt.net!fdc2.netnews.com!peer02.ams1!peer.ams1.xlned.com!news.xlned.com!peer03.iad!feed-me.highwinds-media.com!news.highwinds-media.com!news-out.google.com!nntp.google.com!postnews.google.com!google-groups.googlegroups.com!not-for-mail
Newsgroups: comp.sys.hp48
Date: Sat, 16 Apr 2022 08:57:55 -0700 (PDT)
In-Reply-To: <f0c90463-353c-4a17-902f-66518167a1ffn@googlegroups.com>
Injection-Info: google-groups.googlegroups.com; posting-host=172.110.62.70; posting-account=BZgMCQkAAAB5crGlnJa7n74IkW8Ogg8E
NNTP-Posting-Host: 172.110.62.70
References: <9efc5fbb-0bdb-433b-9027-e17d33ab3e4dn@googlegroups.com>
<80884186-3e0f-404d-9645-1cb186884aden@googlegroups.com> <48f9c8c8-2167-4b3a-81bc-6a9e70613784n@googlegroups.com>
<f0c90463-353c-4a17-902f-66518167a1ffn@googlegroups.com>
User-Agent: G2/1.0
MIME-Version: 1.0
Message-ID: <46d8c3b0-eed4-4d8a-95ff-a9188237c931n@googlegroups.com>
Subject: Re: is it a bug or don't I get it?
From: opticsm...@mindspring.com (Irl)
Injection-Date: Sat, 16 Apr 2022 15:57:56 +0000
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Received-Bytes: 4848
 by: Irl - Sat, 16 Apr 2022 15:57 UTC

The HP calculators, in general and as far as I know, use some rather clever internal tricks to figure out the expected value of a number given its finite-length (12 decimal digits, I believe, plus an exponent) representation. With the calculator in STD mode, try the following experiments: (given in pseudo-RPN code)
1 9 divide 9 multiply: you get .999999999999 sort of not surprising but frustrating
2 9 divide 9 multiply: you get 2. kind of a miracle
In the case of your original question, the seconds part really has only about 9 or ten significant digits, so when you add and subtract two large numbers with a small difference, you should expect the result to be in error in the ninth or tenth digit. Usually the internal code does a good job of dealing with the problem, but not always.
In the case of your original calculation, my HP50GX gives .000200000016.
However, if you just use the built-in HMS-, you get simply .0002.
I suggest you change your original calculation to use 1100 hours instead of 11 hours. You will find the errors are bigger. The machine has finite precision; it tries to generate results that would arise from a machine of infinite precision; it sometimes fails. Even for the brilliant team which programmed this device originally, back when HP was an intellectual force to be reckoned with, there's only so much you can do with a small amount of memory.
I think I'm going to sign off of this thread. I hope this has been helpful!

On Friday, April 15, 2022 at 12:01:41 PM UTC-4, marc....@me.com wrote:
> optic...@mindspring.com schrieb am Donnerstag, 14. April 2022 um 03:57:30 UTC+2:
> > Roundoff error. If you follow discussions of the cardinality of the reals or other such topics, you may recognize that 0.015999999999999999... is equivalent to .0160, i.e., 1 minute 60 seconds, i.e., 2 minutes. 0.015999999988 is a decent numerical approximation to that repeating decimal.
> > On Wednesday, April 13, 2022 at 9:32:29 AM UTC-4, druid....@gmail.com wrote:
> > > > Hello all
> > > > I just wiped the dust off my old HP48GX in order to do some celestial navigation calculations. I like the function to convert HHMMSS into decimal hours, or degrees, if you will.
> > > > Everything works fine, I can convert back and forth. But this morning I found a result that was obviously fairly off.
> > > > When I calculate 11:54:54 minus 11:52:54 it should give me exactly 2 minutes, easy to see. But the operation on the HP results in 11.915 - 11.8816666667 = 0.333333333. This converted back to HHMMSS equals 0.015999999988, ie. 4 seconds off. Why?
> > > What is the actual code that you are using to make the calculation?
> Hello
>
> I guess so. However, with all the calculations I have done so far, this has never occurred. When I convert HHMMSS into Decimals and add or subtract, then convert it back again into HHSSMM it is exact to the split second. But not in the specific example below. Moreover, on a HP41 it gives the proper result of 2 minutes..
>
> Here is what I do: Enter, for example, 3:55:59 (3.5559 ENTER, convert to decimals with the built in function (Time, HMS->) add 1:59:20 (1.5920) by converting and convert the result back (->HMS) I get 5:11:19 which is correct. So, I don’t get that rounding part, really.

Re: is it a bug or don't I get it?

<ee7bf921-5ab8-4d78-bd23-669441f82f5an@googlegroups.com>

 copy mid

https://www.novabbs.com/devel/article-flat.php?id=72&group=comp.sys.hp48#72

 copy link   Newsgroups: comp.sys.hp48
X-Received: by 2002:ac8:5dcf:0:b0:2e1:baf1:502d with SMTP id e15-20020ac85dcf000000b002e1baf1502dmr6269078qtx.635.1650271960188;
Mon, 18 Apr 2022 01:52:40 -0700 (PDT)
X-Received: by 2002:a05:6870:f224:b0:e5:c30a:fa4f with SMTP id
t36-20020a056870f22400b000e5c30afa4fmr3117856oao.252.1650271959901; Mon, 18
Apr 2022 01:52:39 -0700 (PDT)
Path: i2pn2.org!i2pn.org!weretis.net!feeder6.news.weretis.net!news.misty.com!border2.nntp.dca1.giganews.com!border1.nntp.dca1.giganews.com!nntp.giganews.com!news-out.google.com!nntp.google.com!postnews.google.com!google-groups.googlegroups.com!not-for-mail
Newsgroups: comp.sys.hp48
Date: Mon, 18 Apr 2022 01:52:39 -0700 (PDT)
In-Reply-To: <7ffe7bda-5339-449c-9ec9-ff45ee45686cn@googlegroups.com>
Injection-Info: google-groups.googlegroups.com; posting-host=129.205.170.0; posting-account=EPrxEwkAAAB22oFzC3sfI0xtN_t2NShK
NNTP-Posting-Host: 129.205.170.0
References: <9efc5fbb-0bdb-433b-9027-e17d33ab3e4dn@googlegroups.com>
<80884186-3e0f-404d-9645-1cb186884aden@googlegroups.com> <48f9c8c8-2167-4b3a-81bc-6a9e70613784n@googlegroups.com>
<f0c90463-353c-4a17-902f-66518167a1ffn@googlegroups.com> <7ffe7bda-5339-449c-9ec9-ff45ee45686cn@googlegroups.com>
User-Agent: G2/1.0
MIME-Version: 1.0
Message-ID: <ee7bf921-5ab8-4d78-bd23-669441f82f5an@googlegroups.com>
Subject: Re: is it a bug or don't I get it?
From: marc.tan...@me.com (Marc Tee)
Injection-Date: Mon, 18 Apr 2022 08:52:40 +0000
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
Lines: 37
 by: Marc Tee - Mon, 18 Apr 2022 08:52 UTC

Richard Mitchell schrieb am Samstag, 16. April 2022 um 11:56:07 UTC+2:
> On Friday, April 15, 2022 at 12:01:41 PM UTC-4, marc....@me.com wrote:
> > optic...@mindspring.com schrieb am Donnerstag, 14. April 2022 um 03:57:30 UTC+2:
> > > Roundoff error. If you follow discussions of the cardinality of the reals or other such topics, you may recognize that 0.015999999999999999... is equivalent to .0160, i.e., 1 minute 60 seconds, i.e., 2 minutes. 0.015999999988 is a decent numerical approximation to that repeating decimal.
> > > On Wednesday, April 13, 2022 at 9:32:29 AM UTC-4, druid....@gmail.com wrote:
> > > > > Hello all
> > > > > I just wiped the dust off my old HP48GX in order to do some celestial navigation calculations. I like the function to convert HHMMSS into decimal hours, or degrees, if you will.
> > > > > Everything works fine, I can convert back and forth. But this morning I found a result that was obviously fairly off.
> > > > > When I calculate 11:54:54 minus 11:52:54 it should give me exactly 2 minutes, easy to see. But the operation on the HP results in 11.915 - 11.8816666667 = 0.333333333. This converted back to HHMMSS equals 0.015999999988, ie. 4 seconds off. Why?
> > > > What is the actual code that you are using to make the calculation?
> > Hello
> >
> > I guess so. However, with all the calculations I have done so far, this has never occurred. When I convert HHMMSS into Decimals and add or subtract, then convert it back again into HHSSMM it is exact to the split second. But not in the specific example below. Moreover, on a HP41 it gives the proper result of 2 minutes..
> >
> > Here is what I do: Enter, for example, 3:55:59 (3.5559 ENTER, convert to decimals with the built in function (Time, HMS->) add 1:59:20 (1.5920) by converting and convert the result back (->HMS) I get 5:11:19 which is correct. So, I don’t get that rounding part, really.
> How is the original question/answer _4_ seconds off? Isn't 0.015999999988 almost 0.02 ...which is 2 minutes?
You are right. Got a bit dizzy, obviously ;-) Thank you for putting me back into the picture :-)

1
server_pubkey.txt

rocksolid light 0.9.7
clearnet tor