Running OpenFAOM [OF] on Windows Platform

This page assumes you have a running version of OpenFOAM for Windows installed on your machine. The demonstration is based on version 1606+ on Windows 10 OS - 64-bit AMD processor.

Step-01: Installation Folders

OpenFOAM - Default Installation Directory in Windows 10

Note that the key files and folder of OpenFOAM package is missing! This is due to the fact that the Windows OS is only a 'container' of Linux environment under which OpenFOAM is to run. The main files can be accessed though the Linux prompt which opens when OpenFOAM_Start icon on desktop is clicked.

Step-02: User Folders

Mapping of OpenFOAM native folder structure to Windows

As described in the screenshots from OpenFOAM terminal and corresponding Windows folder from Windows Explorer: the OpenFOAM installation creates a link to C:/users/<username> folder in WIndows platform for users to maintain files on the main OS installed on the system [the computer]. One can use 'clear' command any time to clear the contents from the OF (OpenFOAM) terminal.
Go to top

Step-03: User Folders

Mapping of OpenFOAM native folder structure to Windows

The "as-installed" folders inside OF are read-only, they cannot be edited nor any new files or folder can be created. Hence, user needs to create its own folders either inside the Linux environment or to the only folder inside Windows platform which is accessible that is C:/users/<username>.

Tutorial Folders in OpenFOAM

Tutorial Folders in OpenFOAM

Go to top

Step-04: Pre-processing - blockMesh

Running blockMesh in OpenFOAM

Unlike Windows, Linux is a case-sensitive platform and hence OpenFOAM commands are case-sensitive even if being used inside Windows Environment..

Tutorial Folders in OpenFOAM

Tutorial Folders in OpenFOAM

Tutorial Folders in OpenFOAM

Go to top

Step-05: Solver Setting and Solution

Running Solver in OpenFOAM

Note all the patches defined inside the "blockMeshDict" file (or dictionary - in terms of OpenFOAM scheme of things) needs to be defined inside boundary condition file named u, T, D ... based on the physics being addressed.

Tutorial Folders in OpenFOAM

Tutorial Folders in OpenFOAM

Go to top

Step-06: Post-Processing

Running Solver in OpenFOAM

Create an empty file with name same as base directory - the name of the problem. Read this file in ParaView to open the mesh and result to post-process further.

ParaView checks for consistency of patch [boundary or zone] names in all input files as per the names defined in blockMeshDict. These are not fatal errors and mesh/geometry can still be loaded into Paraview. In this case the name of patch "innerWall" was not updated in boundary condition file 'D' and 'T'. This is typical when you copy a reference case and update only the blockMeshDict! Running Solver in OpenFOAM

Go to top

Examples: Tutorial Cases supplied with OF Installation

SRFSimpleFoam

OF Tutorial - Mixer with rotational symmetry

Mixer with Rotation Symmetry - SRFSimpleFoam application. Screeshot shown to demonstrate the simulation domain and type.

SRFPimpleFoam

OF Tutorial - 2D Rotor

OF Tutorial - 2D Rotor

2D Rotor - SRFPimpleFoam application. Screeshot shown to demonstrate the simulation domain.


Go to top

Thick Cylinder

solidDisplacementFoam

solidDisplacementFoam - thick cylinder

Thick cylinder under tangential loading

solidDisplacementFoam - thick cylinder

solidDisplacementFoam - thick cylinder

Thick cylinder under internal pressure

solidDisplacementFoam - thick cylinder

Zip-file of this problem case can be found here: Thick Cylinder - solidDisplacementFoam
Go to top

The content on CFDyna.com is being constantly refined and improvised with on-the-job experience, testing, and training. Examples might be simplified to improve insight into the physics and basic understanding. Linked pages, articles, references, and examples are constantly reviewed to reduce errors, but we cannot warrant full correctness of all content.