12.07.2015 Views

Logix5000 Controllers General Instructions - SLAC Confluence

Logix5000 Controllers General Instructions - SLAC Confluence

Logix5000 Controllers General Instructions - SLAC Confluence

SHOW MORE
SHOW LESS
  • No tags were found...

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

Structured Text Programming 665Use arithmetic operators and functionsYou can combine multiple operators and functions in arithmeticexpressions.Arithmetic operators calculate new values.To Use This Operator Optimal Data Typeadd + DINT, REALsubtract/negate - DINT, REALmultiply * DINT, REALexponent (x to the power of y) ** DINT, REALdivide / DINT, REALmodulo-divide MOD DINT, REALArithmetic functions perform math operations. Specify a constant, anon-boolean tag, or an expression for the function.For Use This Function Optimal Data Typeabsolute value ABS (numeric_expression) DINT, REALarc cosine ACOS (numeric_expression) REALarc sine ASIN (numeric_expression) REALarc tangent ATAN (numeric_expression) REALcosine COS (numeric_expression) REALradians to degrees DEG (numeric_expression) DINT, REALnatural log LN (numeric_expression) REALlog base 10 LOG (numeric_expression) REALdegrees to radians RAD (numeric_expression) DINT, REALsine SIN (numeric_expression) REALsquare root SQRT (numeric_expression) DINT, REALtangent TAN (numeric_expression) REALtruncate TRUNC (numeric_expression) DINT, REALPublication 1756-RM003I-EN-P - January 2007

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!