예제 #1
0
markre = ['Re = ' + '{0:.1f}'.format(x) for x in Re]
markar = ['AR = ' + '{0:.1f}'.format(x) for x in AR]
markofs = ['Offset= ' + '{0:.1f}'.format(x) for x in offset]
marks = [markre, markar, markofs]
#---------------------------------------
time_to_plot = 'all'
coeffs_show_range = 'all'
time_to_plot = [4.0, 5.0]
show_range_cl = [-2.0, 8.0]
show_range_cd = [-15.0, 15.0]
cycle_time = 1.0
#---------------------------------------
show_range = [show_range_cl, show_range_cd]
cd = os.getcwd()
wd = os.path.dirname(cd)
wd = os.path.dirname(wd)
wd = os.path.join(os.path.dirname(wd), 'geometry_effect_fw_data')
image_out_path = cd
#---------------------------------------
cf_array = []
for cfi in cfd_data_list:
    cfd_datai = os.path.join(wd, '3_SIM_RESULTS', cfi)
    cf_arrayi = read_cfd_data(cfd_datai)
    cf_array.append(cf_arrayi)

data_array = cf_array
#---------------------------------------

cf_plotter(data_array, marks, time_to_plot, show_range, image_out_path,
           cycle_time, 'against_t')
예제 #2
0
# else:
# time_to_plot = [1.0, 2.0]
time_to_plot = [1.0, 1.6]
if pa == 0:
    coeffs_show_range = [[-1.0, 1.5], [-1.0, 1.5]]  #--pa0 wake--
elif pa == 45:
    coeffs_show_range = [[-2.5, 1.0], [-9.0, 2]]  #--pa45 wake--
elif pa == 90:
    coeffs_show_range = [[-3.5, 3.5], [-3.5, 3.0]]  #--pa90 wake--
cycle_time = 1.0
# coeffs_show_range = [-10.0, 4.0]
cycle_time = 1.0
#---------------------------------------
cwd = os.getcwd()
wd = os.path.join(os.path.dirname(os.path.dirname(os.path.dirname(cwd))),
                  'wake_convection_data')
oimage_file = os.path.join(
    cwd, 'transient_force_pa' + '{0:.0f}'.format(pa) + 'wake.svg')
#---------------------------------------
cf_array = []
for cfi in cfd_data_list:
    cfd_datai = os.path.join(wd, '3_SIM_RESULTS', cfi)
    cf_arrayi = read_cfd_data(cfd_datai)
    cf_array.append(cf_arrayi)

data_array = cf_array
#---------------------------------------

cf_plotter(pa, data_array, legends, time_to_plot, coeffs_show_range,
           oimage_file, cycle_time, 'wake')