/[ascend]/trunk/models/pipeline.a4c
ViewVC logotype

Diff of /trunk/models/pipeline.a4c

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1154 by johnpye, Tue Jan 16 10:26:50 2007 UTC revision 1155 by johnpye, Tue Jan 16 11:33:52 2007 UTC
# Line 1  Line 1 
1  (*  (*
2      ASCEND modelling environment      ASCEND modelling environment
3      Copyright (C) 2006 Carnegie Mellon University      Copyright (C) 2007 Carnegie Mellon University
4    
5      This program is free software; you can redistribute it and/or modify      This program is free software; you can redistribute it and/or modify
6      it under the terms of the GNU General Public License as published by      it under the terms of the GNU General Public License as published by
# Line 71  MODEL arc_w_no_valve REFINES arc; Line 71  MODEL arc_w_no_valve REFINES arc;
71    
72      (* Disjunctive Statement *)      (* Disjunctive Statement *)
73      WHEN (bol)      WHEN (bol)
74        CASE TRUE:      CASE TRUE:
75          USE eq1;              USE eq1;
76        CASE FALSE:      CASE FALSE:
77          USE eq2;              USE eq2;
78      END WHEN;      END WHEN;
79    
80  METHODS  METHODS
# Line 86  METHODS Line 86  METHODS
86      END specify;      END specify;
87    
88      METHOD bound_self;      METHOD bound_self;
89      Q.lower_bound := -1e50{gpm};          Q.lower_bound := -1e50{gpm};
90      H.lower_bound := -1e50{ft};          H.lower_bound := -1e50{ft};
91      END bound_self;      END bound_self;
92    
93      METHOD values;      METHOD values;
94      H := 0 {ft};          H := 0 {ft};
95      bol := SATISFIED(cond,1e-08 {gpm});          bol := SATISFIED(cond,1e-08 {gpm});
96      END values;      END values;
97    
98  END arc_w_no_valve;  END arc_w_no_valve;
# Line 106  MODEL arc_w_valve REFINES arc; Line 106  MODEL arc_w_valve REFINES arc;
106    
107      (* Boundary *)      (* Boundary *)
108      CONDITIONAL      CONDITIONAL
109        cond: H >= 0.0 {ft};          cond: H >= 0.0 {ft};
110      END CONDITIONAL ;      END CONDITIONAL ;
111    
112      bol == SATISFIED(cond,1e-08{ft});      bol == SATISFIED(cond,1e-08{ft});
# Line 117  MODEL arc_w_valve REFINES arc; Line 117  MODEL arc_w_valve REFINES arc;
117    
118      (* Disjunctive Statement *)      (* Disjunctive Statement *)
119      WHEN (bol)      WHEN (bol)
120        CASE TRUE:      CASE TRUE:
121          USE eq1;          USE eq1;
122        CASE FALSE:      CASE FALSE:
123          USE eq2;          USE eq2;
124      END WHEN;      END WHEN;
125    
# Line 132  METHODS Line 132  METHODS
132      END specify;      END specify;
133    
134      METHOD bound_self;      METHOD bound_self;
135      H.lower_bound := -1e50{ft};          H.lower_bound := -1e50{ft};
136      END bound_self;      END bound_self;
137    
138      METHOD values;      METHOD values;
139      H := 1.0 {ft};          H := 1.0 {ft};
140      bol := SATISFIED(cond,1e-08{ft});          bol := SATISFIED(cond,1e-08{ft});
141      END values;      END values;
142  END arc_w_valve;  END arc_w_valve;
143    
# Line 356  METHODS Line 356  METHODS
356          RUN values;          RUN values;
357      END on_load;      END on_load;
358  END pipeline;  END pipeline;
359    (* :ex: set ts=4: *)

Legend:
Removed from v.1154  
changed lines
  Added in v.1155

john.pye@anu.edu.au
ViewVC Help
Powered by ViewVC 1.1.22