/**
  * evaluate the LND6 function at the given point <CODE>x</CODE>.
  *
  * @param arg Object must be a <CODE>double[]</CODE> or a <CODE>popt4jlib.VectorIntf</CODE>
  *     object.
  * @param p HashMap unused.
  * @throws IllegalArgumentException if <CODE>arg</CODE> is not of the mentioned types.
  * @return double
  */
 public double eval(Object arg, HashMap p) throws IllegalArgumentException {
   if (arg instanceof VectorIntf) {
     VectorIntf x = (VectorIntf) arg;
     return evalArray(x.getDblArray1());
   } else {
     try {
       return evalArray((double[]) arg);
     } catch (Exception e) {
       e.printStackTrace();
       throw new IllegalArgumentException("function cannot be evaluated at the passed argument");
     }
   }
 }