Welcome to curve_shortening_flow’s documentation!¶
Introduction¶
The API curve_shortening_flow was developed for a project at the institute of numerics at the University of Göttingen and is hosted on the gitlab page of the GWDG. This work was done with help from Dr. Jochen Schulz and Prof. Dr. Max Wardetzky. It contains an iterator for curve shortening flow. It is designed to take an array of vertices and iterating them. The resulting flow can be animated afterwards. Also some interesting numbers can be plotted as time series depending on the simulation time (cumulation of the dt). These include length, CM-position or mean curvature. The vertices can either be iterated until they collapse to a point, until they converge to a circle of specific size or for a user specifiable amount of steps.
This guide explains the usage and API itself with help of some examples.
Installation Instructions¶
In order to install the package pip is required. The usual installing is done locally
pip install -e .
or for users without root privileges
pip install –user -e .
The option -e is used for a link into the API of the root directory. By this procedure an update of the API by pulling the Repo will be automatically included.
Todo
Upload tho API to pypi.
Compiling the documentation¶
The documentation is build with sphinx and in order to compile it the API must be installed and the command
make html
executed in the doc directory. Other types are supported as well like latex, epup, man and many more. To see which formats are possible, use
make help
Examples and demos¶
Some examples can be found in the demo folder of the root directory.
They are minimum examples to get the API working and try it out. A in-depth explanation of the API is provided in this document as well and in the docstrings.
Some hand drawn demonstration vertices are provided with their PNG files in the curve_shortening_flow/examples folder. Also a method for loading these into the iterator class is provided and used for an initialization of the class. An example result video my look like this
This is a bean (in German “bohne”) example. It is a curve with two different directions of curvature. On can see that near the end of the video the curve contracts to a point.
It is possible to fix the minimal length, which is shown in the next example
This is a rectangle contracting until a minimal length is reached and then it continues to form a circle.
Todo
Prepare more interesting examples and add them to the API, like a log spiral.
Content and API overview¶
Indices and tables¶
Todo
There is a method for creating vertices from a picture, but it does not work properly. On has to use the right pixel distance for the points an hope the picture has high enough resolution. This might need to be a project on it’s own.
(The original entry is located in /builds/kevin.luedemann/curve_shortening_flow/doc/curve_shortening_flow/get_vertices.rst, line 6.)
Todo
Write the animation in a way that the user can provide an update method. By this it is more easy to personalize to animation.
(The original entry is located in /builds/kevin.luedemann/curve_shortening_flow/doc/curve_shortening_flow/iterator_class.rst, line 12.)
Todo
Make it higher order schemes work for sharp angles.
(The original entry is located in /builds/kevin.luedemann/curve_shortening_flow/doc/curve_shortening_flow/paper.rst, line 120.)
Todo
Resolve parameter dependecie for the higher order schemes.
(The original entry is located in /builds/kevin.luedemann/curve_shortening_flow/doc/curve_shortening_flow/paper.rst, line 124.)
Todo
Resolve graphical jumping of the curve if iterated with higher order schemes.
(The original entry is located in /builds/kevin.luedemann/curve_shortening_flow/doc/curve_shortening_flow/paper.rst, line 128.)
Todo
Add these information to the docstrings as well.
(The original entry is located in /builds/kevin.luedemann/curve_shortening_flow/doc/curve_shortening_flow/paper.rst, line 132.)
Todo
Upload tho API to pypi.
(The original entry is located in /builds/kevin.luedemann/curve_shortening_flow/doc/index.rst, line 38.)
Todo
Prepare more interesting examples and add them to the API, like a log spiral.
(The original entry is located in /builds/kevin.luedemann/curve_shortening_flow/doc/index.rst, line 86.)
Todo
Add a more accurate measure for stopping the infinite loop, because the mean curvature does not behave nicely for most of the examples.
(The original entry is located in /builds/kevin.luedemann/curve_shortening_flow/doc/iterator_how_to.rst, line 90.)