Advanced graphical user interface for particle simulation programs
◀ Previous   △ Index   Next ▶

F5.2.2} Functions

 Square root, exponential, logarithms

      Function        Description
      ~~~~~~~~        ~~~~~~~~~~~
      sqrt(x)         Square root function
      exp(x)          Exponential function
      log(x)          Natural logarithm (base e)
      log10(x)        Common logarithm (base 10)

 Trigonometric functions
      Function       Description
      ~~~~~~~~       ~~~~~~~~~~~
      sin(x)         Trigonometric functions
      asin(x)        Inverse trigonometric functions.
      atan2(y, x)    Evaluates to atan(y/x),

 Hyperbolic functions
      Function       Description
      ~~~~~~~~       ~~~~~~~~~~~
      sinh(x)        Hyperbolic functions
      asinh(x)       Inverse Hyperbolic functions

 Bessel functions
      Function       Description
      ~~~~~~~~       ~~~~~~~~~~~
      besj0(x)       Bessel function of the first kind of order 0
      besy0(x)       ... second kind of order 0
      besj1(x)       ... first kind of order 1
      besy1(x)       ... second kind of order 1

 Error integral and related functions
      Function       Description
      ~~~~~~~~       ~~~~~~~~~~~
      erf(x)         Error function
      erfc(x)        Complementary error function
                     erfc(x) = 1 - erf(x)
      inverf(x)      Inverse error function
      invnorm(x)     Inverse normal distribution function
      norm(x)        Normal (Gaussian) distribution function
                      norm(x) = 0.5*(1+erf(x/sqrt(2)))

 Gamma function and related functions
      Function       Description
      ~~~~~~~~       ~~~~~~~~~~~
      gamma(x)       Gamma function
      ibeta(p, q, x) Incomplete beta function
      igamma(a, x)   Incomplete gamma function
      lgamma(x)      Natural logarithm of gamma function:
                     lgamma(x) = log( gamma(x) )

 Miscellaneous mathematical functions
      Function       Description
      ~~~~~~~~       ~~~~~~~~~~~
      abs(x)         Absolute value for real or complex x.
      ceil(x)        Smallest integer not less than x
      floor(x)       Largest integer not greater than x
      int(x)         Integer part of x, truncated to zero.
      lambertw(x)    Lambert-W Function
                     (the inverse of f(w) = w exp(w)).
      rand(x)        Random number generator
      sgn(x)         Sign function (-1 if x<0; 0 if x=0; 1 if x>0).

 Functions for complex arguments
      Function       Description
      ~~~~~~~~       ~~~~~~~~~~~
      abs(x)         Absolute value of x: sqrt( real(x)**2 + imag(x)**2 )
      arg(x)         Phase angle of x: atan(imag(x)/real(x))
      imag(x)        Imaginary part of x
      real(x)        Real part of x

 String functions
      Function             Description
      ~~~~~~~~             ~~~~~~~~~~~
      exists("x")          Returns 1 if a variable with that name is defined,
                           0 otherwise.
      strlen("s")          String length
      substr("s",i,j)      Substring equivalent to str[i:j]
      strstrt("str","key") Returns position of key in str

      words( "str" )       Number of words in str
      word("str",n )       Return nth word of str
                           C formatting of a string
      gprintf( "format", ... )
                           gnuplot formatting of a string
      system("cmd")        Returns the output of the shell command.

 Column manipulation functions
      Function             Description
      ~~~~~~~~             ~~~~~~~~~~~
      column(x)            Returns the current value of that column
      stringcolumn(x)      Returns the current value of that column as
      valid(x)             Returns 1 is the current value of that
                           column is valid.

 Time column handling functions
      Function             Description
      ~~~~~~~~             ~~~~~~~~~~~
      timecolumn(x)        Parses the column with the format in
                           set timefmt
      tm_sec(x)            Return the seconds part of the time
      tm_min(x)            Minutes part
      tm_hour(x)           Hours
      tm_mday(x)           Month day
      tm_mon(x)            Month
      tm_year(x)           Year
      tm_wday(x)           Week day
      tm_yday(x)           Year day

◀ Previous   △ Index   Next ▶