Changeset 28

Show
Ignore:
Timestamp:
12/07/05 04:33:40 (3 years ago)
Author:
Don Clugston
Message:

Using the new -cov option. Test coverage of ProductLog?() is now 100%.

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • trunk/makeall.bat

    r20 r28  
    1 dmd -Dddocs -unittest mathextra.d mathstat.d mathspecial.d realtest.d complex.d student.d gammadist.d betadist.d etcgamma.d normaldist.d bitoperations.d 
     1dmd -Dddocs -unittest -cov mathextra.d mathstat.d mathspecial.d realtest.d complex.d student.d gammadist.d betadist.d etcgamma.d normaldist.d bitoperations.d 
  • trunk/maketest.bat

    r25 r28  
    1 build -unittest realtest.d testconsistency.d 
     1build -unittest -cov realtest.d testconsistency.d 
  • trunk/mathspecial.d

    r19 r28  
    145145 
    146146unittest { 
     147      // x*exp(x). Used only for testing 
     148    real productExp(real x) 
     149    { 
     150     return x*exp(x); 
     151    } 
     152 
    147153 assert(productLog(-1/E)==-1); 
    148154 assert(isnan(productLog(real.nan))); 
    149155 assert(productLog(E)==1); 
     156 assert(isnan(productLog(-5))); 
     157 assert(productLog(productExp(0.25))==0.25); 
     158 assert(productLog(productExp(2))==2); 
     159 //printf("%a", productLog_1(productExp(-10))); 
     160// assert(productLog_1(productExp(-2))==-2); 
    150161     
    151162  assert(productLog_1(-1/E)==-1); 
  • trunk/normaldist.d

    r25 r28  
    1010 */ 
    1111module normaldist; 
    12 //import etcgamma; 
    13 import std.math; 
    14  
    15 //alias etcgamma.tgamma mytgamma; 
    16 //alias etcgamma.lgamma mylgamma; 
     12private import std.math; 
    1713 
    1814 
  • trunk/testconsistency.d

    r27 r28  
    1010import mathstat; 
    1111import mathspecial; 
    12 import std.math; // for lgamma, tgamma 
     12//import std.math; // for lgamma, tgamma 
     13 
     14// std.math.tgamma and lgamma are STILL buggy! 
    1315import etcgamma; 
    1416 
    1517alias etcgamma.tgamma tgamma; 
    1618alias etcgamma.lgamma lgamma; 
     19 
     20import complex; 
     21// do this just so it will compile. 
     22 real cosh(real x) { return std.math.cosh(x); } 
     23 real sinh(real x) { return std.math.sinh(x); } 
     24 real sin(real x) { return std.math.sin(x); } 
     25 real cos(real x) { return std.math.cos(x); } 
     26 real exp(real x) { return std.math.exp(x); } 
     27 real log(real x) { return std.math.log(x); } 
     28 real atan(real x) { return std.math.atan(x); } 
     29 
     30 
    1731// ------------------------------- 
    1832// Tests of standard mathematical functions