Note: The code will attempt to automatically MEX a .cpp file.
The input "Alpha" is a 3D matrix where each voxel represents the tortuosity of that voxel (or the cost of traveling that voxel). For example, in the case where we have a literal 3D labyrinth consisting of perfectly solid walls and empty space, walls would be marked with '0' (impossible to pass) and empty space would be marked with '1'. If there was a road patch full of vines in there that would make it hard to walk, that would be marked by say '2' because it costs twice as much time/effort to pass through that voxel.
For a 3D matrix representing such a "labyrinth" Tort3D will attempt to reach to the top of the system by any means necessary, starting from every single voxel at the bottom surface. This will result in a distribution of tortuosity.