svalinn / parastell

Parametric 3-D CAD modeling toolset for stellarator fusion devices
MIT License
24 stars 11 forks source link

Radial distance utility returns matrix with rows and columns defined by `num_ribs` and `num_rib_pts` #153

Closed connoramoreno closed 2 weeks ago

connoramoreno commented 2 weeks ago

The elements of the distance matrix returned by the radial_distance_utils.measure_radial_distance function correspond to the expanded angular arrays created by utils.expand_ang_list (using num_ribs and num_rib_pts), rather than the user-supplied toroidal_angles and poloidal_angles arrays.

For most use cases, it might be more useful to instead return a distance matrix whose elements correspond the toroidal_angles and poloidal_angles arrays. This would allow users to use the distances matrix directly to define component thickness matrices, rather than needing to index and slice it for direct use.

connoramoreno commented 2 weeks ago

Scratch that; this can be done rather easily with some clever use of num_ribs and num_rib_pts when building ribs for measure_radial_distance.