Class Utils
java.lang.Object
com.singularsys.jepexamples.diagnostics.Utils
Some common utility methods
- Since:
- Jep 3.5
- Author:
- Richard Morris
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionstatic String
hornerExpression
(String varName, int nTerms) Generate a string giving an approximation to log using Horner expression of the form "x*(1/1-x*(1/2-x*(1/3-x*(1/4 ...))))"static String
lnExpression
(String varName, int nDeriv) Generate string giving approximation to logstatic String
recursiveHornerExpression
(String varName, String lastVar, int nTerms)
-
Constructor Details
-
Utils
public Utils()
-
-
Method Details
-
hornerExpression
Generate a string giving an approximation to log using Horner expression of the form "x*(1/1-x*(1/2-x*(1/3-x*(1/4 ...))))"- Parameters:
varName
-nTerms
-- Returns:
- a string containing the expression
-
recursiveHornerExpression
-
lnExpression
Generate string giving approximation to log
-