Skip to main content
Oct 8, 2018 2:04 PM UTC
Question

/* Adjust LENGTH based on required Volume

Hi,

Please can anybody help me on creating relation between Length and volume of the part. I have part with Length x width x height parameters. I have Volume fixed. So what I am looking for is if I change the width of the part then the Volume of the part should not change instead length or height should change to accommodate the volume.

 

Thanks

8 replies

Oct 8, 2018 2:59 PM UTC

First, run a mass properties report. Then the PRO_MP_VOLUME variable will be populated. You can find the internal mass parameters by selecting the "reported mass properties" drop down. The PRO_MP_VOLUME variable is one of these.

LENGTH = PRO_MP_VOLUME / WIDTH / 2
HEIGHT = LENGTH

Capture.PNG

RAMBKAuthor
Oct 8, 2018 5:34 PM UTC

Thank you Chris for the reply!

But this relation doesn't make the constant volume. Exactly what I am looking is assigning the required volume to the part by changing particular dimension parameter using relations. So whenever I change any dimension that makes the part have the same volume and change the particular dimension which I want.

 

Oct 9, 2018 10:45 AM UTC

I really don't understand what you are asking to have happen. In the simplest case, the volume is a function of three variables

volume = length * width * height

You are asking to change one of the variables and have the volume be kept constant. Fine, that could probably be done in some fashion, but under what constraints? If you change length, what rules are being dictated to change the width and/or height to maintain the constant volume? Keep the ratio of them the same? Lock one and only change the other? What happens if I then initiate a change to one of the other variables?

3-Newcomer
Oct 8, 2018 6:37 PM UTC

You need to create a parameter for your target volume, perhaps TARGET_VOLUME.  Then, assuming your part is a simple rectangle, a relation like this will update the LENGTH based on changes to HEIGHT or WIDTH:

 

LENGTH = TARGET_VOLUME / HEIGHT / WIDTH

However, I doubt that your part is that simple, and therefore the volume formula is more complex than LENGTH x WIDTH x HEIGHT.  For more complex geometry, look into the Behavioral Modeling extension.  It's designed to do these kind of optimizations.

 

If you are dealing with an extruded shape with a constant section, then VOLUME = SECTION_AREA x LENGTH.  You can use an analysis feature to get the cross sectional area and then use this relation:

 

LENGTH = TARGET_VOLUME / SECTION_AREA