# Truncating or Rounding Parameters

I am having difficulties figuring out how to truncate a relation
driven parameter in Wildfire 3.0. What I have is something like this:
(parameter) = (d1/d2)
Which is equal to a value, say 7.856522. I want this to be an
INTEGER. Either 7 or 8. I can work with either truncation or
rounding.
Any advise? I know it's probably simple, and I am just missing the
boat.
I am having difficulties figuring out how to truncate a relation driven parameter in Wildfire 3.0. What I have is something like this:
(parameter) = (d1/d2)
Which is equal to a value, say 7.856522. I want this to be an INTEGER. Either 7 or 8. I can work with either truncation or rounding.
Any advise? I know it's probably simple, and I am just missing the boat.
I think you're looking for an expression like BIG=CEIL(d1/d2); or SMALL=FLOOR(d1/d2) which produces the largest or smallest integer which the expression can produce. This is neither strictly rounding nor truncating. CEIL(1.1) produces the integer 2; and FLOOR(1.9) produces the integer 1, so FLOOR is effectively truncating. CEIL, however, has no discretionary rounding capability. Pro/e's internal programming functionality, compared with SW's integration of VB, blows garbage scows. If you've got another \$10-20K to blow on additional software, you can decadently indulge in (no, not in Godiva Chocolates, but) Pro/TOOLKIT, PTC's interface to the kernel functionality, thus the ability to write the code that makes up for PTC's lameness and laziness and cheapness and unresponsiveness and backwardness and carelessness and arrogance and .... (a hundred more such adjectives). For the best that Pro/e has to offer, check 'Help>Help Center>Fundementals' and search for relations or one of the above functions. And welcome to the group.
David Janes
integer 2; and FLOOR(1.9) produces the integer 1, so FLOOR is effectively truncating. CEIL, however, has no discretionary rounding capability. Pro/e's internal programming functionality, compared with SW's integration of VB, blows garbage scows. If you've got another \$10-20K to blow on additional software, you can decadently indulge in (no, not in Godiva Chocolates, but) Pro/TOOLKIT, PTC's interface to the kernel functionality, thus the ability to write the code that makes up for PTC's lameness and laziness and cheapness and unresponsiveness and backwardness and carelessness and arrogance and .... (a hundred more such adjectives). For the best that Pro/e has to offer, check 'Help>Help Center>Fundementals' and search for relations or one of the above functions. And welcome to the group.
Thank you Mr. Janes, that was exactly what I needed. I had seen the floor and Ceil commands, but my training didn't include those and my reference book doesn't mention them, so I had no idea I was staring at exactly what I needed. Worked perfect, again, thank you.
Thank you Mr. Janes, that was exactly what I needed. I had seen the floor and Ceil commands, but my training didn't include those and my reference book doesn't mention them, so I had no idea I was staring at exactly what I needed. Worked perfect, again, thank you.
FYI, another thing that approximates truncation (lopping off the decimal portion of a real number) is [.0]. Placing this as &parameter[.0] results in no decimals showing in the text, effectively truncating the real number to its lowest integer value. This doesn't actually change or round anything. This only effects the display of the number.
David Janes
P.S. Much more arcanery left to explore. But start with the Help menu. All the time, it is making me look smart.

#### Site Timeline

• No. of Positions 1 State / Country / Province USA: IL Illinois Business Function...
• next in

## PRO/Engineer (Creo) discussions

• Hi, Do any of you out there have a post processor to work with wildfire3 to...
• previous in

## PRO/Engineer (Creo) discussions

• Even I check the all dependencies everything looks good. All the sub components...
• last updated in

## PRO/Engineer (Creo) discussions

• Even I check the all dependencies everything looks good. All the sub components...
• last posted in

## PRO/Engineer (Creo) discussions

• Polska nauka 100 lat za Chinami zdjęcie wygląda jak sprzed 100 lat...
• site's last updated in

## Engineering Science (Polish)

• Polska nauka 100 lat za Chinami zdjęcie wygląda jak sprzed 100 lat...