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.

Converting Variable Equations from Fusion to Onshape

I am trying to redraw a variable table that was originally made in Fusion360 in Onshape. I started with just setting up all of the Variables and I have 5 formulas/equations (not sure which is the right word to use here, if either of those) that are kicking my butt.

1 - ( ceil(( Y_Usable - Edge_Offset_Y * 2 ) / Rib_Spacing_Min) ) + 1

2 - ( ceil(( X_Usable - Edge_Offset_X * 2 ) / Rib_Spacing_Min) ) + 1

3 - ( Y_Usable - 2 * Edge_Offset_Y ) / ( Ribs_YDirection - 1 ) - Rib_Thickness - ( Rib_Thickness / ( Ribs_YDirection - 1 ) )

4 - ( ceil(( ( Y_Usable - 2 * Edge_Offset_Y - Rib_Thickness * Ribs_YDirection ) / X_Rib_Length ) / 2) )

5 - ( floor(( ( Y_Usable - 2 * Edge_Offset_Y - Rib_Thickness * Ribs_YDirection ) / X_Rib_Length ) / 2) )

Can anyone help me write these correctly for onshape? I have copied them in and made sure to add the # to them all, and all of my variables are named the same. But they are all showing up red and not working. Any help here would be greatly appreciated!

Answers

  • eric_pestyeric_pesty Member Posts: 1,947 PRO

    The issue is the units.
    ceil and floor functions only work on a number, not a "value with units".

    You can either divide the variably by the unit every time it's used and then multiply again by the unit at the end.

    Or you could create the variables as numbers (instead of lengths), and then multiply by the unit at the end (probably less work…).

Sign In or Register to comment.