# source:mso/sample/miscellaneous/trigonometrics.mso@90

Last change on this file since 90 was 90, checked in by gerson bicca, 15 years ago

added sample of EMSO's built-in functions

File size: 2.1 KB
Line
1#*-------------------------------------------------------------------
2* EMSO Model Library (EML) Copyright (C) 2004 - 2007 ALSOC.
3*
4* This LIBRARY is free software; you can distribute it and/or modify
5* it under the therms of the ALSOC FREE LICENSE as available at
6* http://www.enq.ufrgs.br/alsoc.
7*
8* EMSO Copyright (C) 2004 - 2007 ALSOC, original code
9* from http://www.rps.eng.br Copyright (C) 2002-2004.
11*
13* available at http://www.enq.ufrgs.br/alsoc.
14*
15*--------------------------------------------------------------------
16* Sample file for trigonometrics functions.
17*--------------------------------------------------------------------
18* Author: Gerson Balbueno Bicca
19* \$Id: trigonometrics.mso 83 2006-12-14 20:29:34Z bicca \$
20*--------------------------------------------------------------------*#
21using "types";
22
23#++++++++++++++++++++++++++++++++++++++++++++++++++++
24#
25#               EMSO sample file of trigonometric functions
26#
27#      -----------------------------
28#               Function    |  EMSO Built-In
29#      -----------------------------
30#               Sine            |       sin
31#               Cosine          |       cos
32#               Tangent         |       tan
33#               ArcSine         |       asin
34#               ArcCosine       |       acos
35#               ArcTangent      |       atan
36#
37#++++++++++++++++++++++++++++++++++++++++++++++++++++
38
39FlowSheet Trigonometric_Function
40
41        PARAMETERS
42
43        Pi              as constant  (Brief="Pi Number",Default=3.14159265);
44        Theta   as angle     (Brief ="theta angle");
45
46        VARIABLES
47
48        cosine  as Real  (Brief ="cosine function",Default=0.5);
49        sine    as Real  (Brief ="sine function",Default=0.5);
50        tangent as Real  (Brief ="tangent function",Default=0.5);
51
52        arccosine  as Real  (Brief ="arc cosine function",Default=0.5);
53        arcsine    as Real  (Brief ="arc sine function",Default=0.5);
54        arctangent as Real  (Brief ="arc tangent function",Default=0.5);
55
56        SET
57
58        Pi         = 3.14159265;
60
61        EQUATIONS
62
63        sine    = sin(Theta);
64        cosine  = cos(Theta);
65        tangent = tan(Theta);
66
67        arccosine  = acos(cosine);
68        arcsine    = asin(sine);
69        arctangent = atan(tangent);
70
71        OPTIONS
72