Examples of evaluate()


Examples of org.jquantlib.math.RegularisedIncompleteBeta.evaluate()

    for (final double[] value : values) {
      final double a = value[0];
      final double b = value[1];
      final double x = value[2];
      final double expected = value[3];
      final double realised = beta.evaluate(x, a, b);
      if (Math.abs(expected-realised)>1.0e-6)
        fail("x: " + x + " expected: " + expected + " realised: " + realised);
    }
  }
}

Examples of org.jquantlib.math.integrals.TabulatedGaussLegendre.evaluate()

        if (Math.abs(correlation) < 0.925) {
            if (Math.abs(correlation) > 0) {
                final double asr = Math.asin(correlation);
                final Eqn3 f = new Eqn3(h, k, asr);
                bvn = gaussLegendreQuad.evaluate(f);
                bvn *= asr * (0.25 / Math.PI);
            }
            bvn += cumnorm.op(-h) * cumnorm.op(-k);
        } else {
            if (correlation < 0) {

Examples of org.junit.internal.runners.statements.FailOnTimeout.evaluate()

    public void stopEndlessStatement() throws Throwable {
        InfiniteLoopStatement infiniteLoop = new InfiniteLoopStatement();
        FailOnTimeout infiniteLoopTimeout = new FailOnTimeout(infiniteLoop,
                TIMEOUT);
        try {
            infiniteLoopTimeout.evaluate();
        } catch (Exception timeoutException) {
            sleep(20); // time to interrupt the thread
            int firstCount = InfiniteLoopStatement.COUNT;
            sleep(20); // time to increment the count
            assertTrue("Thread has not been stopped.",

Examples of org.junit.runners.model.Statement.evaluate()

                maybeCopy(String.format("%s/shared", className));
                maybeCopy(String.format("%s/%s", className, method.getName()));
                for (String extraResource : extraResources) {
                    maybeCopy(extraResource);
                }
                statement.evaluate();
            }
        };
    }

    private TemporaryFolder findTempDir(Object target) {

Examples of org.jwildfire.base.mathparser.JEPWrapper.evaluate()

        double grayValue = 0.0;
        for (int l = 0; l < octaves; l++) {
          double noiseValue = noise(x * freq, y * freq, 0.0);
          if (transform) {
            parser.setVarValue("x", noiseValue);
            noiseValue = (Double) parser.evaluate(node);
          }
          grayValue += alphaInt * noiseValue;
          freq *= frequencyMultiplier;
          alphaInt *= persistence;
        }

Examples of org.jwildfire.envelope.Envelope.evaluate()

  private static double evalCurve(double pFrame, MotionCurve curve) {
    MotionCurve currCurve = curve;
    double value = 0.0;
    while (currCurve != null) {
      Envelope envelope = currCurve.toEnvelope();
      value += envelope.evaluate(pFrame);
      currCurve = currCurve.getParent();
    }
    return value;
  }

Examples of org.jzkit.search.provider.iface.Searchable.evaluate()

      org.jzkit.search.util.QueryModel.CQLString.CQLString qm = new org.jzkit.search.util.QueryModel.CQLString.CQLString("name=dell");

      // Create a query
      IRQuery query = new IRQuery(qm,"Default");

      IRResultSet result = s.evaluate(query);
      result.waitForStatus(IRResultSetStatus.COMPLETE|IRResultSetStatus.FAILURE,0);
      Enumeration e = new org.jzkit.search.util.ResultSet.ReadAheadEnumeration(result, new ArchetypeRecordFormatSpecification("Default"));
      for ( int i=0; ( ( e.hasMoreElements() ) && ( i < 20 ) ); i++) {
        Object o = e.nextElement();
        System.err.println(o);

Examples of org.kitesdk.morphline.scriptengine.java.ScriptEvaluator.evaluate()

  }
 
  @Test
  public void testBasic() throws Exception {
    ScriptEvaluator script = new ScriptEvaluator(javaImports, "return x * 2; ", Integer.class, new String[] { "x" }, new Class[] { Integer.class }, "myQuery");
    Object result = script.evaluate(new Object[] { new Integer(1) });
    assertEquals(result, new Integer(2));
  }

  @Test
  public void testVoid() throws Exception {

Examples of org.milyn.cdr.xpath.evaluators.XPathExpressionEvaluator.evaluate()

            if(parentStep.isTargetedAtElement(parentElement)) {
                if(!parentStep.isStarStar()) {
                    XPathExpressionEvaluator evaluator = parentStep.getPredicatesEvaluator();
                    if(evaluator == null) {
                        logger.debug("Predicate Evaluators for resource [" + this + "] is null.  XPath step predicates will not be evaluated.");
                    } else if(!evaluator.evaluate(parentElement, index.executionContext)) {
                        return false;
                    }
                }
                index.i--;
            }

Examples of org.mule.api.el.ExpressionLanguage.evaluate()

    @Test
    public void evaluationFromCode() throws Exception
    {
        //<start id="lis_02_expressions-5"/>
        ExpressionLanguage mel = muleContext.getExpressionLanguage();
        String applicationName = mel.evaluate("app.name");
        //<end id="lis_02_expressions-5"/>
        assertThat(mel.isValid("'test'"), is(true));
        assertThat(StringUtils.isNotBlank(applicationName), is(true));
        String testEl = "targetDir = new java.io.File(server.tmpDir, 'target');targetDir.mkdir();targetDir";
        File targetDir = mel.evaluate(testEl);
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.