- Timestamp:
- 06/26/12 14:17:10 (12 years ago)
- Location:
- trunk/sources/HeuristicLab.Problems.DataAnalysis.Symbolic/3.4
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/sources/HeuristicLab.Problems.DataAnalysis.Symbolic/3.4/SymbolicDataAnalysisExpressionTreeILEmittingInterpreter.cs
r7708 r8123 837 837 public static double Psi(double x) { 838 838 if (double.IsNaN(x)) return double.NaN; 839 else if (x.IsAlmost(0.0)) return double.NaN; 840 else if ((Math.Floor(x) - x).IsAlmost(0.0)) return double.NaN; 839 else if (x <= 0 && (Math.Floor(x) - x).IsAlmost(0)) return double.NaN; 841 840 return alglib.psi(x); 842 841 } … … 865 864 double shi, chi; 866 865 alglib.hyperbolicsinecosineintegrals(x, out shi, out chi); 867 return chi;866 return shi; 868 867 } 869 868 -
trunk/sources/HeuristicLab.Problems.DataAnalysis.Symbolic/3.4/SymbolicDataAnalysisExpressionTreeInterpreter.cs
r7708 r8123 198 198 { typeof(Norm), OpCodes.Norm}, 199 199 { typeof(Erf), OpCodes.Erf}, 200 { typeof(Bessel), OpCodes.Bessel} 200 { typeof(Bessel), OpCodes.Bessel} 201 201 }; 202 202 … … 370 370 var x = Evaluate(dataset, ref row, state); 371 371 if (double.IsNaN(x)) return double.NaN; 372 else if (x.IsAlmost(0.0)) return double.NaN; 373 else if ((Math.Floor(x) - x).IsAlmost(0)) return double.NaN; 372 else if (x <= 0 && (Math.Floor(x) - x).IsAlmost(0)) return double.NaN; 374 373 return alglib.psi(x); 375 374 }
Note: See TracChangeset
for help on using the changeset viewer.