Skip to content

Commit

Permalink
Initial commit
Browse files Browse the repository at this point in the history
  • Loading branch information
msleigh committed Nov 19, 2020
0 parents commit a0de378
Show file tree
Hide file tree
Showing 90 changed files with 7,969 additions and 0 deletions.
12 changes: 12 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
*.pyc
*.png
*.dat
*.pdf
*.o
*.mod
*.exe
*.out
.ipynb_checkpoints
docs/html
docs/latex
docs/doxygen.log
7 changes: 7 additions & 0 deletions LICENSE.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
Copyright © 2014- msleigh

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the “Software”), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED “AS IS”, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
94 changes: 94 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,94 @@
fcimc
=====

A Python implementation of Fleck and Cummings's implicit Monte Carlo (IMC) scheme, as published in Journal of Computational Physics (JCP) in 1971.

<img src="https://img.shields.io/github/v/release/msleigh/fcimc?include_prereleases"> <img src="https://img.shields.io/github/license/msleigh/fcimc"> <img src="https://img.shields.io/tokei/lines/github/msleigh/fcimc"> <img src="https://img.shields.io/github/last-commit/msleigh/fcimc"> <img src="https://img.shields.io/badge/code%20style-black-lightgrey">

## Dependencies

### Python version

- Python 3 (<3.8, see note 1)
- Numpy

### Fortran version

- GFortran

### Bundled calculations

- Matplotlib (to plot the figures)
- Jupyter (to open the verification notebook)

### Documentation

- Doxygen
- Graphviz
- Doxypypy (requires Python<3.8, see note 1)

### Notes

1. The requirement for Python < 3.8 is due to a bug in Doxypypy; see
[https://github.com/Feneric/doxypypy/issues/70]. If documentation is not required
then this limit can be ignored.

## Installation

To create a Conda env with the necessary Python packages:

conda env create -n <env-name> -f environment.yml
conda activate <env-name>

To install the non-Python dependencies on macOS:

brew install gfortran
brew install doxygen
brew install graphviz

## Usage

### Execution

To build and run everythina from scratch, run the top-level script:

./runall

To see the aggregated output:

jupyter notebook verification.ipynb

To open the documentation:

open docs/html/index.html

### Cleaning

To clean up intermediiate build files etc.:

./runall clean

and to clean out everything (output files, executables, etc.) for a fresh start:

./runall clobber

### Fine control

Each part of the project has its own `Makefile` which can be invoked directly:

./fortran/src/Makefile
./fortran/calcs/Makefile
./python/calcs/Makefile
./docs/Makefile

to either clean up one part, e.g.:

make -C fortran/src clean
make -C docs clobber

or build/execute, e.g.:

make -C python/calcs -j 4 all
make -C docs html


Loading

0 comments on commit a0de378

Please sign in to comment.