HyperVehicle Components

Component Definitions

Base Component

class hypervehicle.components.component.Component(params: dict | None = None, edges: list | None = None, stl_resolution: int | None = 2, verbosity: int | None = 1, name: str | None = None)[source]
add_clustering_options(i_clustering_func: Callable | None = None, j_clustering_func: Callable | None = None)[source]

Add a clustering option to this component.

Parameters:
  • i_clustering_func (Callable, optional) – The clustering function in the i direction. The default is None.

  • j_clustering_func (Callable, optional) – The clustering function in the j direction. The default is None.

analyse()[source]

Evaluates properties of the STL mesh.

curve()[source]

Applies a curvature function to the parametric patches.

grid()[source]

Creates a discrete grid from the parametric patches.

reflect(axis: str = None)[source]

Reflects the parametric patches.

rotate(angle: float = 0, axis: str = 'y')[source]

Rotates the parametric patches.

stl_check(project_area: bool | None = True, matching_lines: bool | None = True)[source]

Check the STL mesh.

stl_repair(small_distance: float = 1e-06)[source]

Attempts to repair stl mesh issues.

Parameters:

small_distance (Float, optional) – Vectors less than this distance apart will be set to the same value.

surface(resolution: int = None)[source]

Creates the discretised surface data from the parametric patches.

to_stl(outfile: str = None)[source]

Writes the component to STL file format.

to_vtk()[source]

Writes the component to VTK file format.