ASin PowerScript function
Description
Calculates the arcsine of an angle.
Syntax
|
1 |
<span>ASin</span> ( <span>n</span> ) |
|
Argument |
Description |
|---|---|
|
n |
The ratio of the lengths of two sides |
Return Values
Double. Returns the arcsine of n.
Examples
This statement returns .999998 (rounded to six places):
|
1 |
<span>ASin</span>(.84147) |
This statement returns .520311 (rounded to six places):
|
1 |
<span>ASin</span>(LogTen (Pi (1))) |
This statement returns 0:
|
1 |
<span>ASin</span>(0) |
This code in the Clicked event of a button catches
a runtime error that occurs when an arcsine is taken for a user-entered
value—passed in a variable—that is outside of
the permitted range:
|
1 |
Double ld_num |
|
1 |
ld_num = Double (sle_1.text) |
|
1 |
|
1 |
TRY |
|
1 |
sle_2.text = string (asin (ld_num)) |
|
1 |
CATCH (runtimeerror er) |
|
1 |
MessageBox("Runtime Error", er.getmessage()) |
|
1 |
END TRY |
See Also
Document get from Powerbuilder help
Thank you for watching.
Subscribe
Login
0 Comments
Oldest