Rocksolid Light

Welcome to RetroBBS

mail  files  register  newsreader  groups  login

Message-ID:  

19 May, 2024: Line wrapping has been changed to be more consistent with Usenet standards.
 If you find that it is broken please let me know here rocksolid.nodes.help


devel / comp.lang.c / Re: Radians Or Degrees?

SubjectAuthor
* Radians Or Degrees?Lawrence D'Oliveiro
+* Re: Radians Or Degrees?James Kuyper
|`* Re: Radians Or Degrees?Michael S
| `* Re: Radians Or Degrees?Lawrence D'Oliveiro
|  `* Re: Radians Or Degrees?Steven G. Kargl
|   `* Re: Radians Or Degrees?Lawrence D'Oliveiro
|    `* Re: Radians Or Degrees?Steven G. Kargl
|     `* Re: Radians Or Degrees?Lawrence D'Oliveiro
|      +* Re: Radians Or Degrees?Michael S
|      |+- Re: Radians Or Degrees?Lawrence D'Oliveiro
|      |+* Re: Radians Or Degrees?MitchAlsup1
|      ||`* Re: Radians Or Degrees?Steven G. Kargl
|      || +* Re: Radians Or Degrees?Chris M. Thomasson
|      || |`* Re: Radians Or Degrees?Chris M. Thomasson
|      || | `* Re: Radians Or Degrees?MitchAlsup1
|      || |  `* Re: Radians Or Degrees?Chris M. Thomasson
|      || |   `* Re: Radians Or Degrees?Lawrence D'Oliveiro
|      || |    `* Re: Radians Or Degrees?Chris M. Thomasson
|      || |     `* Re: Radians Or Degrees?Lawrence D'Oliveiro
|      || |      `* Re: Radians Or Degrees?Chris M. Thomasson
|      || |       +- Re: Radians Or Degrees?Lawrence D'Oliveiro
|      || |       `- Re: Radians Or Degrees?Chris M. Thomasson
|      || +* Re: Radians Or Degrees?MitchAlsup1
|      || |`* Re: Radians Or Degrees?Terje Mathisen
|      || | `* Re: Radians Or Degrees?Michael S
|      || |  +* Re: Radians Or Degrees?MitchAlsup1
|      || |  |+* Re: Radians Or Degrees?MitchAlsup1
|      || |  ||`- Re: Radians Or Degrees?Terje Mathisen
|      || |  |+* Re: Radians Or Degrees?Lawrence D'Oliveiro
|      || |  ||+- Re: Radians Or Degrees?Chris M. Thomasson
|      || |  ||`* Re: Radians Or Degrees?MitchAlsup1
|      || |  || `* Re: Radians Or Degrees?Chris M. Thomasson
|      || |  ||  `- Re: Radians Or Degrees?Chris M. Thomasson
|      || |  |`- Re: Radians Or Degrees?Michael S
|      || |  +* Re: Radians Or Degrees?Terje Mathisen
|      || |  |+* Re: Radians Or Degrees?Michael S
|      || |  ||`* Re: Radians Or Degrees?MitchAlsup1
|      || |  || `- Re: Radians Or Degrees?Terje Mathisen
|      || |  |`* Re: Radians Or Degrees?Chris M. Thomasson
|      || |  | +* Re: Radians Or Degrees?Chris M. Thomasson
|      || |  | |`- Re: Radians Or Degrees?Chris M. Thomasson
|      || |  | +* Re: Radians Or Degrees?Keith Thompson
|      || |  | |+* Re: Radians Or Degrees?Chris M. Thomasson
|      || |  | ||`* Re: Radians Or Degrees?Chris M. Thomasson
|      || |  | || `* Re: Radians Or Degrees?Keith Thompson
|      || |  | ||  `* Re: Radians Or Degrees?Chris M. Thomasson
|      || |  | ||   `- Re: Radians Or Degrees?Chris M. Thomasson
|      || |  | |`* Re: Radians Or Degrees?MitchAlsup1
|      || |  | | `* Re: Radians Or Degrees?Michael S
|      || |  | |  `* Re: Radians Or Degrees?MitchAlsup1
|      || |  | |   +- Re: Radians Or Degrees?Scott Lurndal
|      || |  | |   +- Re: Radians Or Degrees?Michael S
|      || |  | |   `* Re: Radians Or Degrees?Keith Thompson
|      || |  | |    +* Re: Radians Or Degrees?bart
|      || |  | |    |`* Re: Radians Or Degrees?Keith Thompson
|      || |  | |    | `* Re: Radians Or Degrees?bart
|      || |  | |    |  `* Re: Radians Or Degrees?Keith Thompson
|      || |  | |    |   `- Re: Radians Or Degrees?David Brown
|      || |  | |    `* Re: Radians Or Degrees?Michael S
|      || |  | |     +- Re: Radians Or Degrees?Michael S
|      || |  | |     `* Re: Radians Or Degrees?bart
|      || |  | |      `- Re: Radians Or Degrees?Michael S
|      || |  | `- Re: Radians Or Degrees?Chris M. Thomasson
|      || |  `* Re: Radians Or Degrees?Stefan Monnier
|      || |   `* Re: Radians Or Degrees?MitchAlsup1
|      || |    `* Re: Radians Or Degrees?Stefan Monnier
|      || |     +* Re: Radians Or Degrees?Michael S
|      || |     |+* Re: Radians Or Degrees?Stefan Monnier
|      || |     ||`* Re: Radians Or Degrees?MitchAlsup1
|      || |     || `* Re: Radians Or Degrees?Terje Mathisen
|      || |     ||  `* Re: Radians Or Degrees?Michael S
|      || |     ||   +- Re: Radians Or Degrees?MitchAlsup1
|      || |     ||   `- Re: Radians Or Degrees?Terje Mathisen
|      || |     |+* Re: Radians Or Degrees?Steven G. Kargl
|      || |     ||`- Re: Radians Or Degrees?MitchAlsup1
|      || |     |`* Re: Radians Or Degrees?MitchAlsup1
|      || |     | `- Re: Radians Or Degrees?Michael S
|      || |     +* Re: Radians Or Degrees?MitchAlsup1
|      || |     |`- Re: Radians Or Degrees?Stefan Monnier
|      || |     `- Re: Radians Or Degrees?Terje Mathisen
|      || `* Re: Radians Or Degrees?Michael S
|      ||  `* Re: Radians Or Degrees?MitchAlsup1
|      ||   `* Re: Radians Or Degrees?Steven G. Kargl
|      ||    +* Re: Radians Or Degrees?MitchAlsup1
|      ||    |+* Re: Radians Or Degrees?Lawrence D'Oliveiro
|      ||    ||`* Re: Radians Or Degrees?Steven G. Kargl
|      ||    || +* Re: Radians Or Degrees?Lawrence D'Oliveiro
|      ||    || |`* Re: Radians Or Degrees?Steven G. Kargl
|      ||    || | `- Re: Radians Or Degrees?Kaz Kylheku
|      ||    || `* Re: Radians Or Degrees?Lawrence D'Oliveiro
|      ||    ||  `* Re: Radians Or Degrees?Steven G. Kargl
|      ||    ||   `- Re: Radians Or Degrees?MitchAlsup1
|      ||    |`- Re: Radians Or Degrees?Steven G. Kargl
|      ||    +* Re: Radians Or Degrees?Lawrence D'Oliveiro
|      ||    |+* Re: Radians Or Degrees?Ben Bacarisse
|      ||    ||`* Re: Radians Or Degrees?Lawrence D'Oliveiro
|      ||    || `* Re: Radians Or Degrees?Ben Bacarisse
|      ||    ||  +* Re: Radians Or Degrees?Lawrence D'Oliveiro
|      ||    ||  |`* Re: Radians Or Degrees?Ben Bacarisse
|      ||    ||  | +* Re: Radians Or Degrees?Kaz Kylheku
|      ||    ||  | |`* Re: Radians Or Degrees?Ben Bacarisse
|      ||    ||  | `* Re: Radians Or Degrees?Lawrence D'Oliveiro
|      ||    ||  `- Re: Radians Or Degrees?Tim Rentsch
|      ||    |+- Re: Radians Or Degrees?Kaz Kylheku
|      ||    |`* Re: Radians Or Degrees?James Kuyper
|      ||    `* Re: Radians Or Degrees?Terje Mathisen
|      |`- Re: Radians Or Degrees?Terje Mathisen
|      `* Re: Radians Or Degrees?Steven G. Kargl
+* Re: Radians Or Degrees?fir
+* Re: Radians Or Degrees?Malcolm McLean
+- Re: Radians Or Degrees?David Brown
`* Re: Radians Or Degrees?Blue-Maned_Hawk

Pages:1234567
Re: Radians Or Degrees?

<urbsd1$117c5$1@dont-email.me>

  copy mid

https://www.rocksolidbbs.com/devel/article-flat.php?id=35161&group=comp.lang.c#35161

  copy link   Newsgroups: comp.lang.c comp.arch
Path: i2pn2.org!i2pn.org!eternal-september.org!feeder3.eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail
From: ldo@nz.invalid (Lawrence D'Oliveiro)
Newsgroups: comp.lang.c,comp.arch
Subject: Re: Radians Or Degrees?
Date: Sat, 24 Feb 2024 04:47:29 -0000 (UTC)
Organization: A noiseless patient Spider
Lines: 6
Message-ID: <urbsd1$117c5$1@dont-email.me>
References: <ur5trn$3d64t$1@dont-email.me> <ur5v05$3ccut$1@dont-email.me>
<20240222015920.00000260@yahoo.com> <ur69j9$3ftgj$3@dont-email.me>
<ur86eg$1aip$1@dont-email.me> <ur88e4$1rr1$5@dont-email.me>
<ur8a2p$2446$1@dont-email.me> <ur8ctk$2vbd$2@dont-email.me>
<20240222233838.0000572f@yahoo.com>
<3b2e86cdb0ee8785b4405ab10871c5ca@www.novabbs.org>
<ur8nud$4n1r$1@dont-email.me> <20240223143250.000012a8@yahoo.com>
<59454a79216ece74ac3fee0e00473357@www.novabbs.org>
<uravp3$nl44$1@dont-email.me>
<9862882e1badcd541491098b47c61802@www.novabbs.org>
<urb6qn$phho$2@dont-email.me> <urbpps$10mal$1@dont-email.me>
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Injection-Date: Sat, 24 Feb 2024 04:47:29 -0000 (UTC)
Injection-Info: dont-email.me; posting-host="90cd705a0b104282cd54d6df08a2cdc8";
logging-data="1088901"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1+GDiX4XqB21Oe2a8DnByA1"
User-Agent: Pan/0.155 (Kherson; fc5a80b8)
Cancel-Lock: sha1:IeZHu884/z7zviEcoHfgFFqjWXY=
 by: Lawrence D'Oliv - Sat, 24 Feb 2024 04:47 UTC

On Sat, 24 Feb 2024 04:03:08 -0000 (UTC), Steven G. Kargl wrote:

> I can assure one of the libm and mpfr values, when x = 5653.00049,
> is quite wrong.

That’s 9 figures, but single-precision IEEE754 floats only allow about 7.

Re: Radians Or Degrees?

<urbune$11ag0$1@dont-email.me>

  copy mid

https://www.rocksolidbbs.com/devel/article-flat.php?id=35162&group=comp.lang.c#35162

  copy link   Newsgroups: comp.lang.c comp.arch
Path: i2pn2.org!i2pn.org!eternal-september.org!feeder3.eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail
From: sgk@REMOVEtroutmask.apl.washington.edu (Steven G. Kargl)
Newsgroups: comp.lang.c,comp.arch
Subject: Re: Radians Or Degrees?
Date: Sat, 24 Feb 2024 05:27:10 -0000 (UTC)
Organization: A noiseless patient Spider
Lines: 48
Message-ID: <urbune$11ag0$1@dont-email.me>
References: <ur5trn$3d64t$1@dont-email.me> <ur5v05$3ccut$1@dont-email.me>
<20240222015920.00000260@yahoo.com> <ur69j9$3ftgj$3@dont-email.me>
<ur86eg$1aip$1@dont-email.me> <ur88e4$1rr1$5@dont-email.me>
<ur8a2p$2446$1@dont-email.me> <ur8ctk$2vbd$2@dont-email.me>
<20240222233838.0000572f@yahoo.com>
<3b2e86cdb0ee8785b4405ab10871c5ca@www.novabbs.org>
<ur8nud$4n1r$1@dont-email.me> <20240223143250.000012a8@yahoo.com>
<59454a79216ece74ac3fee0e00473357@www.novabbs.org>
<uravp3$nl44$1@dont-email.me>
<9862882e1badcd541491098b47c61802@www.novabbs.org>
<urb6qn$phho$2@dont-email.me> <urbpps$10mal$1@dont-email.me>
<urbsd1$117c5$1@dont-email.me>
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Injection-Date: Sat, 24 Feb 2024 05:27:10 -0000 (UTC)
Injection-Info: dont-email.me; posting-host="6719a06acd7653ce47d0597a0ad9615d";
logging-data="1092096"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1/d94yk6nPzevdGreBR/VHD"
User-Agent: Pan/0.145 (Duplicitous mercenary valetism; d7e168a
git.gnome.org/pan2)
Cancel-Lock: sha1:HLZll1L9GD30pjbtGT3VQrz0sUo=
 by: Steven G. Kargl - Sat, 24 Feb 2024 05:27 UTC

On Sat, 24 Feb 2024 04:47:29 +0000, Lawrence D'Oliveiro wrote:

> On Sat, 24 Feb 2024 04:03:08 -0000 (UTC), Steven G. Kargl wrote:
>
>> I can assure one of the libm and mpfr values, when x = 5653.00049,
>> is quite wrong.
>
> That’s 9 figures, but single-precision IEEE754 floats only allow about
> 7.

ROTFL. I suggest (re-)reading the entire section

IEEE Std 754TM-2008

5.12.2 External decimal character sequences representing
finite numbers

However, I'll give you the salient part on p.32

For the purposes of discussing the limits on correctly
rounded conversion, define the following quantities:

for binary32, Pmin (binary32) = 9
....

Conversions from a supported binary format bf to an external
character sequence and back again results in a copy of the
original number so long as there are at least Pmin (bf)
significant digits specified and the rounding-direction
attributes in effect during the two conversions are round to
nearest rounding-direction attributes.

You also seem to miss that I gave you the bit pattern as
an unsigned 32-bit int. There are no extra binary digits.

At this point, I think it might be prudent for you to
read Goldberg's paper [1] and IEEE 754.

[1] https://docs.oracle.com/cd/E19957-01/806-3568/ncg_goldberg.html

I'm done responding to your trolls and apologies other c.l.c
posters.

--
steve

Re: Radians Or Degrees?

<urbvdd$11l69$1@dont-email.me>

  copy mid

https://www.rocksolidbbs.com/devel/article-flat.php?id=35163&group=comp.lang.c#35163

  copy link   Newsgroups: comp.lang.c comp.arch
Path: i2pn2.org!i2pn.org!eternal-september.org!feeder3.eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail
From: ldo@nz.invalid (Lawrence D'Oliveiro)
Newsgroups: comp.lang.c,comp.arch
Subject: Re: Radians Or Degrees?
Date: Sat, 24 Feb 2024 05:38:53 -0000 (UTC)
Organization: A noiseless patient Spider
Lines: 20
Message-ID: <urbvdd$11l69$1@dont-email.me>
References: <ur5trn$3d64t$1@dont-email.me> <ur5v05$3ccut$1@dont-email.me>
<20240222015920.00000260@yahoo.com> <ur69j9$3ftgj$3@dont-email.me>
<ur86eg$1aip$1@dont-email.me> <ur88e4$1rr1$5@dont-email.me>
<ur8a2p$2446$1@dont-email.me> <ur8ctk$2vbd$2@dont-email.me>
<20240222233838.0000572f@yahoo.com>
<3b2e86cdb0ee8785b4405ab10871c5ca@www.novabbs.org>
<ur8nud$4n1r$1@dont-email.me> <20240223143250.000012a8@yahoo.com>
<59454a79216ece74ac3fee0e00473357@www.novabbs.org>
<uravp3$nl44$1@dont-email.me>
<9862882e1badcd541491098b47c61802@www.novabbs.org>
<urb6qn$phho$2@dont-email.me> <urbpps$10mal$1@dont-email.me>
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Injection-Date: Sat, 24 Feb 2024 05:38:53 -0000 (UTC)
Injection-Info: dont-email.me; posting-host="90cd705a0b104282cd54d6df08a2cdc8";
logging-data="1103049"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1/MHBl6ah1GKViXIR84nDLs"
User-Agent: Pan/0.155 (Kherson; fc5a80b8)
Cancel-Lock: sha1:h6E2KC3ky9MhPavcIJY4VdANSqk=
 by: Lawrence D'Oliv - Sat, 24 Feb 2024 05:38 UTC

On Sat, 24 Feb 2024 04:03:08 -0000 (UTC), Steven G. Kargl wrote:

> % ./tlibm sinpi -f -a 5.65300049e+03
> x = 5.65300049e+03f, /* 0x45b0a801 */
> libm = -2.51050433e-03f, /* 0xbb248746 */
> mpfr = -1.53398013e-03f, /* 0xbac90fd5 */
> ULP = 8388278.50000
>
> I can assure one of the libm and mpfr values, when x = 5653.00049,
> is quite wrong.

They’re all wrong. Python says (in double-precision), that
math.sin(5653.00049) is -0.9566595256716378.

Even GCC’s sinf function says the value is -0.9565167, which is only a
slight discrepancy in the fourth decimal place, so even in single-
precision it is doing a darn sight better than you have managed above.

So where is there a version of the code you’re using, using different
angle units, that gets closer to the right answer?

Re: Radians Or Degrees?

<20240223213938.723@kylheku.com>

  copy mid

https://www.rocksolidbbs.com/devel/article-flat.php?id=35164&group=comp.lang.c#35164

  copy link   Newsgroups: comp.lang.c comp.arch
Path: i2pn2.org!i2pn.org!eternal-september.org!feeder3.eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail
From: 433-929-6894@kylheku.com (Kaz Kylheku)
Newsgroups: comp.lang.c,comp.arch
Subject: Re: Radians Or Degrees?
Date: Sat, 24 Feb 2024 05:48:33 -0000 (UTC)
Organization: A noiseless patient Spider
Lines: 33
Message-ID: <20240223213938.723@kylheku.com>
References: <ur5trn$3d64t$1@dont-email.me> <ur5v05$3ccut$1@dont-email.me>
<20240222015920.00000260@yahoo.com> <ur69j9$3ftgj$3@dont-email.me>
<ur86eg$1aip$1@dont-email.me> <ur88e4$1rr1$5@dont-email.me>
<ur8a2p$2446$1@dont-email.me> <ur8ctk$2vbd$2@dont-email.me>
<20240222233838.0000572f@yahoo.com>
<3b2e86cdb0ee8785b4405ab10871c5ca@www.novabbs.org>
<ur8nud$4n1r$1@dont-email.me> <20240223143250.000012a8@yahoo.com>
<59454a79216ece74ac3fee0e00473357@www.novabbs.org>
<uravp3$nl44$1@dont-email.me>
<9862882e1badcd541491098b47c61802@www.novabbs.org>
<urb6qn$phho$2@dont-email.me> <urbpps$10mal$1@dont-email.me>
<urbsd1$117c5$1@dont-email.me> <urbune$11ag0$1@dont-email.me>
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Injection-Date: Sat, 24 Feb 2024 05:48:33 -0000 (UTC)
Injection-Info: dont-email.me; posting-host="34619b51a16732ed137354a6ec65eead";
logging-data="1105664"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX18mQ/vN3UcTkPmNimgAiKO1C7xnMYTXiVc="
User-Agent: slrn/pre1.0.4-9 (Linux)
Cancel-Lock: sha1:T+Y1W00i09g7OPqAYTiLW1uqRQo=
 by: Kaz Kylheku - Sat, 24 Feb 2024 05:48 UTC

On 2024-02-24, Steven G. Kargl <sgk@REMOVEtroutmask.apl.washington.edu> wrote:
> On Sat, 24 Feb 2024 04:47:29 +0000, Lawrence D'Oliveiro wrote:
>
>> On Sat, 24 Feb 2024 04:03:08 -0000 (UTC), Steven G. Kargl wrote:
>>
>>> I can assure one of the libm and mpfr values, when x = 5653.00049,
>>> is quite wrong.
>>
>> That’s 9 figures, but single-precision IEEE754 floats only allow about
>> 7.
>
> ROTFL. I suggest (re-)reading the entire section

[ snip ]

> for binary32, Pmin (binary32) = 9

Also, from the comp.lang.c point of view, in the C language we have
FLT_DIG and FLT_DECIMAL_DIG in <float.h>.

On IEEE 754 systems these are 6 and 9.

FLT_DIG gives you, roughly speaking, how many decimal digits of
precision a float can preserve in the decimal -> float -> decimal
conversion sequence

FLT_DECIMAL_DIG indicates how many digits are required to exactly
preserve a float value in decimal form: float -> decimal -> float.

--
TXR Programming Language: http://nongnu.org/txr
Cygnal: Cygwin Native Application Library: http://kylheku.com/cygnal
Mastodon: @Kazinator@mstdn.ca

Re: Radians Or Degrees?

<urc1f6$11u41$1@dont-email.me>

  copy mid

https://www.rocksolidbbs.com/devel/article-flat.php?id=35165&group=comp.lang.c#35165

  copy link   Newsgroups: comp.lang.c comp.arch
Path: i2pn2.org!i2pn.org!eternal-september.org!feeder3.eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail
From: sgk@REMOVEtroutmask.apl.washington.edu (Steven G. Kargl)
Newsgroups: comp.lang.c,comp.arch
Subject: Re: Radians Or Degrees?
Date: Sat, 24 Feb 2024 06:13:58 -0000 (UTC)
Organization: A noiseless patient Spider
Lines: 38
Message-ID: <urc1f6$11u41$1@dont-email.me>
References: <ur5trn$3d64t$1@dont-email.me> <ur5v05$3ccut$1@dont-email.me>
<20240222015920.00000260@yahoo.com> <ur69j9$3ftgj$3@dont-email.me>
<ur86eg$1aip$1@dont-email.me> <ur88e4$1rr1$5@dont-email.me>
<ur8a2p$2446$1@dont-email.me> <ur8ctk$2vbd$2@dont-email.me>
<20240222233838.0000572f@yahoo.com>
<3b2e86cdb0ee8785b4405ab10871c5ca@www.novabbs.org>
<ur8nud$4n1r$1@dont-email.me> <20240223143250.000012a8@yahoo.com>
<59454a79216ece74ac3fee0e00473357@www.novabbs.org>
<uravp3$nl44$1@dont-email.me>
<9862882e1badcd541491098b47c61802@www.novabbs.org>
<urb6qn$phho$2@dont-email.me> <urbpps$10mal$1@dont-email.me>
<urbvdd$11l69$1@dont-email.me>
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Injection-Date: Sat, 24 Feb 2024 06:13:58 -0000 (UTC)
Injection-Info: dont-email.me; posting-host="6719a06acd7653ce47d0597a0ad9615d";
logging-data="1112193"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1/+eLAndgAMESUB9P2iGVl7"
User-Agent: Pan/0.145 (Duplicitous mercenary valetism; d7e168a
git.gnome.org/pan2)
Cancel-Lock: sha1:hnJV4FSOcUU5+7X23lW09Xrz1ZM=
 by: Steven G. Kargl - Sat, 24 Feb 2024 06:13 UTC

On Sat, 24 Feb 2024 05:38:53 +0000, Lawrence D'Oliveiro wrote:

> On Sat, 24 Feb 2024 04:03:08 -0000 (UTC), Steven G. Kargl wrote:
>
>> % ./tlibm sinpi -f -a 5.65300049e+03
>> x = 5.65300049e+03f, /* 0x45b0a801 */
>> libm = -2.51050433e-03f, /* 0xbb248746 */
>> mpfr = -1.53398013e-03f, /* 0xbac90fd5 */
>> ULP = 8388278.50000
>>
>> I can assure one of the libm and mpfr values, when x = 5653.00049,
>> is quite wrong.
>
> They’re all wrong. Python says (in double-precision), that
> math.sin(5653.00049) is -0.9566595256716378.
>
> Even GCC’s sinf function says the value is -0.9565167, which is only a
> slight discrepancy in the fourth decimal place, so even in single-
> precision it is doing a darn sight better than you have managed above.
>
> So where is there a version of the code you’re using, using different
> angle units, that gets closer to the right answer?

sin(x) is not sinpi(x). The conversion factor that you're missing
is M_PI as in sinpi(x) = sin(M_PI*x). The whole point of the
half-cycle trig functions is that one does not need to do the
multiplication by pi, or more importantly the argument reduction
modulo pi.

% ./tlibm sin -f -a 5.65300049e+3
x = 5.65300049e+03f, /* 0x45b0a801 */
libm = -9.56659019e-01f, /* 0xbf74e79b */
mpfr = -9.56659019e-01f, /* 0xbf74e79b */
ULP = 0.10338

--
steve

Re: Radians Or Degrees?

<urc5lv$12sao$1@dont-email.me>

  copy mid

https://www.rocksolidbbs.com/devel/article-flat.php?id=35166&group=comp.lang.c#35166

  copy link   Newsgroups: comp.lang.c
Path: i2pn2.org!i2pn.org!news.niel.me!news.gegeweb.eu!gegeweb.org!eternal-september.org!feeder3.eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail
From: jameskuyper@alumni.caltech.edu (James Kuyper)
Newsgroups: comp.lang.c
Subject: Re: Radians Or Degrees?
Date: Sat, 24 Feb 2024 02:25:51 -0500
Organization: A noiseless patient Spider
Lines: 19
Message-ID: <urc5lv$12sao$1@dont-email.me>
References: <ur5trn$3d64t$1@dont-email.me> <ur5v05$3ccut$1@dont-email.me>
<20240222015920.00000260@yahoo.com> <ur69j9$3ftgj$3@dont-email.me>
<ur86eg$1aip$1@dont-email.me> <ur88e4$1rr1$5@dont-email.me>
<ur8a2p$2446$1@dont-email.me> <ur8ctk$2vbd$2@dont-email.me>
<20240222233838.0000572f@yahoo.com>
<3b2e86cdb0ee8785b4405ab10871c5ca@www.novabbs.org>
<ur8nud$4n1r$1@dont-email.me> <20240223143250.000012a8@yahoo.com>
<59454a79216ece74ac3fee0e00473357@www.novabbs.org>
<uravp3$nl44$1@dont-email.me> <urb6rt$phho$3@dont-email.me>
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Injection-Date: Sat, 24 Feb 2024 07:25:51 -0000 (UTC)
Injection-Info: dont-email.me; posting-host="ac5c6f3fe9f4fdfe0cbb5023851d5171";
logging-data="1143128"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX18pE0pKoYSZfqqqN5Ken6p4kDk4ZYxzxSc="
User-Agent: Mozilla Thunderbird
Cancel-Lock: sha1:gkL9MJS8q4aoQdvYvXWyWUhmXS8=
Content-Language: en-US
In-Reply-To: <urb6rt$phho$3@dont-email.me>
 by: James Kuyper - Sat, 24 Feb 2024 07:25 UTC

On 2/23/24 17:39, Lawrence D'Oliveiro wrote:
> On Fri, 23 Feb 2024 20:38:59 -0000 (UTC), Steven G. Kargl wrote:
>
>> Note 2: subnormal values ...
>
> Why did they bring in the term “subnormal”, anyway? What was wrong with
> “denormalized”?

The same thing that's wrong with calling a horse a quadruped. It's
technically correct, but in a context where it could only be a horse,
the term "quadruped" is unnecessarily vague. Denormal numbers that are
not subnormal are called unnormal, and are part of IEEE Decimal Floating
Point. Decimal floating point types have been an optional feature of C
since 2020.
The C standard never uses the term denormal, but it does use unnormal.
The only thing it does with the term is define it, and allow for the
presence of such numbers - but nothing that it says about normal or
subnormal numbers (which is quite a lot) applies to unnormal numbers,
and that is a deliberate feature of the standard.

Re: Radians Or Degrees?

<urdk8j$1cis4$1@dont-email.me>

  copy mid

https://www.rocksolidbbs.com/devel/article-flat.php?id=35169&group=comp.lang.c#35169

  copy link   Newsgroups: comp.lang.c
Path: i2pn2.org!i2pn.org!eternal-september.org!feeder3.eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail
From: chris.m.thomasson.1@gmail.com (Chris M. Thomasson)
Newsgroups: comp.lang.c
Subject: Re: Radians Or Degrees?
Date: Sat, 24 Feb 2024 12:40:52 -0800
Organization: A noiseless patient Spider
Lines: 14
Message-ID: <urdk8j$1cis4$1@dont-email.me>
References: <ur5trn$3d64t$1@dont-email.me> <ur5v05$3ccut$1@dont-email.me>
<20240222015920.00000260@yahoo.com> <ur69j9$3ftgj$3@dont-email.me>
<ur86eg$1aip$1@dont-email.me> <ur88e4$1rr1$5@dont-email.me>
<ur8a2p$2446$1@dont-email.me> <ur8ctk$2vbd$2@dont-email.me>
<20240222233838.0000572f@yahoo.com>
<3b2e86cdb0ee8785b4405ab10871c5ca@www.novabbs.org>
<ur8nud$4n1r$1@dont-email.me> <ur8q2k$5nfr$1@dont-email.me>
<ur8qlp$5nfr$2@dont-email.me>
<a2a5c98883cafb6ab19668403b2dfb15@www.novabbs.org>
<urav5o$nqvp$1@dont-email.me> <urb704$phho$4@dont-email.me>
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 8bit
Injection-Date: Sat, 24 Feb 2024 20:40:52 -0000 (UTC)
Injection-Info: dont-email.me; posting-host="7a5e0a725b528e2337414270c82c765a";
logging-data="1461124"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1/3Jm2h88ezOM0QoWBlfFZR3VSnN93l6Xw="
User-Agent: Mozilla Thunderbird
Cancel-Lock: sha1:xSTO8mzma60cBxi8Epg/wEnkkC0=
Content-Language: en-US
In-Reply-To: <urb704$phho$4@dont-email.me>
 by: Chris M. Thomasson - Sat, 24 Feb 2024 20:40 UTC

On 2/23/2024 2:42 PM, Lawrence D'Oliveiro wrote:
> On Fri, 23 Feb 2024 12:28:40 -0800, Chris M. Thomasson wrote:
>
>> So zooming in "deep" on say, something like my MultiJulia IFS work is
>> going to require arbitrary precision trig...
>
> In which case, all these arguments from people saying that particular non-
> radian angle units are going to squeeze out just that little bit more in
> significant figures from IEEE754 single or double precision are really
> just irrelevant, aren’t they?

It depends on the task at hand? Think of what type of performance hit
one can take if they use double precision on a GPU that supports it in
shader programs...

Re: Radians Or Degrees?

<urdmkt$1d2g9$2@dont-email.me>

  copy mid

https://www.rocksolidbbs.com/devel/article-flat.php?id=35171&group=comp.lang.c#35171

  copy link   Newsgroups: comp.lang.c
Path: i2pn2.org!i2pn.org!eternal-september.org!feeder3.eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail
From: ldo@nz.invalid (Lawrence D'Oliveiro)
Newsgroups: comp.lang.c
Subject: Re: Radians Or Degrees?
Date: Sat, 24 Feb 2024 21:21:33 -0000 (UTC)
Organization: A noiseless patient Spider
Lines: 8
Message-ID: <urdmkt$1d2g9$2@dont-email.me>
References: <ur5trn$3d64t$1@dont-email.me> <ur5v05$3ccut$1@dont-email.me>
<20240222015920.00000260@yahoo.com> <ur69j9$3ftgj$3@dont-email.me>
<ur86eg$1aip$1@dont-email.me> <ur88e4$1rr1$5@dont-email.me>
<ur8a2p$2446$1@dont-email.me> <ur8ctk$2vbd$2@dont-email.me>
<20240222233838.0000572f@yahoo.com>
<3b2e86cdb0ee8785b4405ab10871c5ca@www.novabbs.org>
<ur8nud$4n1r$1@dont-email.me> <20240223143250.000012a8@yahoo.com>
<59454a79216ece74ac3fee0e00473357@www.novabbs.org>
<uravp3$nl44$1@dont-email.me> <urb6rt$phho$3@dont-email.me>
<urc5lv$12sao$1@dont-email.me>
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Injection-Date: Sat, 24 Feb 2024 21:21:33 -0000 (UTC)
Injection-Info: dont-email.me; posting-host="90cd705a0b104282cd54d6df08a2cdc8";
logging-data="1477129"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1/7BVxyEThfl6BWGftgTB18"
User-Agent: Pan/0.155 (Kherson; fc5a80b8)
Cancel-Lock: sha1:sWENuKKeD3ttM7jrnT/7Jn8Oju8=
 by: Lawrence D'Oliv - Sat, 24 Feb 2024 21:21 UTC

On Sat, 24 Feb 2024 02:25:51 -0500, James Kuyper wrote:

> Denormal numbers that are not subnormal are called unnormal, and are
> part of IEEE Decimal Floating Point.

Interesting, because when I brought up decimal floats in this thread, I
was accused, by Michael S <already5chosen@yahoo.com>, of “trolling”, on
the grounds that “nobody uses DFP for science or engineering”.

Re: Radians Or Degrees?

<urdqqg$1e1nr$1@dont-email.me>

  copy mid

https://www.rocksolidbbs.com/devel/article-flat.php?id=35174&group=comp.lang.c#35174

  copy link   Newsgroups: comp.lang.c
Path: i2pn2.org!i2pn.org!eternal-september.org!feeder3.eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail
From: jameskuyper@alumni.caltech.edu (James Kuyper)
Newsgroups: comp.lang.c
Subject: Re: Radians Or Degrees?
Date: Sat, 24 Feb 2024 17:32:47 -0500
Organization: A noiseless patient Spider
Lines: 14
Message-ID: <urdqqg$1e1nr$1@dont-email.me>
References: <ur5trn$3d64t$1@dont-email.me> <ur5v05$3ccut$1@dont-email.me>
<20240222015920.00000260@yahoo.com> <ur69j9$3ftgj$3@dont-email.me>
<ur86eg$1aip$1@dont-email.me> <ur88e4$1rr1$5@dont-email.me>
<ur8a2p$2446$1@dont-email.me> <ur8ctk$2vbd$2@dont-email.me>
<20240222233838.0000572f@yahoo.com>
<3b2e86cdb0ee8785b4405ab10871c5ca@www.novabbs.org>
<ur8nud$4n1r$1@dont-email.me> <20240223143250.000012a8@yahoo.com>
<59454a79216ece74ac3fee0e00473357@www.novabbs.org>
<uravp3$nl44$1@dont-email.me> <urb6rt$phho$3@dont-email.me>
<urc5lv$12sao$1@dont-email.me> <urdmkt$1d2g9$2@dont-email.me>
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Injection-Date: Sat, 24 Feb 2024 22:32:48 -0000 (UTC)
Injection-Info: dont-email.me; posting-host="ac5c6f3fe9f4fdfe0cbb5023851d5171";
logging-data="1509115"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX19lpoEUeq9OiYES814ZcCcRqMXpfWchUJA="
User-Agent: Mozilla Thunderbird
Cancel-Lock: sha1:rUs2FDzrTVLomQPwgjKhDhsrnyM=
In-Reply-To: <urdmkt$1d2g9$2@dont-email.me>
Content-Language: en-US
 by: James Kuyper - Sat, 24 Feb 2024 22:32 UTC

On 2/24/24 16:21, Lawrence D'Oliveiro wrote:
> On Sat, 24 Feb 2024 02:25:51 -0500, James Kuyper wrote:
>
>> Denormal numbers that are not subnormal are called unnormal, and are
>> part of IEEE Decimal Floating Point.
>
> Interesting, because when I brought up decimal floats in this thread, I
> was accused, by Michael S <already5chosen@yahoo.com>, of “trolling”, on
> the grounds that “nobody uses DFP for science or engineering”.

Yes, that makes sense. Precisely because DFP is not likely to be used
for this kind of application, it's inappropriate to talk about denormal
number, because outside of DFP, you're unlikely to run into any denormal
numbers that aren't also subnormal.

Re: Radians Or Degrees?

<urdrs5$1e8e4$1@dont-email.me>

  copy mid

https://www.rocksolidbbs.com/devel/article-flat.php?id=35175&group=comp.lang.c#35175

  copy link   Newsgroups: comp.lang.c
Path: i2pn2.org!i2pn.org!eternal-september.org!feeder3.eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail
From: ldo@nz.invalid (Lawrence D'Oliveiro)
Newsgroups: comp.lang.c
Subject: Re: Radians Or Degrees?
Date: Sat, 24 Feb 2024 22:50:46 -0000 (UTC)
Organization: A noiseless patient Spider
Lines: 14
Message-ID: <urdrs5$1e8e4$1@dont-email.me>
References: <ur5trn$3d64t$1@dont-email.me> <ur5v05$3ccut$1@dont-email.me>
<20240222015920.00000260@yahoo.com> <ur69j9$3ftgj$3@dont-email.me>
<ur86eg$1aip$1@dont-email.me> <ur88e4$1rr1$5@dont-email.me>
<ur8a2p$2446$1@dont-email.me> <ur8ctk$2vbd$2@dont-email.me>
<20240222233838.0000572f@yahoo.com>
<3b2e86cdb0ee8785b4405ab10871c5ca@www.novabbs.org>
<ur8nud$4n1r$1@dont-email.me> <20240223143250.000012a8@yahoo.com>
<59454a79216ece74ac3fee0e00473357@www.novabbs.org>
<uravp3$nl44$1@dont-email.me> <urb6rt$phho$3@dont-email.me>
<urc5lv$12sao$1@dont-email.me> <urdmkt$1d2g9$2@dont-email.me>
<urdqqg$1e1nr$1@dont-email.me>
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Injection-Date: Sat, 24 Feb 2024 22:50:46 -0000 (UTC)
Injection-Info: dont-email.me; posting-host="90cd705a0b104282cd54d6df08a2cdc8";
logging-data="1515972"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX18IqXAew0SU3E6o/HGFsMUF"
User-Agent: Pan/0.155 (Kherson; fc5a80b8)
Cancel-Lock: sha1:05+MUYxZUWYz5T81IR75Ug3d/dE=
 by: Lawrence D'Oliv - Sat, 24 Feb 2024 22:50 UTC

On Sat, 24 Feb 2024 17:32:47 -0500, James Kuyper wrote:

> Precisely because DFP is not likely to be used for this kind of
> application ...

But remember why the IEEE decided to formulate a standard for numerics in
the first place: it’s because your typical (non-computer) engineer is just
as naïve about numerical techniques as anybody else. IEEE754 was designed
to reduce many of the unpleasant surprises that bedevilled computer
arithmetic back in the day (Prof William “Mr IEEE754” Kahan’s foreword to
Apple’s Standard Numerics manual, from back in 1987, still makes
entertaining reading today). But as you know, binary arithmetic still has
its share of nonintuitive results. So it only seems logical to go to
decimal arithmetic, as the next step.

Re: Radians Or Degrees?

<urdrv1$1e8e4$2@dont-email.me>

  copy mid

https://www.rocksolidbbs.com/devel/article-flat.php?id=35176&group=comp.lang.c#35176

  copy link   Newsgroups: comp.lang.c
Path: i2pn2.org!i2pn.org!eternal-september.org!feeder3.eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail
From: ldo@nz.invalid (Lawrence D'Oliveiro)
Newsgroups: comp.lang.c
Subject: Re: Radians Or Degrees?
Date: Sat, 24 Feb 2024 22:52:17 -0000 (UTC)
Organization: A noiseless patient Spider
Lines: 9
Message-ID: <urdrv1$1e8e4$2@dont-email.me>
References: <ur5trn$3d64t$1@dont-email.me> <ur5v05$3ccut$1@dont-email.me>
<20240222015920.00000260@yahoo.com> <ur69j9$3ftgj$3@dont-email.me>
<ur86eg$1aip$1@dont-email.me> <ur88e4$1rr1$5@dont-email.me>
<ur8a2p$2446$1@dont-email.me> <ur8ctk$2vbd$2@dont-email.me>
<20240222233838.0000572f@yahoo.com>
<3b2e86cdb0ee8785b4405ab10871c5ca@www.novabbs.org>
<ur8nud$4n1r$1@dont-email.me> <ur8q2k$5nfr$1@dont-email.me>
<ur8qlp$5nfr$2@dont-email.me>
<a2a5c98883cafb6ab19668403b2dfb15@www.novabbs.org>
<urav5o$nqvp$1@dont-email.me> <urb704$phho$4@dont-email.me>
<urdk8j$1cis4$1@dont-email.me>
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Injection-Date: Sat, 24 Feb 2024 22:52:17 -0000 (UTC)
Injection-Info: dont-email.me; posting-host="90cd705a0b104282cd54d6df08a2cdc8";
logging-data="1515972"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX18WMCu+uJ8Tu+w+jMLuz9mg"
User-Agent: Pan/0.155 (Kherson; fc5a80b8)
Cancel-Lock: sha1:jtj85XR/7vRmKvq7Pee03kic8SU=
 by: Lawrence D'Oliv - Sat, 24 Feb 2024 22:52 UTC

On Sat, 24 Feb 2024 12:40:52 -0800, Chris M. Thomasson wrote:

> Think of what type of performance hit one can take if they use double
> precision on a GPU that supports it in shader programs...

I don’t know; what kind of “performance hit” would it be?

Is it time to consider single-precision floats as basically a “legacy”
format, a holdover from the days when we couldn’t afford anything better?

Re: Radians Or Degrees?

<87r0h19z1i.fsf@bsb.me.uk>

  copy mid

https://www.rocksolidbbs.com/devel/article-flat.php?id=35182&group=comp.lang.c#35182

  copy link   Newsgroups: comp.lang.c
Path: i2pn2.org!i2pn.org!eternal-september.org!feeder3.eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail
From: ben.usenet@bsb.me.uk (Ben Bacarisse)
Newsgroups: comp.lang.c
Subject: Re: Radians Or Degrees?
Date: Sun, 25 Feb 2024 00:18:33 +0000
Organization: A noiseless patient Spider
Lines: 39
Message-ID: <87r0h19z1i.fsf@bsb.me.uk>
References: <ur5trn$3d64t$1@dont-email.me> <ur5v05$3ccut$1@dont-email.me>
<20240222015920.00000260@yahoo.com> <ur69j9$3ftgj$3@dont-email.me>
<ur86eg$1aip$1@dont-email.me> <ur88e4$1rr1$5@dont-email.me>
<ur8a2p$2446$1@dont-email.me> <ur8ctk$2vbd$2@dont-email.me>
<20240222233838.0000572f@yahoo.com>
<3b2e86cdb0ee8785b4405ab10871c5ca@www.novabbs.org>
<ur8nud$4n1r$1@dont-email.me> <20240223143250.000012a8@yahoo.com>
<59454a79216ece74ac3fee0e00473357@www.novabbs.org>
<uravp3$nl44$1@dont-email.me> <urb6rt$phho$3@dont-email.me>
<878r3abwkv.fsf@bsb.me.uk> <urbaki$qb3j$1@dont-email.me>
<8734tibr1t.fsf@bsb.me.uk> <urbg72$rbo3$1@dont-email.me>
<87wmquaby7.fsf@bsb.me.uk> <20240223174153.703@kylheku.com>
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Transfer-Encoding: 8bit
Injection-Info: dont-email.me; posting-host="e770f46cfdd6e611e431e3de15c787fc";
logging-data="1543358"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1/jWOuEFJ4qnpL2thZDMID+YtS1saRFYNY="
User-Agent: Gnus/5.13 (Gnus v5.13)
Cancel-Lock: sha1:xN/yjFcwnR8JH2Kluurln14wYoY=
sha1:uNPzL7r2Q6lVKCWMsQpAT0UaKx4=
X-BSB-Auth: 1.7068616e46dbac23db03.20240225001833GMT.87r0h19z1i.fsf@bsb.me.uk
 by: Ben Bacarisse - Sun, 25 Feb 2024 00:18 UTC

Kaz Kylheku <433-929-6894@kylheku.com> writes:

> On 2024-02-24, Ben Bacarisse <ben.usenet@bsb.me.uk> wrote:
>> Lawrence D'Oliveiro <ldo@nz.invalid> writes:
>>
>>> On Sat, 24 Feb 2024 01:15:58 +0000, Ben Bacarisse wrote:
>>>
>>>> Lawrence D'Oliveiro <ldo@nz.invalid> writes:
>>>>
>>>>> I thought they were the same thing: extra numbers inserted in the gap
>>>>> between the normalized number closest to zero on each side, to allow
>>>>> for gradual underflow.
>>>>
>>>> Those are subnormal. They are smaller (in magnitude) than the smallest
>>>> normal. Denormals are simply representations with leading zeros. IEEE
>>>> FP's implicit leading 1 means these (denormals that are not subnormal)
>>>> can't exist in that representation.
>>>
>>> So in IEEE754, they are the same thing.
>>
>> No. I am pretty sure you understand what's been said so you must be
>> arguing for the sake of it.
>
> I have only bicycles in my garage, so in my garage, "bicycles" and
> "vehicles" are the same thing, not just the same set.

I'm not sure what your point is. LD'O wanted to know why "they" brought
in the more specific term:

"Why did they bring in the term “subnormal”, anyway? What was wrong
with “denormalized”?"

I just suggested they "they" might have chosen to use the more specific
term "bicycles" for the vehicles in you garage because it's more
precise. Are you disagreeing or using mockery to support that rather
obvious idea?

--
Ben.

Re: Radians Or Degrees?

<urec1s$1l3du$1@dont-email.me>

  copy mid

https://www.rocksolidbbs.com/devel/article-flat.php?id=35193&group=comp.lang.c#35193

  copy link   Newsgroups: comp.lang.c
Path: i2pn2.org!i2pn.org!eternal-september.org!feeder3.eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail
From: chris.m.thomasson.1@gmail.com (Chris M. Thomasson)
Newsgroups: comp.lang.c
Subject: Re: Radians Or Degrees?
Date: Sat, 24 Feb 2024 19:26:53 -0800
Organization: A noiseless patient Spider
Lines: 25
Message-ID: <urec1s$1l3du$1@dont-email.me>
References: <ur5trn$3d64t$1@dont-email.me> <ur5v05$3ccut$1@dont-email.me>
<20240222015920.00000260@yahoo.com> <ur69j9$3ftgj$3@dont-email.me>
<ur86eg$1aip$1@dont-email.me> <ur88e4$1rr1$5@dont-email.me>
<ur8a2p$2446$1@dont-email.me> <ur8ctk$2vbd$2@dont-email.me>
<20240222233838.0000572f@yahoo.com>
<3b2e86cdb0ee8785b4405ab10871c5ca@www.novabbs.org>
<ur8nud$4n1r$1@dont-email.me> <ur8q2k$5nfr$1@dont-email.me>
<ur8qlp$5nfr$2@dont-email.me>
<a2a5c98883cafb6ab19668403b2dfb15@www.novabbs.org>
<urav5o$nqvp$1@dont-email.me> <urb704$phho$4@dont-email.me>
<urdk8j$1cis4$1@dont-email.me> <urdrv1$1e8e4$2@dont-email.me>
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 8bit
Injection-Date: Sun, 25 Feb 2024 03:26:53 -0000 (UTC)
Injection-Info: dont-email.me; posting-host="c4b1053402b94d374edaefe0d2d552d3";
logging-data="1740222"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX18ZqGNBNLQvqgVIut5FVHpwBxARmnczu/Y="
User-Agent: Mozilla Thunderbird
Cancel-Lock: sha1:FV9TQNc1PiVQG60xKdrk6DvOJD4=
In-Reply-To: <urdrv1$1e8e4$2@dont-email.me>
Content-Language: en-US
 by: Chris M. Thomasson - Sun, 25 Feb 2024 03:26 UTC

On 2/24/2024 2:52 PM, Lawrence D'Oliveiro wrote:
> On Sat, 24 Feb 2024 12:40:52 -0800, Chris M. Thomasson wrote:
>
>> Think of what type of performance hit one can take if they use double
>> precision on a GPU that supports it in shader programs...
>
> I don’t know; what kind of “performance hit” would it be?
>
> Is it time to consider single-precision floats as basically a “legacy”
> format, a holdover from the days when we couldn’t afford anything better?

Imvho, it still has a lot to do with what type of work is involved. Some
people want to get bleeding edge wrt FPS and use floats for games, and
all sorts of interesting tricks wrt not really caring about accuracy all
that much, in a sense. Then, others don't seem to mind "too" of a
little hit on fps as long is they can reach a reasonable level of
accuracy for their particular problem. Double precision, heck I have
seen quad precision in a shader program before.

think of the following interesting aspect:

https://forums.parallax.com/discussion/147522/dog-leg-hypotenuse-approximation

Vs "needing" to get much more accurate results, for say medical imaging
wrt volumetric renders...

Re: Radians Or Degrees?

<urempm$1mvl0$4@dont-email.me>

  copy mid

https://www.rocksolidbbs.com/devel/article-flat.php?id=35196&group=comp.lang.c#35196

  copy link   Newsgroups: comp.lang.c
Path: i2pn2.org!i2pn.org!eternal-september.org!feeder3.eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail
From: ldo@nz.invalid (Lawrence D'Oliveiro)
Newsgroups: comp.lang.c
Subject: Re: Radians Or Degrees?
Date: Sun, 25 Feb 2024 06:30:14 -0000 (UTC)
Organization: A noiseless patient Spider
Lines: 21
Message-ID: <urempm$1mvl0$4@dont-email.me>
References: <ur5trn$3d64t$1@dont-email.me> <ur5v05$3ccut$1@dont-email.me>
<20240222015920.00000260@yahoo.com> <ur69j9$3ftgj$3@dont-email.me>
<ur86eg$1aip$1@dont-email.me> <ur88e4$1rr1$5@dont-email.me>
<ur8a2p$2446$1@dont-email.me> <ur8ctk$2vbd$2@dont-email.me>
<20240222233838.0000572f@yahoo.com>
<3b2e86cdb0ee8785b4405ab10871c5ca@www.novabbs.org>
<ur8nud$4n1r$1@dont-email.me> <ur8q2k$5nfr$1@dont-email.me>
<ur8qlp$5nfr$2@dont-email.me>
<a2a5c98883cafb6ab19668403b2dfb15@www.novabbs.org>
<urav5o$nqvp$1@dont-email.me> <urb704$phho$4@dont-email.me>
<urdk8j$1cis4$1@dont-email.me> <urdrv1$1e8e4$2@dont-email.me>
<urec1s$1l3du$1@dont-email.me>
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Injection-Date: Sun, 25 Feb 2024 06:30:14 -0000 (UTC)
Injection-Info: dont-email.me; posting-host="5d3a24d1dc8cf78704609d9d7dcc21b3";
logging-data="1801888"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1+gr0iMBfWMJqk/Zd/L3ube"
User-Agent: Pan/0.155 (Kherson; fc5a80b8)
Cancel-Lock: sha1:fEFzm6qjagYmztHOJT36t/KGoVw=
 by: Lawrence D'Oliv - Sun, 25 Feb 2024 06:30 UTC

On Sat, 24 Feb 2024 19:26:53 -0800, Chris M. Thomasson wrote:

> think of the following interesting aspect:

One of many. Have you read the paper “What Every Computer Scientist Should
Know About Computer Arithmetic”? Among the examples, it looks at the well-
known formula for the quadratic equation:

-b ± sqrt(b² - 4ac)
-------------------
2a

and considers cases where this will not work well, and where you should
use the alternative form

2c
-------------------
-b ± sqrt(b² - 4ac)

instead. (Which has its own cases where it produces poor results, but
luckily they don’t overlap those for the first form.)

Re: Radians Or Degrees?

<20240225125748.00003982@yahoo.com>

  copy mid

https://www.rocksolidbbs.com/devel/article-flat.php?id=35197&group=comp.lang.c#35197

  copy link   Newsgroups: comp.lang.c
Path: i2pn2.org!i2pn.org!eternal-september.org!feeder3.eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail
From: already5chosen@yahoo.com (Michael S)
Newsgroups: comp.lang.c
Subject: Re: Radians Or Degrees?
Date: Sun, 25 Feb 2024 12:57:48 +0200
Organization: A noiseless patient Spider
Lines: 44
Message-ID: <20240225125748.00003982@yahoo.com>
References: <ur5trn$3d64t$1@dont-email.me>
<ur5v05$3ccut$1@dont-email.me>
<20240222015920.00000260@yahoo.com>
<ur69j9$3ftgj$3@dont-email.me>
<ur86eg$1aip$1@dont-email.me>
<ur88e4$1rr1$5@dont-email.me>
<ur8a2p$2446$1@dont-email.me>
<ur8ctk$2vbd$2@dont-email.me>
<20240222233838.0000572f@yahoo.com>
<3b2e86cdb0ee8785b4405ab10871c5ca@www.novabbs.org>
<ur8nud$4n1r$1@dont-email.me>
<20240223143250.000012a8@yahoo.com>
<59454a79216ece74ac3fee0e00473357@www.novabbs.org>
<uravp3$nl44$1@dont-email.me>
<urb6rt$phho$3@dont-email.me>
<878r3abwkv.fsf@bsb.me.uk>
<urbaki$qb3j$1@dont-email.me>
<8734tibr1t.fsf@bsb.me.uk>
<urbg72$rbo3$1@dont-email.me>
<87wmquaby7.fsf@bsb.me.uk>
<20240223174153.703@kylheku.com>
<87r0h19z1i.fsf@bsb.me.uk>
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Transfer-Encoding: quoted-printable
Injection-Info: dont-email.me; posting-host="5f5e751eedbdba9b2a3fc75e9f7acc52";
logging-data="4005671"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1/FNLhzIQlkLGmf7G5M9gZXBlNIeZPKyFo="
Cancel-Lock: sha1:l8y+eRDFV6uYhB+0HS/ptOh44rA=
X-Newsreader: Claws Mail 3.19.1 (GTK+ 2.24.33; x86_64-w64-mingw32)
 by: Michael S - Sun, 25 Feb 2024 10:57 UTC

On Sun, 25 Feb 2024 00:18:33 +0000
Ben Bacarisse <ben.usenet@bsb.me.uk> wrote:

> Kaz Kylheku <433-929-6894@kylheku.com> writes:
>
> > On 2024-02-24, Ben Bacarisse <ben.usenet@bsb.me.uk> wrote:
> >> Lawrence D'Oliveiro <ldo@nz.invalid> writes:
> >>
> >>> On Sat, 24 Feb 2024 01:15:58 +0000, Ben Bacarisse wrote:
> >>>
> >>>> Lawrence D'Oliveiro <ldo@nz.invalid> writes:
> >>>>
> >>>>> I thought they were the same thing: extra numbers inserted in
> >>>>> the gap between the normalized number closest to zero on each
> >>>>> side, to allow for gradual underflow.
> >>>>
> >>>> Those are subnormal. They are smaller (in magnitude) than the
> >>>> smallest normal. Denormals are simply representations with
> >>>> leading zeros. IEEE FP's implicit leading 1 means these
> >>>> (denormals that are not subnormal) can't exist in that
> >>>> representation.
> >>>
> >>> So in IEEE754, they are the same thing.
> >>
> >> No. I am pretty sure you understand what's been said so you must
> >> be arguing for the sake of it.
> >
> > I have only bicycles in my garage, so in my garage, "bicycles" and
> > "vehicles" are the same thing, not just the same set.
>
> I'm not sure what your point is. LD'O wanted to know why "they"
> brought in the more specific term:
>
> "Why did they bring in the term “subnormal”, anyway? What was wrong
> with “denormalized”?"
>
> I just suggested they "they" might have chosen to use the more
> specific term "bicycles" for the vehicles in you garage because it's
> more precise. Are you disagreeing or using mockery to support that
> rather obvious idea?
>

Re: Radians Or Degrees?

<urf7nn$1qi2u$1@dont-email.me>

  copy mid

https://www.rocksolidbbs.com/devel/article-flat.php?id=35198&group=comp.lang.c#35198

  copy link   Newsgroups: comp.lang.c
Path: i2pn2.org!i2pn.org!eternal-september.org!feeder3.eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail
From: malcolm.arthur.mclean@gmail.com (Malcolm McLean)
Newsgroups: comp.lang.c
Subject: Re: Radians Or Degrees?
Date: Sun, 25 Feb 2024 11:19:19 +0000
Organization: A noiseless patient Spider
Lines: 19
Message-ID: <urf7nn$1qi2u$1@dont-email.me>
References: <ur5trn$3d64t$1@dont-email.me>
<pan$d0f42$eeb000fb$9b95dafc$a5a80129@invalid.invalid>
<ur76he$3qbhl$2@dont-email.me> <ur87th$1rr1$2@dont-email.me>
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 7bit
Injection-Date: Sun, 25 Feb 2024 11:19:19 -0000 (UTC)
Injection-Info: dont-email.me; posting-host="7a3a2a7d61b5a0f760dcb239f691c4f1";
logging-data="1919070"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX19O8DfKKl8HHGCGr3apW0uauLOu1NHYFnE="
User-Agent: Mozilla Thunderbird
Cancel-Lock: sha1:tSE/8x52/NJV4pjBqGtwNJNUmQc=
Content-Language: en-GB
In-Reply-To: <ur87th$1rr1$2@dont-email.me>
 by: Malcolm McLean - Sun, 25 Feb 2024 11:19 UTC

On 22/02/2024 19:39, Lawrence D'Oliveiro wrote:
> On Thu, 22 Feb 2024 11:09:50 +0100, David Brown wrote:
>
>> And while degrees were created by people, rather than something
>> fundamental in the mathematics, the number of divisions was picked
>> carefully for particular properties (lots of divisors).
>
> I know base-360 is supposed to have come from the Babylonians. But
> consider: you get exactly the same range of exact divisors (2, 3, 5, and
> powers and products thereof) with base-30.

A year has 365 days, and that influenced the idea that there should be
360 degrees in a circle. But the Babylonians knew that it was 365 or
close and not 360. So did they think that having 360 degrees was a
fundamental, inherent, mathematical property of a circle, or did they not?
--
Check out Basic Algorithms and my other books:
https://www.lulu.com/spotlight/bgy1mm

Re: Radians Or Degrees?

<urfe56$1s0q9$1@dont-email.me>

  copy mid

https://www.rocksolidbbs.com/devel/article-flat.php?id=35200&group=comp.lang.c#35200

  copy link   Newsgroups: comp.lang.c
Path: i2pn2.org!i2pn.org!eternal-september.org!feeder3.eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail
From: richard.nospam@gmail.invalid (Richard Harnden)
Newsgroups: comp.lang.c
Subject: Re: Radians Or Degrees?
Date: Sun, 25 Feb 2024 13:08:53 +0000
Organization: A noiseless patient Spider
Lines: 21
Message-ID: <urfe56$1s0q9$1@dont-email.me>
References: <ur5trn$3d64t$1@dont-email.me>
<pan$d0f42$eeb000fb$9b95dafc$a5a80129@invalid.invalid>
<ur76he$3qbhl$2@dont-email.me> <ur87th$1rr1$2@dont-email.me>
<urf7nn$1qi2u$1@dont-email.me>
Reply-To: nospam.harnden@invalid.com
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 7bit
Injection-Date: Sun, 25 Feb 2024 13:08:54 -0000 (UTC)
Injection-Info: dont-email.me; posting-host="1ff133eb3ebe1a49e8cd8170adc7489c";
logging-data="1966921"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1+W6pAPbNk83KRbOye0INAXegkQ72Ac9Zo="
User-Agent: Mozilla Thunderbird
Cancel-Lock: sha1:IfsQetoo7vOJvCVMS89aRypKo2s=
Content-Language: en-GB
In-Reply-To: <urf7nn$1qi2u$1@dont-email.me>
 by: Richard Harnden - Sun, 25 Feb 2024 13:08 UTC

On 25/02/2024 11:19, Malcolm McLean wrote:
> On 22/02/2024 19:39, Lawrence D'Oliveiro wrote:
>> On Thu, 22 Feb 2024 11:09:50 +0100, David Brown wrote:
>>
>>> And while degrees were created by people, rather than something
>>> fundamental in the mathematics, the number of divisions was picked
>>> carefully for particular properties (lots of divisors).
>>
>> I know base-360 is supposed to have come from the Babylonians. But
>> consider: you get exactly the same range of exact divisors (2, 3, 5, and
>> powers and products thereof) with base-30.
>
> A year has 365 days, and that influenced the idea that there should be
> 360 degrees in a circle. But the Babylonians knew that it was 365 or
> close and not 360. So did they think that having 360 degrees was a
> fundamental, inherent, mathematical property of a circle, or did they not?

I don't think that's true.

It's 360 because it divides by {lots}, nothing to do with days in a year.

Re: Radians Or Degrees?

<urflp8$1tol5$1@dont-email.me>

  copy mid

https://www.rocksolidbbs.com/devel/article-flat.php?id=35201&group=comp.lang.c#35201

  copy link   Newsgroups: comp.lang.c comp.arch
Path: i2pn2.org!i2pn.org!eternal-september.org!feeder3.eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail
From: terje.mathisen@tmsw.no (Terje Mathisen)
Newsgroups: comp.lang.c,comp.arch
Subject: Re: Radians Or Degrees?
Date: Sun, 25 Feb 2024 16:19:02 +0100
Organization: A noiseless patient Spider
Lines: 52
Message-ID: <urflp8$1tol5$1@dont-email.me>
References: <ur5trn$3d64t$1@dont-email.me> <ur5v05$3ccut$1@dont-email.me>
<20240222015920.00000260@yahoo.com> <ur69j9$3ftgj$3@dont-email.me>
<ur86eg$1aip$1@dont-email.me> <ur88e4$1rr1$5@dont-email.me>
<ur8a2p$2446$1@dont-email.me> <ur8ctk$2vbd$2@dont-email.me>
<20240222233838.0000572f@yahoo.com>
<3b2e86cdb0ee8785b4405ab10871c5ca@www.novabbs.org>
<ur8nud$4n1r$1@dont-email.me> <20240223143250.000012a8@yahoo.com>
<59454a79216ece74ac3fee0e00473357@www.novabbs.org>
<uravp3$nl44$1@dont-email.me>
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 7bit
Injection-Date: Sun, 25 Feb 2024 15:19:04 -0000 (UTC)
Injection-Info: dont-email.me; posting-host="bdf1a72e5770c24bab60250a7030be71";
logging-data="2024101"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX185+ks7KGyDP4p7cZrcS05nWBWjkwLOdTmMLuFybgQklA=="
User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:91.0) Gecko/20100101
Firefox/91.0 SeaMonkey/2.53.18.1
Cancel-Lock: sha1:kNkkWu4fZVdnu/TN0hMl5fOGzek=
In-Reply-To: <uravp3$nl44$1@dont-email.me>
 by: Terje Mathisen - Sun, 25 Feb 2024 15:19 UTC

Steven G. Kargl wrote:
> Fortunately, for 32-bit single precision floating point, one can
> exhaustively test single-argument functions. For the SW implementation
> on FreeBSD, exhaustive testing shows
>
> % tlibm sinpi -fPED -x 0 -X 0x1p23 -s 0
> Interval tested for sinpif: [0,8.38861e+06]
> 1000000 calls, 0.015453 secs, 0.01545 usecs/call
> ulp <= 0.5: 99.842% 1253631604 | 99.842% 1253631604
> 0.5 < ulp < 0.6: 0.158% 1989420 | 100.000% 1255621024
> Max ulp: 0.583666 at 6.07950642e-05

That seems worse than it should be, I would expect better results than
the 0.5009 quoted for regular sin() below, and still with the same or
better performance. The only obvious explanation would be that sin(x)
over +/- 45 degrees would have a first Taylor term of 1.0*x, and you
could probably force the first Cheby term to be the same, so by adding
that as the last stage you get improved precision for free?

>
> % tlibm sin -fPED -x 0 -X 0x1p23 -s 0
> Interval tested for sinf: [0,8.38861e+06]
> 1000000 calls, 0.019520 secs, 0.01952 usecs/call
> ulp <= 0.5: 99.995% 1249842491 | 99.995% 1249842491
> 0.5 < ulp < 0.6: 0.005% 60102 | 100.000% 1249902593
> Max ulp: 0.500900 at 3.68277281e+05
>
> The speed test is for 1M values evenly distributed over
> the interval. The difference in speed for sinpi vs sin
> is due to the argument reduction.
>
> Note 1: libm built with clang/llvm with only -O2 on a
> AMD Phenom II X2 560 Processor (3300.14-MHz K8-class CPU).
>
> Note 2: subnormal values for x are test not included in
> the count as subnormal are tested with a different approach.
>

sin(x) for Subnormal x seems like it should be trivial: If you just
return x the maximum error of a Taylor series with two terms
(x - x^3/3!)
would be that second term which is by definition zero since x is already
subnormal, right?

If you want to perform well on a platform where subnormal ops traps to a
much slower hardware or software path, then it might make sense to start
by checking for |x| < 2^-340 or so?

Terje
--
- <Terje.Mathisen at tmsw.no>
"almost all programming can be viewed as an exercise in caching"

Re: Radians Or Degrees?

<4c2829a95c68dcdf7965afe15804110e@www.novabbs.org>

  copy mid

https://www.rocksolidbbs.com/devel/article-flat.php?id=35207&group=comp.lang.c#35207

  copy link   Newsgroups: comp.lang.c comp.arch
Path: i2pn2.org!.POSTED!not-for-mail
From: mitchalsup@aol.com (MitchAlsup1)
Newsgroups: comp.lang.c,comp.arch
Subject: Re: Radians Or Degrees?
Date: Sun, 25 Feb 2024 18:11:40 +0000
Organization: Rocksolid Light
Message-ID: <4c2829a95c68dcdf7965afe15804110e@www.novabbs.org>
References: <ur5trn$3d64t$1@dont-email.me> <ur5v05$3ccut$1@dont-email.me> <20240222015920.00000260@yahoo.com> <ur69j9$3ftgj$3@dont-email.me> <ur86eg$1aip$1@dont-email.me> <ur88e4$1rr1$5@dont-email.me> <ur8a2p$2446$1@dont-email.me> <ur8ctk$2vbd$2@dont-email.me> <20240222233838.0000572f@yahoo.com> <3b2e86cdb0ee8785b4405ab10871c5ca@www.novabbs.org> <ur8nud$4n1r$1@dont-email.me> <20240223143250.000012a8@yahoo.com> <59454a79216ece74ac3fee0e00473357@www.novabbs.org> <uravp3$nl44$1@dont-email.me> <urflp8$1tol5$1@dont-email.me>
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8; format=flowed
Content-Transfer-Encoding: 8bit
Injection-Info: i2pn2.org;
logging-data="4096975"; mail-complaints-to="usenet@i2pn2.org";
posting-account="PGd4t4cXnWwgUWG9VtTiCsm47oOWbHLcTr4rYoM0Edo";
User-Agent: Rocksolid Light
X-Rslight-Posting-User: ac58ceb75ea22753186dae54d967fed894c3dce8
X-Rslight-Site: $2y$10$mD0bsjnkN9tAvaT3zv.np.K2jmsi3PJlW4kmcn43j9n9Isj20E.Ti
X-Spam-Checker-Version: SpamAssassin 4.0.0
 by: MitchAlsup1 - Sun, 25 Feb 2024 18:11 UTC

Terje Mathisen wrote:

>

> sin(x) for Subnormal x seems like it should be trivial: If you just
> return x the maximum error of a Taylor series with two terms
> (x - x^3/3!)
> would be that second term which is by definition zero since x is already
> subnormal, right?

The 2 term polynomial begins to be accurate when |x| < ~2^-19 which is far
bigger than 2^-1023. (2^-19)^3 is 2^-57 which has few digits in the resulting
fraction 2^-19; certainly no 3rd term is required.

> If you want to perform well on a platform where subnormal ops traps to a
> much slower hardware or software path, then it might make sense to start
> by checking for |x| < 2^-340 or so?

Many subnormal operands yield constant results or themselves::

cos(sn) = 1.0
sin(sn) = sn
tan(sn) = sn

> Terje

Re: Radians Or Degrees?

<urgeho$240t1$1@dont-email.me>

  copy mid

https://www.rocksolidbbs.com/devel/article-flat.php?id=35212&group=comp.lang.c#35212

  copy link   Newsgroups: comp.lang.c
Path: i2pn2.org!i2pn.org!eternal-september.org!feeder3.eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail
From: ldo@nz.invalid (Lawrence D'Oliveiro)
Newsgroups: comp.lang.c
Subject: Re: Radians Or Degrees?
Date: Sun, 25 Feb 2024 22:21:44 -0000 (UTC)
Organization: A noiseless patient Spider
Lines: 5
Message-ID: <urgeho$240t1$1@dont-email.me>
References: <ur5trn$3d64t$1@dont-email.me>
<pan$d0f42$eeb000fb$9b95dafc$a5a80129@invalid.invalid>
<ur76he$3qbhl$2@dont-email.me> <ur87th$1rr1$2@dont-email.me>
<urf7nn$1qi2u$1@dont-email.me> <urfe56$1s0q9$1@dont-email.me>
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Injection-Date: Sun, 25 Feb 2024 22:21:44 -0000 (UTC)
Injection-Info: dont-email.me; posting-host="5d3a24d1dc8cf78704609d9d7dcc21b3";
logging-data="2229153"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX18/bCDAB4IJPwhCFXXHegmD"
User-Agent: Pan/0.155 (Kherson; fc5a80b8)
Cancel-Lock: sha1:ZGVEZAeK8e52wQU5dN8rEpyLQPo=
 by: Lawrence D'Oliv - Sun, 25 Feb 2024 22:21 UTC

On Sun, 25 Feb 2024 13:08:53 +0000, Richard Harnden wrote:

> It's 360 because it divides by {lots}, nothing to do with days in a year.

And you can get all those same divisors with 30.

Re: Radians Or Degrees?

<87a5no9nze.fsf@bsb.me.uk>

  copy mid

https://www.rocksolidbbs.com/devel/article-flat.php?id=35213&group=comp.lang.c#35213

  copy link   Newsgroups: comp.lang.c
Path: i2pn2.org!i2pn.org!eternal-september.org!feeder3.eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail
From: ben.usenet@bsb.me.uk (Ben Bacarisse)
Newsgroups: comp.lang.c
Subject: Re: Radians Or Degrees?
Date: Sun, 25 Feb 2024 22:29:41 +0000
Organization: A noiseless patient Spider
Lines: 13
Message-ID: <87a5no9nze.fsf@bsb.me.uk>
References: <ur5trn$3d64t$1@dont-email.me>
<pan$d0f42$eeb000fb$9b95dafc$a5a80129@invalid.invalid>
<ur76he$3qbhl$2@dont-email.me> <ur87th$1rr1$2@dont-email.me>
<urf7nn$1qi2u$1@dont-email.me> <urfe56$1s0q9$1@dont-email.me>
<urgeho$240t1$1@dont-email.me>
MIME-Version: 1.0
Content-Type: text/plain
Injection-Info: dont-email.me; posting-host="e770f46cfdd6e611e431e3de15c787fc";
logging-data="2233281"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX19s6ptcaUIfKykaE1e5sqI+/Z79WkOpvww="
User-Agent: Gnus/5.13 (Gnus v5.13)
Cancel-Lock: sha1:k8AfybAYi0Pz6qjtves41BzSpK4=
sha1:dB54Qc7V2HsB7s0hcxv24vuW9TI=
X-BSB-Auth: 1.094d8f0ab311e0012ca8.20240225222941GMT.87a5no9nze.fsf@bsb.me.uk
 by: Ben Bacarisse - Sun, 25 Feb 2024 22:29 UTC

Lawrence D'Oliveiro <ldo@nz.invalid> writes:

> On Sun, 25 Feb 2024 13:08:53 +0000, Richard Harnden wrote:
>
>> It's 360 because it divides by {lots}, nothing to do with days in a year.
>
> And you can get all those same divisors with 30.

You are confusing unique prime factors with divisors. Well, that's what
you appear to be doing but I suspect another motive altogether.

--
Ben.

Re: Radians Or Degrees?

<87le78w4fe.fsf@nosuchdomain.example.com>

  copy mid

https://www.rocksolidbbs.com/devel/article-flat.php?id=35214&group=comp.lang.c#35214

  copy link   Newsgroups: comp.lang.c
Path: i2pn2.org!i2pn.org!eternal-september.org!feeder3.eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail
From: Keith.S.Thompson+u@gmail.com (Keith Thompson)
Newsgroups: comp.lang.c
Subject: Re: Radians Or Degrees?
Date: Sun, 25 Feb 2024 14:43:33 -0800
Organization: None to speak of
Lines: 14
Message-ID: <87le78w4fe.fsf@nosuchdomain.example.com>
References: <ur5trn$3d64t$1@dont-email.me>
<pan$d0f42$eeb000fb$9b95dafc$a5a80129@invalid.invalid>
<ur76he$3qbhl$2@dont-email.me> <ur87th$1rr1$2@dont-email.me>
<urf7nn$1qi2u$1@dont-email.me> <urfe56$1s0q9$1@dont-email.me>
<urgeho$240t1$1@dont-email.me>
MIME-Version: 1.0
Content-Type: text/plain
Injection-Info: dont-email.me; posting-host="bb66de1b9b107dde749bb8d6bc16acf3";
logging-data="2241799"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1/RJNyaC/sHmDoUGME9Sp4Y"
User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.2 (gnu/linux)
Cancel-Lock: sha1:dognJIErwPbF0UNPHVdYN7pNSfM=
sha1:Xn2V8KKABYGrOjhcce5QD4IiiBU=
 by: Keith Thompson - Sun, 25 Feb 2024 22:43 UTC

Lawrence D'Oliveiro <ldo@nz.invalid> writes:
> On Sun, 25 Feb 2024 13:08:53 +0000, Richard Harnden wrote:
>
>> It's 360 because it divides by {lots}, nothing to do with days in a year.
>
> And you can get all those same divisors with 30.

All except 4, 8, 9, 12, 18, 20, 24, 36, 40, 45, 60, 72, 90, 120, 180,
and 360.

--
Keith Thompson (The_Other_Keith) Keith.S.Thompson+u@gmail.com
Working, but not speaking, for Medtronic
void Void(void) { Void(); } /* The recursive call of the void */

Re: Radians Or Degrees?

<urgham$24j63$1@dont-email.me>

  copy mid

https://www.rocksolidbbs.com/devel/article-flat.php?id=35217&group=comp.lang.c#35217

  copy link   Newsgroups: comp.lang.c
Path: i2pn2.org!i2pn.org!eternal-september.org!feeder3.eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail
From: bc@freeuk.com (bart)
Newsgroups: comp.lang.c
Subject: Re: Radians Or Degrees?
Date: Sun, 25 Feb 2024 23:09:10 +0000
Organization: A noiseless patient Spider
Lines: 22
Message-ID: <urgham$24j63$1@dont-email.me>
References: <ur5trn$3d64t$1@dont-email.me>
<pan$d0f42$eeb000fb$9b95dafc$a5a80129@invalid.invalid>
<ur76he$3qbhl$2@dont-email.me> <ur87th$1rr1$2@dont-email.me>
<urf7nn$1qi2u$1@dont-email.me> <urfe56$1s0q9$1@dont-email.me>
<urgeho$240t1$1@dont-email.me>
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 7bit
Injection-Date: Sun, 25 Feb 2024 23:09:10 -0000 (UTC)
Injection-Info: dont-email.me; posting-host="8721302dc2883c48b2e64fb653a28420";
logging-data="2247875"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1/4nuOW8whtZ9CJoKa4s/qHUBtfCVPJ7xo="
User-Agent: Mozilla Thunderbird
Cancel-Lock: sha1:7Afk0qx9KnRgkwV+ZvgtqX1DpTU=
Content-Language: en-GB
In-Reply-To: <urgeho$240t1$1@dont-email.me>
 by: bart - Sun, 25 Feb 2024 23:09 UTC

On 25/02/2024 22:21, Lawrence D'Oliveiro wrote:
> On Sun, 25 Feb 2024 13:08:53 +0000, Richard Harnden wrote:
>
>> It's 360 because it divides by {lots}, nothing to do with days in a year.
>
> And you can get all those same divisors with 30.

You mean, by dividing a circle into 30 degrees instead of 360?

30 can't be evenly divided by 4, 8, 9, 12, 18 or 20 for a start.

The angles of a triangle would add up to 15 degrees; so a right-angled
triangle would have angles of 7.5 and 3.75 degrees.

A heading of 270 on a compass would be 22.5 degrees in your scheme, and
the smallest change of heading, 1 degree, would be 12 degrees using the
current system.

Or maybe you mean something else entirely; using base-30 instead of
base-10? Sure, that's going to be practical!

Re: Radians Or Degrees?

<urivrk$2olmn$2@dont-email.me>

  copy mid

https://www.rocksolidbbs.com/devel/article-flat.php?id=35259&group=comp.lang.c#35259

  copy link   Newsgroups: comp.lang.c
Path: i2pn2.org!i2pn.org!eternal-september.org!feeder3.eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail
From: ldo@nz.invalid (Lawrence D'Oliveiro)
Newsgroups: comp.lang.c
Subject: Re: Radians Or Degrees?
Date: Mon, 26 Feb 2024 21:29:25 -0000 (UTC)
Organization: A noiseless patient Spider
Lines: 16
Message-ID: <urivrk$2olmn$2@dont-email.me>
References: <ur5trn$3d64t$1@dont-email.me>
<pan$d0f42$eeb000fb$9b95dafc$a5a80129@invalid.invalid>
<ur76he$3qbhl$2@dont-email.me> <ur87th$1rr1$2@dont-email.me>
<urf7nn$1qi2u$1@dont-email.me> <urfe56$1s0q9$1@dont-email.me>
<urgeho$240t1$1@dont-email.me> <87a5no9nze.fsf@bsb.me.uk>
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Injection-Date: Mon, 26 Feb 2024 21:29:25 -0000 (UTC)
Injection-Info: dont-email.me; posting-host="ea15bd06c2061660f1136ed37eb9a688";
logging-data="2905815"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1/qZPmcMSmbxFkZmj7j4haZ"
User-Agent: Pan/0.155 (Kherson; fc5a80b8)
Cancel-Lock: sha1:WydhsvgwJeeRuk59dOSEoY7+QSI=
 by: Lawrence D'Oliv - Mon, 26 Feb 2024 21:29 UTC

On Sun, 25 Feb 2024 22:29:41 +0000, Ben Bacarisse wrote:

> Lawrence D'Oliveiro <ldo@nz.invalid> writes:
>
>> On Sun, 25 Feb 2024 13:08:53 +0000, Richard Harnden wrote:
>>
>>> It's 360 because it divides by {lots}, nothing to do with days in a
>>> year.
>>
>> And you can get all those same divisors with 30.
>
> You are confusing unique prime factors with divisors.

No, I’m not. Once you have one occurrence of a prime factor, you get the
ability to exactly represent fractions involving all powers of that
factor, and all products of that factor with other factors.

Re: Radians Or Degrees?

<urj00h$2olmn$3@dont-email.me>

  copy mid

https://www.rocksolidbbs.com/devel/article-flat.php?id=35260&group=comp.lang.c#35260

  copy link   Newsgroups: comp.lang.c
Path: i2pn2.org!i2pn.org!eternal-september.org!feeder3.eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail
From: ldo@nz.invalid (Lawrence D'Oliveiro)
Newsgroups: comp.lang.c
Subject: Re: Radians Or Degrees?
Date: Mon, 26 Feb 2024 21:32:01 -0000 (UTC)
Organization: A noiseless patient Spider
Lines: 34
Message-ID: <urj00h$2olmn$3@dont-email.me>
References: <ur5trn$3d64t$1@dont-email.me>
<pan$d0f42$eeb000fb$9b95dafc$a5a80129@invalid.invalid>
<ur76he$3qbhl$2@dont-email.me> <ur87th$1rr1$2@dont-email.me>
<urf7nn$1qi2u$1@dont-email.me> <urfe56$1s0q9$1@dont-email.me>
<urgeho$240t1$1@dont-email.me> <87le78w4fe.fsf@nosuchdomain.example.com>
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Injection-Date: Mon, 26 Feb 2024 21:32:01 -0000 (UTC)
Injection-Info: dont-email.me; posting-host="ea15bd06c2061660f1136ed37eb9a688";
logging-data="2905815"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1+Sp6eejABtYnUhj7EpdCO7"
User-Agent: Pan/0.155 (Kherson; fc5a80b8)
Cancel-Lock: sha1:Ki++kbBULinB9YrFimsWgaS8sCI=
 by: Lawrence D'Oliv - Mon, 26 Feb 2024 21:32 UTC

On Sun, 25 Feb 2024 14:43:33 -0800, Keith Thompson wrote:

> Lawrence D'Oliveiro <ldo@nz.invalid> writes:
>
>> On Sun, 25 Feb 2024 13:08:53 +0000, Richard Harnden wrote:
>>
>>> It's 360 because it divides by {lots}, nothing to do with days in a
>>> year.
>>
>> And you can get all those same divisors with 30.
>
> All except 4, 8, 9, 12, 18, 20, 24, 36, 40, 45, 60, 72, 90, 120, 180,
> and 360.

All exactly representable in Base-30:

1 / 4 => 0.7f
1 / 8 => 0.3mf
1 / 9 => 0.3a
1 / 12 => 0.2f
1 / 18 => 0.1k
1 / 20 => 0.1f
1 / 24 => 0.17f
1 / 36 => 0.0p
1 / 40 => 0.0mf
1 / 45 => 0.0k
1 / 60 => 0.0f
1 / 72 => 0.0cf
1 / 90 => 0.0a
1 / 120 => 0.07f
1 / 180 => 0.05
1 / 360 => 0.02f

No approximations, no recurring digits.


devel / comp.lang.c / Re: Radians Or Degrees?

Pages:1234567
server_pubkey.txt

rocksolid light 0.9.81
clearnet tor