# source:branches/newlanguage/sample/miscellaneous/sample_mathematicals.mso@217

Last change on this file since 217 was 217, checked in by Argimiro Resende Secchi, 16 years ago

Remove some warnings from samples.

File size: 1.8 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 some math functions.
17*--------------------------------------------------------------------
18* Author: Gerson Balbueno Bicca
19* \$Id: Math_Function.mso 83 2006-12-14 20:29:34Z bicca \$
20*--------------------------------------------------------------------*#
21using "types";
22
23#++++++++++++++++++++++++++++++++++++++++++++++++++++
24#
25#               EMSO sample file of Mathematical functions
26#
27#      --------------------------------------------
28#               Function                |         EMSO Built-In
29#      --------------------------------------------
30#               exponential             |       exp
31#               Logarithmic             |       log
32#               Natural Logarithmic |   ln
33#               Square root         |   sqrt
34#
35#++++++++++++++++++++++++++++++++++++++++++++++++++++
36
37FlowSheet Math_Function
38
39        VARIABLES
40
41        exponential     as Real  (Brief ="exponential function");
42        log10                   as Real  (Brief ="log function");
43        NatLog                  as Real  (Brief ="Natural log function");
44        squareRoot      as Real  (Brief ="square root function");
45
46        EQUATIONS
47
48        exponential     = exp(time/'s');
49        log10                   = log(time/'s');
50        NatLog                  = ln(time/'s');
51        squareRoot      = sqrt(time/'s');
52
53        OPTIONS
54        TimeStart = 0.001;
55        TimeStep = 0.001;
56        TimeEnd = 1;
57        RelativeAccuracy = 1e-6;
58end
Note: See TracBrowser for help on using the repository browser.