Raw File
Tip revision: db5c7fa56b977d3f1ac0ac11ed875f75229f2d27 authored by eriszhang on 08 August 2021, 03:27:39 UTC
Tip revision: db5c7fa
# Surface Multigrid via Intrinsic Prolongation
<img src="./assets/teaser.jpg" width="100%">

Public code release for [Surface Multigrid via Intrinsic Prolongation]( For more details, please refer to:

**Surface Multigrid via Intrinsic Prolongation**<br>
[Hsueh-Ti Derek Liu](, [Jiayi Eris Zhang](, [Mirela Ben-Chen](, and [Alec Jacobson](<br>
ACM Transaction on Graphics (Proceedings of SIGGRAPH 2021)<br>
**[[Paper](]** **[[ArXiv](]** **[[Project Page](]**

## Installation
To get started, clone this repository *recursively*
git clone --recursive
On all platforms, we assume you have installed cmake and a modern c++ compiler on Mac OS X, Linux, or Windows.

## Layout
The main folder contains 6 separate examples that demonstrate some core functionalities and typical usage of our code. All of them have a similar directory and file layout:
+ `01_single_SSP/`: visualize our prolongation operator by mapping the fine mesh vertices onto the coarse mesh.
+ `02_mg_hierarchy/`: show the construction of our multigrid hierarchy and visualize the corresponding prolongation operators between different levels.
+ `03_mg_solver/`: show the usage of our multigrid solver on surface meshes with boundaries.
+ `04_mg_solver_nobd/`: show the usage of our multigrid solver on surface meshes without boundaries.
+ `05_example_mean_curvature_flow/`: show the usage of our multigrid solver in mean curvature flow.
+ `06_example_balloon_sim/`: show the usage of our multigrid solver in balloon simulation.

And they share a common `src` folder for source code and a `meshes` folder for input meshes.

## Compilation
Inside each subfolder, for example `01_single_SSP`, compile in release mode using the following typical cmake/make build routine:
cd 01_single_SSP
mkdir build
cd build
cmake -DCMAKE_BUILD_TYPE=Release ..
make -j8
If all goes well, you should be able to find and run the executable `main_bin` directly with no arguments.

## Usage
We aim to make our multigrid solver as easy to use as possible. To use our multigrid solver for linear systems defined on a fixed surface mesh i.e. typically for solving `Ax = b`, first call `mg_precompute` to construct the multigrid hierarchy. Then, similar to [libigl]('s style of calling direct solvers [min_quad_with_fixed](, our multigrid solver can be used by calling `min_quad_with_fixed_mg_precompute` given a left-hand-side system matrix `A` and then calling `min_quad_with_fixed_mg_solve` to solve the system with the right-hand-side `b`. Please refer to the above examples for more details.

If any issues or questions, please do not hesitate to contact or
back to top