Skip to content

Commit

Permalink
added example
Browse files Browse the repository at this point in the history
  • Loading branch information
shimwell committed Oct 1, 2024
1 parent ade633a commit b268e40
Showing 1 changed file with 7 additions and 4 deletions.
11 changes: 7 additions & 4 deletions docs/usage.rst
Original file line number Diff line number Diff line change
Expand Up @@ -328,6 +328,8 @@ Reactor with divertor(s)
:width: 100%
:height: 600px

from cadquery import Workplane

# makes a rectangle that overlaps the lower blanket under the plasma
# the intersection of this and the layers will form the lower divertor
points = [(300, -700), (300, 0), (400, 0), (400, -700)]
Expand All @@ -353,6 +355,8 @@ Reactor with divertor(s)

.. code-block:: python
from cadquery import Workplane
# makes a rectangle that overlaps the lower blanket under the plasma
# the intersection of this and the layers will form the lower divertor
points = [(300, -700), (300, 0), (400, 0), (400, -700)]
Expand Down Expand Up @@ -800,13 +804,12 @@ Tokamak with several customizations
rotation_angle=180,
add_extra_cut_shapes=add_extra_cut_shapes,
extra_intersect_shapes=[divertor_lower]
)
result.toCompound()
).toCompound()

.. code-block:: python
import paramak
from cadquery import vis, Workplane
from cadquery import Workplane
# makes a rectangle that overlaps the lower blanket under the plasma
# the intersection of this and the layers will form the lower divertor
Expand Down Expand Up @@ -880,4 +883,4 @@ Tokamak with several customizations
add_extra_cut_shapes=add_extra_cut_shapes,
extra_intersect_shapes=[divertor_lower]
)
my_reactor.save(f"tokamak_with_divertor.step")
my_reactor.save(f"tokamak_with_customizations.step")

0 comments on commit b268e40

Please sign in to comment.