mymesh.implicit.lidinoid#
- mymesh.implicit.lidinoid(x, y, z)[source]#
Implicit function approximation of the lidinoid triply periodic minimal surface (TPMS). This function uses sympy functions (sp.cos, sp.sin) to enable symbolic differentiation.
For efficient vectorized evaluation, use: x, y, z = sp.symbols(‘x y z’, real=True) vector_func = sp.lambdify((x, y, z), func(x,y,z), ‘numpy’)
- Parameters:
x (scalar or np.ndarray) – x coordinate(s)
y (scalar or np.ndarray) – y coordinate(s)
z (scalar or np.ndarray) – z coordinate(s)
- Returns:
f – implicit function evaluated with sympy
- Return type:
sympy expression
Examples
surface = implicit.SurfaceMesh(implicit.lidinoid, [0,1,0,1,0,1], 0.05) surface.plot(bgcolor='w')