Interface KnownFunction

All Superinterfaces:
Function
All Known Implementing Classes:
KnownPolynomial, UserFunction

public interface KnownFunction extends Function
Title: KnownFunction Description: A function that provides its name, expression and parameters to users.
  • Method Details

    • getParameterCount

      int getParameterCount()
      Gets the parameter count.
      Returns:
      the number of parameters
    • getParameterName

      String getParameterName(int i)
      Gets a parameter name.
      Parameters:
      i - the parameter index
      Returns:
      the name of the parameter
    • getParameterValue

      double getParameterValue(int i)
      Gets a parameter value.
      Parameters:
      i - the parameter index
      Returns:
      the value of the parameter
    • getParameterDescription

      String getParameterDescription(int i)
      Gets a parameter description. May be null.
      Parameters:
      i - the parameter index
      Returns:
      the description of the parameter (may be null)
    • setParameterValue

      void setParameterValue(int i, double value)
      Sets a parameter value.
      Parameters:
      i - the parameter index
      value - the value
    • setParameters

      void setParameters(String[] names, double[] values, String[] descriptions)
      Sets the parameters.
      Parameters:
      names - the parameter names
      values - the parameter values
      descriptions - the parameter descriptions
    • getExpression

      String getExpression(String indepVarName)
      Gets the equation.
      Parameters:
      indepVarName - the name of the independent variable
      Returns:
      the equation
    • getName

      String getName()
      Gets the name of the function.
      Returns:
      the name
    • setName

      void setName(String name)
      Sets the name of the function.
      Parameters:
      name - the name
    • getDescription

      String getDescription()
      Gets the description of the function.
      Returns:
      the description
    • setDescription

      void setDescription(String description)
      Sets the description of the function.
      Parameters:
      description - the description
    • clone

      KnownFunction clone()
      Gets a clone of the function.
      Returns:
      the clone
    • equals

      boolean equals(Object f)
      Determines if another Object is the same as this one.
      Overrides:
      equals in class Object
      Parameters:
      f - the Object to test
      Returns:
      true if equal
    • newUserFunction

      UserFunction newUserFunction(String var)