You can edit almost every page by Creating an account and confirming your email.

Mathcad rounding syntax

From EverybodyWiki Bios & Wiki



The Mathcad notation or Mathcad syntax is used to enter formulas and commands for Mathcad, a commercial mathematical software.

Numbers

Rounding functions

Several functions are available for rounding fractional numeric values to integral values or a specific number of fractional digits:

  • round(z,n): returns z rounded to n (optional) decimal places. If n is omitted, it returns z rounded to the nearest integer (n is assumed to be zero). If n<0, it returns z rounded to n places to the left of the decimal point. For example,
round(π-2πi) returns 3-6i
round(-(π-2πi)) returns -3+6i.
  • trunc(z): returns the integer part of z by removing the fractional part. For example,
trunc(2.7) returns 2
trunc(-2.2) returns -2
  • floor(z): returns the greatest integer ≤ z
floor(π-2πi) returns 3-7i
floor(-(π-2πi)) returns -4+6i
  • ceil(z): returns the smallest integer ≥ z
ceil(π-2πi) returns 4-6i
ceil(-(π-2πi)) returns -3+7i



This article "Mathcad rounding syntax" is from Wikipedia. The list of its authors can be seen in its historical. Articles copied from Draft Namespace on Wikipedia could be seen on the Draft Namespace of Wikipedia and not main one.