MEDYAN.FilamentMechParams
Union{}
Mechanical parameters shared by all filaments of a type.
Elastic constants are specified at the monomer scale. With n = numpercylinder and a = spacing, a full cylinder has rest length L0 = n*a; mechanics uses klength/n, kangle/n, and ktwist/n. Keep these monomer-scale constants fixed when changing cylinder resolution.
The bending parameter is named kangle. Its continuum bending rigidity is EI = kangle*spacing (pN·nm²). For a three-dimensional wormlike chain, the bending persistence length is
Here lp and spacing are in nm and kB*T is in pN·nm. For example, at 310 K, spacing = 2.7 and kangle = 16_000 give lp ≈ 10_093 nm (10.1 μm).
The NaN and -1 defaults are placeholders, not a complete physical parameter set. Supply geometry, elastic and collision constants, cylinder size, and the tip limit. Leave twist_per_monomer = NaN to disable twist; otherwise supply both twist_per_monomer and ktwist.
radius::Float64: Cylinder radius (nm), used for excluded-volume contact distances and filament geometry.spacing::Float64: Axial rest-length increment per monomer (nm). A full cylinder spansnumpercylinder*spacing.klength::Float64: Monomer-scale stretching spring constant (pN/nm). A cylinder contributesE = (klength/numpercylinder)*(L-L0)^2/2, whereLandL0are its current and rest lengths. The corresponding axial rigidity isEA = klength*spacing(pN).kangle::Float64: Monomer-scale bending constant (pN·nm/rad²). Each joint contributesE = (kangle/numpercylinder)*(1-cos(θ)), whereθ = 0is straight. For small bends this is(kangle/numpercylinder)*θ^2/2. Setkangle = kB*T*lp/spacingfor the desired continuum bending persistence lengthlp.ktwist::Float64: Monomer-scale torsional constant (pN·nm/rad²), used only when twist is enabled. For excess twistΔφrelative to the relaxed twist, a joint contributesE = 2*(ktwist/numpercylinder)*tan(Δφ/2)^2, approximately(ktwist/numpercylinder)*Δφ^2/2near equilibrium. The continuum torsional rigidity isC = ktwist*spacing(pN·nm²).twist_per_monomer::Float64: Signed relaxed rotation of the material direction per monomer (rad). The reference twist between neighboring cylinders isnumpercylinder*twist_per_monomer.NaNdisables twist degrees of freedom;0enables twist with an untwisted reference state.numpercylinder::Int32: Number of monomers represented by a full cylinder; must be positive. Controls mechanical discretization and the division of the monomer-scale elastic constants. End cylinders can be shorter.kcollide::Float64: Excluded-volume repulsion stiffness (pN/nm) supplied to the collision model. Larger values penalize overlap more strongly. This is separate from stretching stiffness and is not divided bynumpercylinder.collision_layers::UInt32: Bitmask of collision layers occupied by this filament type; defaultUInt32(1)selects the first layer. Multiple bits may be set.no_collide_mask::UInt32: Bitmask of layers this filament type ignores. A pair is excluded if either object’s mask intersects the other’s layers. DefaultUInt32(0)excludes no layers.max_num_unmin_end::Int32: Maximum number of newly added, mechanically unminimized monomers allowed at each tip. Tip reactions that would exceed this limit are disabled until mechanical relaxation. Choose a nonnegative limit smaller than(radius + minimum_other_filament_radius)/spacingso unrelaxed growth remains shorter than the filament contact distance.