CADquest Article Series

Featured in "Pro/E The Magazine", July/August 1998



    Adding Motion to Parts Using Relations

    Kinematics motion can be easily added to skeleton parts (or any other part or assembly) using a few simple relations. All types of motion can be simulated in Pro/ENGINEER without using Pro/MECHANICA.

    Linear Motion

    The simplest form of motion is linear motion. Define a parameter and use it in a relation to increment a linear dimension value during regeneration.

    Example:

      incr = 5

      d12 = d12 + incr

    At each regeneration of the part, the dimension (d12) is lengthened by the value of the incr parameter. By changing the incr parameter you can adjust the smoothness of the motion.

    Radial Motion

    Radial motion can be accomplished in a similar manner. The only difference is that a angle dimension may not be driven to 360 degrees or above. Test for the condition where the angle dimension is one increment value less than 360, and if so, set it to 0 degrees (which is visually the same as 360). Increment the angle dimension the same way as the linear example, with a relation.

    Example:

      incr = 30

      if d6 == 360 - incr

        d6 = 0

        else

        d6 = d6 + incr

      endif

    At each regeneration of the part, the angle dimension (d6) is increased by the value of the incr parameter. By changing the incr parameter you can adjust the smoothness of the motion. When the angle is one increment value away from 360, the test passes and it is set to 0, which continues the smooth rotational motion.

    Oscillating Motion

    To achieve oscillating motion, define the maximum and minimum range of motion using parameters. Also using a parameter, define the increment of motion. In the relations, test to see if the dimension being varied is equal to or greater than the maximum, and similarly for the minimum. Using a direction parameter, you can flip the direction of motion as a result of the test. Then increment the dimension using the increment parameter times the direction parameter.

    Example:

      incr = 12

      max = 90

      min = 0

      if d15 >= max

        $dir = -1

      endif

      if d15 <= min

        $dir = 1

      endif

      d15 = d15 + (( incr ) * ( $dir ))

    At each regeneration of the part, the dimension (d15) is increased (or decreased) by the value of the incr parameter. By changing the incr parameter you can adjust the smoothness of the motion. When the dimension is greater than or equal to the max, the first test passes and the direction parameter it is set to -1, which reverses the direction of motion. When the dimension is less than or equal to the min, the second test passes and the direction is reversed again. This oscillating motion continues with each regeneration. Create a mapkey to regenerate your model 10 times or so. Use this mapkey to show the motion of your design.

    Steven G. Smith, CADquest, Harrisburg, PA