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

Diff of /trunk/models/johnpye/airprops.a4c

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

revision 1618 by jpye, Thu Aug 30 02:29:50 2007 UTC revision 1619 by jpye, Wed Sep 5 06:48:07 2007 UTC
# Line 33  REQUIRE "johnpye/thermo_types.a4c"; Line 33  REQUIRE "johnpye/thermo_types.a4c";
33  MODEL airprops;  MODEL airprops;
34      p IS_A pressure;      p IS_A pressure;
35      T IS_A temperature;      T IS_A temperature;
36        v IS_A specific_volume;
37    
38      p_c IS_A pressure_constant;      p_c IS_A pressure_constant;
39      p_c :== 37.7 {bar};      p_c :== 37.7 {bar};
# Line 46  MODEL airprops; Line 47  MODEL airprops;
47      T_r IS_A factor;      T_r IS_A factor;
48      T_r = T / T_c;      T_r = T / T_c;
49    
50        v_r IS_A factor;
51        v_r = (v * M) / (1{GAS_C} * T_c / p_c);
52    
53      a[0..6] IS_A real_constant;      a[0..6] IS_A real_constant;
54      a[0] :== 1.685175;      a[0] :== 1.685175;
55      a[1] :== 2.283617;      a[1] :== 2.283617;
# Line 55  MODEL airprops; Line 59  MODEL airprops;
59      a[5] :== 7.471154e-4;      a[5] :== 7.471154e-4;
60      a[6] :== -1.732085e-5;      a[6] :== -1.732085e-5;
61    
62      b_1, b_2, b_3 IS_A real_constant;      b_0, b_1, b_2, b_3 IS_A real_constant;
63        b_0 :== -8.107e-4;
64      b_1 :== 0.1629;      b_1 :== 0.1629;
65      b_2 :== -0.338964;      b_2 :== -0.338964;
66      b_3 :== -0.143369;      b_3 :== -0.143369;
# Line 73  MODEL airprops; Line 78  MODEL airprops;
78      h_r = SUM[ a[k]/(k+0.5)*T_r^(k+0.5) | k IN [0..6]] + h_r0      h_r = SUM[ a[k]/(k+0.5)*T_r^(k+0.5) | k IN [0..6]] + h_r0
79          + ( b_1 + 2.6*b_2 / T_r^1.6 + 1.6 * b_3 / T_r^0.6 ) * p_r;          + ( b_1 + 2.6*b_2 / T_r^1.6 + 1.6 * b_3 / T_r^0.6 ) * p_r;
80    
81        Z IS_A factor;
82        Z * T_r = p_r * v_r;
83    
84        Z = 1 + (b_0 + b_1 / T_r + b_2 / T_r^2.6 + b_3 / T_r^1.6) * p_r;
85    
86  METHODS  METHODS
87      METHOD on_load;      METHOD on_load;
88          FIX p, T;          FIX p, T;
89          p := 1 {bar};          p := 1 {bar};
90          T := 300 {K};          T := 300 {K};
91            h.lower_bound := -1e5 {kJ/kg};
92      END on_load;      END on_load;
93  END airprops;  END airprops;
94    

Legend:
Removed from v.1618  
changed lines
  Added in v.1619

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