Skip to content

Commit 2daf537

Browse files
committed
Init
1 parent 0bd266a commit 2daf537

File tree

93 files changed

+62213
-0
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

93 files changed

+62213
-0
lines changed

.gitignore

Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
doc/Doxygen/*/html
2+
doc/Doxygen/*logo*
3+
doc/Doxygen/*icon*
4+
src/*/*.mod
5+
src/*/*.o
6+
src/pre_process_code/pre_process
7+
src/simulation_code/simulation
8+
src/post_process_code/post_process
9+
src/master_scripts/*.pyc
10+
src/master_scripts/__*
11+
make_doc.sh
12+
cases/
13+
.DS_Store
14+
tests/*/D/*
15+
tests/*/p*
16+
tests/*/D_*
17+
tests/*/*.inf
18+
tests/*/*.inp
19+
tests/*/*.dat
20+
tests/*/silo*
21+
tests/*/restart*
22+
tests/*/*.out
23+
tests/*/binary
24+
example_cases/*/D/*
25+
example_cases/*/p*
26+
example_cases/*/D_*
27+
example_cases/*/*.inf
28+
example_cases/*/*.inp
29+
example_cases/*/*.dat
30+
example_cases/*/silo*
31+
example_cases/*/restart*
32+
example_cases/*/*.out
33+
example_cases/*/binary
34+
lib/fftw-3.3.8

AUTHORS

Lines changed: 46 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,46 @@
1+
The MFC is distributed under the GNU GPLv3 license (or later).
2+
3+
Contributors: S. H. Bryngelson, K. Schmidmayer, V. Coralic, J. Meng, K. Maeda, T. Colonius
4+
5+
6+
Spencer H. Bryngelson
7+
--------------------------------------------
8+
Senior Postdoctoral Scholar
9+
California Institute of Technology
10+
Pasadena, California, USA
11+
12+
13+
Kevin Schmidmayer
14+
--------------------------------------------
15+
Postdoctoral Scholar
16+
California Institute of Technology
17+
Pasadena, California, USA
18+
19+
20+
Vedran Coralic
21+
--------------------------------------------
22+
Senior Research Scientist
23+
Prime Air, Amazon Inc.
24+
Seattle, Washington, USA
25+
26+
27+
Jomela Meng
28+
--------------------------------------------
29+
Research Engineer
30+
Bosch Research and Technology Center
31+
Sunnyvale, California, USA
32+
33+
34+
Kazuki Maeda
35+
--------------------------------------------
36+
Acting Assistant Professor
37+
University of Washington
38+
Seattle, Washington, USA
39+
40+
41+
Tim Colonius
42+
--------------------------------------------
43+
Frank and Ora Lee Marble Professor of Mechanical Engineering
44+
California Institute of Technology
45+
Pasadena, California, USA
46+

CONFIGURE

Lines changed: 62 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,62 @@
1+
#> Simulations using MFC depend upon Python, MPI,
2+
#> and FFTW.
3+
4+
## Python ##
5+
If you do not have Python, it can be installed via
6+
Homebrew on OSX (https://www.brew.sh) as:
7+
$$ brew install python
8+
or compiled via your favorite package manager on Unix
9+
systems.
10+
11+
## MPI ##
12+
An MPI fortran compiler is required for all systems.
13+
If you do not have one, Homebrew can take care of this
14+
on OSX:
15+
$$ brew install open-mpi
16+
or compiled via another package manager on Unix systems.
17+
18+
## FFTW ##
19+
If you already have FFTW compiled:
20+
- Specify the location of your FFTW library and
21+
include files in Makefile.user (fftw_lib_dir and
22+
fftw_include_dir)
23+
24+
If you do not have FFTW compiler, the library and
25+
installer are included in this package. Just:
26+
$$ cd installers
27+
$$ ./install_fftw.sh
28+
29+
#> Post-processing of parallel data files is not required,
30+
#> but can indeed be handled with the MFC. For this, HDF5
31+
#> and Silo must be installed
32+
33+
On OSX, a custom tap for Silo is included in the installers
34+
directory. You can use it via
35+
$$ cd lib
36+
$$ brew install silo.rb
37+
This will install silo and its dependences (including HDF5)
38+
in their usual locations (/usr/local/lib and
39+
/usr/local/include)
40+
41+
On Unix systems, you can install via a package manager or
42+
from source. On CentOS (also Windows 7), HDF5
43+
binaries can be found at
44+
https://support.hdfgroup.org/ftp/HDF5/current18/bin/
45+
Untar this archive in your intended location via
46+
$$ tar -zxf [your HDF5 archive]
47+
48+
Silo should be downloaded at
49+
https://wci.llnl.gov/simulation/computer-codes/silo/downloads
50+
then
51+
$$ tar -zxf [your Silo archive]
52+
$$ cd [your Silo archive]
53+
$$ ./configure --prefix=[target installation directory] --enable-pythonmodule --enable-optimization --disable-hzip --disable-fpzip --enableportable-binary FC=mpif90 F77=mpif77 -with-hdf5=[your hdf5 directory]/include,/[your hdf5 directory]/lib --disable-silex
54+
$$ make
55+
$$ make install
56+
then add this line to your ~/.bash_profile
57+
export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$HOME/[your silo directory]/lib:/[your hdf5 directory]/lib
58+
and
59+
$$ source ~/.bash_profile
60+
61+
You will then need to modify silo_lib_dir and silo_include_dir in
62+
Makefile.user to point to your silo directory

COPYRIGHT

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
MFC
2+
3+
Copyright © 2019 Spencer Bryngelson, Kevin Schmidmayer, Vedran Coralic, Jomela Meng, Kazuki Maeda, Timothy Colonius

INSTALL

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
2+
READ "CONFIGURE" BEFORE PROCEEDING WITH INSTALL
3+
4+
Once all dependencies have been installed, the MFC can be built via
5+
6+
$$ make
7+
8+
from the MFC directory. This will build all MFC components. Individual
9+
components can be built via
10+
11+
$$ make [component]
12+
13+
where [component] is one of "pre_process,simulation,post_process".
14+
15+
Once this is completed, you can ensure that the software is working
16+
as intended by running
17+
18+
$$ make test

Makefile

Lines changed: 43 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,43 @@
1+
include Makefile.user
2+
3+
default: all
4+
5+
include installers/Makefile.messages
6+
7+
all: pre_process simulation post_process
8+
9+
pre_process:
10+
@$(MAKE) -C src/pre_process_code -f makefile
11+
12+
simulation:
13+
14+
ifneq ("$(wildcard $(fftw_include_dir)/fftw3.*)","")
15+
ifneq ("$(wildcard $(fftw_lib_dir)/libfftw*.la)","")
16+
@$(MAKE) -C src/simulation_code -f makefile
17+
else
18+
@echo "$$FFTW_LIB_ERR"
19+
endif
20+
else
21+
@echo "$$FFTW_INC_ERR"
22+
endif
23+
24+
post_process:
25+
26+
ifneq ("$(wildcard $(silo_include_dir)/silo_*.inc)","")
27+
ifneq ("$(wildcard $(silo_lib_dir)/libsilo*.*a)","")
28+
@$(MAKE) -C src/post_process_code -f makefile
29+
else
30+
@echo "$$SILO_LIB_ERR"
31+
endif
32+
else
33+
@echo "$$SILO_INC_ERR"
34+
endif
35+
36+
test:
37+
./tests/checks.sh
38+
39+
.PHONY: clean
40+
clean:
41+
@$(MAKE) -C src/pre_process_code -f makefile clean
42+
@$(MAKE) -C src/simulation_code -f makefile clean
43+
@$(MAKE) -C src/post_process_code -f makefile clean

Makefile.in

Lines changed: 38 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,38 @@
1+
include ../../Makefile.user
2+
3+
########################## FFTW Flags ###########################
4+
# Linker flags
5+
ifdef fftw_lib_dir
6+
ld_sim_flags = -L$(fftw_lib_dir) -lfftw3 -lm
7+
else
8+
ld_sim_flags =
9+
endif
10+
11+
# Header flags
12+
ifdef fftw_include_dir
13+
hd_flags = -I$(fftw_include_dir)
14+
else
15+
hd_flags =
16+
endif
17+
18+
# Compiler flags
19+
f90_flags = $(FFLAGS) $(hd_flags)
20+
21+
#################### Post-process Silo Flags #####################
22+
# Linker flags
23+
ifdef silo_lib_dir
24+
silo_flags = -L$(silo_lib_dir) -lsiloh5 -lm
25+
else
26+
silo_flags =
27+
endif
28+
ld_post_flags = $(ld_sim_flags) $(silo_flags)
29+
30+
# Header flags
31+
ifdef silo_include_dir
32+
hd_post_flags = -I$(silo_include_dir)
33+
else
34+
hd_post_flags =
35+
endif
36+
37+
# Compiler flags
38+
f90_post_flags = $(f90_flags) $(hd_post_flags)

Makefile.user

Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
################ Compiler options ####################
2+
# Gets the MFC directory [do not modify]
3+
MFC_DIR:=$(shell dirname $(realpath $(lastword $(MAKEFILE_LIST))))
4+
5+
### Compiler command ###
6+
FC = mpif90
7+
#FC = mpiifort
8+
9+
### Compiler flags [set according to your compiler] ###
10+
#Note: Requires -cpp to enable preprocessor
11+
12+
FFLAGS = -cpp -c -w
13+
#NOTE: Cray compilers require: -eZ
14+
15+
######### FFTW library and include locations #########
16+
######### Set these to the location of FFTW #########
17+
18+
## For the FFTW included in the MFC package
19+
fftw_lib_dir = $(MFC_DIR)/lib/fftw-3.3.8/lib
20+
fftw_include_dir = $(MFC_DIR)/lib/fftw-3.3.8/include
21+
22+
## Other possible locatins [only use absolute paths]
23+
#fftw_lib_dir = /usr/local/lib
24+
#fftw_include_dir = /usr/include
25+
#fftw_include_dir = /usr/local/include
26+
27+
######### Silo library and include locations #########
28+
######### Set these to the location of Silo #########
29+
######### [ only use absolute paths ] #########
30+
31+
silo_lib_dir = /usr/local/lib
32+
silo_include_dir = /usr/local/include
33+
34+
#silo_lib_dir = /home/spencer/packages/silo-4.10.2/lib
35+
#silo_include_dir = /home/spencer/packages/silo-4.10.2/include

0 commit comments

Comments
 (0)