Introduce [=min..max] operator.

* src/ltlast/bunop.hh: Declare bunop::Equal
* src/ltlast/bunop.cc: Handle it.
* src/ltlparse/ltlparse.yy,
src/ltlparse/ltlscan.ll: Add rules for [=min..max].
* src/tgbaalgos/ltl2tgba_fm.cc: Handle bunop::Equal in
the translation.
* src/ltltest/equals.test: Test trivial identities
for [=min..max].
* src/tgbatest/ltl2tgba.test: Add new formulae to test.
This commit is contained in:
Alexandre Duret-Lutz 2010-10-14 18:51:34 +02:00
parent d7781bc4d6
commit 8d4a413a37
7 changed files with 236 additions and 91 deletions

View file

@ -37,7 +37,7 @@ namespace spot
class bunop : public ref_formula
{
public:
enum type { Star };
enum type { Star, Equal };
static const unsigned unbounded = -1U;
@ -49,7 +49,13 @@ namespace spot
/// - 0[*0..max] = [*0]
/// - 0[*min..max] = 0 if min > 0
/// - [*0][*min..max] = [*0]
/// - Exp[*0] = [*0]
/// - Exp[*i..j][*k..l] = Exp[*ik..jl] if i*(k+1)<=jk+1.
/// - 0[=0..max] = 1[*]
/// - 0[=min..max] = 0 if min > 0
/// - 1[=0] = [*0]
/// - 1[=min..max] = 1[*min..max] if max > 0
/// - Exp[=0] = (!Exp)[*]
///
/// These rewriting rules imply that it is not possible to build
/// an LTL formula object that is SYNTACTICALLY equal to one of