Round value calculated by equation

Discussion in 'SolidWorks' started by Sam, Nov 23, 2005.

  1. Sam

    Sam Guest

    Is there a way to have the value calculated by an equation
    automatically round to the nearst whole inch? We have some equations
    that we use to locate some components in an assembly but the equation
    never results in a nice whole number and the location of these
    components is not so critical that we want to dimension them to the
    16th or 32nd. If we just set the dimension in the drawing to round the
    dimensions will look ok but the dimension string will not add up to
    equal the actual overall dimension.

    Thanks,

    Sam
     
    Sam, Nov 23, 2005
    #1
  2. Sam

    That70sTick Guest

    Look in the help under "Equatins --> Functions". There is an integer
    function, "INT". INT gives the lowest whole integer of a decimal
    number,
    i.e. INT(10.666 ) = 10.
    For rounding to nearest (up or down), you can add 0.5 to the final,
    i.e. INT(10.222 + 0.5) = 10,
    INT(10.666 + 0.5) = 11
     
    That70sTick, Nov 23, 2005
    #2
Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments (here). After that, you can post your question and our members will help you out.