Package org.zkoss.zss.engine

Examples of org.zkoss.zss.engine.Complex.log()


   * @param ctx the function context.
   * @return the natural logarithm of a complex number.
   */
  public static Object engineerImln(Object[] args, XelContext ctx) {
    Complex complex = UtilFns.validateComplex(args[0].toString());
    return UtilFns.cToComplex(complex.log(), complex.getSuffix());
  }
 
  /**
   * Returns the base-10 logarithm of a complex number.
   * This function implements the IMLOG10(inumber) spreadsheet function.
View Full Code Here


   * @return the base-10 logarithm of a complex number.
   */
  public static Object engineerImlog10(Object[] args, XelContext ctx) {
    Complex complex = UtilFns.validateComplex(args[0].toString());
    String suffix = complex.getSuffix();
    return UtilFns.cToComplex(complex.log().divide(new Complex(10, 0, suffix).log()), suffix);
  }
 
  /**
   * Returns the base-2 logarithm of a complex number.
   * This function implements the IMLOG2(inumber) spreadsheet function.
View Full Code Here

   * @return the base-2 logarithm of a complex number.
   */
  public static Object engineerImlog2(Object[] args, XelContext ctx) {
    Complex complex = UtilFns.validateComplex(args[0].toString());
    String suffix = complex.getSuffix();
    return UtilFns.cToComplex(complex.log().divide(new Complex(2, 0, suffix).log()), complex.getSuffix());
  }
 
  /**
   * Returns a complex number raised to an integer power.
   * This function implements the IMPOWER(inumber, number) spreadsheet function.
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.