close Warning: Can't synchronize with repository "(default)" (/var/svn/tolp does not appear to be a Subversion repository.). Look in the Trac log for more information.

Opened 12 years ago

Closed 12 years ago

#1699 closed defect (fixed)

TimeSets compatibles

Reported by: Pedro Gea Owned by: Pedro Gea
Priority: high Milestone: Mantainance
Component: TimeAlgebra Version: 3.1
Severity: major Keywords:
Cc:

Description

La función que compara si dos timesets son compatibles en un determinado intervalo, compara en fechas más allá del intervalo indicado.

Por ejemplo:

TimeSet ts1 = Day(y2001)+Day(y2003);
TimeSet ts2 = Day(y2001)+Day(y2003)+Day(y2005);
Real AreCompatibleTimeSet(ts1, ts2, y2000, y2004); //=>0
Real AreCompatibleTimeSet(ts1, ts2, y2000, y2002); //=>1

Change History (5)

comment:1 Changed 12 years ago by Pedro Gea

Owner: changed from Víctor de Buen Remiro to Pedro Gea
Status: newaccepted

comment:2 Changed 12 years ago by Pedro Gea

Se aprecia también el error en el verdadero intervalo en el que se compara si hacemos:

TimeSet ts1 = Day(y1998)+Day(y2001)+Day(y2003);
TimeSet ts2 = Day(y1999)+Day(y2001)+Day(y2003);
Real AreCompatibleTimeSet(ts1, ts2, y2000, y2002); //=>0

comment:3 Changed 12 years ago by Pedro Gea

(In [5950]) Refs #1699
Se modifica la función para hacer la comparación en el intervalo correcto.

comment:4 Changed 12 years ago by Pedro Gea

(In [5951]) Refs #1699
A raíz del warning de compilación:

9>..\btol\timeset_type\tms.cpp(923) : warning C4305: 'argument' : truncation from 'int' to 'bool'
9>..\btol\timeset_type\tms.cpp(930) : warning C4305: 'argument' : truncation from 'int' to 'bool'
9>..\btol\timeset_type\tms.cpp(944) : warning C4305: 'argument' : truncation from 'int' to 'bool'
9>..\btol\timeset_type\tms.cpp(953) : warning C4305: 'argument' : truncation from 'int' to 'bool'
9>..\btol\timeset_type\tms.cpp(964) : warning C4305: 'argument' : truncation from 'int' to 'bool'
9>..\btol\timeset_type\tms.cpp(994) : warning C4305: 'argument' : truncation from 'int' to 'bool'
9>..\btol\timeset_type\tms.cpp(1019) : warning C4305: 'argument' : truncation from 'int' to 'bool'
9>..\btol\timeset_type\tms.cpp(1027) : warning C4305: 'argument' : truncation from 'int' to 'bool'
9>..\btol\timeset_type\tms.cpp(1130) : warning C4305: 'argument' : truncation from 'int' to 'bool'

comment:5 Changed 12 years ago by Pedro Gea

Resolution: fixed
Status: acceptedclosed

(In [5952]) Closes #1699
Se suben los cambios en la rama 3.1.

Note: See TracTickets for help on using tickets.