@Test public void testToString() { final double[] params = {5, 0, 0, 0}; final InverseMultiquadricFunction funct = new InverseMultiquadricFunction(3, params, 0); final double[] x = {-1, 0, 1}; funct.evaluate(x); assertEquals("[InverseMultiquadricFunction:width=5.00,center=0.00,0.00,0.00]", funct.toString()); }
@Override public double evaluate(final double[] x) { double value = 0; final double width = getWidth(); for (int i = 0; i < getDimensions(); i++) { final double center = getCenter(i); value += Math.pow(x[i] - center, 2) + (width * width); } return 1 / Math.sqrt(value); }
InverseMultiquadricFunction extends AbstractRBF { @Override public double evaluate(final double[] x) { double value = 0; final double width = getWidth(); for (int i = 0; i < getDimensions(); i++) { final double center = getCenter(i); value += Math.pow(x[i] - center, 2) + (width * width); } return 1 / Math.sqrt(value); } }
InverseMultiquadricFunction extends AbstractRBF { @Override public double evaluate(final double[] x) { double value = 0; final double width = getWidth(); for (int i = 0; i < getDimensions(); i++) { final double center = getCenter(i); value += Math.pow(x[i] - center, 2) + (width * width); } return 1 / Math.sqrt(value); } InverseMultiquadricFunction(final int theDimensions, final double[] theParams, final int theIndex); }
InverseMultiquadricFunction extends AbstractRBF { @Override public double evaluate(final double[] x) { double value = 0; final double width = getWidth(); for (int i = 0; i < getDimensions(); i++) { final double center = getCenter(i); value += Math.pow(x[i] - center, 2) + (width * width); } return 1 / Math.sqrt(value); } InverseMultiquadricFunction(final int theDimensions, final double[] theParams, final int theIndex); @Override double evaluate(final double[] x); }
InverseMultiquadricFunction extends AbstractRBF { @Override public double evaluate(final double[] x) { double value = 0; final double width = getWidth(); for (int i = 0; i < getDimensions(); i++) { final double center = getCenter(i); value += Math.pow(x[i] - center, 2) + (width * width); } return 1 / Math.sqrt(value); } InverseMultiquadricFunction(final int theDimensions, final double[] theParams, final int theIndex); @Override double evaluate(final double[] x);  }