How to Mirror an Implicit Body

Follow

The steps below will teach you how to mirror an Implicity Body using a Plane the mirror. The steps may be involved the first time around, but as always, we can create a Custom Block with them to easily repeat the process when we need it.

1. Start with the Implicit Body you want to mirror and create a Plane (or implicit body) to use as your mirror. Make both of these blocks Variables and name them.

2. Create a simple vector field. This will be used to create the reflected mirror field. 

  • Add a Vector Field from Components block 
  • Set the X, Y, Z values to X, Y, Z

vector_from_components.jpg

3. Create the Reflected Field

  • Add a Multiply block and multiply the scalar field of the Mirror by -2

multiply.jpg

  • Add a Vector Field from Gradient block using the Mirror as the Scalar Field

vector_gradient.jpg

  • Multiply both of the previous steps together

multiply1.jpg

  • Add the result of this to the Simple Vector from Step 2. to create the Reflected Vector

mirror.jpg

3. Remap the Field to Mirror the Object

  • Add a Remap Field block
  • For Scalar Field input use the Shape from Step 1 (the object to be mirrored)
  • Use the Properties from the Reflected block, use X, Y, Z for each input

Follow along with the gif below to see Step 3. 

mirror.gif

And that’s it! You’ve successfully mirrored your object

As an added bonus with this Custom Block, you can use any Implicit Body or Plane as the Mirror Plane. Try mirroring your object with a sphere.

 

Bonus: How to load in a Custom Block

  • Download the Custom Block file provided with this tutorial
  • Open nTop Platform
  • Click on the + icon at the far right of the Notebook
  • Import your Custom Block

Are you still having issues? Reach out to the support team, and we’ll be happy to help!

Thanks for following along with this tutorial and for using nTop Platform.

Download the Example file:

Keywords:

block field implicit translate body custom vector mirror transform 
Was this article helpful?
1 out of 1 found this helpful

Comments

0 comments

Please sign in to leave a comment.