Welcome to the Onshape forum! Ask questions and join in the discussions about everything Onshape.

First time visiting? Here are some places to start:
  1. Looking for a certain topic? Check out the categories filter or use Search (upper right).
  2. Need support? Ask a question to our Community Support category.
  3. Please submit support tickets for bugs but you can request improvements in the Product Feedback category.
  4. Be respectful, on topic and if you see a problem, Flag it.

If you would like to contact our Community Manager personally, feel free to send a private message or an email.

How to have number of part instances driven by a variable?

david_lynch037david_lynch037 Member Posts: 4

Hi. I have this part that is a wheel with cylinders on the edge of a wheel, such that the cylinders all touch each other. The wheel is 20 inches in diameter, driven by variable #dia. I would like to be able to change the diameter to 40 inches, by changing #dia, and get more cylinders on the wheel, so that they touch. Right now, there are 18 cylinders, but when I change #dia to 40, I would want enough cylinders so that they still touch each other.

Also complicating this is that there are some values of #dia that will be impossible to fill completely with cylinders. I can't have 1/2 a cylinder or gaps between cylinders.

Is this possible? How do I model this without manually iterating over the pattern tool, trying to find the perfect combination of #dia and the number of cylinders to support scaling of the part to various diameters?

Here is the design:

https://cad.onshape.com/documents/7aef99bb7ab5475c70e92f74/w/cc4a7dc99b6308703b4d0870/e/b7d556c02a14e7bba7fa223a?renderMode=0&uiState=66db9a613ffdfa79fcd6ca40

Thanks!

Comments

Sign In or Register to comment.