Installation

Dolfyn suite consists of a preprocessor and the CFD solver (dolfyn). Both program's have to be compiled.

The convention on this page is: red the commands as you type them ('$' is the command line prompt), in blue the output.

This page has the following sections:
1. Download
2a. Installing the code (Unix/Linux)
2b. Running a case (Unix/Linux)
2c. Binaries (Linux)
3a. Compiling on Windows with Compaq Visual Fortran
3b. Windows Binaries
3c. Binaries and compiling with g95 on Windows XP/Vista/Win7
3d. Running a case on Windows XP, Vista, Win7

1. Download

Download these sources:

2a. Installing the code (Unix/Linux)

Unpack the file:



$ tar xvozf dolfyn_apr2009b.tgz
LICENSE
NOTICE
artificial.f90
collectcells.f90
diffschemes.f90
dolfyn.f90
gmsh.f90
gmv.f90
gradients.f90
initialfield.f90
modules.f90
opendx.f90
particles.f90
patches.f90
patchscalars.f90
preprocessor.f90
readcontrolfile1.f90
readcontrolfile2.f90
saverestart.f90
solverinterface.f90
tecplt.f90
tools.f90
user.f90
vtk.f90
watches.f90
lapacks.f
solver_sparsekit2.f
Makefile
Changelog
$

You will see the following files:

The preprocessor is compiled with for example:

$ f95 -o preprocessor preprocessor.f90
$

Next adapt the Makefile for dolfyn; check the names and compiler options (beware! 'tab's' in Makefile's are important!). For example with Intel's ifc:

F77 = ifc
F77Opt = -O2
F95 = ifc
F95Opt =
F95Lib =

And compile with:

$ make dolfyn
$

De codes 'dolfyn' en 'preprocessor' are ready to be used.

2b. Running a case (Unix/Linux)

Download the file:

Unpack:

$ tar xvozf demo_sep2005.tgz
demo.bnd
demo.cel
demo.cfg
demo.din
demo.net
demo.vrt
$

You will see the following files:

First create the geometry file 'demo.geo':

$ preprocessor
Dolfyn PreProcessor
Input casename:
demo
Using demo as input
Opening demo.dbg
File demo.dbg opened
Opening vertex file
Opening demo.vrt
File demo.vrt opened
Initialise vertex list
.
.
.
Setting up boundary list: 2140
Total number of boundaries: 4140
Default boundaries: 2000
Assigned boundaries: 2140
Done reading geometry
Minimum distance to a wall: 2.4999976E-02
Maximum distance to a wall: 0.1000004
Minimum wall angle (degs) : 0.0000000E+00
Maximum wall angle (degs) : 0.0000000E+00
Enter scaling factor (1.0):
1.0
Using: 1.000000
Enter format of geometry file (bin|ascii):
bin
Dump geometry file
Opening demo.geo
File demo.geo opened
$


The result is the geometry input file for dolfyn 'demo.geo'.

Next you might edit the input file 'demo.din':

$ nedit demo.din &
$

Now start dolfyn:

$ dolfyn
This is dolfyn version 0.300
Copyright(C) 2002-2005 Cyclone Fluid Dynamics BV
NL-5583 XM, Waalre, The Netherlands
Enter case:
demo
Using case: demo
demo.geo binary
Opening geometry file
*** Warning: Geometry file of version: 0.200
Maximum region number found: 6
Geometry checks
Angles: 0.0000000E+00 0.0000000E+00 0
End reading geometry
Boundary 1 inlet conditions
Boundary 2 outlet conditions
Boundary 3 sym. conditions
Boundary 4 wall conditions
Boundary 5 sym. conditions
Boundary 6 wall conditions
Boundary 4 sym. conditions
Boundary 6 sym. conditions
Boundary 0 sym. conditions
End of input deck


-------------------------------------------------------
Case : demo
Title : Demo test run
Date and time : 09/26/2005 (15:25)
Number of cells : 1000
Number of vertices : 2146
Number of boundaries : 2140
Number of faces : 4070
Number of regions : 6
-------------------------------------------------------
Number of iterations : 200
Steady state run
Target residual tol. : 2.000E-06
Monitor cell : 1
Pressure ref. cell : 1
Reference pressure : 0.000E+00 Pa
Reference density : 1.200E+00 kg/m3
Molecular viscosity : 1.000E-04 Pa s
Gravity vector : 0.000E+00 0.000E+00 0.000E+00
-------------------------------------------------------
V SCV gamma urf rtol guess
U: TTF 5.000E-01 7.000E-01 1.000E-01 1.000E+00
V: TTF 5.000E-01 7.000E-01 1.000E-01 0.000E+00
W: FTF 5.000E-01 7.000E-01 1.000E-01 0.000E+00
P: TTF 0.000E+00 2.000E-01 5.000E-02 0.000E+00
k: TTF 0.000E+00 5.000E-01 1.000E-01 0.000E+00
e: TTF 0.000E+00 5.000E-01 1.000E-01 0.000E+00
T: FTF 0.000E+00 5.000E-01 1.000E-01 2.930E+02
S: FTF 0.000E+00 5.000E-01 1.000E-01 0.000E+00

.
.
.
Go!

1: 2.50E-06 7.09E-09 0.00E+00 1.58E-06 ...
2: 2.48E-06 3.15E-08 0.00E+00 1.56E-06 ...
3: 2.47E-06 2.40E-08 0.00E+00 1.53E-06 ...
.
.
.
Done
$

The results are stored in 'demo.odx'. Finally start OpenDX to inspect the results (load 'demo.net' in OpenDX ):

$ dx&
$

Have fun!

Of course you can run your own cases.

You will need three geometry files name.cel, name.vrt, and name.bnd, where name as the name of your case. Also you'll have to adapt the file 'demo.din' and rename it to name.din.

The results are stored in name.geo (generated by the preprocessor) and name.odx with the simulation result(s).

The files 'demo.cfg' en 'demo.net' are OpenDX configuration en network files. You can adapt an OpenDX net and rename it, or create your own net from scratch. In an OpenDX net you'll have to load name.odx and this files contains anything you'll need. See www.opendx.org for examples and usage of OpenDX.

Warning! You need to know what to do. The codes and files are 'as is'. The software and files are there to give you an impression only without any guarantee whatsoever. Accompanying documentation is (still) unavailable.

Everything here is still under heavy development. Updates and changes are not ruled out; in matter of fact, expected.

2c. Binaries (Linux)

For a quick start, two binaries are provided to you. They were made on a SuSE GNU/Linux 9.0 system with the Intel compiler (ifc 7.1, sep. 2004, non-shared libs) (note unzip with 'gunzip' first):

3a. Compiling on Windows with Compaq Visual Fortran

Thanks to Jos van Heck and Peter van de Velde for this section.

First unpack the files with winzip (an evaluation version is available here). Put the files in a separate directory. 'D:\dolfyn' is used here.

The compilation procedure is demonstrated with the version of March 2004. The current version has more files but the procedure remains the same. The Compaq Visual Fortran 6.1.0 Professional Edition compiler has been used. You can order this compiler here. Of course there some more like: Intel, Absoft, or the experimental g95 compiler, the first two with free evaluation versions; the process will be more or less the same.

After the installation of the Fortran compiler; start it with: New --> Project. Under the tab projects, choose Fortran Console application from the list, enter dolfyn as the projectname and enter a location for the files. Click on OK

1

You will see a dialog box with questions regarding the project. This is a kind of 'wizard' which creates a piece of standard code. You do not need that; therfore go for An empty project en click on Finish

1

Now a dialog with a summary of the choices. Click on OK

1

On the left side of the compiler now appears a project structure. Choose the tab FileView and click with your right mouse on Source Files in the folder dolfyn Files. Opt for Add Files to Folder ... from the context menu.

1

Choose in Files of type menu Fortran Source Files and go to the folder where the dolfyn files were unpacked. Select the *.f and *.f90 dolfyn source codes. Note, do not select the source code of the preprocessor; this file will be compiled in a separate project. In the figure below are the files from the March 2004 version visible. Click on OK

1

Now the real work starts. Hit F7 or choose from the Build menu Build dolfyn.exe

1

In the lower part of the screen some information is echoed to you. When everything goes well the compilation will be completed with "dolfyn.exe - 0 error(s), 0 warning(s)".

1

Move or copy the file dolfyn.exe to the folder debug under the dolfyn compiler project folder to the folder where the dolfyn input resides.

The same procedure is used for the preprocessor. Create a NEW compiler project preprocessor and proceed in the same way. Move or copy the resulting preprocessor.exe to the input folder.

Open a DOS command window (win 9x/ME: Start --> Programs --> MS-DOS prompt; Win XP: Start --> Programs --> Accessories --> Command Prompt) and use cd to walk to the input directory. Now you can run a simulation according to the above described procedure.

Warning! You need to know what to do. The codes and files are 'as is'. The software and files are there to give you an impression only without any guarantee whatsoever. Accompanying documentation is (still) unavailable.

Everything here is still under heavy development. Updates and changes are not ruled out; in matter of fact, expected.

3b. Windows Binaries

Thanks to Jos van Heck and Peter van de Velde for this section as well!

The September 2004 version for those Windows users without Fortran compiler(s):

The December 2004 version for Windows/Cygwin users (compiled with g95 under Cygwin, including a VTK-interface):

Thanks to Bouke Tuinstra for the december 2005 Windows version (compiled with Microsoft/Digital/Compaq/HP Fortran 6.5; dolfyn stack size increased to 10 MB):

Screenshots from the december 2004 Cygwin version:

OpenDX ParaView VisIt
OpenDXParaViewVisIt

The December 2007 version (compiled with g95-MinGW on Windows Vista):

Screenshot December 2007 g95-MinGW-Version:

figparaview2

3c. Binaries and compiling with g95 on Windows XP/Vista/Win7

The December 2007 version (compiled with g95-MinGW on Windows Vista):

or the latest developer version:

needed for gmsh and tetraedra (using gfortran):

compiled with MinGWw32 and gcc/gfortran 4.6.1 on a Win7 x64 system:

Compiling on Vista with g95 (on XP/Win7 the procedure is identical):

figg95

Download the dolfyn source (status December 2007) and drop the contents in for example 'Documents\dolfyn' (adjust the paths in the two batch files to your own situation!):

Open a DOS command window ( Win XP of Vista: Start --> Programs --> Accessories --> Command Prompt) and go with cd to the folder with the source code of dolfyn. Run 'setpaths.bat' and then compile with 'compile.bat'.

figcompile

Download the demo files and put the contents in for example 'Documents\demo':

cd to this folder. Now run a case like the Linux procedure described above. First create a geometry file 'demo.geo' using the preprocessor ("..\dolfyn\preprocessor.exe"):

figprep

Next start dolfyn ("..\dolfyn\dolfyn.exe"):

figdolfyn1

After a short while the run is finished:

figdolfyn2

Start ParaView and load 'demo.vtk':

figparaview1

And look at the result:

figparaview2

3d. Running a case on Windows XP en Vista

Thanks to Peet Franken for this section.

As soon as all the needed software has been (compiled and) installed, dolfyn can be 'announced' to Windows.

Step 1. All the needed files (like 'demo.vrt', 'demo.cel', 'demo.bnd' and 'demo.din') have to be in the same folder (hint: use a appropriate name).

figxp1

Step 2. Copy both executables, "preprocessor" and "dolfyn", to this folder.

figxp2

Step 3. Double click on "preprocessor":

figxp3

File "demo.geo" is produced.

figxp4

Step 4. Double click on "dolfyn":

The simulation starts.

figxp5

And then there some results.

figxp6

Setting up the "DOS box" under Windows XP and Vista

Start dolfyn.

Click with right mouse button on the blue bar and then choose properties:

dosbox1

Open tab "indeling":

dosbox2

Adjust the width of the buffer and window to for example 132. Adjust the height of the buffer (here to 500):

dosbox3

Click on OK.

If you like the adjustsments to be permanent then you'll need to save them (apllies to the directory where the adjustments were made).

dosbox4



Cyclone www.dolfyn.net