marshall@software.org (Eric Marshall) (12/09/88)
Concerning the NeWS stuff on the SUG tape just made available, the two files: sex/news-tape/documents/NeWSCode.ps sex/news-tape/documents/NeWSProg.ps both get rangecheck errors while executing the getinterval operator. This occurs on both our Apple LaserWriter and Dataproducts LZR-2600 printers. Also, Bruce Schwartz's NewsDraw program fails to link on our SunOS 3.4 system. The unresolved reference is to sincos. Because sincos is no doubt in the SunOS 4.0 math library, can someone please send me a description of what it does. Thanks in advance. Eric Marshall Software Productivity Consortium 1880 North Campus Commons Drive Reston, VA 22091 (703) 391-1838 CSNET: marshall@software.org ARPANET: marshall%software.org@relay.cs.net ---------------------------------------------------------------------- Today's quote: Donal O'Shea (an OSF VP) on System V.4: "It's not of sufficient quality. People can't put commercial applications on it."
bvs@SUN.COM (Bruce Schwartz) (12/10/88)
Also, Bruce Schwartz's NewsDraw program fails to link on our SunOS 3.4 system. The unresolved reference is to sincos. Because sincos is no doubt in the SunOS 4.0 math library, can someone please send me a description of what it does. Sorry about that, sincos is as optimization. From the 4.0 man pages: #include <math.h> double sin(x) double x; double cos(x) double x; void sincos(x, s, c) double x, *s, *c; Note that sincos(x,s,c) allows simultaneous computation of *s = sin(x) and *c = cos(x). I believe that a #define sincos(x,s,c) { *s = sin(x); *c = cos(x); } in one of the .h files will fix your problem. I'll be posting NewsDraw as well as a few of other programs: a new version of the class browser, an interactive lockscreen, a granite desktop, and NewsLine (a modified psview set up to view the Sun Porting Reference Guide). I could post the .ps files of the Guide (they're on the SUG tape too), but it's about 700k. Anyone have any ideas on how to post that? Bruce Schwartz
guy@auspex.UUCP (Guy Harris) (12/10/88)
> Also, Bruce Schwartz's NewsDraw program fails to link on >our SunOS 3.4 system. The unresolved reference is to sincos. Because >sincos is no doubt in the SunOS 4.0 math library, can someone please >send me a description of what it does. From the 4.0 TRIG(3M): void sincos(x, s, c) double x, *s, *c; ... sin, cos, sincos, and tan() return trigonometric functions of radian arguments. The values of trigonometric functions of arguments exceeding pi/4 in magnitude are affected by the precision of the approximation to pi2 used to reduce those arguments to the range -pi/4 to pi/4. Argument reduction may occur in hardware or software; if in software, the vari- able fp_pi defined in <math.h> allows changing that preci- sion at run time. Trigonometric argument reduction is dis- cussed in the Floating Point Programmers Guide. Note that sincos(x,s,c) allows simultaneous computation of *s = sin(x) and *c = cos(x). It shouldn't have been used, or at least its use should have been #ifdeffed; it's an optimization, and "sincos" isn't present on every system (probably not even on every system that runs NeWS).