home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Software Du Jour
/
SoftwareDuJour.iso
/
BUSINESS
/
DBASE
/
DBAPG.ARC
/
TRIGDEMO.PRG
< prev
next >
Wrap
Text File
|
1984-08-12
|
2KB
|
66 lines
* Program.: TRIGDEMO.PRG
* Author..: Alastair Dallas
* Date....: 07/03/84
* Notice..: Copyright 1984, Ashton-Tate, All Rights Reserved
* Version.: dBASE III, version 1.0
* Notes...: Demonstrates the use of the Trig.prg procedure file.
*
SET TALK OFF
SET PROCEDURE TO Trig
SET DECIMALS TO 12
SET FIXED ON
*
CLEAR
@ 2, 0 SAY "TRIGONOMETRIC DEMONSTRATION"
@ 3, 0 SAY "========================================"
@ 3,40 SAY "========================================"
INPUT "Enter a value (in degrees)--> " TO value
?
DO Makrad WITH value
? "In radians ", value
*
sin_val = value
DO Sine WITH sin_val
? "SINE is ", sin_val
*
cos_val = value
DO Cosine WITH cos_val
? "COSINE is ", cos_val
*
argument = value
DO Tangent WITH argument
? "TANGENT is ", argument
*
* ---Identity computation.
* ---The computed value should be 1.000000000000
value = ( sin_val ^ 2 ) + ( cos_val ^ 2 )
? "Identity is ", value
?
INPUT "Enter side one--> " TO side_one
INPUT "Enter side two--> " TO side_two
value = side_one / side_two
?
argument = value
DO Arcsin WITH argument
? "ARCSINE is ", argument, " radians"
DO Makdeg WITH argument
?? argument, " degrees"
*
argument = value
DO Arccos WITH argument
? "ARCCOSINE is ", argument, " radians"
DO Makdeg WITH argument
?? argument, " degrees"
*
argument = value
DO Arctan WITH argument
? "ARCTANGENT is", argument, " radians"
DO Makdeg WITH argument
?? argument, " degrees"
?
SET FIXED OFF
CLOSE PROCEDURE
SET TALK ON
RETURN
* EOF: TRIGDEMO.PRG