#variables needed to be read #-------------------------------------- #from the input variable #cold end temperature GAS_TEMP_COLD = "0" GAS_TEMP_COLD_pos = 0 #regenerator length RG_LENGTH = "0" RG_LENGTH_pos = 0 #frequency of the mass flux HERZ = "0" HERZ_pos = 0 #cold end mass flux MASS_FLUX_COLD = "0" MASS_FLUX_COLD_pos= 0 #phase between mass and pressure PRES_PHASE = "0" PRES_PHASE_pos = 0 #number of mesh points NUM_POINTS_X = "0" NUM_POINTS_X_pos = 0 #number of steps per cycle NUM_STEPS_CYC = "0" NUM_STEPS_CYC_pos = 0 #duration of cycle FINAL_CYCLE = "0" FINAL_CYCLE_pos = 0 #---------------------------------------- #from output #maximum CFL number over cycle CFLMAX = "0" CFLMAX_pos = 0 #enthalpy plus heat variation across the regenerator EHTDIF = "0" EHTDIF_pos = 0 #enthalpy plus heat flux at cold side of regenerator EHTFLX = "0" EHTFLX_pos = 0 #energy inbalance for the gas over the cycle ENGBAL = "0" ENGBAL_pos = 0 #normed matrix temperature at mid point GTPNRM = "0" GTPNRM_pos = 0 #second law efficiency EFFIC = "0" EFFIC_pos = 0 #specific gas cross sectional area GASARS = "0" GASARS_pos = 0 #gas volume in regenerator GASVO = "0" GASVO_pos = 0 #ineffectiveness INEFCT = "0" INEFCT_pos = 0 #COP NTACOP = "0" NTACOP_pos = 0 #adjusted net refrigeration power NTCADJ = "0" NTCADJ_pos = 0 #portion of enthalpy flux due to pressurization PRLOSS = "0" PRLOSS_pos = 0 #pv work done by gas at warm end PVWK0T = "0" PVWK0T_pos = 0 #pv work by pressure drop at warm end PVWKPR = "0" PVWKPR_pos = 0 #regenerator loss [W], loss due to ineffectiveness RGLOSS = "0" RGLOSS_pos = 0 #the integral average of the enthalpy flux at the right side of the regenerator over one cycle ENTFLX = "0" ENTFLX_pos = 0 #-----END of data Variable setup------------------------------------------------------------------- #-----------------Control variables---------------------------------------------------------------- num_file_1 = 0 num_file_2 = 0 num_file = 0 file_nam = "0" rgpr = "rgpr" line = "0" num_file_1 = input("input start file number \n") num_file_2 = input("input end file number \n") num_file = num_file_2 - num_file_1 + 1
Run
Reset
Share
Import
Link
Embed
Language▼
English
中文
Python Fiddle
Python Cloud IDE
Follow @python_fiddle
Browser Version Not Supported
Due to Python Fiddle's reliance on advanced JavaScript techniques, older browsers might have problems running it correctly. Please download the latest version of your favourite browser.
Chrome 10+
Firefox 4+
Safari 5+
IE 10+
Let me try anyway!
url:
Go
Python Snippet
Stackoverflow Question