[Bug 268421] ATAN2(3) manpage contains UTF8 character codes
- Reply: bugzilla-noreply_a_freebsd.org: "[Bug 268421] ATAN2(3) manpage contains UTF8 character codes"
- Reply: bugzilla-noreply_a_freebsd.org: "[Bug 268421] ATAN2(3) manpage contains UTF8 character codes"
- Reply: bugzilla-noreply_a_freebsd.org: "[Bug 268421] ATAN2(3) manpage contains UTF8 character codes"
- Reply: bugzilla-noreply_a_freebsd.org: "[Bug 268421] ATAN2(3) manpage contains UTF8 character codes"
- Reply: bugzilla-noreply_a_freebsd.org: "[Bug 268421] ATAN2(3) manpage contains UTF8 character codes"
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Sat, 17 Dec 2022 00:46:05 UTC
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=268421
Bug ID: 268421
Summary: ATAN2(3) manpage contains UTF8 character codes
Product: Documentation
Version: Latest
Hardware: Any
OS: Any
Status: New
Severity: Affects Many People
Priority: ---
Component: Manual Pages
Assignee: bugs@FreeBSD.org
Reporter: dclarke@blastwave.org
CC: doc@FreeBSD.org
Looking at the manpage for ATAN2(3) where I see the strange usage of
some UTF8 characters where a trivial asterisk '*' would be fine. This
page does not render on my XTerm with a whole collection of fonts
available.
$ uname -apKU
FreeBSD callisto 13.1-RELEASE-p3 FreeBSD 13.1-RELEASE-p3 GENERIC amd64 amd64
1301000 1301000
$ man atan2 | grep 'satisfy' | hdump -Ax -t x1 -v
0: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20
10: 73 61 74 69 73 66 79 20 78 20 3d 20 72 e2 88 97
20: 63 6f 73 20 74 68 65 74 61 20 61 6e 64 20 79 20
30: 3d 20 72 e2 88 97 73 69 6e 20 74 68 65 74 61 2e
40: 20 20 54 68 65 73 65 20 65 71 75 61 74 69 6f 6e
50: 73 0a
52:
$
There we see the strange UTF-8 char byte sequence "e2 88 97".
On NetBSD 9.3 I see :
NOTES
The function atan2() defines "if x > 0," atan2(0, 0) = 0 on a VAX despite
that previously atan2(0, 0) may have generated an error message. The
reasons for assigning a value to atan2(0, 0) are these:
1. Programs that test arguments to avoid computing atan2(0, 0)
must be indifferent to its value. Programs that require it to
be invalid are vulnerable to diverse reactions to that
invalidity on diverse computer systems.
2. The atan2() function is used mostly to convert from
rectangular (x,y) to polar (r,theta) coordinates that must
satisfy x = r*cos theta and y = r*sin theta. These equations
are satisfied when (x=0,y=0) is mapped to (r=0,theta=0) on a
VAX. In general, conversions to polar coordinates should be
computed thus:
r := hypot(x,y); ... := sqrt(x*x+y*y)
theta := atan2(y,x).
3. The foregoing formulas need not be altered to cope in a
reasonable way with signed zeros and infinities on a machine
that conforms to IEEE 754; the versions of hypot(3) and
atan2() provided for such a machine are designed to handle all
cases. That is why atan2(+-0, -0) = +-pi for instance. In
general the formulas above are equivalent to these:
r := sqrt(x*x+y*y); if r = 0 then x := copysign(1,x);
Those are trivial asterisk chars 0x2A ASCII and they work everywhere.
--
Dennis Clarke
RISC-V/SPARC/PPC/ARM/CISC
UNIX and Linux spoken
GreyBeard and suspenders optional
--
You are receiving this mail because:
You are on the CC list for the bug.