Valiation Delta Wing NASA experiment for different leading edge radii

Delta Wing - VORTEX AND BOUNDAYR LAYER INTERACTION----Investigation also performed within NATO VFE 2 project (DLR)

Parameters

alpha = 13.3 Mach = 0.4 Re = 3.0e06

Other parameters may be considered

References

Chu J. and Luckring J. N. (1996). Experimental surface pressure data obtained on 65deg delta wing accorss Reynolds numerb and Mach number ranges. Nasa Technical Memorandum (TM 4645)
R. Konrath, C. Klein and A. Schröder. 3PSP and PIV investigations on the VFE-2 configuration in sub and transonic flow. Aerospace Science and Technology. Vol 24, Issue 1, Jan–Feb2013, Pages 22–31
http://vfe2.dlr.de/Site/index.php?id=17&sid=cb67e6756b9988a658542af816c16a03547c292aa3a8d/

Define case name

This is the solver case to be analysed


In [1]:
case_name = 'dlr_delta_2'

Define Data Location

For remote data the interaction will use ssh to securely interact with the data
This uses the reverse connection capability in paraview so that the paraview server can be submitted to a job scheduler
Note: The default paraview server connection will use port 11111


In [2]:
remote_data = True

data_dir = '/gpfs/cfms/workarea/projects/hyper_flux/delta_wing_high_Re/delta_wing_dlr_2'

data_host='acimpoeru@vis03'

remote_server_auto = True

paraview_cmd='mpiexec /gpfs/cfms/apps/bin/pvserver'
if not remote_server_auto:
    paraview_cmd=None

if not remote_data:
    data_host='localhost'
    paraview_cmd=None

Initialise Environment


In [3]:
%pylab inline
from paraview.simple import *

paraview.simple._DisableFirstRenderCameraReset()
import pylab as pl


Populating the interactive namespace from numpy and matplotlib
paraview version 4.2.0-75-gff3f889

Data Connection

This starts paraview server on remote host and connects


In [4]:
from zutil.post import pvserver_connect
from zutil.post import pvserver_process
if remote_data:
    pvserver_connect(data_host=data_host,data_dir=data_dir,paraview_cmd=paraview_cmd)


[acimpoeru@vis03] Executing task 'port_test'
[acimpoeru@vis03] Executing task 'port_test'
[acimpoeru@vis03] Executing task 'port_test'
Selected Port: 12002
[acimpoeru@vis03] Executing task 'pvserver'
[acimpoeru@vis03] run: /bin/bash -l -c "cd /gpfs/cfms/workarea/projects/hyper_flux/delta_wing_high_Re/delta_wing_dlr_2 && sleep 2;mpiexec /gpfs/cfms/apps/bin/pvserver -rc --client-host=localhost -sp=12002"
[acimpoeru@vis03] out: 
[acimpoeru@vis03] out: 		   _____ ______ __  __  _____ 
[acimpoeru@vis03] out: 		  / ____|  ____|  \/  |/ ____|
[acimpoeru@vis03] out: 		 | |    | |__  | \  / | (___  
[acimpoeru@vis03] out: 		 | |    |  __| | |\/| |\___ \ 
[acimpoeru@vis03] out: 		 | |____| |    | |  | |____) |
[acimpoeru@vis03] out: 		  \_____|_|    |_|  |_|_____/ 
[acimpoeru@vis03] out: 
[acimpoeru@vis03] out: ++++++++++++++++++++++++++++: System Data :++++++++++++++++++++++++++++
[acimpoeru@vis03] out: + Hostname = vis03
[acimpoeru@vis03] out: + Kernel = 2.6.32-358.el6.x86_64
[acimpoeru@vis03] out: + RHEL Release = Red Hat Enterprise Linux Server release 6.4 (Santiago)
[acimpoeru@vis03] out: + Uptime = 14:35:23 up 26 days, 4:19, 15 users,
[acimpoeru@vis03] out: ++++++++++++++++++++++++++++: User Data :++++++++++++++++++++++++++++++
[acimpoeru@vis03] out: + Username = acimpoeru
[acimpoeru@vis03] out: +++++++++++++++++++++++: Contact Information :+++++++++++++++++++++++++
[acimpoeru@vis03] out: + in case of any problems, contact: support@cfms.org.uk
[acimpoeru@vis03] out: + for feedback, contact: feedback@cfms.org.uk 
[acimpoeru@vis03] out: +++++++++++++++++++++: Maintenance Information :+++++++++++++++++++++++
[acimpoeru@vis03] out: + There is no planned maintenance taking place this week
[acimpoeru@vis03] out: +++++: Group Home Directory Quota Usage (updated every 10 mins)   +++++
[acimpoeru@vis03] out: + 
[acimpoeru@vis03] out: +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
[acimpoeru@vis03] out: Warning: Conflicting CPU frequencies detected, using: 3059.000000.
[acimpoeru@vis03] out: [acimpoeru@vis03] rtunnel: opened reverse tunnel: (u'127.0.0.1', 43522) -> ('172.20.1.25', 22) -> ('localhost', 11111)
Connecting to client (reverse connection requested)...
[acimpoeru@vis03] out: Connection URL: csrc://localhost:12002
[acimpoeru@vis03] out: Client connected.
[acimpoeru@vis03] out: 

Get control dictionary


In [5]:
from zutil.post import get_case_parameters,print_html_parameters
parameters=get_case_parameters(case_name,data_host=data_host,data_dir=data_dir)

Get status file


In [6]:
from zutil.post import get_status_dict
status=get_status_dict(case_name,data_host=data_host,data_dir=data_dir)
num_procs = str(status['num processor'])

Define test conditions


In [7]:
alpha = 13.3 # degrees
reference_area = 594720.0 # inches^2
reference_length = 275.8 # inches, mean chord. 
reference_span = 1156.75 # inches

from IPython.display import HTML
HTML(print_html_parameters(parameters))


Out[7]:
pressure407552.8904
temperature322.15
Reynolds No3000000.0
Ref length0.328
Speed0.0
Mach No0.4

In [8]:
import zutil
import zutil.post as post
reload(zutil)
reload(post)
from zutil.post import cp_profile_wall_from_file
from zutil.post import cp_profile_wall_from_file_span
def plot_cp_profile(ax,file_root,loc):
    force_data = cp_profile_wall_from_file_span(file_root,
                              [1.0,0.0,0.0],
                              [loc, 0.0 , 0.0],
                              func=plot_array,
                              axis=ax,
                              loc=loc,
                              alpha=alpha)
def plot_array(data_array,pts_array,**kwargs):
    ax = kwargs['axis']
    loc = kwargs['loc']
    #alpha = kwargs['alpha']
    cp_array = data_array.GetPointData()['cp']
    chord_array = data_array.GetPointData()['chord']
    ax.plot(chord_array, cp_array , 'b.',color='k',label='zCFD SST', markersize=20)
    ax.plot(pts_array.GetPoints()[:,1]/(max(pts_array.GetPoints()[:,1])),
            pts_array.GetPoints()[:,2]/(max(pts_array.GetPoints()[:,2])),
            '_',color='k',markersize=3.0)
    ax.legend(loc = 'upper left',numpoints=1,prop = prop)

Comparison Data


In [9]:
# Reproduce plots from delta wing presentation

from collections import OrderedDict
station_values = OrderedDict([("S01" , 0.2), ("S02" , 0.4), ("S03" , 0.6), ("S04" , 0.8)])

Experimental data


In [10]:
import zutil
import zutil.post as post
reload(zutil)
reload(post)
from zutil.post import get_csv_data
import os
import glob
from collections import OrderedDict

#"/gpfs/cfms/workarea/projects/hyper_flux/delta_wing_high_Re/results_csv_format/results_delta_wing"


#LARGE RADIUS
cp_s02 = zutil.post.get_csv_data("/gpfs/cfms/workarea/projects/hyper_flux/delta_wing_high_Re/results_csv_format/dlr_experiment/dlr_02.csv",
                                 header=True,remote=True,delim=' ')

cp_s04 = zutil.post.get_csv_data("/gpfs/cfms/workarea/projects/hyper_flux/delta_wing_high_Re/results_csv_format/dlr_experiment/dlr_04.csv",
                                 header=True,remote=True,delim=' ')


cp_s06 = zutil.post.get_csv_data("/gpfs/cfms/workarea/projects/hyper_flux/delta_wing_high_Re/results_csv_format/dlr_experiment/dlr_06.csv",
                                 header=True,remote=True,delim=' ')


cp_s08 = zutil.post.get_csv_data("/gpfs/cfms/workarea/projects/hyper_flux/delta_wing_high_Re/results_csv_format/dlr_experiment/dlr_08.csv",
                                 header=True,remote=True,delim=' ')

stat = OrderedDict([("S01" ,(0.2,cp_s02[2],cp_s02[0])),
                    ("S02" ,(0.4,cp_s04[2],cp_s04[0])),
                    ("S03" ,(0.6,cp_s06[2],cp_s06[0])),
                    ("S04" ,(0.8,cp_s08[2],cp_s08[0])),
                  ])


//Applications/paraview.app/Contents/Python/paraview/vtk/numpy_interface/dataset_adapter.py:126: FutureWarning: comparison to `None` will result in an elementwise object comparison in the future.
  if array == None:

Cp Profile


In [11]:
from zutil.post import get_case_root
from zutil.post import get_chord_spanwise
import matplotlib.font_manager as fm
prop=fm.FontProperties(size=20)

fig = pl.figure(figsize=(30, 50),dpi=600, facecolor='w', edgecolor='k')
fig2 = pl.figure(figsize=(30, 50),dpi=600, facecolor='w', edgecolor='k')

plot = 1
for key in stat:
        loc = stat[key][0]
        ax = fig.add_subplot(len(station_values),2,plot)
        ax.set_title('$C_p$ at x/c = '+str(loc), fontsize=40, fontweight='bold')
        ax.grid(True)
        ax.set_xlabel('y/c - Spanwise',fontsize=20, fontweight='bold')
        ax.set_ylabel('$C_p$',fontsize=50, fontweight='bold')
        ax.axis([0.0,1.01,0.5,-4.0])
        plot_cp_profile(ax,get_case_root(case_name,num_procs),loc)
        
        ax.plot(stat[key][1],stat[key][2],'b.',color='r',label='Experiment - DLR', markersize=20)
        
        ax.legend(loc = 'upper left',numpoints=1,prop = prop)
        plot += 1    
from matplotlib.backends.backend_pdf import PdfPages
pp = PdfPages('dlr_medium_delta.pdf')
pp.savefig()
pp.close()
fig.savefig("dlr_medium_delta.png")
show()
from IPython.display import FileLink, display 
display(FileLink('dlr_medium_delta.png'))


<matplotlib.figure.Figure at 0x11ab918d0>

Convergence


In [12]:
from zutil.post import residual_plot, get_case_report
residual_plot(get_case_report(case_name))
show()


Cleaning up


In [13]:
if remote_data:
    print 'Disconnecting from remote paraview server connection'
    Disconnect()


Disconnecting from remote paraview server connection
Exiting...
[acimpoeru@vis03] out: 

In [ ]: