Limit operand by value calculated from other operand

  • 10 April 2024
  • 2 replies

How to limit value of operand to a value which is not constant and depends other parameter? For example: calculate 1/10 of radius from Surface and then task is to limit conic to be bellow calculated value. OPLT does not allow for this.



Best answer by David.Nguyen 10 April 2024, 16:22

View original

2 replies

Thanks for this simple and clear solution.

Userlevel 7
Badge +2



There are probably several solutions to this problem. Here is one implementation with a DIFF operand (to take the difference of two operands):

Note that DIFF in operand calculates the Conic of Surface 2 minus the 1/10th Radius of Surface 1. If both are equal the difference is zero. If the Conic is greater, this is a positive value, if the Conic is smaller, this is a negative value.

One has to be a little bit careful as the sign of the Radii and Conic can change (but I can see you’ve already used ABSO in your screenshot :). I have put the absolute values (ABSO) as optional in case you have another way to already control the sign of the Radii and Conic for some reason. Let me know if this is clear. When running the optimizer with the Merit Function above with only the Conic of Surface 2 as variable, this Conic value goes to 0.5.

Let me know if this is clear.

Take care,