Differences From Artifact [1e7784419c]:

To Artifact [3f74ca255c]:


1
2
3
4
5
6
7
8



9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28

29
30
31
32
33
34
35
36
37
38
39
40
41
42
# Numerical parameter file (CarnotCycle_input.txt)
# Generated by MTT at Mon Dec  8 20:05:30 GMT 1997

# %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
# %% Version control history
# %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
# %% $Id$
# %% $Log$



# %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%


alpha = 0.553;

# Set the inputs
if ((t>=0.0)&&(t<1.0))		#Cooling
  u(1) = 300.0;			# Source temperature
  r    = 1e-5;			# Small r - isothermal
  u(2) = -alpha;		# Volume rate-of-change
endif;

if ((t>=1.0)&&(t<2.0))		#Compression
  u(1) = 300.0;			# Source temperature 
  r    = 1e5;			# Large resistance -- isentropic
  u(2) = -(0.8-alpha);		# Volume rate-of-change
  TopTemp = x(1)/(m_g*c_v);
endif;

if ((t>=2.0)&&(t<3.0))		#Heating

  u(1) = TopTemp;		# Source temperature
  r    = 1e-5;			# Small r - isothermal
  u(2) = (0.8-alpha);		# Volume rate-of-change
endif;

if (t>=3.0)			#Cooling
%  Temp = x(1)/(m_g*c_v);	# 
  u(1) = 300.0;			# Source temperature
  r    = 1e5;			# Large resistance -- no entropy flow
  u(2) = alpha;			# Volume rate-of-change
endif;



|







>
>
>







|
|
|



|
|
|
<



>
|
|
|



<
|
|
|

<
<

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27

28
29
30
31
32
33
34
35
36
37

38
39
40
41


42
# Input file (CarnotCycle_input.txt)
# Generated by MTT at Mon Dec  8 20:05:30 GMT 1997

# %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
# %% Version control history
# %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
# %% $Id$
# %% $Log$
# %% Revision 1.1  2000/12/28 18:14:40  peterg
# %% To RCS
# %%
# %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%


alpha = 0.553;

# Set the inputs
if ((t>=0.0)&&(t<1.0))		#Cooling
  carnotcycle__heat__u= 300.0;	# Source temperature
  carnotcycle__switch__u    = 1e10; # Large conductance - isothermal
  carnotcycle__work__u = -alpha;	# Volume rate-of-change
endif;

if ((t>=1.0)&&(t<2.0))		#Compression
  carnotcycle__heat__u = 300.0;	# Source temperature 
  carnotcycle__switch__u    = 0; # Small conductance -- isentropic
  carnotcycle__work__u = -(0.8-alpha); # Volume rate-of-change

endif;

if ((t>=2.0)&&(t<3.0))		#Heating
  TopTemp = x(1)/(m_g*c_v);
  carnotcycle__heat__u = TopTemp;	# Source temperature
  carnotcycle__switch__u    = 1e10; # Large conductance - isothermal
  carnotcycle__work__u = (0.8-alpha); # Volume rate-of-change
endif;

if (t>=3.0)			#Cooling

  carnotcycle__heat__u = 300.0;	# Source temperature
  carnotcycle__switch__u    = 0; # Small conductance -- isentropic
  carnotcycle__work__u = alpha;	# Volume rate-of-change
endif;




MTT: Model Transformation Tools
GitHub | SourceHut | Sourceforge | Fossil RSS ]