1 |
REQUIRE "atoms.a4l"; |
2 |
(* => atoms.a4l, measures.a4l, system.a4l, basemodel.a4l *) |
3 |
PROVIDE "vesselNotes.a4c"; |
4 |
(* |
5 |
* This file is part of the ASCEND Modeling Library and is released |
6 |
* under the GNU Public License as described at the end of this file. |
7 |
*) |
8 |
|
9 |
MODEL vessel; |
10 |
NOTES |
11 |
'author' SELF {Arthur W. Westerberg} |
12 |
'creation date' SELF {May, 1998} |
13 |
END NOTES; |
14 |
|
15 |
(* variables *) |
16 |
side_area "the area of the cylindrical side wall of the vessel", |
17 |
end_area "the area of the flat ends of the vessel" |
18 |
IS_A area; |
19 |
|
20 |
vessel_vol "the volume contained within the cylindrical vessel", |
21 |
wall_vol "the volume of the walls for the vessel" |
22 |
IS_A volume; |
23 |
|
24 |
wall_thickness "the thickness of all of the vessel walls", |
25 |
H "the vessel height (of the cylindrical side walls)", |
26 |
D "the vessel diameter" |
27 |
IS_A distance; |
28 |
|
29 |
H_to_D_ratio "the ratio of vessel height to diameter" |
30 |
IS_A factor; |
31 |
|
32 |
metal_density "density of the metal from which the vessel |
33 |
is constructed" |
34 |
IS_A mass_density; |
35 |
|
36 |
metal_mass "the mass of the metal in the walls of the vessel" |
37 |
IS_A mass; |
38 |
|
39 |
(* equations *) |
40 |
FlatEnds: end_area = 1{PI} * D^2 / 4; |
41 |
Sides: side_area = 1{PI} * D * H; |
42 |
Cylinder: vessel_vol = end_area * H; |
43 |
Metal_volume: (side_area + 2 * end_area) * wall_thickness = wall_vol; |
44 |
HD_definition: D * H_to_D_ratio = H; |
45 |
VesselMass: metal_mass = metal_density * wall_vol; |
46 |
END vessel; |
47 |
|
48 |
ADD NOTES IN vessel; |
49 |
'description' SELF {This model relates the dimensions of a |
50 |
cylindrical vessel -- e.g., diameter, height and wall thickness |
51 |
to the volume of metal in the walls. It uses a thin wall |
52 |
assumption -- i.e., that the volume of metal is the area of |
53 |
the vessel times the wall thickness.} |
54 |
'purpose' SELF {to illustrate the insertion of notes into a model} |
55 |
END NOTES; |
56 |
|
57 |
|
58 |
(* |
59 |
* vesselNotes.a4c |
60 |
* by Arthur W. Westerberg |
61 |
* Part of the ASCEND Library |
62 |
* $Date: 1998/06/17 19:35:04 $ |
63 |
* $Revision: 1.2 $ |
64 |
* $Author: mthomas $ |
65 |
* $Source: /afs/cs.cmu.edu/project/ascend/Repository/models/vesselNotes.a4c,v $ |
66 |
* |
67 |
* This file is part of the ASCEND Modeling Library. |
68 |
* |
69 |
* Copyright (C) 1998 Carnegie Mellon University |
70 |
* |
71 |
* The ASCEND Modeling Library is free software; you can redistribute |
72 |
* it and/or modify it under the terms of the GNU General Public |
73 |
* License as published by the Free Software Foundation; either |
74 |
* version 2 of the License, or (at your option) any later version. |
75 |
* |
76 |
* The ASCEND Modeling Library is distributed in hope that it will be |
77 |
* useful, but WITHOUT ANY WARRANTY; without even the implied |
78 |
* warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. |
79 |
* See the GNU General Public License for more details. |
80 |
* |
81 |
* You should have received a copy of the GNU General Public License |
82 |
* along with the program; if not, write to the Free Software |
83 |
* Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139 USA. Check |
84 |
* the file named COPYING. |
85 |
*) |