Welcome to MANTIS.jl, a package for high-order structure-preserving
finite element methods. This package is designed around
structure-preserving/mimetic methods. It has extensive support for basis
functions; 'standard' mimetic finite elements, multi-patch splines, and
(MIT license).
A brief description of what you can find in the README.md.
- A brief description of the Authors.
- A step-by-step guide on how to build and view the
Mantisdocs. - An overview of the source code organisation.
The Mantis package was created by
- Diogo C. Cabanas,
- Joey Dekker,
- Artur Palha,
- Deepesh Toshniwal,
from TU Delft's Institute of Applied Mathematics (DIAM).
One can hope.
As the documentation is not (yet) hosted online, you will have to build and view the documentation locally. How to do this is described here.
The main file structure of the the docs has now been created, so you
only have to build the documentation. Fortunately, the heavy lifting
will be done by Julia and/or Python.
For convenience, there is a bash script in the tools folder,
build_local_docs.sh, that automates the process. Make sure to run the
script starting in the main Mantis folder. Use
bash tools/build_local_docs.sh
If this does not work, or if you prefer to go through the steps yourself, you can use the following step-by-step guide.
To create the docs, follow these steps:
- Navigate to the
docs/directory. If you open a terminal in theMantis.jlrepo, this is a simple matter of executing(or the equivalent on your system) in your terminal.cd docs - Next, run
in this directory (you can leave the
julia --color=yes --project make.jl--color=yesoption out if you don't want the printed output to be coloured). This will update (or generate if it doesn't exist yet) abuild/-directory in thedocs/-directory1. All.htmlfiles are generated here. Make sure that you save all changes before running this command or you won't see the changes! Should this step fail, see the next step. - If the dependencies of
Mantis.jlchanged, the build may fail when building in thedocs/-folder. This is because thedocs/-folder defines its own julia environment, since the documentation may have different dependencies than Mantis itself. To update the environment, open a terminal in thedocs/-directory and typejuliato open julia. Enter the package manager by typing]and activate the current environment by typingactivate .. The environment is shown in parenthesis '()' and should say 'docs'. Typedev ../../Mantis.jland execute this command. Note that../../Mantis.jlrefers to the folder name. If you did not call this Mantis.jl, make sure to use to correct name. The environment will be updated so that the latest version of Mantis is available with its updated structure. Then you may also have to runinstantiateto make sure thedocs\-environment is updated. You can now redo the previous step. - Then you need to create a (local) webserver to view the HTML docs, for
which there are a few options, see the Documenter Docs.
Since I have
Pythoninstalled, I use the python option. Run(after, in my case, activating my conda environment by executingpython -m http.server --bind localhostconda activate) in thedocs/-directory. You may have to useinstead. Alternatively, you can use Julia withpython3 -m http.server --bind localhostLiveServer.jl:Note that the automate script tries all these options for you.julia -e 'using LiveServer; serve(dir="build") - In my case, this will result in VScode giving me the message:
Your application running on port 8000 is available. See all forwarded portswith the optionsOpen in BrowserandPreview in Editor. Click theOpen in Browser-option to see the html pages. You (may) have to click thebuild/-link when the browser opens. - Enjoy the Mantis docs!
- When done, you can kill the local webserver by using
Ctrl+C.
The Mantis source code is organized as follows:
| Directory | Contents |
|---|---|
docs/ |
Source for the user and developer manuals |
src/ |
Source for the all Mantis code |
test/ |
Test suites |
test/data/output |
Empty directories for storing output files during tests. This is needed to prevent crashes over write access. |
tools |
Scripts for development (e.g. benchmark scripts, paraview macros, etc.) |
Footnotes
-
The
docs/build/-folder should never be gitted. (See also the warning in the Documenter Docs). The.gitignore-file is already setup to prevent this. ↩