Implementation of ZEUS3D on LINUX / x86 Fortran
This page is not an introduction to Zeus3D. The Zeus3D source code version 3.4.1
(zeus34) of 1995 Apr, the version update to 3.4.2 (fixes34) up to 1997 May,
and the (pre-)compilation script zeus34.s of 1997 May (updated 1999 Apr)
can be accessed from one of the authors, M. Norman, now at UCSD:
The ZEUS-3D Code
(http://cosmos.ucsd.edu/lca-www/software/lca_intro_zeus3d.html, last checked to be valid 2005 July)
The collection of files, individually
(http://cosmos.ucsd.edu/lca-www/software/zeus3d/, last checked to be valid 2005 July)
More software from the former LCA at NCSA/UIUC
(http://cosmos.ucsd.edu/lca-www/software/, last checked to be valid 2005 July)
If you plan to use Zeus-3D, it is advisable to read comments, notes, and hints embedded in the files
zeus34 (first pages; deck history), fixes34, FAQ_v.3.4, Readme, userdmp, and myprob.
Your first hurdle is to successfully compile an executable called "xedit22". In principle, this is
achieved by executing zeus34.s; the process will likely involve an anonymous ftp call to ncsa
to get files like edit22, edit22.f, and namelist.
June 2005 PFP
---Changes to xedit22
We experienced a problem with the subroutine ofile in edit22.f. The bug was
mysteriously fixed by inserting a print statement in the middle of the ofile
routine. 2006 Aug: still a problem, in contrast to previous sentence.
We replaced 'stat' in 'open' statement with a fixed “unknown”.
GENERAL NOTES
- During pre-compilation:
zeus34: initial raw Zeus3D source code, aliases, directives intact
zeus34.m: same raw zeus source code, when micro surgery has been performed
(the changed lines have a * in the right margin).
zeus34.f: the whole block after precompilation and alias subsitution, but seems to be deleted when results are split into directory zeus3.4/ .
- during precompilation, references can only be made to previously existing decks.
In other words, all change decks refer to line numbers in zeus3.4.1.
- DEBUG option currently barely used.
- Zeus-3D precompiled code is organized into groups:
** G R O U P : A L G O R I T H M S **
** G R O U P : B O U N D A R Y **
** G R O U P : G R I D **
** G R O U P : I N I T I A L **
** G R O U P : I O **
** G R O U P : P H Y S I C S **
** G R O U P : P R O B L E M S **
** G R O U P : S U N D R Y **
- chgnml is part of minimum distribution, the REAL definition in there has to match the one in chgzeus.
- TAB as line beginning in pre-compiled code is inadmissible.
June 2005 PFP
ZEUS34.S MODIFICATIONS
- Addition of LINUX as a machine option in zeus34.s
In order to select appropriate compiler options, LINUX has been added as a
machine platform with LINUX as the default OS.
- makezeus:
zeus34.s inserts the compiler options into makezeus near line 2520. we had to
tweak the code here so that makezeus was effectively edited. notice the change
in logic on the LINUX line of code.
June 2, 2004 PFP
BLD_LIB MODIFICATION
The script bld_lib crashes when called from zeus34.s, due to a logic error on line 54.
bld_lib tries to determine the existence of fsplit, but the if statement fails on some platforms.
Execute "which fsplit" to learn the response of your system.
line 54 reads:
if ("'echo $FSPLIT | egrep 'no fsplit|fsplit not'" != "") then
and should be modified to
if (1) then
bld_lib appears to run correctly after this modification.
A less radical fix can be programmed depending on the answer of "which fsplit."
July 2005 HRM
FIXES34 MODIFICATIONS
- added LINUX (as an .or. option) for default exclusion in zeus3d, intchk: for timer routine handling.
- bvald extension to 3.4.2 by MMML: some things (the "i,j edges") commented out and done easier:
**For ijb, ojb increase the scope of i loop so that 4 nodes each
**on 4 corners get set, too (was: do i=is, ie)
*delete bvald.175
do 80 i=ism2,iep2
*delete bvald.215
  do 110 i=ism2,iep2
July 2005 HRM
CODE MODIFICATIONS through CHGZEUS or similar
- viscsub subroutine: assumes that at least one variable is saved in
between calls. Well, this cannot always be relied on for all compilers.
*insert viscsub.79
  save dtqqi2s
- Adding the ghost corners of the grid to be updated as well (in my case, i and j only; motivation
was data output routine):
**For ijb, ojb increase the scope of i loop so that 4 nodes each
**on 4 corners get set, too (was: do i=is, ie)
*delete bvale.145
  do 80 i=ism2,iep2
*delete bvale.185
  do 110 i=ism2,iep2
**bvalv1: (was: do i=isp1, ie) [ijb1, ojb1]
*delete bvalv1.154
  do 80 i=ism1,iep2
*delete bvalv1.194
  do 110 i=ism1,iep2
**bvalv2: (was: do i=is, ie)
*delete bvalv2.162
  do 80 i=ism2,iep2
*delete bvalv2.207
  do 110 i=ism2,iep2
- Get some feedback while zeus3d is running:
*insert zeus3d.182
  if( (mod(nhy,100).eq.0) .and. (iotty .gt. 0) )
& write (iotty, *) 'nhy=',nhy,' & dt=',dt,' & time=',time
- Disable any keyboard feedback while zeus3d is running:
*delete intchk.400
  nchar = 0
*delete intchk.452
  nchar = 0
*delete intchk.473
  nchar = 0
- MHD off: Some compilers do not like a function that does not set the
return value:
*insert xibtorsq.53
*else
  xibtorsq= 0.0
*insert btor.51
*else
  btor = 0.0
- pdvcool, coolinit, etc need some major re-write.
Some compilers do not like the function "index".
- Getting cpu time in seconds, and elapsed wall clock time, on a RedHat
Linux system with Intel Fortran compiler:
*insert intchk.236
*if def,LINUX
  integer ITIME
*endif LINUX
*insert intchk.261
*if def,LINUX
  tused = ITIME()/1000.0
*endif LINUX
*insert zeus3d.41
*if def,LINUX
  real*4 ETIME
  integer ITIME
*endif LINUX
*insert zeus3d.108
*if def,LINUX
  cputot = ITIME()
  wctot = ETIME ( 0.0)
*endif LINUX
*insert zeus3d.186
*if def,LINUX
  cpu2 = ITIME()/1000.0
*endif LINUX
*insert zeus3d.230
*if def,LINUX
  wctot = ETIME ( wctot)
*endif LINUX
*insert zeus3d.252
*if def,LINUX
  cputot = (ITIME() - cputot)/1000.0
*endif LINUX
This change deck also requires the following for a RedHat
Linux system with Intel Fortran compiler:
*alias ETIME secnds
*alias ITIME mclock
mclock is an integer function, empty argument, that return the
cpu time of the process and all daughter processes; seconds(realvar)
is a real function that returns wall time in seconds (arg=0.0),
minus an offset if arg is nonzero.
[Top page of Müller]
[Departmental home page]
Modified