lineardiskmap: Conformally map a simply-connected open triangle mesh to the unit disk using a linear formulation

This code computes the disk conformal parameterizations (i.e. angle-preserving mappings onto the unit disk) of triangle meshes with disk topology using the linear method in [1], which has been applied for texture mapping, surface registration, engineering design and so on.
Any comments and suggestions are welcome. 

If you use this code in your own work, please cite the following paper:
[1] G. P.-T. Choi and L. M. Lui, 
    "A Linear Formulation for Disk Conformal Parameterization of Simply-Connected Open Surfaces."
    Advances in Computational Mathematics, 44(1), pp. 87-114, 2018.

Copyright (c) 2015-2019, Gary Pui-Tung Choi
https://scholar.harvard.edu/choi

===============================================================

Usage:
map = lineardiskmap(v,f)

Input:
v: nv x 3 vertex coordinates of a simply-connected open triangle mesh
f: nf x 3 triangulations of a simply-connected open triangle mesh

Output:
map: nv x 3 vertex coordinates of the disk conformal map

Remark:
1. Please make sure that the input mesh does not contain any unreferenced vertices/non-manifold vertices/non-manifold edges.
2. Please remove all valence 1 boundary vertices (i.e. vertices with only 1 face attached to them) before running the program.