Last change
on this file since 815 was
765,
checked in by Rafael de Pelegrini Soares, 14 years ago

Tutorial files simplified.


Property svn:eolstyle set to
native

Property svn:keywords set to
Id

File size:
1.4 KB

Line  

1  #* 

2  * This file is property of the author and cannot be used, copyed 

3  * or modified without permission. 

4  * 

5  * Copyright (C) 20022004 the author 

6  * 

7  * Author: Rafael de Pelegrini Soares 

8  * $Id: ThreeTank3.mso 765 20090616 13:15:20Z rafael $ 

9  * 

10  * 

11  * Arquivo de exemplo do EMSO 

12  * 

13  * Sistema de uma série de tanques. 

14  * 

15  **# 

16  

17  Model tank_simplified 

18  PARAMETERS 

19  k as Real (Brief="Valve Constant", Unit = 'm^2.5/h', Default=4); 

20  A as Real (Brief="Tank area", Default=2, Unit = 'm^2'); 

21  

22  VARIABLES 

23  Level as Real(Brief="Tank level", Unit='m'); 

24  in Fin as Real(Brief="Input flow", Unit='m^3/h'); 

25  out Fout as Real(Brief="Output flow", Unit='m^3/h'); 

26  

27  EQUATIONS 

28  "Mass balance" 

29  diff(A*Level) = Fin  Fout; 

30  

31  "Valve equation" 

32  Fout = k*sqrt(Level); 

33  end 

34  

35  

36  FlowSheet ThreeTank 

37  VARIABLES 

38  Feed as Real(Unit='m^3/h'); 

39  

40  DEVICES 

41  Tank1 as tank_simplified; 

42  Tank2 as tank_simplified; 

43  Tank3 as tank_simplified; 

44  

45  CONNECTIONS 

46  Feed to Tank1.Fin; 

47  Tank1.Fout to Tank2.Fin; 

48  Tank2.Fout to Tank3.Fin; 

49  

50  SPECIFY 

51  Feed = 10 * 'm^3/h'; 

52  

53  INITIAL 

54  Tank1.Level = 1 * 'm'; 

55  Tank2.Level = 2 * 'm'; 

56  Tank3.Level = 1 * 'm'; 

57  

58  SET 

59  Tank2.k = 8 * 'm^2.5/h'; 

60  Tank2.A = 4 * 'm^2'; 

61  

62  OPTIONS 

63  TimeStep = 0.1; 

64  TimeEnd = 2; 

65  TimeUnit = 'h'; 

66  end 

Note: See
TracBrowser
for help on using the repository browser.