One-Click CFD Users' Guide

18
One-Click CFD Users' Guide

Transcript of One-Click CFD Users' Guide

Page 1: One-Click CFD Users' Guide

One-Click CFD

Users' Guide

Page 2: One-Click CFD Users' Guide

Distributed by Khamsin Virtual Racecar Challengehttp://www.khamsinvirtualracecarchallenge.com

Copryight (C) 2015 Julien de Charentenay, PhD

Presentation Outline1.Introduction

2.Objective(s) of the Presentation

3.Geometry Preparation

4.Starting a Simulation

5.Post-processing

Page 3: One-Click CFD Users' Guide

Distributed by Khamsin Virtual Racecar Challengehttp://www.khamsinvirtualracecarchallenge.com

Copryight (C) 2015 Julien de Charentenay, PhD

IntroductionWhat is One-Click CFD?

• It is a CFD framework based around openFoam;• It enables people interested in car aerodynamic to run CFD analysis

with no or very limited knowledge of CFD or openFoam;• It is the framework used for CFD modelling in the KVRC Challenge;• It is free to use (Note: One-Click CFD can send simulation to

Amazon AWS Cloud at user request. When using this option, users need a valid Amazon AWS account and will be charged by Amazon AWS for their usage).

Interested: Download One-Click CFD from http://www.khamsinvirtualracecarchallenge.com/one-click-cfd

Page 4: One-Click CFD Users' Guide

Distributed by Khamsin Virtual Racecar Challengehttp://www.khamsinvirtualracecarchallenge.com

Copryight (C) 2015 Julien de Charentenay, PhD

Presentation Objective

• Provide an overview of what is involved when using One-Click CFD

Page 5: One-Click CFD Users' Guide

Distributed by Khamsin Virtual Racecar Challengehttp://www.khamsinvirtualracecarchallenge.com

Copryight (C) 2015 Julien de Charentenay, PhD

Geometry Preparation

1.Orientation & positioning;

2.Part splitting & naming;

Page 6: One-Click CFD Users' Guide

Distributed by Khamsin Virtual Racecar Challengehttp://www.khamsinvirtualracecarchallenge.com

Copryight (C) 2015 Julien de Charentenay, PhD

Geometry Preparation

• The first step is for the user to generate the geometry using a CAD package, then export the CAD geometry in STL format. The CAD model requirements and STL naming conventions are detailed herein.

• One-Click CFD will only simulate for airflow for half of the geometry to reduce simulation time. But: you need to prepare a full model!

• One-Click CFD uses the STL file format:• Export to STL in meters;• The STL file name and solid name are used to identify the parts of the car.

The naming convention described later can be used in the file name and solid name. For example for the car body (convention name body):

– The filename could be "mycar.stl" and the solid name "body"; or– The filename could be "body.stl" and the solid name "test23"; or any other variations.

Page 7: One-Click CFD Users' Guide

Distributed by Khamsin Virtual Racecar Challengehttp://www.khamsinvirtualracecarchallenge.com

Copryight (C) 2015 Julien de Charentenay, PhD

Geometry Preparation

The geometry should be facing the -y axis direction

Page 8: One-Click CFD Users' Guide

Distributed by Khamsin Virtual Racecar Challengehttp://www.khamsinvirtualracecarchallenge.com

Copryight (C) 2015 Julien de Charentenay, PhD

Geometry Preparation

Align lowest point of wheels with plane z = -5mm

(in other words: the ground will always be the plane z = 0)

Page 9: One-Click CFD Users' Guide

Distributed by Khamsin Virtual Racecar Challengehttp://www.khamsinvirtualracecarchallenge.com

Copryight (C) 2015 Julien de Charentenay, PhD

Geometry Preparation• One-Click CFD identifies geometry part(s) through their

name (which can appear as filename or solid name in the STL file itself). The identified name patterns are case insensitive and are as follows:

• wheel-front to identify front wheels and apply wheel rotation;• wheel-rear to identify rear wheels and apply wheel rotation;• engine-intake to identify engine air intakes and apply ;• engine-exhaust to identify engine air exhausts;• cooling-intake to identify cooling system air intakes;• cooling-exhaust to identify cooling system exhausts.

• STL parts that are not identified above will be considered to be parts of the car body. It is not required to have all or any of the above.

Page 10: One-Click CFD Users' Guide

Distributed by Khamsin Virtual Racecar Challengehttp://www.khamsinvirtualracecarchallenge.com

Copryight (C) 2015 Julien de Charentenay, PhD

Geometry PreparationExample of STL naming convention:

Wheel-Front-Left

Wheel-Rear-Left

Body

Engine-Intake-1

Page 11: One-Click CFD Users' Guide

Distributed by Khamsin Virtual Racecar Challengehttp://www.khamsinvirtualracecarchallenge.com

Copryight (C) 2015 Julien de Charentenay, PhD

Geometry Preparation• Brief checklist:

– Did you model the full car?– Is the car facing the -y direction with the +z the up direction?– Is the car position consistent with the road at plane z=0?– Did you export the CAD model to STL using meter units?

– Does the exported STL parts or filename follow the naming convention?

Page 12: One-Click CFD Users' Guide

Distributed by Khamsin Virtual Racecar Challengehttp://www.khamsinvirtualracecarchallenge.com

Copryight (C) 2015 Julien de Charentenay, PhD

Starting a Simulation• To start a simulation:

1. Open a File Explorer;2. Change the directory to:

• If using only 1 STL file, the directory where the STL file is located;

• If using multiple STL files, the parent directory of the directory where the STL files are located

1. Select the STL file (or the directory containing the STL files);

2. Right click;3. Select the context menu entry:

• One-Click CFD > 100mph (local) to run a simulation on the local computer with a car velocity of 100 mph;

• One-Click CFD > 100mph (AWS) to run a simulation on the Amazon AWS Cloud with a car velocity of 100 mph;

• One-Click CFD > 200kmh (local) to run a simulation on the local computer with a car velocity of 200 km/h;

• One-Click CFD > 200mph (AWS) to run a simulation on the Amazon AWS Cloud with a car velocity of 200 km/h.

• Note: the KVRC challenge will use the 100mph scenario.

Using one STL file

Using multiple STL files

Page 13: One-Click CFD Users' Guide

Distributed by Khamsin Virtual Racecar Challengehttp://www.khamsinvirtualracecarchallenge.com

Copryight (C) 2015 Julien de Charentenay, PhD

Start a Simulation• After starting a simulation, the simulation will proceed

without any further user input.– If running the simulation on your local computer, a Command

Prompt window will open that will inform you on the progress of the simulation.

• If the simulation succeeds (ie everything works as expected), the window will close automatically when the simulation is complete, and you can move on to Post-processing;

• If the simulation fails an error message, the window will stay open with an error message. The error message will not be very helpful (in most cases), but please take a screenshot and send me an email. I may not be able to help in the short term, but it is worth a try. Also ask help from others on either F1 Technical or CFD online forums. Also have a look at the Post-processing to view the log file.

Page 14: One-Click CFD Users' Guide

Distributed by Khamsin Virtual Racecar Challengehttp://www.khamsinvirtualracecarchallenge.com

Copryight (C) 2015 Julien de Charentenay, PhD

Start a Simulation– If running a simulation on the Amazon AWS Cloud:

• a Command Prompt window will open that will prepare the setup, start the Amazon AWS instance and start the simulation;

• a Windows batch script called oneClickCFD-...-monitor.bat is created in the directory where the geometry file is located;

• Double-click on the batch script to monitor the simulation on Amazon AWS Cloud;

• When the simulation is complete (whether it successfully complete or failed), the results should automatically downloaded in the directory as a file called simulationid.tar.gz (where simulationid is a long list of numbers and letters). This is an archive that you need to extract locally using 7-zip (twice!). Then proceed to Post-processing.

Page 15: One-Click CFD Users' Guide

Distributed by Khamsin Virtual Racecar Challengehttp://www.khamsinvirtualracecarchallenge.com

Copryight (C) 2015 Julien de Charentenay, PhD

Post-processing• The simulation

generates quite a number of files:

Log file:Store the software output and can be

used to check errors when the simulation failed.

HTML file:Automated result summary,

including drag, downforce, etc

Page 16: One-Click CFD Users' Guide

Distributed by Khamsin Virtual Racecar Challengehttp://www.khamsinvirtualracecarchallenge.com

Copryight (C) 2015 Julien de Charentenay, PhD

Post-processing• Automated post-

processed result summary:– HTML format;

– Overall drag, downforce, etc;

– Residuals, etc;– 3D pressure map;– Drag and downforce

distributions.

Page 17: One-Click CFD Users' Guide

Distributed by Khamsin Virtual Racecar Challengehttp://www.khamsinvirtualracecarchallenge.com

Copryight (C) 2015 Julien de Charentenay, PhD

Post-processing• ParaView

– open-source post-processing tool;

– Reads openFoam (the CFD solver used in One-Click CFD) results;

– Generate cuts, streamlines, maps, etc by loading the .foam file located in the same directory as the HTML file.

Download from http://www.paraview.org/

Page 18: One-Click CFD Users' Guide

Distributed by Khamsin Virtual Racecar Challengehttp://www.khamsinvirtualracecarchallenge.com

Copryight (C) 2015 Julien de Charentenay, PhD

One-Click CFD

Happy Modelling &

Don't Forget the KVRC 2015 Challengehttp://www.khamsinvirtualracecarchallenge.com

Question(s)?

Contact us through the F1 Technical forum at http://www.f1technical.net/forum/viewtopic.php?f=14&t=19456