#191 closed defect (fixed)
Problems between BTsrFromReal and other Series
Reported by: | danirus | Owned by: | danirus |
---|---|---|---|
Priority: | normal | Milestone: | |
Component: | TimeSetAlgebra | Version: | head |
Severity: | normal | Keywords: | |
Cc: |
Description
With code like this:
_
Serie ser1 = 5 * CalVar(Diario, Monthly);
or
Serie ser2 = 5 * Pulse(y2004m01, Weekly);
Tol presents some problems.
In those two examples Tol creates two BTsrFromReal series. In both cases, "5"
constant is a BTsrFromReal Serie, which has a Dating == C (or Daily), since bug
177 was resolved.
When we make a product between a BTsrFromReal (with Dating==C) and other
Serie of any other Dating (for example Monthly), Tol can not set a correct Dating
for the result.
Change History (3)
comment:1 Changed 20 years ago by
Status: | new → assigned |
---|
comment:2 Changed 20 years ago by
Resolution: | → fixed |
---|---|
Status: | assigned → closed |
comment:3 Changed 18 years ago by
bug_file_loc: | → http://cvs.tol-project.org/viewcvs.cgi/tol_tests/tol/Bugzilla/bug_000173 |
---|---|
dependson: | → 173 |
This bug has been resolved and fixed.
Now you can try:
It works.
The problem was related with dating_ attribute of BTsrFromReal. I just implement a
solution based on a new attribute for class BTimeSerie. This new attribute, called
datingType_ can has two values: FIXED or VOLATILE. When Tol operates with
something like:
A BTsrReal is created with a Daily dating_. Then a BTsrMinus, which inherit the
same dating_ attribute. After that, when we do:
Tol created a new Serie called "CalVar(Diario, Monthly)" with a Monthly dating_.
The it tries to do the product, but there is a problem of incompatible datings.
Using a VOLATILE dating_, Tol can choose the correct dating between one FIXED
and one or more VOLATILEs. All those operations are done inside a BSerieGroup
object.