Paramak¶
The Paramak python package allows rapid production of 3D CAD models of fusion reactors. The purpose of the Paramak is to provide geometry for parametric studies in a variety of geometry formats including STL, STP, Brep, HTML and DAGMC h5m files.
CadQuery functions provide the majority of the features, and incorporating additional capabilities is straightforward for developers with Python knowledge.
Contributions are welcome.
History¶
The package was originally conceived by Jonathan Shimwell and based on the FreeCAD Python API When CadQuery 2 was released the project started to migrate the code base. Shortly after this migration the project became open-source and has flourished ever since.
The project has grown largely due to two contributors in particular (John Billingsley and Remi Delaporte-Mathurin) and others have also helped, you can see all those who have helped the development in the GitHub contributions.
The code has been professionally reviewed by PullRequest.com who produced a report and inline suggestions.
The Paramak source code is distributed with a permissive open-source license (MIT) and is available from the GitHub repository https://github.com/fusion-energy/paramak
Publications and Presentations¶
Published in F1000 Research. https://f1000research.com/articles/10-27
Presented at the Spanish Fusion HPC Workshop and available in the 3rd video and starts at minute 41. https://hpcfusion2020.bsc.es/media also available directly here
Slides from first released presentation. Link
Paramak used for geometry creation in an ARC reactor study. https://iopscience.iop.org/article/10.1088/1741-4326/ac5450
Features¶
In general the Paramak takes input arguments and creates 3D objects. This can be accomplished via the use of parametric Shapes, parametric Components and parametric Reactors with each level building upon the level below.
Parametric Shapes are the simplest and accept points and connection information in 2D space (defaults to x,z plane) and performs operations on them to create 3D volumes. The points and connections are provided by the user when making parametric Shapes. Supported CAD operations include (rotate, extrude, sweep) and Boolean operations such as cut, union and intersect. Additionally the CadQuery objects created can be combined and modified using CadQuery’s powerful filtering capabilities to further customise the shapes by performing operations like edge filleting.
Parametric Components build on top of this foundation and will calculate the points and connections for you when provided with input arguments. The inputs differ between components as a center column requires different inputs to a breeder blanket or a magnet.
Parametric Reactors build upon these two lower level objects to create an entire reactor model from input parameters. Linkage between the components is encoded in each parametric Rector design.
Some of the different parametric reactor families are shown below.
A sub section of the available parametric Components are shown below.
The different families of parametric Shapes that can be made with the Paramak are shown int he table below.
Rotate |
Extrude |
Sweep |
|
---|---|---|---|
Points connected with straight lines |
RotateStraightShape()
|
ExtrudeStraightShape()
|
SweepStraightShape()
|
Points connected with spline curves |
RotateSplineShape()
|
ExtrudeSplineShape()
|
SweepSplineShape()
|
Points connected with a circle |
RotateCircleShape()
|
ExtrudeCircleShape()
|
SweepCircleShape()
|
Points connected with a mixture (splines, straights and circles)
|
RotateMixedShape()
|
ExtrudeMixedShape()
|
SweepMixedShape()
|
Table Of Contents
- Install
- Quick Tour
- Examples
- Parametric Shapes
- Parametric Components
- make_components_blankets.ipynb
- make_components_center_column.ipynb
- make_components_magnets.ipynb
- make_components_other.ipynb
- make_demo_style_blankets.ipynb
- make_firstwall_for_neutron_wall_loading.ipynb
- make_magnet_set.ipynb
- make_plasmas.ipynb
- make_vacuum_vessel_with_ports.ipynb
- make_varible_offset_firstwall.ipynb
- Parametric Reactors
- API-Reference
- Parametric Shapes
- Parametric Components
- Parametric Reactors
- Shape() class
- Reactor() class
- Utils functions
EdgeLengthSelector
FaceAreaSelector
add_thickness()
calculate_wedge_cut()
coefficients_of_line_from_points()
convert_circle_to_spline()
cut_solid()
diff_between_angles()
distance_between_two_points()
export_solids_to_brep()
export_solids_to_brep_object()
export_wire_to_html()
extend()
extract_points_from_edges()
facet_wire()
find_center_point_of_circle()
find_radius_of_circle()
get_bounding_box()
get_center_of_bounding_box()
get_hash()
get_largest_dimension()
get_largest_distance_from_origin()
intersect_solid()
load_stp_file()
patch_workplane()
plotly_trace()
rotate()
transform_curve()
union_solid()