Difference between revisions of "OpenFOAM"

From UFRC
Jump to navigation Jump to search
(Created page with "=OpenFoam= == Version 1.7.1 == Needs to be built with gcc 4.4.4 or newer. Gcc 4.4.4, in turn, requires a bunch of stuff so we have the following (in the order in which they s…")
 
 
(50 intermediate revisions by 4 users not shown)
Line 1: Line 1:
=OpenFoam=
+
__NOTOC__
 +
__NOEDITSECTION__
 +
[[Category:Software]][[Category:Fluid Dynamics]]
 +
{|<!--Main settings - REQUIRED-->
 +
|{{#vardefine:app|OpenFoam}}
 +
|{{#vardefine:url|http://www.openfoam.org}}
 +
|{{#vardefine:exe|}} <!--Present manual instructions for running the software -->
 +
|{{#vardefine:conf|}} <!--Enable config wiki page link - {{#vardefine:conf|1}} = ON/conf|}} = OFF-->
 +
|{{#vardefine:pbs|}} <!--Enable PBS script wiki page link-->
 +
|{{#vardefine:slurm|}} <!--Enable SLURM script wiki page link-->
 +
|{{#vardefine:policy|}} <!--Enable policy section -->
 +
|{{#vardefine:testing|}} <!--Enable performance testing/profiling section -->
 +
|{{#vardefine:faq|}} <!--Enable FAQ section -->
 +
|{{#vardefine:citation|}} <!--Enable Reference/Citation section -->
 +
|}
 +
<!-- ########  Template Body ######## -->
 +
<!--Description-->
 +
{{#if: {{#var: url}}|
 +
{{App_Description|app={{#var:app}}|url={{#var:url}}|name={{#var:app}}}}|}}
  
== Version 1.7.1 ==
+
OpenFOAM is a free, open source CFD software package produced by a commercial company, OpenCFD Ltd. It has a large user base across most areas of engineering and science, from both commercial and academic organisations. OpenFOAM has an extensive range of features to solve anything from complex fluid flows involving chemical reactions, turbulence and heat transfer, to solid dynamics and electromagnetic.
  
Needs to be built with gcc 4.4.4 or newer.  Gcc 4.4.4, in turn, requires a bunch of stuff so we have the following (in the order in which they should be built).
+
<!--Modules-->
 +
==Required Modules==
 +
[[Modules|modules documentation]]
 +
*intel/2018
 +
*openmpi/3.0.0
 +
*openfoam/5.0
  
 +
<pre>
 +
$ module load intel/2018  openmpi/3.0.0 openfoam/5.0
 +
</pre>
  
 +
==System Variables==
 +
{|cellpadding="10"
 +
|-style="vertical-align:top;"
 +
|
 +
=== OpenFOAM variables ===
 +
* FOAM_INST_DIR - installation base directory
 +
* FOAM_APPBIN - executable program directory
 +
* FOAM_LIB - library directory
 +
* FOAM_SRC - source directory
 +
* FOAM_EXT_LIBBIN - ThirdParty library directory
 +
* PV_PLUGIN_PATH - ParaView library directory
 +
* FOAM_TUTORIALS - tutorial directory
 +
||
 +
=== Wmake variables ===
 +
These are the wmake parameters used in building OpenFOAM and could be used for compiling the third-party OpenFOAM applications using wmake.
  
Undefined references to pthread routines required the following change to the wmake rules...
+
* WM_PROJECT_INST_DIR - wmake installation base directory
 +
* WM_PROJECT_VERSION - wmake project version
 +
* WM_PROJECT - wmake project name (OpenFOAM in this case)
 +
* WM_PROJECT_DIR - wmake project directory
 +
* WM_DIR - directory where "wmake" executable is
 +
* WM_ARCH - architecture type
 +
* WM_COMPILER - compiler name
 +
* WM_COMPILE_OPTION - compiler option
 +
* WM_LINK_LANGUAGE - compiler for linking
 +
* WM_PRECISION_OPTION - precision type
 +
|}
  
--- wmake/rules/linux64Gcc/general.orig 2011-02-11 12:00:54.000000000 -0500
+
<!--Additional-->
+++ wmake/rules/linux64Gcc/general 2011-02-11 11:45:49.000000000 -0500
+
{{#if: {{#var: exe}}|==Additional Information==
@@ -1,7 +1,7 @@
+
WRITE INSTRUCTIONS ON RUNNING THE ACTUAL BINARY|}}
CPP        = cpp -traditional-cpp $(GFLAGS)
+
{{#if: {{#var: conf}}|==Configuration==
LD        = ld
+
See the [[{{PAGENAME}}_Configuration]] page for {{#var: app}} configuration details.|}}
+
{{#if: {{#var: pbs}}|==PBS Script Examples==
-PROJECT_LIBS = -l$(WM_PROJECT) -liberty -ldl
+
See the [[{{PAGENAME}}_PBS]] page for {{#var: app}} PBS script examples.|}}
+PROJECT_LIBS = -l$(WM_PROJECT) -liberty -ldl -lpthread
+
{{#if: {{#var: slurm}}|==SLURM Script Examples==
+
See the [[{{PAGENAME}}_SLURM]] page for {{#var: app}} SLURM script examples.|}}
include $(GENERAL_RULES)/standard
+
{{#if: {{#var: policy}}|==Usage Policy==
 +
WRITE USAGE POLICY HERE (perhaps templates for a couple of main licensing schemes can be used)|}}
 +
{{#if: {{#var: testing}}|==Performance==
 +
WRITE PERFORMANCE TESTING RESULTS HERE|}}
 +
{{#if: {{#var: faq}}|==FAQ==
 +
*'''Q:''' **'''A:'''|}}
 +
{{#if: {{#var: citation}}|==Citation==
 +
If you publish research that uses {{{app}}} you have to cite it as follows:
 +
WRITE CITATION HERE
 +
|}}

Latest revision as of 14:20, 15 December 2022

Description

OpenFoam website  

OpenFOAM is a free, open source CFD software package produced by a commercial company, OpenCFD Ltd. It has a large user base across most areas of engineering and science, from both commercial and academic organisations. OpenFOAM has an extensive range of features to solve anything from complex fluid flows involving chemical reactions, turbulence and heat transfer, to solid dynamics and electromagnetic.

Required Modules

modules documentation

  • intel/2018
  • openmpi/3.0.0
  • openfoam/5.0
$ module load intel/2018  openmpi/3.0.0 openfoam/5.0

System Variables

OpenFOAM variables

  • FOAM_INST_DIR - installation base directory
  • FOAM_APPBIN - executable program directory
  • FOAM_LIB - library directory
  • FOAM_SRC - source directory
  • FOAM_EXT_LIBBIN - ThirdParty library directory
  • PV_PLUGIN_PATH - ParaView library directory
  • FOAM_TUTORIALS - tutorial directory

Wmake variables

These are the wmake parameters used in building OpenFOAM and could be used for compiling the third-party OpenFOAM applications using wmake.

  • WM_PROJECT_INST_DIR - wmake installation base directory
  • WM_PROJECT_VERSION - wmake project version
  • WM_PROJECT - wmake project name (OpenFOAM in this case)
  • WM_PROJECT_DIR - wmake project directory
  • WM_DIR - directory where "wmake" executable is
  • WM_ARCH - architecture type
  • WM_COMPILER - compiler name
  • WM_COMPILE_OPTION - compiler option
  • WM_LINK_LANGUAGE - compiler for linking
  • WM_PRECISION_OPTION - precision type