Changeset 7707


Ignore:
Timestamp:
04/05/12 10:28:47 (8 years ago)
Author:
gkronber
Message:

#1810 fixed issues with newly added symbols to fix unit tests

Location:
trunk/sources
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/sources/HeuristicLab.Problems.DataAnalysis.Symbolic/3.4/Grammars/FullFunctionalExpressionGrammar.cs

    r7696 r7707  
    6262      sqrt.InitialFrequency = 0.0;
    6363      var airyA = new AiryA();
     64      airyA.InitialFrequency = 0.0;
    6465      var airyB = new AiryB();
     66      airyB.InitialFrequency = 0.0;
    6567      var bessel = new Bessel();
     68      bessel.InitialFrequency = 0.0;
    6669      var cosineIntegral = new CosineIntegral();
     70      cosineIntegral.InitialFrequency = 0.0;
    6771      var dawson = new Dawson();
     72      dawson.InitialFrequency = 0.0;
    6873      var erf = new Erf();
     74      erf.InitialFrequency = 0.0;
    6975      var expIntegralEi = new ExponentialIntegralEi();
     76      expIntegralEi.InitialFrequency = 0.0;
    7077      var fresnelCosineIntegral = new FresnelCosineIntegral();
     78      fresnelCosineIntegral.InitialFrequency = 0.0;
    7179      var fresnelSineIntegral = new FresnelSineIntegral();
     80      fresnelSineIntegral.InitialFrequency = 0.0;
    7281      var gamma = new Gamma();
     82      gamma.InitialFrequency = 0.0;
    7383      var hypCosineIntegral = new HyperbolicCosineIntegral();
     84      hypCosineIntegral.InitialFrequency = 0.0;
    7485      var hypSineIntegral = new HyperbolicSineIntegral();
     86      hypSineIntegral.InitialFrequency = 0.0;
    7587      var norm = new Norm();
     88      norm.InitialFrequency = 0.0;
    7689      var psi = new Psi();
     90      psi.InitialFrequency = 0.0;
    7791      var sineIntegral = new SineIntegral();
     92      sineIntegral.InitialFrequency = 0.0;
    7893
    7994      var exp = new Exponential();
  • trunk/sources/HeuristicLab.Problems.DataAnalysis.Symbolic/3.4/SymbolicDataAnalysisExpressionTreeInterpreter.cs

    r7696 r7707  
    370370            var x = Evaluate(dataset, ref row, state);
    371371            if (double.IsNaN(x)) return double.NaN;
    372             else if (x.IsAlmost(0.0)) return 0.0;
    373             else if (x.IsAlmost(-1.0)) return 0.0;
     372            else if (x.IsAlmost(0.0)) return double.NaN;
     373            else if ((Math.Floor(x) - x).IsAlmost(-1.0)) return double.NaN;
    374374            return alglib.psi(x);
    375375          }
  • trunk/sources/HeuristicLab.Tests/HeuristicLab.Problems.DataAnalysis.Symbolic-3.4/SymbolicDataAnalysisExpressionTreeInterpreterTest.cs

    r7259 r7707  
    5656    [TestMethod]
    5757    public void SymbolicDataAnalysisExpressionTreeInterpreterArithmeticGrammarPerformanceTest() {
    58       FullGrammarPerformanceTest(new SymbolicDataAnalysisExpressionTreeInterpreter(), 12.5e6);
     58      ArithmeticGrammarPerformanceTest(new SymbolicDataAnalysisExpressionTreeInterpreter(), 12.5e6);
    5959    }
    6060
     
    6565    [TestMethod]
    6666    public void SymbolicDataAnalysisExpressionTreeILEmittingInterpreterArithmeticGrammarPerformanceTest() {
    67       FullGrammarPerformanceTest(new SymbolicDataAnalysisExpressionTreeILEmittingInterpreter(), 7.5e6);
     67      ArithmeticGrammarPerformanceTest(new SymbolicDataAnalysisExpressionTreeILEmittingInterpreter(), 7.5e6);
    6868    }
    6969
Note: See TracChangeset for help on using the changeset viewer.