#87 closed defect (fixed)
Parser problem
Reported by: | Lander Ibarra Iriondo | Owned by: | danirus |
---|---|---|---|
Priority: | highest | Milestone: | |
Component: | Kernel | Version: | head |
Severity: | critical | Keywords: | |
Cc: |
Description
Show next code lines;
Serie VerJul11E = CalInd(In(y2003m01d01,y2005m01d01), Diario);
Serie VerSep12E = CalInd(In(y2003m01d01,y2005m01d01), Diario);
Serie SumMVerJulE = VerJul11E-VerSep12E; (1)
Serie SumMVerJul2E = VerJul11E - VerSep12E; (2)
(1) doesn´t work, (2) does work
Change History (5)
comment:1 Changed 21 years ago by
Status: | new → assigned |
---|
comment:2 Changed 21 years ago by
Resolution: | → fixed |
---|---|
Status: | assigned → closed |
comment:3 Changed 21 years ago by
In both next functions of tol/bmath/bprdist/prd.cpp
BDat BFSnedecorDist::Dist(BDat x)
and
BDat BFSnedecorDist::Inverse(BDat prob, BDat tolerance)
it was wrong the assignation of degrees of freedom
dfn = n_;
dfd = m_;
numerator may be m_ and denominator may by n_.
This is an usual case of dyslexia that makes the mind to think that N is before than
M because N is the natural name of a number. Nobody wrongs between A and B or
X and Y, P and Q, etc.; but everybody trends to unsort N and M.
I think a better nomenclature of parameters should be used in probability
functions.
comment:4 Changed 21 years ago by
Sorry for the last comment. I don't how it happened but it were for bug 85.
comment:5 Changed 18 years ago by
bug_file_loc: | → http://cvs.tol-project.org/viewcvs.cgi/tol_tests/tol/Bugzilla/bug_000087 |
---|
A solution for this bug has been delivered to CVS. An update needs only fil.cpp
file, under bparser directory.
Curiously this bug was produced when the Filter of Tol (a little piece of the
Parser) tries to detect a number in scientific notation. The problem appears in
Clean method, into an internal and not necessary if-sentence.
Before update with this solution, you can reproduce this error using any
identifier ended with: a digit, and a letter "e" or "E", followed by '-' or '+'
symbol. ie:
Real a1e = 1;
Real b2e = 2;
Real c = a1e+b2e;
Once you apply the solution, please, use never an identifier beginning with a
number. For a compatibility reason Tol accepts it. ie:
Real 1e = 1; not recommended
Real 2e = 2; not recommended
Real c = 1e+2e; --> Produce an error, but
Real c = 1e + 2e; works