Reproducibility repository for A fully adaptive, high-order, fast Poisson solver for complex two-dimensional geometries
This repository contains the code and data required to reproduce all results from the paper:
- D. Fortunato, D. B. Stein, and A. H. Barnett, A fully adaptive, high-order, fast Poisson solver for complex two-dimensional geometries.
Figures 4.1, 4.3–4.4, 5.1–5.4 and Table 5.1 in the paper contain numerical results. Each has a corresponding script in this repository which generates a figure or data.
- MATLAB R2021a or newer
- GCC 11 or newer
This repository uses git submodules. To initialize the submodules, either clone this repository with the --recurse-submodules flag or run git submodule update --init --recursive after cloning.
- Make sure MATLAB's
mexis accessible from the command line. Edit the file+util/make.incto setMEXandCXXappropriately. - Change to the
+utildirectory and typemaketo build the MATLAB MEX interface.
- Follow the instructions in
external/kdtreeto build the MATLAB MEX interface.
- Follow the instructions in
external/fmmlib2dto build the MATLAB MEX interface. This will likely involve modifyingexternal/fmmlib2d/matlab/mwrap.incto match your specific platform.
- Follow the instructions in
external/treefun/external/boxcode2dto build the MATLAB MEX interface.
First, run the MATLAB script setup.m to add the required directories to your MATLAB path. To generate figure X.Y, change to the figures directory and run the MATLAB script figureX_Y.m. The script may plot a figure in MATLAB and/or write data to a file. Many scripts define a boolean variable doExport, which if set to true will export the generated figures as images.