/[ascend]/trunk/models/johnpye/cavity.a4c
ViewVC logotype

Contents of /trunk/models/johnpye/cavity.a4c

Parent Directory Parent Directory | Revision Log Revision Log


Revision 360 - (show annotations) (download) (as text)
Tue Mar 7 03:38:36 2006 UTC (14 years, 4 months ago) by johnpye
File MIME type: text/x-ascend
File size: 4267 byte(s)
Added external radiation losses
1 REQUIRE "atoms.a4l";
2
3 ATOM energy_rate_per_length REFINES solver_var
4 DIMENSION M*L/T^3
5 DEFAULT 1000{W/m};
6 lower_bound := -1e50{W/m};
7 upper_bound := 1e50{W/m};
8 nominal := 1000{W/m};
9 END energy_rate_per_length;
10
11 ATOM energy_flux REFINES solver_var
12 DIMENSION M/T^3
13 DEFAULT 1000{W/m^2};
14 lower_bound := -1e50{W/m^2};
15 upper_bound := 1e50{W/m^2};
16 nominal := 1000{W/m^2};
17 END energy_flux;
18
19 ATOM heat_transfer_coefficient REFINES solver_var
20 DIMENSION M/T^3/TMP
21 DEFAULT 5{W/m^2/K};
22
23 lower_bound := 0{W/m^2/K};
24 upper_bound := 1e50{W/m^2/K};
25 nominal := 5{W/m^2/K};
26
27 END heat_transfer_coefficient;
28
29 MODEL cavity;
30 W,B,S,N,C,E,D IS_A distance;
31 theta, phi, psi IS_A angle;
32
33 F_WN, F_WW, F_WB IS_A factor;
34 F_NB, F_NW, F_NN, F_BW, F_BN IS_A factor;
35 F_WS IS_A factor;
36
37 N * sin(theta) = D;
38 S * tan(theta) = D;
39 B = W + 2 * S;
40 E^2 = W^2 + D^2;
41 phi = arctan(D/W);
42 psi = 1{PI} - phi;
43 C^2 = E^2 + S^2 - 2* E * S * cos(psi);
44
45 F_WN = (W+N-C)/2/W;
46 F_WW = (2*E-2*D)/2/W; (* from top to directly opp part of bottom *)
47 F_WB = 1 - 2 * F_WN;
48 F_WS = (1 - 2 * F_WN - F_WB)/2;
49 F_NB = (N+B-C)/2/N;
50 F_NW = (N+W-C)/2/N;
51
52 F_BN = F_NB*N/B;
53 F_NN = 1 - F_NW - F_NB;
54 F_BW = F_WB*W/B;
55
56 n IS_A set OF symbol_constant;
57 n :== ['W','B','L','R'];
58
59 (* Put lengths into a vector *)
60
61 A[n] IS_A distance;
62 A['W'], W ARE_THE_SAME;
63 A['B'], B ARE_THE_SAME;
64 A['L'], N ARE_THE_SAME;
65 A['R'], N ARE_THE_SAME;
66
67 (* View factor matrix *)
68
69 F[n][n] IS_A factor;
70
71 F['W']['L'], F['W']['R'], F_WN ARE_THE_SAME;
72 F['W']['B'], F_WB ARE_THE_SAME;
73 F['W']['W'] = 0;
74
75 F['B']['L'], F['B']['R'], F_BN ARE_THE_SAME;
76 F['B']['W'], F_BW ARE_THE_SAME;
77 F['B']['B'] = 0;
78
79 F['L']['R'], F['R']['L'], F_NN ARE_THE_SAME;
80 F['L']['B'], F['R']['B'], F_NB ARE_THE_SAME;
81 F['L']['W'], F['R']['W'], F_NW ARE_THE_SAME;
82 F['L']['L'] = 0;
83 F['R']['R'] = 0;
84
85 (* Radiation equations *)
86 q[n] IS_A energy_rate_per_length;
87
88 E_b[n] IS_A energy_flux;
89 J[n] IS_A energy_flux;
90 T[n] IS_A temperature;
91 eps[n] IS_A factor; (* emissivity *)
92
93 FOR i IN n CREATE
94 q[i] = SUM[ (J[i]-J[j])*(A[i]*F[i][j]) | j IN n];
95 END FOR;
96
97 FOR i IN n CREATE
98 E_b[i] = 1{SIGMA_C} * T[i]^4;
99 END FOR;
100
101 FOR i IN n CREATE
102 q[i] * (1-eps[i]) = (E_b[i] - J[i]) * (eps[i]*A[i]);
103 END FOR;
104
105 METHODS
106 METHOD default_self;
107 RUN reset; RUN values; RUN bound_self;
108 END default_self;
109
110 METHOD bound_self;
111 phi.lower_bound := 0 {deg};
112 phi.upper_bound := 90 {deg};
113 psi.lower_bound := 90 {deg};
114 psi.upper_bound := 180 {deg};
115 END bound_self;
116
117 METHOD specify;
118 FIX T['W', 'B'];
119 FIX q['L','R'];
120 FIX W,D,theta;
121 FIX eps[n];
122 END specify;
123
124 METHOD values;
125 T['W'] := 550 {K};
126 T['B'] := 373.15 {K};
127 q['L','R'] := 0 {W/m};
128
129 W := 500 {mm};
130 D := 300 {mm};
131 theta := 30 {deg};
132
133 eps['W'] := 0.49;
134 eps['B'] := 0.9;
135 eps['L','R'] := 0.1;
136
137 END values;
138
139 END cavity;
140
141 (*========================================
142 This model adds external convection
143 coefficients to the model, and an
144 ambient temperature.
145
146 We also calculate the F_rad correlation
147 parameter.
148 *)
149 MODEL cavity_losses REFINES cavity;
150 h_B, h_N IS_A heat_transfer_coefficient;
151 T_amb IS_A temperature;
152
153 (* external heat loss *)
154
155 q_ext_rad IS_A energy_rate;
156 q_ext_conv IS_A energy_rate;
157 q_ext_conv = h_B * B * (T['B'] - T_amb);
158 q_ext_rad = B * eps['B'] * 1{SIGMA_C} * (T['B']^4 - T_amb^4);
159 - q['B'] = q_ext_conv + q_ext_rad;
160 - q['L'] = h_N * N * (T['L'] - T_amb);
161 - q['R'] = h_N * N * (T['L'] - T_amb);
162
163 (* Determine 'F_rad' from overall heatloss... *)
164
165 F_rad IS_A factor;
166 F_rad_1 IS_A factor;
167
168 - q['B'] = F_rad * eps['W'] * 1{SIGMA_C} * (T['W']^4 - T['B']^4);
169
170 - q['B'] = F_rad_1 * 1{SIGMA_C} * (T['W']^4 - T['B']^4) /
171 (1/eps['B'] + 1/eps['W'] - 1);
172
173 METHODS
174 METHOD specify;
175 FIX T['W'], T_amb;
176 FIX h_B, h_N;
177 FIX W,D,theta;
178 FIX eps[n];
179 END specify;
180 METHOD values;
181 T['W'] := 550 {K};
182 T_amb := 290 {K};
183 W := 500 {mm};
184 D := 300 {mm};
185 theta := 30 {deg};
186 eps['W'] := 0.49;
187 eps['B'] := 0.9;
188 eps['L','R'] := 0.1;
189 h_B := 10 {W/m^2/K};
190 h_N := 0.5 {W/m^2/K};
191 (* free values *)
192 T['L','R'] := 500 {K};
193 T['B'] := 400 {K};
194 END values;
195 END cavity_losses;

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