General Mechanical

General Mechanical

Topics relate to Mechanical Enterprise, Motion, Additive Print and more

equality constraint in optimization

    • Md_Salem

      Hello everyone,

      I am doing an optimization on ANSYS Workbench using direct optimization.

      I suppose to optimize a design moudular configuration of a square patern of (n) patches attached to a plate of (l) length, where

      (s) is the distance between the start of the plate and the first patch.

      (lp) is the patch length.

      (p) is the pitch between patches.

      (e) is the distance between the last patch and the end of the plate.

      I need to set an equality constraint or equality relationship between the shown parameters, such that

      l = s+ lp + n*p + e  

      given that (l) is a constant while (s,lp,n,p,e) are optimization parameters

      Could anyone help me with that problem?


    • peteroznewman

      Don’t you have another constraint?  lp < p

      Use DesignModeler and create input parameters: s, lp, n, p and e.

      Sketch a rectangle. Apply a constraint of equal lengths to force it to be a square. Add a horizontal dimension to size the square. After dimensioning, go to the Parameter/Dimension Assignments tab of the Parameter Editor and type in the expression that constrains the length to be equal to your equation.

      Turn that sketch into a surface or solid.  Create another sketch, use the equal constraint on two edges, and dimension the length of the patch and the offsets for the s parameter. Extrude that into a solid using Add Frozen so it is a separate Body. Use the Pattern menu to copy that solid according to the n and p parameters. Note that in DesignModeler, the n stands for the number of copies of the original, so when n = 4, you get a total of 5 x 5 patches.

      Now you have a completely parametric model that obeys the constraint equations, but you have to be aware to keep lp < p.

      • Md_Salem




        I appreciate it so much, I will try it.






Viewing 1 reply thread
  • You must be logged in to reply to this topic.