Greenpower VWT

CFD Wind Tunnel System

T.Barnaby - Rotary Racer - Chipping Sodbury School

Introduction

This page gives information on the Greenpower Car Virtual Wind Tunnel system developed to simulate the Rotary Racer's aerodynamics performance. It has been developed using the Open Source OpenFOAM CFD (Computational Fluid Dynamics) software together with some pre-processing, post-processing and web interface code. This uses heavy weight mathematics to simulate the airflow over the cars shape in a virtual wind tunnel.

To use, the cars design has to be drawn, to scale, in a 3D CAD program. We have used the Open Source, Blender program to achieve this although other programs can be used such as Pro/Enginneer andPro/Desktop. Indeed any 3D CAD program can be used as long as it is able to output files in ".stl" stereolithography format. The input to the VWT is a small set of configuration parameters and an STL file which is exported from the 3D CAD program. The cars design is then be simulated in the wind tunnel and the overall aerodynamic drag in Newtons and CD values calculated. The VWT software also  provides data for a 3D data viewing package, paraview, to allow streamers, arrows and coloured "hot spots" to be shown. This allows the aerodynamic faetures of the car to be investigated and refined.
We have made this VWT software available from the web in a simple way so that the pupils can easily use it to simulate the cars performance. This does not have the full features of the native software CFD but is more accessible and easier to use. The software is not fully tested ...

Although the VWT produces an absolute drag force in Newtons and a CD value, it will not be that accurate. The VWT is best used to determine if design changes increase or decrease the drag value with respect to another similar design.

How To Use the Web VWT

  1. Create the design of the car using a 3D drawing program. The car should be drawn to scale (ie 2.5 meters long).  It should face to -X, ie the cars front should be in the -X direction (normally left side of screen). The Top of the car should be in the +Z direction. There are some example files listed later on this page fo rthe Blender and Pro/Desktop programs. As you will probably make many modifications to the design in order to improve its performance, it is a good idea to use a meaningfull naming scheme for the file names that define the design version and features of the design. For Rotary Racer we have used names such as rr8e-23-higher-rollbar.blend. Do not use spaces in the file names, "-" and "_" can be used as separators.
  2. Export the drawing as a STL file (eg car1.stl). See the details for the different CAD packages below for details of this.
  3. Use the Greenpower VWT simulation page and enter the team and password, the mode, the height above ground level (0.01m leaves a bit of room under the wheels to reduce wheel/road effects), a reasonable title that allows you to identify the features changed in this design, your user name followed by the name of the STL file to be simulated (the Browse button with bring up a file browser window). Finally click on the simulate button to start off the simulation. The link to the VWT simulation page is here. The system will assign a case number to your simulation run.
  4. Wait some time. The simulation will take around 20 minutes.
  5. Keep reloading the VWT simulation page. Eventually you will see the results from the simulation or an error message for your case number.
  6. The main aerodynamic drag in Newtons at 13m/s (46.8Km/H) is displayed for the x, y and z directions together with the CD values and other information.
  7. You can download the full output data set using the Result Data vtk.zip button. The resulting file can be unpacked and viewed using the Paraview program.
  8. Only one simulation will be run at a time although you can queue up any number.
Note that the 3D cad design must fit within the VWT size (X(-4m - +4m) Y(-2m - +2m) Z(0m - 3m)). Also the design should have just one complete surface with no breaks. Errors can easily occur. A "cryptic" error message will be produced in this case.
The web VWT is simple to use, but limited in features. It runs on a Linux based computer cluster with 12 to 20 CPU's.

Example Car Designs

Information on Results

The web results page shows the Drag in Newtons at 13m/s (46.8 Km/H) in the X, Y and Z directions. The X direction is the one we are most interested in for Greenpower cars. A lower number means better aerodynamics and increased speed in the race. The Drag forces based on preasure and viscous are given. The Total forces are the ones we are interested in.
The results also display the calculated Cd value. This is based on a calculated frontal area.
A Greenpower car, with 25 Amps flowing into the motor uses 600 Watts of power (24V * 25A = 600W). Assuming a motor and gearing efficiency of about 65% this results in 390 Watts available.
The speed of the car, assuming the gearing is set correctly, is given by:

speed = power / dragForce
dragForce = (carRollingFrictionCoeff * weight * 9.8) + (0.5 * airDensity * carAirDragCoeff * carFrontArea * (speed * speed))

Assuming the cars rolling resistance is about 10N and the car moves at 13m/s (46.8Km/H) at 25 Amps, then the air drag is 30 - 10 = 20.0 Newtons.
The air drag is proportional to the square of the velocity. So reducing the cars airdrag by 10% will yield, approximately, a 3.00% increase in speed.
So reducing the drag from 20N to 18N, at the same speed, would increase the cars maximum speed to 13.39m/s (48.2Km/H).

Details of Simulation

The VWT software creates a VWT of size 8x4x3 meters. It creates a 10x10x10 set of cubes within this space. The cars design is then placed in this cubic grid and the grid is "refined" around the edges of the cars surface. This subdivides the cubes until there are a lot of cells just around the surface of the car and a little way beyond. The VWT is set to use just under 1 million cells. The cells that cross the cars surface are marked.
The software then sets up some initial conditions with a 13m/s airflow from the left and the road moving at 13m/s (46.8 Km/H). It then calculates the air pressure, air velocity and other values for each cell in the VWT taking into account all the neighboring cubes. This set of calculations is repeated to see how the airflow changes with time. After about 120 itterations the complete set of data for all VWT cells is written to a set of files and the pressure on each cars surface is calculated to determine the overall force in Newtons in each of the major axis. The results are stored for retrieval later.

Picture of simple car in the VWT with streamers

Car in wind tunnel

Picture of Cube Showing turbulence

Cube in VWT

Some Rotary Racer Pictures

RR
RR
RR
RR

Using Blender for 3D Design Entry

You can download Blender from www.blender.org for Linux or Microsoft Windows. It is free Open Source software. Blender is quite a sophisticated 3D drawing and animation package. However, Blender is not really a 3D engineering CAD, it is more of a 3D drawing package. It has a "unique" GUI and takes a little getting used to but works well for this purpose.
Make sure the design is scaled correctly (2.5 meters long etc) and is of the correct orientation (-X to the front of the car, Y is the sideways dimension and Z is the vertical dimension).
Notes:

Using Pro/Desktop for 3D design entry

The Pro/Desktop package can be used for car design entry. Note that, by default, dimensions are in mm.
You will be interested to know that there is a way of exporting STL from
Pro/DESKTOP assemblies as follows:
To create a derived model of a design:
* Click Assembly> Add Component and include the design in the assembly
* Click Select> Parts
* Click the component to select it
* Click Feature> Use Component. In the graphics pane, the original
component is replaced by an identical copy. The original component is hidden
(you can see it in the object browser using the Components sort). The copy
is treated as a native feature, not as an added component. It appears in the
object browser under the Features sort, with the name Tool#. The whole model
can now be exported as STL.

Viewing the VWT output data using Paraview

You will need the "paraview" application installed on your computer to do this.
First download the result data. This is in the form of a "zip" archive of VTK files. Unpack this archive onto your local hard disk.
We have provided a basic Paraview state file, vwt.pvsm, that can be loaded using the "Load State" button of Paraview. This loads the main data files and sets up some basic views.
Alternatively you can manually open the "VTK/vwt_200.vtk" and the "VTK/car/car_200.vtk" files using the Paraview program. Click on the "Apply" buttons to load the data sets.

Then to view streamers:
  1. Select the vwt_200.vtk data set.
  2. Click on the Stream Tracer Icon. In the "Seeds" settings set the point to be (0,0,0.4), set the Number of Points to be 300 and set the Radius to be 0.7. The click on "Apply". This gives useful starting values.
  3. Click on the Stream Tracer's "Display" tab and set the "Color by" option to "p" (pressure). Yo may want to manually set the data range colour map so that the streamers are displayed in the full colour range. A range of -50 to 50 works quite well.
To view pressure areas in color on the car:
  1. Click on the Car's "Display" tab and set the "Color by" option to "p" (pressure). Yo may want to manually set the data range colour map. A range of -50 to 50 works quite well.

Installing CAD programs on Microsoft Windows

A CD and USB Drive is available with the necessary Microsoft Windows applications for editing car 3D CAD drawings and viewing the resulting data from the VWT. Alternatively they can be downloaded over the Internet. The actual VWT simulation is performed on a Linux system accessed via the Internet.

For the CD/USBDrive Installation, perform the following actions:
  1. Insert the CD/USBDrive into the system
  2. Open up a Windows Explorer window onto the CD or USB drive
  3. Install Blender: Double click on the "blender-2.49b-windows.exe" file.
  4. Install Paraview: Double click on the "paraview-3.6.1-win32-x86.exe" file.
Blender is used to edit the 3D CAD drawings. The master file has a ".blend" extension. These files are exported as ".stl" files which are then uploaded to the VWT simulator via a web browser.
The results are viewed via the web. The results give the overall forces on the car at 46.8Km/H.
The Paraview application is used to view the VWT's output data in graphical form. The VWT's data can be downloaded from the simulator via the web. This is in a "zip" archive which needs to be unpacked to the local disk drive before use.
Paraview can then view this information and put on streamers, or show pressure zones in colour etc.

The Programs can be downloaded from the following Internet web sites:

Item Url
Blender http://www.blender.org/download/get-blender/
Paraview http://www.paraview.org/New/download.html


Note that for Blender to access files on a network server, the network servers path needs to be mapped to a local drive letter.

Web Links