src/auxprocs.jl

MEDYAN.adapt_membranes!

adapt_membranes!(c::Context; params::MeshAdaptParams=MeshAdaptParams())

Remesh every membrane that is not fixed, so that edge lengths follow the local curvature. Edges are split, collapsed and flipped as set by params, see MeshAdaptParams.

Vertex and triangle indices from before the call are invalid afterwards.

  • The border of an open membrane is unchanged.
  • A vertex with a nonzero state is never removed. New vertices have state zero.
  • A vertex whose MembVertIdx tag has a link is never removed, and its tag follows it to its new index. MembVertIdx tags without links are freed.
  • In-triangle points keep their InTriPointIdx and tags. A point in a changed triangle moves to the closest point on the new triangles.

Chem caching is deferred, see defer_chem_caching!.

MEDYAN.compute_all_membrane_geometry!_system

Updates all membrane geometries used across various parts of MEDYAN.

The list of all items can be found in the document for MEDYAN.compute_geometry!_system function.

Keyword parameters:

  • include_ff::Bool: If true, compute_geometry! used in energy computations will be applied as well, requiring vectorization of the membrane. This happens before system geometry computation in case some fields are overriden.