Boost logo

Boost-Commit :

Subject: [Boost-commit] svn:boost r50446 - in sandbox/itl: boost/itl boost/itl/type_traits boost/validate boost/validate/gentor boost/validate/laws libs/itl/build/win32 libs/itl/doc libs/validate/example/labat_itv_map_groupig libs/validate/example/labat_itv_map_settic libs/validate/example/labat_single libs/validate/example/labatea libs/validate/src/gentor
From: afojgo_at_[hidden]
Date: 2009-01-02 18:52:43


Author: jofaber
Date: 2009-01-02 18:52:40 EST (Fri, 02 Jan 2009)
New Revision: 50446
URL: http://svn.boost.org/trac/boost/changeset/50446

Log:
Added tests. Stable {msvc-9.0, partly congcc-4.3-a7}
Added:
   sandbox/itl/boost/itl/type_traits/absorbs_neutrons.hpp (contents, props changed)
   sandbox/itl/boost/itl/type_traits/emits_neutrons.hpp (contents, props changed)
   sandbox/itl/boost/validate/utility.hpp (contents, props changed)
   sandbox/itl/libs/validate/example/labat_itv_map_groupig/
   sandbox/itl/libs/validate/example/labat_itv_map_groupig/labat_itv_map_groupig.cpp (contents, props changed)
   sandbox/itl/libs/validate/example/labat_itv_map_groupig/vc9_labat_itv_map_groupig.vcproj (contents, props changed)
   sandbox/itl/libs/validate/example/labat_itv_map_settic/
   sandbox/itl/libs/validate/example/labat_itv_map_settic/labat_itv_map_settic.cpp (contents, props changed)
   sandbox/itl/libs/validate/example/labat_itv_map_settic/vc9_labat_itv_map_settic.vcproj (contents, props changed)
   sandbox/itl/libs/validate/example/labat_single/
   sandbox/itl/libs/validate/example/labat_single/labat_single.cpp (contents, props changed)
   sandbox/itl/libs/validate/example/labat_single/vc9_labat_single.vcproj (contents, props changed)
Removed:
   sandbox/itl/boost/itl/type_traits/is_neutron_absorber.hpp
   sandbox/itl/boost/itl/type_traits/is_neutron_emitter.hpp
Text files modified:
   sandbox/itl/boost/itl/functors.hpp | 70 ++++++++++
   sandbox/itl/boost/itl/interval_base_map.hpp | 12 -
   sandbox/itl/boost/itl/interval_map.hpp | 12
   sandbox/itl/boost/itl/interval_set.hpp | 4
   sandbox/itl/boost/itl/map.hpp | 52 ++++--
   sandbox/itl/boost/itl/map_algo.hpp | 43 +++++
   sandbox/itl/boost/itl/notate.hpp | 6
   sandbox/itl/boost/itl/separate_interval_set.hpp | 4
   sandbox/itl/boost/itl/set.hpp | 24 +--
   sandbox/itl/boost/itl/split_interval_map.hpp | 11 -
   sandbox/itl/boost/itl/split_interval_set.hpp | 4
   sandbox/itl/boost/itl/type_traits/type_to_string.hpp | 2
   sandbox/itl/boost/validate/gentor/gentorprofile.h | 13 +
   sandbox/itl/boost/validate/gentor/randomgentor.h | 12 +
   sandbox/itl/boost/validate/laws/order.h | 10
   sandbox/itl/boost/validate/laws/set_laws.h | 194 +++++++++++++++++++++++++--
   sandbox/itl/boost/validate/lawvalidater.h | 2
   sandbox/itl/boost/validate/realmvalidater.h | 209 ++++++-----------------------
   sandbox/itl/boost/validate/typevalidater.h | 276 ++++++++++++++++++++++++++++++---------
   sandbox/itl/libs/itl/build/win32/vc9_all.sln | 18 ++
   sandbox/itl/libs/itl/doc/interface.qbk | 17 ++
   sandbox/itl/libs/validate/example/labatea/labatea.cpp | 41 ++++-
   sandbox/itl/libs/validate/src/gentor/gentorprofile.cpp | 28 ++-
   23 files changed, 718 insertions(+), 346 deletions(-)

Modified: sandbox/itl/boost/itl/functors.hpp
==============================================================================
--- sandbox/itl/boost/itl/functors.hpp (original)
+++ sandbox/itl/boost/itl/functors.hpp 2009-01-02 18:52:40 EST (Fri, 02 Jan 2009)
@@ -104,6 +104,60 @@
     inline std::string unary_template_to_string<inplace_minus>::apply() { return "-="; }
 
     // ------------------------------------------------------------------------
+ template <typename Type> struct inplace_bit_add
+ : public neutron_based_inplace_combine<Type>
+ {
+ typedef Type type;
+
+ void operator()(Type& object, const Type& operand)const
+ { object |= operand; }
+ };
+
+ template<>
+ inline std::string unary_template_to_string<inplace_bit_add>::apply() { return "b|="; }
+
+ // ------------------------------------------------------------------------
+ template <typename Type> struct inplace_bit_subtract
+ : public neutron_based_inplace_combine<Type>
+ {
+ typedef Type type;
+ void operator()(Type& object, const Type& operand)const
+ { object &= ~operand; }
+
+ static Type neutron() { return boost::itl::neutron<Type>::value(); }
+ };
+
+ template<>
+ inline std::string unary_template_to_string<inplace_bit_subtract>::apply() { return "b-="; }
+
+ // ------------------------------------------------------------------------
+ template <typename Type> struct inplace_bit_and
+ : public neutron_based_inplace_combine<Type>
+ {
+ typedef Type type;
+
+ void operator()(Type& object, const Type& operand)const
+ { object &= operand; }
+ };
+
+ template<>
+ inline std::string unary_template_to_string<inplace_bit_and>::apply() { return "b&="; }
+
+ // ------------------------------------------------------------------------
+ template <typename Type> struct inplace_bit_xor
+ : public neutron_based_inplace_combine<Type>
+ {
+ typedef Type type;
+ void operator()(Type& object, const Type& operand)const
+ { object ^= operand; }
+
+ static Type neutron() { return boost::itl::neutron<Type>::value(); }
+ };
+
+ template<>
+ inline std::string unary_template_to_string<inplace_bit_xor>::apply() { return "b^="; }
+
+ // ------------------------------------------------------------------------
     template <typename Type> struct inserter
         : public neutron_based_inplace_combine<Type>
     {
@@ -200,6 +254,22 @@
         { typedef itl::inplace_plus<Type> type; };
 
         template<class Type>
+ struct inverse<itl::inplace_bit_add<Type> >
+ { typedef itl::inplace_bit_subtract<Type> type; };
+
+ template<class Type>
+ struct inverse<itl::inplace_bit_subtract<Type> >
+ { typedef itl::inplace_bit_add<Type> type; };
+
+ template<class Type>
+ struct inverse<itl::inplace_bit_and<Type> >
+ { typedef itl::inplace_bit_xor<Type> type; };
+
+ template<class Type>
+ struct inverse<itl::inplace_bit_xor<Type> >
+ { typedef itl::inplace_bit_and<Type> type; };
+
+ template<class Type>
         struct inverse<itl::inplace_star<Type> >
         { typedef itl::inplace_slash<Type> type; };
 

Modified: sandbox/itl/boost/itl/interval_base_map.hpp
==============================================================================
--- sandbox/itl/boost/itl/interval_base_map.hpp (original)
+++ sandbox/itl/boost/itl/interval_base_map.hpp 2009-01-02 18:52:40 EST (Fri, 02 Jan 2009)
@@ -465,7 +465,7 @@
     SubType& subtract(const value_type& x)
     {
                 typedef typename inverse<Combine<CodomainT> >::type InverseCombine;
- if(Traits::emits_neutrons)
+ if(Traits::emits_neutrons && !is_set<codomain_type>::value)
                         that()->template add_<InverseCombine>(x);
         else
                         that()->template subtract_<InverseCombine>(x);
@@ -1077,7 +1077,7 @@
>
 CodomainT interval_base_map<SubType,DomainT,CodomainT,Traits,Compare,Combine,Section,Interval,Alloc>::sum()const
 {
- CodomainT sum = CodomainT();
+ CodomainT sum = codomain_combine::neutron();
     const_FOR_IMPLMAP(it)
         sum += (*it).CONT_VALUE;
     return sum;
@@ -1196,13 +1196,7 @@
 inline bool is_protonic_equal(const interval_base_map<SubType,DomainT,CodomainT,Traits,Compare,Combine,Section,Interval,Alloc>& lhs,
                               const interval_base_map<SubType,DomainT,CodomainT,Traits,Compare,Combine,Section,Interval,Alloc>& rhs)
 {
- interval_base_map<SubType,DomainT,CodomainT,Traits,Compare,Combine,Section,Interval,Alloc> lhs0 = lhs;
- interval_base_map<SubType,DomainT,CodomainT,Traits,Compare,Combine,Section,Interval,Alloc> rhs0 = rhs;
-
- lhs0.absorb_neutrons();
- rhs0.absorb_neutrons();
-
- return Set::lexicographical_equal(lhs0, rhs0);
+ return Map::lexicographical_protonic_equal(lhs, rhs);
 }
 
 

Modified: sandbox/itl/boost/itl/interval_map.hpp
==============================================================================
--- sandbox/itl/boost/itl/interval_map.hpp (original)
+++ sandbox/itl/boost/itl/interval_map.hpp 2009-01-02 18:52:40 EST (Fri, 02 Jan 2009)
@@ -398,7 +398,7 @@
     {
         CodomainT added_val = Combiner::neutron();
         Combiner()(added_val, value.CONT_VALUE);
- if(Traits::absorbs_neutrons && added_val == neutron<CodomainT>::value())
+ if(Traits::absorbs_neutrons && added_val == Combiner::neutron())
                         return this->_map.end();
                 else
             insertion = this->_map.insert(value_type(value.KEY_VALUE, added_val));
@@ -429,7 +429,7 @@
     {
         CodomainT added_val = Combiner::neutron();
         Combiner()(added_val, value.CONT_VALUE);
- if(Traits::absorbs_neutrons && added_val == neutron<CodomainT>::value())
+ if(Traits::absorbs_neutrons && added_val == Combiner::neutron())
                         return this->_map.end();
                 else
             insertion = this->_map.insert(value_type(value.KEY_VALUE, added_val));
@@ -464,7 +464,7 @@
     {
         CodomainT added_val = Combiner::neutron();
         Combiner()(added_val, x_val);
- if(Traits::absorbs_neutrons && added_val == neutron<CodomainT>::value())
+ if(Traits::absorbs_neutrons && added_val == Combiner::neutron())
                         return;
                 else
                         insertion = this->_map.insert(value_type(x_itv, added_val));
@@ -1009,14 +1009,14 @@
 
 template <class KeyT, class DataT, class Traits>
 struct is_interval_splitter<itl::interval_map<KeyT,DataT,Traits> >
-{ enum{value = true}; };
+{ enum{value = false}; };
 
 template <class KeyT, class DataT, class Traits>
-struct is_neutron_absorber<itl::interval_map<KeyT,DataT,Traits> >
+struct absorbs_neutrons<itl::interval_map<KeyT,DataT,Traits> >
 { enum{value = Traits::absorbs_neutrons}; };
 
 template <class KeyT, class DataT, class Traits>
-struct is_neutron_emitter<itl::interval_map<KeyT,DataT,Traits> >
+struct emits_neutrons<itl::interval_map<KeyT,DataT,Traits> >
 { enum{value = Traits::emits_neutrons}; };
 
 template <class KeyT, class DataT, class Traits>

Modified: sandbox/itl/boost/itl/interval_set.hpp
==============================================================================
--- sandbox/itl/boost/itl/interval_set.hpp (original)
+++ sandbox/itl/boost/itl/interval_set.hpp 2009-01-02 18:52:40 EST (Fri, 02 Jan 2009)
@@ -390,11 +390,11 @@
 { enum{value = false}; };
 
 template <class Type>
-struct is_neutron_absorber<itl::interval_set<Type> >
+struct absorbs_neutrons<itl::interval_set<Type> >
 { enum{value = false}; };
 
 template <class Type>
-struct is_neutron_emitter<itl::interval_set<Type> >
+struct emits_neutrons<itl::interval_set<Type> >
 { enum{value = false}; };
 
 template <class Type>

Modified: sandbox/itl/boost/itl/map.hpp
==============================================================================
--- sandbox/itl/boost/itl/map.hpp (original)
+++ sandbox/itl/boost/itl/map.hpp 2009-01-02 18:52:40 EST (Fri, 02 Jan 2009)
@@ -35,6 +35,7 @@
 
 #include <string>
 #include <boost/itl/notate.hpp>
+#include <boost/itl/type_traits/is_map.hpp>
 #include <boost/itl/type_traits/to_string.hpp>
 #include <boost/itl/functors.hpp>
 #include <boost/itl/predicates.hpp>
@@ -75,14 +76,14 @@
     template<>
     inline std::string type_to_string<neutron_emitter>::apply() { return "^0"; }
 
- struct neutron_emitter_and_enricher
+ struct neutron_polluter
     {
         enum { absorbs_neutrons = false };
         enum { emits_neutrons = true };
     };
 
     template<>
- inline std::string type_to_string<neutron_emitter_and_enricher>::apply() { return "e^0"; }
+ inline std::string type_to_string<neutron_polluter>::apply() { return "e^0"; }
 
 
     /*JODO move this comment to concept InplaceAddable, InplaceSubtractable, InplaceCombinable
@@ -130,10 +131,11 @@
         typedef CodomainT mapped_type;
         typedef CodomainT data_type;
         typedef std::pair<const DomainT, CodomainT> value_type;
- typedef ITL_COMPARE_DOMAIN(Compare,DomainT) key_compare;
- typedef ITL_COMBINE_CODOMAIN(Combine,CodomainT) data_combine;
- typedef typename inverse<Combine<CodomainT> >::type inverse_data_combine;
- typedef inplace_star<CodomainT> data_intersect;
+ typedef ITL_COMPARE_DOMAIN(Compare,DomainT) domain_compare;
+ typedef ITL_COMBINE_CODOMAIN(Combine,CodomainT) codomain_combine;
+ typedef domain_compare key_compare;
+ typedef typename inverse<codomain_combine >::type inverse_codomain_combine;
+ typedef inplace_star<CodomainT> codomain_intersect;
                 typedef typename base_type::value_compare value_compare;
 
     public:
@@ -209,7 +211,7 @@
 
         std::pair<iterator,bool> insert(const value_type& value_pair)
         {
- if(Traits::absorbs_neutrons && value_pair.CONT_VALUE == CodomainT())
+ if(Traits::absorbs_neutrons && value_pair.CONT_VALUE == codomain_combine::neutron())
                 return std::pair<iterator,bool>(end(),true);
             else
                 return base_type::insert(value_pair);
@@ -219,7 +221,7 @@
             not exist in the map.
             If \c value_pairs's key value exists in the map, it's data
             value is added to the data value already found in the map. */
- iterator add(const value_type& value_pair) { return add<data_combine>(value_pair); }
+ iterator add(const value_type& value_pair) { return add<codomain_combine>(value_pair); }
 
         template<class Combiner>
         iterator add(const value_type& value_pair);
@@ -238,9 +240,9 @@
             in \c *this, subtract the contents using <tt>operator -=</tt>. */
         map& operator -= (const map& x2)
         {
- if(Traits::emits_neutrons)
+ if(Traits::emits_neutrons && !is_set<codomain_type>::value)
                 const_FORALL(typename map, it_, x2)
- this->add<inverse_data_combine>(*it_);
+ this->add<inverse_codomain_combine>(*it_);
             else Set::subtract(*this, x2);
             return *this;
         }
@@ -372,13 +374,13 @@
     typename map<DomainT,CodomainT,Traits,Compare,Combine,Section,Alloc>::iterator
         map<DomainT,CodomainT,Traits,Compare,Combine,Section,Alloc>::add(const value_type& val)
     {
- if(Traits::absorbs_neutrons && val.CONT_VALUE == CodomainT())
+ if(Traits::absorbs_neutrons && val.CONT_VALUE == Combiner::neutron())
             return end();
 
         std::pair<iterator, bool> insertion;
         if(Traits::emits_neutrons)
         {
- CodomainT added_val = CodomainT();
+ CodomainT added_val = Combiner::neutron();
             Combiner()(added_val, val.CONT_VALUE);
             insertion = insert(value_type(val.KEY_VALUE, added_val));
         }
@@ -392,7 +394,7 @@
             iterator it = insertion.ITERATOR;
             Combiner()((*it).CONT_VALUE, val.CONT_VALUE);
 
- if(Traits::absorbs_neutrons && (*it).CONT_VALUE == CodomainT())
+ if(Traits::absorbs_neutrons && (*it).CONT_VALUE == Combiner::neutron())
             {
                 erase(it);
                 return end();
@@ -407,7 +409,7 @@
         map<DomainT,CodomainT,Traits,Compare,Combine,Section,Alloc>
         ::erase(const value_type& value_pair)
     {
- if(Traits::absorbs_neutrons && value_pair.CONT_VALUE == CodomainT())
+ if(Traits::absorbs_neutrons && value_pair.CONT_VALUE == codomain_combine::neutron())
             return 0; // neutrons are never contained 'substantially'
                       // only 'virually'.
 
@@ -426,8 +428,8 @@
     typename map<DomainT,CodomainT,Traits,Compare,Combine,Section,Alloc>::iterator
         map<DomainT,CodomainT,Traits,Compare,Combine,Section,Alloc>::subtract(const value_type& val)
     {
- if(Traits::emits_neutrons)
- return add<inverse_data_combine>(val);
+ if(Traits::emits_neutrons && !is_set<codomain_type>::value)
+ return add<inverse_codomain_combine>(val);
         else
         {
             iterator it_ = find(val.KEY_VALUE);
@@ -435,7 +437,7 @@
             {
                 (*it_).CONT_VALUE -= val.CONT_VALUE;
 
- if(Traits::absorbs_neutrons && (*it_).CONT_VALUE == CodomainT())
+ if(Traits::absorbs_neutrons && (*it_).CONT_VALUE == codomain_combine::neutron())
                 {
                     erase(it_);
                     return end();
@@ -520,7 +522,17 @@
         return object;
     }
 
- //-------------------------------------------------------------------------
+ //-----------------------------------------------------------------------------
+ // type traits
+ //-----------------------------------------------------------------------------
+ template <class KeyT, class DataT, class Traits>
+ struct is_set<itl::map<KeyT,DataT,Traits> >
+ { enum{value = true}; };
+
+ template <class KeyT, class DataT, class Traits>
+ struct is_map<itl::map<KeyT,DataT,Traits> >
+ { enum{value = true}; };
+
     template <class DomainT, class CodomainT, class Traits>
     struct is_interval_container<itl::map<DomainT,CodomainT,Traits> >
     { enum{value = true}; };
@@ -530,11 +542,11 @@
     { enum{value = false}; };
 
     template <class DomainT, class CodomainT, class Traits>
- struct is_neutron_absorber<itl::map<DomainT,CodomainT,Traits> >
+ struct absorbs_neutrons<itl::map<DomainT,CodomainT,Traits> >
     { enum{value = Traits::absorbs_neutrons}; };
 
     template <class DomainT, class CodomainT, class Traits>
- struct is_neutron_emitter<itl::map<DomainT,CodomainT,Traits> >
+ struct emits_neutrons<itl::map<DomainT,CodomainT,Traits> >
     { enum{value = Traits::emits_neutrons}; };
 
     template <class DomainT, class CodomainT, class Traits>

Modified: sandbox/itl/boost/itl/map_algo.hpp
==============================================================================
--- sandbox/itl/boost/itl/map_algo.hpp (original)
+++ sandbox/itl/boost/itl/map_algo.hpp 2009-01-02 18:52:40 EST (Fri, 02 Jan 2009)
@@ -105,9 +105,9 @@
                 {
                     result.insert(*x1_);
                     if(is_set<typename MapType::data_type>::value)
- result.template add<MapType::data_intersect>(*x2_); //MEMO template cast for gcc
+ result.template add<MapType::codomain_intersect>(*x2_); //MEMO template cast for gcc
                     else
- result.template add<MapType::data_combine>(*x2_);//JODO URG
+ result.template add<MapType::codomain_combine>(*x2_);//JODO URG
                 }
                 x1_++;
             }
@@ -155,6 +155,45 @@
             tmp.swap(result);
         }
 
+ template<class MapType>
+ typename MapType::const_iterator next_proton(typename MapType::const_iterator& iter_, const MapType& object)
+ {
+ while( iter_ != object.end()
+ && iter_->CONT_VALUE == neutron<typename MapType::codomain_type>::value())
+ ++iter_;
+
+ return iter_;
+ }
+
+ /** Function template <tt>lexicographical_equal</tt> implements
+ lexicographical equality except for neutronic content values. */
+ template<class MapType>
+ bool lexicographical_protonic_equal(const MapType& left, const MapType& right)
+ {
+ if(&left == &right)
+ return true;
+
+ typename MapType::const_iterator left_ = left.begin();
+ typename MapType::const_iterator right_ = right.begin();
+
+ left_ = next_proton(left_, left);
+ right_ = next_proton(right_, right);
+
+ while(left_ != left.end() && right_ != right.end())
+ {
+ if(!(left_->KEY_VALUE == right_->KEY_VALUE && left_->CONT_VALUE == right_->CONT_VALUE))
+ return false;
+
+ ++left_;
+ ++right_;
+ left_ = next_proton(left_, left);
+ right_ = next_proton(right_, right);
+ }
+
+ return left_ == left.end() && right_ == right.end();
+ }
+
+
     } // namespace Map
 }} // namespace boost itl
 

Modified: sandbox/itl/boost/itl/notate.hpp
==============================================================================
--- sandbox/itl/boost/itl/notate.hpp (original)
+++ sandbox/itl/boost/itl/notate.hpp 2009-01-02 18:52:40 EST (Fri, 02 Jan 2009)
@@ -126,6 +126,12 @@
 //------------------------------------------------------------------------------
 #define ITL_ALLOC template<class>class
 
+//------------------------------------------------------------------------------
+namespace boost{namespace itl
+{
+ typedef unsigned int nat;
+}} // namespace itl boost
+
 #endif // __itl_NOTATE_H_JOFA_990119__
 
 

Modified: sandbox/itl/boost/itl/separate_interval_set.hpp
==============================================================================
--- sandbox/itl/boost/itl/separate_interval_set.hpp (original)
+++ sandbox/itl/boost/itl/separate_interval_set.hpp 2009-01-02 18:52:40 EST (Fri, 02 Jan 2009)
@@ -270,11 +270,11 @@
 { enum{value = false}; };
 
 template <class Type>
-struct is_neutron_absorber<itl::separate_interval_set<Type> >
+struct absorbs_neutrons<itl::separate_interval_set<Type> >
 { enum{value = false}; };
 
 template <class Type>
-struct is_neutron_emitter<itl::separate_interval_set<Type> >
+struct emits_neutrons<itl::separate_interval_set<Type> >
 { enum{value = false}; };
 
 template <class Type>

Modified: sandbox/itl/boost/itl/set.hpp
==============================================================================
--- sandbox/itl/boost/itl/set.hpp (original)
+++ sandbox/itl/boost/itl/set.hpp 2009-01-02 18:52:40 EST (Fri, 02 Jan 2009)
@@ -41,8 +41,8 @@
 #include <boost/itl/type_traits/is_set.hpp>
 #include <boost/itl/type_traits/is_interval_container.hpp>
 #include <boost/itl/type_traits/is_interval_splitter.hpp>
-#include <boost/itl/type_traits/is_neutron_absorber.hpp>
-#include <boost/itl/type_traits/is_neutron_emitter.hpp>
+#include <boost/itl/type_traits/absorbs_neutrons.hpp>
+#include <boost/itl/type_traits/emits_neutrons.hpp>
 #include <boost/itl/set_algo.hpp>
 #include <boost/itl/predicates.hpp>
 
@@ -80,6 +80,7 @@
 
     public:
         typedef DomainT domain_type;
+ typedef DomainT codomain_type;
         typedef DomainT key_type;
         typedef DomainT value_type;
         typedef DomainT data_type;
@@ -223,10 +224,8 @@
         return operator==((const base_type&)lhs, (const base_type&)rhs);
     }
 
- /** Element equality. Two sets are equal if they contain the same
- elements */
- template <typename DomainT, ITL_COMPARE Compare,
- ITL_ALLOC Alloc>
+ /** Element equality. Two sets are equal if they contain the same elements */
+ template <typename DomainT, ITL_COMPARE Compare, ITL_ALLOC Alloc>
     inline bool is_element_equal(const itl::set<DomainT,Compare,Alloc>& lhs,
                                  const itl::set<DomainT,Compare,Alloc>& rhs)
     {
@@ -235,8 +234,7 @@
     }
 
     /** Strict weak less ordering which is given by the Compare order */
- template <typename DomainT, ITL_COMPARE Compare,
- ITL_ALLOC Alloc>
+ template <typename DomainT, ITL_COMPARE Compare, ITL_ALLOC Alloc>
     inline bool operator < (const itl::set<DomainT,Compare,Alloc>& lhs,
                             const itl::set<DomainT,Compare,Alloc>& rhs)
     {
@@ -245,8 +243,7 @@
     }
 
     /** Partial ordering which is induced by Compare */
- template <typename DomainT, ITL_COMPARE Compare,
- ITL_ALLOC Alloc>
+ template <typename DomainT, ITL_COMPARE Compare, ITL_ALLOC Alloc>
     inline bool operator <= (const itl::set<DomainT,Compare,Alloc>& lhs,
         const itl::set<DomainT,Compare,Alloc>& rhs)
     {
@@ -255,8 +252,7 @@
     }
 
 
- template <typename DomainT, ITL_COMPARE Compare,
- ITL_ALLOC Alloc>
+ template <typename DomainT, ITL_COMPARE Compare, ITL_ALLOC Alloc>
     typename set<DomainT,Compare,Alloc>::iterator
         set<DomainT,Compare,Alloc>::subtract(const value_type& val)
     {
@@ -346,11 +342,11 @@
     { enum{value = false}; };
 
     template <class Type>
- struct is_neutron_absorber<itl::set<Type> >
+ struct absorbs_neutrons<itl::set<Type> >
     { enum{value = false}; };
 
     template <class Type>
- struct is_neutron_emitter<itl::set<Type> >
+ struct emits_neutrons<itl::set<Type> >
     { enum{value = false}; };
 
     template <class Type>

Modified: sandbox/itl/boost/itl/split_interval_map.hpp
==============================================================================
--- sandbox/itl/boost/itl/split_interval_map.hpp (original)
+++ sandbox/itl/boost/itl/split_interval_map.hpp 2009-01-02 18:52:40 EST (Fri, 02 Jan 2009)
@@ -286,8 +286,7 @@
     {
         CodomainT added_val = Combiner::neutron();
         Combiner()(added_val, value.CONT_VALUE);
-
- if(Traits::absorbs_neutrons && added_val == neutron<CodomainT>::value())
+ if(Traits::absorbs_neutrons && added_val == Combiner::neutron())
                         return;
                 else
             this->_map.insert(value_type(value.KEY_VALUE, added_val));
@@ -318,9 +317,7 @@
     {
         CodomainT added_val = Combiner::neutron();
         Combiner()(added_val, x_val);
- insertion = this->_map.insert(value_type(x_itv, added_val));
-
- if(Traits::absorbs_neutrons && added_val == neutron<CodomainT>::value())
+ if(Traits::absorbs_neutrons && added_val == Combiner::neutron())
                         return;
                 else
                         insertion = this->_map.insert(value_type(x_itv, added_val));
@@ -790,11 +787,11 @@
 { enum{value = true}; };
 
 template <class KeyT, class DataT, class Traits>
-struct is_neutron_absorber<itl::split_interval_map<KeyT,DataT,Traits> >
+struct absorbs_neutrons<itl::split_interval_map<KeyT,DataT,Traits> >
 { enum{value = Traits::absorbs_neutrons}; };
 
 template <class KeyT, class DataT, class Traits>
-struct is_neutron_emitter<itl::split_interval_map<KeyT,DataT,Traits> >
+struct emits_neutrons<itl::split_interval_map<KeyT,DataT,Traits> >
 { enum{value = Traits::emits_neutrons}; };
 
 template <class KeyT, class DataT, class Traits>

Modified: sandbox/itl/boost/itl/split_interval_set.hpp
==============================================================================
--- sandbox/itl/boost/itl/split_interval_set.hpp (original)
+++ sandbox/itl/boost/itl/split_interval_set.hpp 2009-01-02 18:52:40 EST (Fri, 02 Jan 2009)
@@ -430,11 +430,11 @@
     { enum{value = true}; };
 
     template <class Type>
- struct is_neutron_absorber<itl::split_interval_set<Type> >
+ struct absorbs_neutrons<itl::split_interval_set<Type> >
     { enum{value = false}; };
 
     template <class Type>
- struct is_neutron_emitter<itl::split_interval_set<Type> >
+ struct emits_neutrons<itl::split_interval_set<Type> >
     { enum{value = false}; };
 
     template <class Type>

Added: sandbox/itl/boost/itl/type_traits/absorbs_neutrons.hpp
==============================================================================
--- (empty file)
+++ sandbox/itl/boost/itl/type_traits/absorbs_neutrons.hpp 2009-01-02 18:52:40 EST (Fri, 02 Jan 2009)
@@ -0,0 +1,21 @@
+/*----------------------------------------------------------------------------+
+Copyright (c) 2008-2008: Joachim Faulhaber
++-----------------------------------------------------------------------------+
+ Distributed under the Boost Software License, Version 1.0.
+ (See accompanying file LICENCE.txt or copy at
+ http://www.boost.org/LICENSE_1_0.txt)
++----------------------------------------------------------------------------*/
+#ifndef __itl_type_traits_absorbs_neutrons_JOFA_081004_H__
+#define __itl_type_traits_absorbs_neutrons_JOFA_081004_H__
+
+namespace boost{ namespace itl
+{
+ template <class Type> struct absorbs_neutrons;
+
+ template <class Type> struct absorbs_neutrons{ enum {value = false}; };
+
+}} // namespace boost itl
+
+#endif
+
+

Added: sandbox/itl/boost/itl/type_traits/emits_neutrons.hpp
==============================================================================
--- (empty file)
+++ sandbox/itl/boost/itl/type_traits/emits_neutrons.hpp 2009-01-02 18:52:40 EST (Fri, 02 Jan 2009)
@@ -0,0 +1,21 @@
+/*----------------------------------------------------------------------------+
+Copyright (c) 2008-2008: Joachim Faulhaber
++-----------------------------------------------------------------------------+
+ Distributed under the Boost Software License, Version 1.0.
+ (See accompanying file LICENCE.txt or copy at
+ http://www.boost.org/LICENSE_1_0.txt)
++----------------------------------------------------------------------------*/
+#ifndef __itl_type_traits_emits_neutrons_JOFA_081004_H__
+#define __itl_type_traits_emits_neutrons_JOFA_081004_H__
+
+namespace boost{ namespace itl
+{
+ template <class Type> struct emits_neutrons;
+
+ template <class Type> struct emits_neutrons{ enum {value = false}; };
+
+}} // namespace boost itl
+
+#endif
+
+

Deleted: sandbox/itl/boost/itl/type_traits/is_neutron_absorber.hpp
==============================================================================
--- sandbox/itl/boost/itl/type_traits/is_neutron_absorber.hpp 2009-01-02 18:52:40 EST (Fri, 02 Jan 2009)
+++ (empty file)
@@ -1,21 +0,0 @@
-/*----------------------------------------------------------------------------+
-Copyright (c) 2008-2008: Joachim Faulhaber
-+-----------------------------------------------------------------------------+
- Distributed under the Boost Software License, Version 1.0.
- (See accompanying file LICENCE.txt or copy at
- http://www.boost.org/LICENSE_1_0.txt)
-+----------------------------------------------------------------------------*/
-#ifndef __itl_type_traits_is_neutron_absorber_JOFA_081004_H__
-#define __itl_type_traits_is_neutron_absorber_JOFA_081004_H__
-
-namespace boost{ namespace itl
-{
- template <class Type> struct is_neutron_absorber;
-
- template <class Type> struct is_neutron_absorber{ enum {value = false}; };
-
-}} // namespace boost itl
-
-#endif
-
-

Deleted: sandbox/itl/boost/itl/type_traits/is_neutron_emitter.hpp
==============================================================================
--- sandbox/itl/boost/itl/type_traits/is_neutron_emitter.hpp 2009-01-02 18:52:40 EST (Fri, 02 Jan 2009)
+++ (empty file)
@@ -1,21 +0,0 @@
-/*----------------------------------------------------------------------------+
-Copyright (c) 2008-2008: Joachim Faulhaber
-+-----------------------------------------------------------------------------+
- Distributed under the Boost Software License, Version 1.0.
- (See accompanying file LICENCE.txt or copy at
- http://www.boost.org/LICENSE_1_0.txt)
-+----------------------------------------------------------------------------*/
-#ifndef __itl_type_traits_is_neutron_emitter_JOFA_081004_H__
-#define __itl_type_traits_is_neutron_emitter_JOFA_081004_H__
-
-namespace boost{ namespace itl
-{
- template <class Type> struct is_neutron_emitter;
-
- template <class Type> struct is_neutron_emitter{ enum {value = false}; };
-
-}} // namespace boost itl
-
-#endif
-
-

Modified: sandbox/itl/boost/itl/type_traits/type_to_string.hpp
==============================================================================
--- sandbox/itl/boost/itl/type_traits/type_to_string.hpp (original)
+++ sandbox/itl/boost/itl/type_traits/type_to_string.hpp 2009-01-02 18:52:40 EST (Fri, 02 Jan 2009)
@@ -51,6 +51,8 @@
     template<>
     inline std::string type_to_string<int>::apply() { return "int"; }
     template<>
+ inline std::string type_to_string<unsigned int>::apply() { return "int+"; }
+ template<>
     inline std::string type_to_string<double>::apply() { return "double"; }
     template<>
     inline std::string type_to_string<std::string>::apply() { return "string"; }

Modified: sandbox/itl/boost/validate/gentor/gentorprofile.h
==============================================================================
--- sandbox/itl/boost/validate/gentor/gentorprofile.h (original)
+++ sandbox/itl/boost/validate/gentor/gentorprofile.h 2009-01-02 18:52:40 EST (Fri, 02 Jan 2009)
@@ -21,6 +21,8 @@
 
         void set_range_int(int lwb, int upb)
         { _range_int = interval<int>::rightopen(lwb, upb); }
+ void set_range_nat(nat lwb, nat upb)
+ { _range_nat = interval<nat>::rightopen(lwb, upb); }
         void set_range_double(double lwb, double upb)
         { _range_double = interval<double>::rightopen(lwb, upb); }
         void set_range_ContainerSize(int lwb, int upb)
@@ -35,6 +37,7 @@
         { _range_element_ContainerSize = interval<int>::rightopen(lwb, upb); }
 
         interval<int> range_int() { return _range_int; }
+ interval<nat> range_nat() { return _range_nat; }
         interval<double> range_double() { return _range_double; }
         interval<int> range_ContainerSize() { return _range_ContainerSize; }
         interval<int> range_interval_int() { return _range_interval_int; }
@@ -45,6 +48,7 @@
 
     private:
         interval<int> _range_int;
+ interval<nat> _range_nat;
         interval<double> _range_double;
         interval<int> _range_ContainerSize;
 
@@ -68,6 +72,7 @@
     // specific interface ---------------------------------------------------------
     public:
         void set_range_int(int lwb, int upb) { m_profile.set_range_int(lwb, upb); }
+ void set_range_nat(nat lwb, nat upb) { m_profile.set_range_nat(lwb, upb); }
         void set_range_double(double lwb, double upb) { m_profile.set_range_double(lwb, upb); }
         void set_range_ContainerSize(int lwb, int upb) { m_profile.set_range_ContainerSize(lwb, upb); }
         void set_range_interval_int(int lwb, int upb) { m_profile.set_range_interval_int(lwb, upb); }
@@ -77,6 +82,7 @@
                                                        { m_profile.set_range_element_ContainerSize(lwb, upb); }
 
         interval<int> range_int() { return m_profile.range_int(); }
+ interval<nat> range_nat() { return m_profile.range_nat(); }
         interval<double> range_double() { return m_profile.range_double(); }
         interval<int> range_ContainerSize() { return m_profile.range_ContainerSize(); }
         interval<int> range_interval_int() { return m_profile.range_interval_int(); }
@@ -109,6 +115,13 @@
     };
 
     template<>
+ struct GentorProfileSgl_numeric_range<nat>
+ {
+ static interval<nat> get()
+ { return GentorProfileSgl::it()->range_nat(); }
+ };
+
+ template<>
     struct GentorProfileSgl_numeric_range<double>
     {
         static interval<double> get()

Modified: sandbox/itl/boost/validate/gentor/randomgentor.h
==============================================================================
--- sandbox/itl/boost/validate/gentor/randomgentor.h (original)
+++ sandbox/itl/boost/validate/gentor/randomgentor.h 2009-01-02 18:52:40 EST (Fri, 02 Jan 2009)
@@ -10,6 +10,7 @@
 #pragma once
 
 
+#include <boost/itl/notate.hpp>
 #include <boost/itl_xt/numbergentor.hpp>
 #include <boost/itl_xt/setgentor.hpp>
 #include <boost/itl_xt/mapgentor.hpp>
@@ -28,6 +29,7 @@
     // ----------------------------------------------------------
     template <class ValueT> class RandomGentor;
     template <> class RandomGentor<int> : public NumberGentorT<int> {};
+ template <> class RandomGentor<nat> : public NumberGentorT<nat> {};
     template <> class RandomGentor<double> : public NumberGentorT<double> {};
 
     // ----- sets ----------------------------------------------------------------
@@ -121,6 +123,16 @@
     };
 
     template <>
+ struct Calibrater<nat, RandomGentor>
+ {
+ static void apply(RandomGentor<nat>& gentor)
+ {
+ // Set the range within which the sizes of the generated object varies.
+ gentor.setRange(GentorProfileSgl::it()->range_nat());
+ }
+ };
+
+ template <>
     struct Calibrater<double, RandomGentor>
     {
         static void apply(RandomGentor<double>& gentor)

Modified: sandbox/itl/boost/validate/laws/order.h
==============================================================================
--- sandbox/itl/boost/validate/laws/order.h (original)
+++ sandbox/itl/boost/validate/laws/order.h 2009-01-02 18:52:40 EST (Fri, 02 Jan 2009)
@@ -124,8 +124,8 @@
 
     // ---------------------------------------------------------------------------
     template <typename Type, template<class>class Relation>
- class Antisymmetry2
- : public Law<Antisymmetry2<Type,Relation>,
+ class Asymmetry
+ : public Law<Asymmetry<Type,Relation>,
                      LOKI_TYPELIST_2(Type,Type), LOKI_TYPELIST_1(Type)>
     {
         /** a < b => !(b < a)
@@ -133,13 +133,13 @@
         Output = ()
         */
     public:
- std::string name()const { return "Antisymmetry2"; }
+ std::string name()const { return "Asymmetry"; }
         std::string formula()const { return " a < b => !(b < a)"; }
 
         std::string typeString()const
         {
- return "Antisymmetry2<"+type_to_string<Type>::apply()+","
- +unary_template_to_string<Relation>::apply()+">";
+ return "Asymmetry<"+type_to_string<Type>::apply()+","
+ +unary_template_to_string<Relation>::apply()+">";
         }
 
     public:

Modified: sandbox/itl/boost/validate/laws/set_laws.h
==============================================================================
--- sandbox/itl/boost/validate/laws/set_laws.h (original)
+++ sandbox/itl/boost/validate/laws/set_laws.h 2009-01-02 18:52:40 EST (Fri, 02 Jan 2009)
@@ -17,25 +17,30 @@
 namespace boost{namespace itl
 {
 
- template <typename Type, template<class>class Equality = itl::std_equal>
- class InplaceUnionInvertability
- : public Law<InplaceUnionInvertability<Type>,
+ template <typename Type,
+ template<class>class Combiner = inplace_plus,
+ template<class>class Equality = itl::std_equal>
+ class InplaceSelfRemovability
+ : public Law<InplaceSelfRemovability<Type,Combiner,Equality>,
                      LOKI_TYPELIST_1(Type), LOKI_TYPELIST_2(Type,Type)>
     {
- /** a - a == 0
- computed using inplace operators +=
- Input = (a := inVal1, b := inVal2)
- Output = (lhs_result, rhs_result)
- */
+ //a - a == 0
+ //computed using inplace operators +=
+ //Input = (a := inVal1, b := inVal2)
+ //Output = (lhs_result, rhs_result)
 
     public:
- std::string name()const { return "InplaceUnionInvertability"; }
+ typedef typename inverse<Combiner<Type> >::type InverseCombinerT;
+
+ std::string name()const { return "InplaceSelfRemovability"; }
         std::string formula()const { return "a -= a; a == 0"; }
 
         std::string typeString()const
         {
- return "UnionInvertability<"+type_to_string<Type>::apply()+","
- +unary_template_to_string<Equality>::apply()+">";
+ return "SelfRemovability<"+type_to_string<Type>::apply()+","
+ +unary_template_to_string<Combiner>::apply()+","
+ +unary_template_to_string<Equality>::apply()
+ +">";
         }
 
     public:
@@ -43,9 +48,9 @@
         bool holds()
         {
             Type lhs = this->template getInputValue<operand_a>();
- lhs -= this->template getInputValue<operand_a>();
+ InverseCombinerT()(lhs, this->template getInputValue<operand_a>());
 
- Type rhs = Type();
+ Type rhs = Combiner<Type>::neutron();
 
             this->template setOutputValue<lhs_result>(lhs);
             this->template setOutputValue<rhs_result>(rhs);
@@ -53,11 +58,69 @@
             return Equality<Type>()(lhs, rhs);
         }
 
- bool debug_holds(){ return holds(); }
+ bool debug_holds()
+ {
+ return holds();
+ }
 
         size_t size()const { return value_size<Type>::apply(this->template getInputValue<operand_a>()); }
     };
 
+
+ template <typename Type,
+ template<class>class Combiner = inplace_plus,
+ template<class>class Equality = itl::std_equal>
+ class InplaceInverseRemovability
+ : public Law<InplaceInverseRemovability<Type,Combiner,Equality>,
+ LOKI_TYPELIST_1(Type), LOKI_TYPELIST_2(Type,Type)>
+ {
+ //(0 - a) + a == 0
+ //computed using inplace operators +=
+ //Input = (a := inVal1, b := inVal2)
+ //Output = (lhs_result, rhs_result)
+
+ public:
+ typedef typename inverse<Combiner<Type> >::type InverseCombinerT;
+
+ std::string name()const { return "InplaceInverseRemovability"; }
+ std::string formula()const { return "a -= a; a == 0"; }
+
+ std::string typeString()const
+ {
+ return "InverseRemovability<"+type_to_string<Type>::apply()+","
+ +unary_template_to_string<Combiner>::apply()+","
+ +unary_template_to_string<Equality>::apply()
+ +">";
+ }
+
+ public:
+
+ bool holds()
+ {
+ Type lhs = Combiner<Type>::neutron();
+ Type value_a = this->template getInputValue<operand_a>();
+ // lhs = (0 - a)
+ InverseCombinerT()(lhs, value_a);
+ // lhs = (0 - a) + a
+ Combiner<Type>()(lhs, value_a);
+
+ Type rhs = Combiner<Type>::neutron();
+
+ this->template setOutputValue<lhs_result>(lhs);
+ this->template setOutputValue<rhs_result>(rhs);
+
+ return Equality<Type>()(lhs, rhs);
+ }
+
+ bool debug_holds()
+ {
+ return holds();
+ }
+
+ size_t size()const { return value_size<Type>::apply(this->template getInputValue<operand_a>()); }
+ };
+
+
     // ---------------------------------------------------------------------------
     template <typename Type, template<class>class Operator1 = inplace_plus,
                              template<class>class Operator2 = inplace_star,
@@ -226,7 +289,8 @@
     // ---------------------------------------------------------------------------
     template <typename Type,
               template<class>class Operator1 = inplace_plus,
- template<class>class Operator2 = inplace_minus>
+ template<class>class Operator2 = inplace_minus,
+ template<class>class Equality = itl::std_equal>
     class InplaceRightDistributivity
         : public Law<InplaceRightDistributivity<Type,Operator1,Operator2>,
                      LOKI_TYPELIST_3(Type,Type,Type), LOKI_TYPELIST_2(Type,Type)>
@@ -244,7 +308,8 @@
         {
             return "RightDistributivity<"+type_to_string<Type>::apply()+","
                                          +unary_template_to_string<Operator1>::apply()+","
- +unary_template_to_string<Operator2>::apply()+">";
+ +unary_template_to_string<Operator2>::apply()+","
+ +unary_template_to_string<Equality>::apply() +">";
         }
 
     public:
@@ -280,7 +345,7 @@
             this->template setOutputValue<lhs_result>(lhs);
             this->template setOutputValue<rhs_result>(rhs);
 
- return lhs == rhs;
+ return Equality<Type>()(lhs, rhs);
         }
 
         bool debug_holds()
@@ -314,7 +379,7 @@
             this->template setOutputValue<lhs_result>(lhs);
             this->template setOutputValue<rhs_result>(rhs);
 
- return lhs == rhs;
+ return Equality<Type>()(lhs, rhs);
         }
     };
 
@@ -469,6 +534,99 @@
         }
     };
 
+ // ---------------------------------------------------------------------------
+ template <typename MapT>
+ class ProtonicEquality
+ : public Law<ProtonicEquality<MapT>,
+ LOKI_TYPELIST_2(MapT,MapT), LOKI_TYPELIST_2(bool,bool)>
+ {
+ /** (a.absorb_neutrons() == b.absorb_neutrons()) == is_protonic_equal(a, b)
+ Input = (a := inVal1, b := inVal2)
+ Output = (lhs_result, rhs_result)
+ */
+ public:
+ std::string name()const { return "ProtonicEquality"; }
+ std::string formula()const { return "(a.absorb_neutrons() == b.absorb_neutrons()) == is_protonic_equal(a, b)"; }
+
+ std::string typeString()const
+ {
+ return "ProtonicEquality<"+type_to_string<MapT>::apply()+">";
+ }
+
+ public:
+
+ bool holds()
+ {
+ // (a.absorb_neutrons() == b.absorb_neutrons()) == is_protonic_equal(a, b)
+ // --- left hand side ------------------------
+ // lhs := (a.absorb_neutrons() == b.absorb_neutrons())
+ MapT a = this->template getInputValue<operand_a>();
+ MapT a_protonic = a;
+ a_protonic.absorb_neutrons();
+ MapT b = this->template getInputValue<operand_b>();
+ MapT b_protonic = b;
+ b_protonic.absorb_neutrons();
+
+ bool lhs = a_protonic == b_protonic;
+
+ // --- right hand side -----------------------
+ // rhs := is_protonic_equal(a, b)
+ bool rhs = is_protonic_equal(a, b);
+
+ this->template setOutputValue<lhs_result>(lhs);
+ this->template setOutputValue<rhs_result>(rhs);
+
+ return lhs == rhs;
+ }
+
+ bool debug_holds()
+ {
+ // (a.absorb_neutrons() == b.absorb_neutrons()) == is_protonic_equal(a, b)
+ // --- left hand side ------------------------
+ // lhs := (a.absorb_neutrons() == b.absorb_neutrons())
+
+ cout << name() << "::debug_holds():" << endl;
+ cout << "Instance: " << typeString() << endl;
+ cout << "Formula: " << formula() << endl;
+
+ MapT a = this->template getInputValue<operand_a>();
+ MapT b = this->template getInputValue<operand_b>();
+
+ cout << "a: " << a.as_string() << endl;
+ cout << "b: " << b.as_string() << endl;
+
+ MapT a_protonic = a;
+ a_protonic.absorb_neutrons();
+ MapT b_protonic = b;
+ b_protonic.absorb_neutrons();
+
+ cout << "a.absorb_neutrons(): " << a_protonic.as_string() << endl;
+ cout << "b.absorb_neutrons(): " << b_protonic.as_string() << endl;
+
+ bool lhs = a_protonic == b_protonic;
+
+ cout << "lhs := (a.absorb_neutrons() == b.absorb_neutrons()): " << lhs << endl;
+
+ // --- right hand side -----------------------
+ // rhs := is_protonic_equal(a, b)
+ bool rhs = is_protonic_equal(a, b);
+
+ cout << "rhs := is_protonic_equal(a, b): " << rhs << endl;
+
+ this->template setOutputValue<lhs_result>(lhs);
+ this->template setOutputValue<rhs_result>(rhs);
+
+ return lhs == rhs;
+ }
+
+ size_t size()const
+ {
+ return
+ value_size<MapT>::apply(this->template getInputValue<operand_a>())+
+ value_size<MapT>::apply(this->template getInputValue<operand_b>());
+ }
+ };
+
 }} // namespace itl boost
 
 #endif // __itl_set_laws_h_JOFA_071124__

Modified: sandbox/itl/boost/validate/lawvalidater.h
==============================================================================
--- sandbox/itl/boost/validate/lawvalidater.h (original)
+++ sandbox/itl/boost/validate/lawvalidater.h 2009-01-02 18:52:40 EST (Fri, 02 Jan 2009)
@@ -49,7 +49,7 @@
         typedef typename Loki::tuple<gentor_types> input_gentor;
 
     public:
- LawValidater(){ setTrialsCount(1000); } //1000(std)//JODO config at only ONE location
+ LawValidater(){ setTrialsCount(250); } //1000(std)//JODO config at only ONE location
 
         void setTrialsCount(int trials)
         {

Modified: sandbox/itl/boost/validate/realmvalidater.h
==============================================================================
--- sandbox/itl/boost/validate/realmvalidater.h (original)
+++ sandbox/itl/boost/validate/realmvalidater.h 2009-01-02 18:52:40 EST (Fri, 02 Jan 2009)
@@ -13,94 +13,29 @@
 #include <stdio.h>
 #include <time.h>
 #include <boost/validate/typevalidater.h>
+#include <boost/validate/itl_validater.hpp>
 #include <boost/validate/utility.hpp>
 
 namespace boost{namespace itl
 {
- namespace RootType
- {
- enum RootTypes
- {
- itl_set, interval_set, separate_interval_set, split_interval_set,
- itl_map, interval_map, split_interval_map,
- Types_size
- };
- }
-
- namespace DomainType
- {
- enum DomainTypes { Int, Double, DomainTypes_size };
- }
-
- namespace CodomainType
- {
- enum CodomainTypes { Int, Double, set_int, CodomainTypes_size };
- }
-
- namespace NeutronHandlerType
- {
- enum NeutronHandlerTypes { absorber, enricher, emitter, NeutronHandlerTypes_size };
- }
-
     
- class RealmValidater
+ class RealmValidater : public itl_validater
     {
     public:
         RealmValidater() { setProfile(); }
 
- private:
- void setRootTypeNames()
- {
- std::vector<std::string> type_names(RootType::Types_size);
- type_names[RootType::itl_set] = "itl_set";
- type_names[RootType::interval_set] = "interval_set";
- type_names[RootType::separate_interval_set] = "separate_interval_set";
- type_names[RootType::split_interval_set] = "split_interval_set";
- type_names[RootType::itl_map] = "itl_map";
- type_names[RootType::interval_map] = "interval_map";
- type_names[RootType::split_interval_map] = "split_interval_map";
- _rootChoice.setTypeNames(type_names);
- }
- void setDomainTypeNames()
- {
- std::vector<std::string> type_names(CodomainType::CodomainTypes_size);
- type_names[CodomainType::Int] = "Int";
- type_names[CodomainType::Double] = "Double";
- _domainChoice.setTypeNames(type_names);
- }
- void setCodomainTypeNames()
- {
- std::vector<std::string> type_names(CodomainType::CodomainTypes_size);
- type_names[CodomainType::Int] = "Int";
- type_names[CodomainType::Double] = "Double";
- type_names[CodomainType::set_int] = "set_int";
- _codomainChoice.setTypeNames(type_names);
- }
-
- void setInvalid() { _isValid = false; }
-
- AlgebraValidater* choiceError(const std::string& location, int value, const ChoiceT& choice)
- {
- reportTypeChoiceError(location, value, choice);
- setInvalid();
- return NULL;
- }
-
- public:
- bool hasValidProfile()const { return _isValid; }
-
         void setProfile()
         {
- _isValid = true;
+ setValid(true);
             _rootChoice.setSize(RootType::Types_size);
             _rootChoice.setMaxWeights(100);
- _rootChoice[RootType::itl_set] = 0;
- _rootChoice[RootType::interval_set] = 0;
- _rootChoice[RootType::separate_interval_set] = 0;
- _rootChoice[RootType::split_interval_set] = 0;
- _rootChoice[RootType::itl_map] = 33;
- _rootChoice[RootType::interval_map] = 33;
- _rootChoice[RootType::split_interval_map] = 34;
+ _rootChoice[RootType::itl_set] = 14;
+ _rootChoice[RootType::interval_set] = 14;
+ _rootChoice[RootType::separate_interval_set] = 14;
+ _rootChoice[RootType::split_interval_set] = 14;
+ _rootChoice[RootType::itl_map] = 14;
+ _rootChoice[RootType::interval_map] = 15;
+ _rootChoice[RootType::split_interval_map] = 15;
             setRootTypeNames();
             _rootChoice.init();
 
@@ -119,26 +54,42 @@
             setCodomainTypeNames();
             _codomainChoice.init();
 
+ _neutronizerChoice.setSize(NeutronHandlerType::NeutronHandlerTypes_size);
+ _neutronizerChoice.setMaxWeights(100);
+ _neutronizerChoice[NeutronHandlerType::absorber] = 50;
+ _neutronizerChoice[NeutronHandlerType::enricher] = 50;
+ _neutronizerChoice[NeutronHandlerType::emitter] = 0;
+ _neutronizerChoice[NeutronHandlerType::polluter] = 0;
+ setNeutronHandlerTypeNames();
+ _neutronizerChoice.init();
+
             if(!_rootChoice.is_consistent())
             {
- setInvalid();
+ setValid(false);
                 std::cout << _rootChoice.inconsitencyMessage("RealmValidater::setProfile()") << std::endl;
             }
 
             if(!_domainChoice.is_consistent())
             {
- setInvalid();
+ setValid(false);
                 std::cout << _domainChoice.inconsitencyMessage("RealmValidater::setProfile()") << std::endl;
             }
 
             if(!_codomainChoice.is_consistent())
             {
- setInvalid();
+ setValid(false);
                 std::cout << _codomainChoice.inconsitencyMessage("RealmValidater::setProfile()") << std::endl;
             }
 
+ if(!_neutronizerChoice.is_consistent())
+ {
+ setValid(false);
+ std::cout << _neutronizerChoice.inconsitencyMessage("RealmValidater::setProfile()") << std::endl;
+ }
+
         }
 
+ /*CL
         void validate()
         {
             //srand(static_cast<unsigned>(time(NULL))); //Different numbers each run
@@ -157,12 +108,14 @@
                 validateType();
             }
         }
+ */
 
         AlgebraValidater* chooseValidater()
         {
- int rootChoice = _rootChoice.some();
- int domainChoice = _domainChoice.some();
- int codomainChoice = _codomainChoice.some();
+ int rootChoice = _rootChoice.some();
+ int domainChoice = _domainChoice.some();
+ int codomainChoice = _codomainChoice.some();
+ int neutronizerChoice = _neutronizerChoice.some();
 
             switch(rootChoice)
             {
@@ -199,13 +152,13 @@
                     }
                 }
             //-----------------------------------------------------------------
+ // Maps
+ //-----------------------------------------------------------------
             case RootType::itl_map: {
                 switch(domainChoice) {
                 case DomainType::Int:
                     switch(codomainChoice) {
- // than enricher maps have.
- case CodomainType::Int: return new InplaceMapValidater<itl::map<int,int,neutron_enricher> >;
- //case CodomainType::Double: return new InplaceMapValidater<itl::map<int,double,neutron_enricher> >;
+ case CodomainType::Int: return new InplaceMapValidater<itl::map<int,int> >;
                     case CodomainType::set_int: return new InplaceMapValidater<itl::map<int,itl::set<int> > >;
                     default: return choiceError(ITL_LOCATION("\nRootType::itl_map: codomainChoice:\n"),
                                                 codomainChoice, _codomainChoice);
@@ -214,8 +167,7 @@
                 case DomainType::Double:
                     switch(codomainChoice) {
                     case CodomainType::Int: return new InplaceMapValidater<itl::map<double,int,neutron_enricher> >;
- //case CodomainType::Double: return new InplaceMapValidater<itl::map<double,double,neutron_enricher> >;
- case CodomainType::set_int: return new InplaceMapValidater<itl::map<double,itl::set<int> > >;
+ case CodomainType::set_int: return new InplaceSetValidater<itl::map<double,itl::set<int>,neutron_enricher > >;
                     default: return choiceError(ITL_LOCATION("\nRootType::itl_map: codomainChoice:\n"),
                                                 codomainChoice, _codomainChoice);
                     }//switch codomain
@@ -229,18 +181,15 @@
                 switch(domainChoice) {
                 case DomainType::Int:
                     switch(codomainChoice) {
- //JODO SectionAbsorbtion has to be tested for all absorber maps
- case CodomainType::Int: return new IntervalMapValidater<interval_map<int,int,neutron_enricher> >;
- //case CodomainType::Double: return new IntervalMapValidater<interval_map<int,double,neutron_enricher> >;
+ case CodomainType::Int: return new IntervalMapValidater<interval_map<int,int,neutron_emitter> >;
                     case CodomainType::set_int: return new IntervalMapValidater<interval_map<int,itl::set<int> > >;
                     default: return choiceError(ITL_LOCATION("\nRootType::interval_map: codomainChoice:\n"),
                                                 codomainChoice, _codomainChoice);
                     }// switch codomain
                 case DomainType::Double:
                     switch(codomainChoice) {
- case CodomainType::Int: return new IntervalMapValidater<interval_map<double,int,neutron_enricher> >;
- //case CodomainType::Double: return new IntervalMapValidater<interval_map<double,double,neutron_enricher> >;
- case CodomainType::set_int: return new IntervalMapValidater<interval_map<double,itl::set<int> > >;
+ case CodomainType::Int: return new IntervalMapValidater<interval_map<double,int,neutron_polluter> >;
+ case CodomainType::set_int: return new IntervalMapValidater<interval_map<double,itl::set<int>,neutron_enricher > >;
                     default: return choiceError(ITL_LOCATION("\nRootType::interval_map: codomainChoice:\n"),
                                                 codomainChoice, _codomainChoice);
                     }// switch codomain
@@ -254,16 +203,14 @@
                 case DomainType::Int:
                     switch(codomainChoice) {
                     case CodomainType::Int: return new IntervalMapValidater<split_interval_map<int,int,neutron_enricher> >;
- //case CodomainType::Double: return new IntervalMapValidater<split_interval_map<int,double,neutron_enricher> >;
- case CodomainType::set_int: return new IntervalMapValidater<split_interval_map<int,itl::set<int> > >;
+ case CodomainType::set_int: return new IntervalMapValidater<split_interval_map<int,itl::set<int>,neutron_enricher> >;
                     default: return choiceError(ITL_LOCATION("\nRootType::split_interval_map: codomainChoice:\n"),
                                                 codomainChoice, _codomainChoice);
                     }
                 case DomainType::Double:
                     switch(codomainChoice) {
- case CodomainType::Int: return new IntervalMapValidater<split_interval_map<double,int,neutron_enricher> >;
- //case CodomainType::Double: return new IntervalMapValidater<split_interval_map<double,double,neutron_enricher> >;
- case CodomainType::set_int: return new IntervalMapValidater<split_interval_map<double,itl::set<int> > >;
+ case CodomainType::Int: return new IntervalMapValidater<split_interval_map<double,int,neutron_emitter> >;
+ case CodomainType::set_int: return new IntervalSetValidater<split_interval_map<double,itl::set<int> > >;
                     default: return choiceError(ITL_LOCATION("\nRootType::split_interval_map: codomainChoice:\n"),
                                                 codomainChoice, _codomainChoice);
                 }
@@ -279,74 +226,6 @@
             return NULL; //just to please the compiler ;)
         }
 
-
- void validateType()
- {
- _validater = chooseValidater();
- if(_validater)
- {
- _validater->validate();
- _validater->addFrequencies(_frequencies);
- _validater->addViolations(_violationsCount, _violations);
- delete _validater;
- }
- }
-
- void reportFrequencies()
- {
- std::cout << "------------------------------------------------------------------------------" << std::endl;
- int valid_count = 1;
- FORALL(ValidationCounterT, it, _frequencies)
- {
- printf("%3d %-66s%8d\n", valid_count, it->KEY_VALUE.c_str(), it->CONT_VALUE);
- valid_count++;
- }
- std::cout << "------------------------------------------------------------------------------" << std::endl;
- int violation_count = 1;
- FORALL(ViolationMapT, it, _violations)
- {
- printf("%3d %-66s%8d\n", violation_count, it->KEY_VALUE.c_str(), it->CONT_VALUE.getViolationsCount());
- violation_count++;
- }
- if(!_violations.empty())
- std::cout << "------------------------------------------------------------------------------" << std::endl;
- FORALL(ViolationMapT, it, _violations)
- {
- PolyLawViolations violas = it->CONT_VALUE;
- violas.reportFirst();
- }
- if(!_violations.empty())
- std::cout << "------------------------------------------------------------------------------" << std::endl;
- }
-
- void reportFrequencies(const std::string& filename)
- {
- FILE* fp = fopen(filename.c_str(), "w");
- int valid_count = 1;
- FORALL(ValidationCounterT, it, _frequencies)
- {
- fprintf(fp, "%3d %-66s\n", valid_count, it->KEY_VALUE.c_str());
- valid_count++;
- }
- }
-
- void reportTypeChoiceError(const std::string& location, int rootChoice, const ChoiceT& chooser)const
- {
- std::cout << location
- << "Type choice: " << rootChoice << " is out of range or unselectable in switch clause.\n"
- << "Expected types and their weights are:\n"
- << chooser.asString();
- }
-
- private:
- ChoiceT _rootChoice;
- ChoiceT _domainChoice;
- ChoiceT _codomainChoice;
- AlgebraValidater* _validater;
- ValidationCounterT _frequencies;
- ViolationCounterT _violationsCount;
- ViolationMapT _violations;
- bool _isValid;
     };
 
 

Modified: sandbox/itl/boost/validate/typevalidater.h
==============================================================================
--- sandbox/itl/boost/validate/typevalidater.h (original)
+++ sandbox/itl/boost/validate/typevalidater.h 2009-01-02 18:52:40 EST (Fri, 02 Jan 2009)
@@ -9,6 +9,8 @@
 +----------------------------------------------------------------------------*/
 #pragma once
 
+#include <boost/mpl/bool.hpp>
+#include <boost/mpl/if.hpp>
 #include <boost/itl/type_traits/is_continuous.hpp>
 #include <boost/itl/functors.hpp>
 #include <boost/itl/interval_morphism.hpp>
@@ -33,7 +35,7 @@
         enum Laws
         {
             transitivity,
- antisymmetry2,
+ asymmetry,
             irreflexivity,
             Laws_size
         };
@@ -45,7 +47,7 @@
             _lawChoice.setSize(Laws_size);
             _lawChoice.setMaxWeights(100);
             _lawChoice[transitivity] = 33;
- _lawChoice[antisymmetry2] = 33;
+ _lawChoice[asymmetry] = 33;
             _lawChoice[irreflexivity] = 34;
             _lawChoice.init();
         }
@@ -56,7 +58,7 @@
             switch(_lawChoice.some())
             {
             case transitivity: return new LawValidater<Transitivity <Type, Relation >, RandomGentor >;
- case antisymmetry2: return new LawValidater<Antisymmetry2<Type, Relation >, RandomGentor >;
+ case asymmetry: return new LawValidater<Asymmetry<Type, Relation >, RandomGentor >;
             case irreflexivity: return new LawValidater<Irreflexivity<Type, Relation >, RandomGentor >;
             default: return NULL;
             }
@@ -77,7 +79,7 @@
         void addFrequencies(ValidationCounterT& summary) { summary += _frequencies; }
         void addViolations(ViolationCounterT& summary, ViolationMapT& collector)
         {
- summary += _violationsCount;
+ summary += _violationsCount;
             collector += _violations;
         }
 
@@ -261,7 +263,7 @@
             //JODO _lawChoice[inplaceStarDistributivity] = 100; // only (map|cop)<set> NOT (map|cop)<group>
             //JODO _lawChoice[inplacePlusDeMorgan] = 100; // only (map|cop)<set> NOT (map|cop)<group>
             //JODO _lawChoice[inplaceStarDeMorgan] = 100; // only (map|cop)<set> NOT (map|cop)<group>
- //JODO _lawChoice[inplaceUnionInvertability] = 25; // only cop NOT map
+ //JODO _lawChoice[inplaceSelfRemovability] = 25; // only cop NOT map
             _lawChoice.init();
         }
 
@@ -274,16 +276,16 @@
             case partialStdOrder: return _lessEqualValidater.chooseValidater();
             case containedInOrder: return _containedInValidater.chooseValidater();
             case inplacePlusAssociativity:
- if( itl::is_interval_container<Type>::value && itl::is_interval_splitter<Type>::value
- && is_neutron_absorber<Type>::value && is_neutron_emitter<Type>::value)
+ if( itl::is_interval_container<Type>::value && itl::is_interval_splitter<Type>::value
+ && absorbs_neutrons<Type>::value && emits_neutrons<Type>::value)
                     return new LawValidater<InplaceAssociativity<Type, inplace_plus, element_equal>, RandomGentor>;
                 else
                     return new LawValidater<InplaceAssociativity<Type>, RandomGentor>;
             case inplacePlusNeutrality: return new LawValidater<InplaceNeutrality<Type>, RandomGentor>;
             case inplacePlusCommutativity: return new LawValidater<InplaceCommutativity<Type>, RandomGentor>;
             case inplaceStarAssociativity:
- if( is_interval_container<Type>::value && is_interval_splitter<Type>::value
- && is_neutron_absorber<Type>::value && is_neutron_emitter<Type>::value)
+ if( is_interval_container<Type>::value && is_interval_splitter<Type>::value
+ && absorbs_neutrons<Type>::value && emits_neutrons<Type>::value)
                     return new LawValidater<InplaceAssociativity<Type, inplace_star, element_equal>, RandomGentor>;
                 else
                     return new LawValidater<InplaceAssociativity<Type, inplace_star>, RandomGentor>;
@@ -325,60 +327,149 @@
     };
 
 
-
- template <typename Type>
- class InplaceMapValidater : public InplaceSetBaseValidater<Type>
+ template <typename Type>
+ class InplaceSetValidater : public InplaceSetBaseValidater<Type>
     {
     public:
         enum Laws
         {
             inplaceSetBaseLaws,
             inplaceSymmetricDifference,
- inplaceUnionInvertability,
- sectionAbsorbtion,
+ inplaceSelfRemovability,
+ inplacePlusDistributivity,
+ inplaceStarDistributivity,
+ inplacePlusDashRightDistrib,
+ inplaceStarDashRightDistrib,
+ inplacePlusDeMorgan,
+ inplaceStarDeMorgan,
             Laws_size
         };
 
- InplaceMapValidater() {setProfile();}
+ InplaceSetValidater() {setProfile();}
 
         void setProfile()
         {
             _lawChoice.setSize(Laws_size);
             _lawChoice.setMaxWeights(100);
- _lawChoice[inplaceSetBaseLaws] = 85;
- if(Type::has_symmetric_difference())
- {
- _lawChoice[inplaceSymmetricDifference] = 5;
- _lawChoice[inplaceUnionInvertability] = 5;
- _lawChoice[sectionAbsorbtion] = 5;
- }
- else
- {
- _lawChoice[inplaceSymmetricDifference] = 0;
- _lawChoice[inplaceUnionInvertability] = 7;
- _lawChoice[sectionAbsorbtion] = 8;
- }
+ _lawChoice[inplaceSetBaseLaws] = 44;
+ _lawChoice[inplaceSymmetricDifference] = 7;
+ _lawChoice[inplaceSelfRemovability] = 7;
+ _lawChoice[inplacePlusDistributivity] = 7;
+ _lawChoice[inplaceStarDistributivity] = 7;
+ _lawChoice[inplacePlusDashRightDistrib] = 7;
+ _lawChoice[inplaceStarDashRightDistrib] = 7;
+ _lawChoice[inplacePlusDeMorgan] = 7;
+ _lawChoice[inplaceStarDeMorgan] = 7;
             _lawChoice.init();
         }
 
 
         LawValidaterI* chooseValidater()
         {
- switch(_lawChoice.some())
+ int lawChoice = _lawChoice.some();
+ if(itl::is_map<Type>::value)
+ return chooseMapValidater(lawChoice);
+ else
+ return chooseSetValidater(lawChoice);
+ }
+
+ LawValidaterI* chooseMapValidater(int lawChoice)
+ {
+ switch(lawChoice)
             {
- case inplaceSetBaseLaws:
- return InplaceSetBaseValidater<Type>::chooseValidater();
- case inplaceSymmetricDifference:
- return new LawValidater<InplaceSymmetricDifference<Type>, RandomGentor>;
- case inplaceUnionInvertability:
- return new LawValidater<InplaceUnionInvertability<Type,itl::protonic_equal>, RandomGentor >;
- case sectionAbsorbtion:
- return new LawValidater<SectionAbsorbtion<Type,itl::protonic_equal>, RandomGentor>;
- default:
- return NULL;
+ case inplaceSetBaseLaws: return InplaceSetBaseValidater<Type>::chooseValidater();
+ case inplaceSymmetricDifference: return new LawValidater<InplaceSymmetricDifference<Type>, RandomGentor>;
+
+ case inplaceSelfRemovability:
+ if( itl::is_map<Type>::value && itl::is_set<typename Type::codomain_type>::value
+ && !absorbs_neutrons<Type>::value && !emits_neutrons<Type>::value)
+ return new
+ mpl::if_<mpl::bool_<is_map<Type>::value>,
+ LawValidater<InplaceSelfRemovability<Type, inplace_plus, protonic_equal>, RandomGentor>,
+ LawValidater<InplaceSelfRemovability<Type, inplace_plus, std_equal>, RandomGentor> >::type;
+ else
+ return new LawValidater<InplaceSelfRemovability<Type, inplace_plus, std_equal>, RandomGentor>;
+
+ case inplacePlusDistributivity:
+ if( itl::is_interval_container<Type>::value && itl::is_interval_splitter<Type>::value)
+ return new LawValidater<InplaceDistributivity<Type, inplace_plus, inplace_star, itl::element_equal>, RandomGentor>;
+ else
+ return new LawValidater<InplaceDistributivity<Type, inplace_plus, inplace_star, itl::std_equal>, RandomGentor>;
+
+ case inplaceStarDistributivity:
+ if( itl::is_interval_container<Type>::value && itl::is_interval_splitter<Type>::value
+ && absorbs_neutrons<Type>::value && !emits_neutrons<Type>::value)
+ return new LawValidater<InplaceDistributivity<Type, inplace_star, inplace_plus, element_equal>, RandomGentor>;
+ else
+ return new LawValidater<InplaceDistributivity<Type, inplace_star, inplace_plus, std_equal>, RandomGentor>;
+
+ case inplacePlusDashRightDistrib:
+ if( itl::is_interval_container<Type>::value && itl::is_interval_splitter<Type>::value
+ && absorbs_neutrons<Type>::value && !emits_neutrons<Type>::value)
+ return new LawValidater<InplaceRightDistributivity<Type, inplace_plus, inplace_minus, element_equal>, RandomGentor>;
+ else
+ return new LawValidater<InplaceRightDistributivity<Type, inplace_plus, inplace_minus, std_equal>, RandomGentor>;
+
+ case inplaceStarDashRightDistrib:
+ return new LawValidater<InplaceRightDistributivity<Type, inplace_star, inplace_minus>, RandomGentor>;
+
+ case inplacePlusDeMorgan:
+ return new LawValidater<InplaceDeMorgan<Type, inplace_plus, inplace_star, itl::std_equal>, RandomGentor>;
+
+ case inplaceStarDeMorgan:
+ if( itl::is_interval_container<Type>::value && itl::is_interval_splitter<Type>::value)
+ return new LawValidater<InplaceDeMorgan<Type, inplace_star, inplace_plus, itl::element_equal>, RandomGentor>;
+ else
+ return new LawValidater<InplaceDeMorgan<Type, inplace_star, inplace_plus, itl::std_equal>, RandomGentor>;
+
+ default: return NULL;
+ }
+ }
+
+
+ LawValidaterI* chooseSetValidater(int lawChoice)
+ {
+ switch(lawChoice)
+ {
+ case inplaceSetBaseLaws: return InplaceSetBaseValidater<Type>::chooseValidater();
+ case inplaceSymmetricDifference: return new LawValidater<InplaceSymmetricDifference<Type>, RandomGentor>;
+ case inplaceSelfRemovability: return new LawValidater<InplaceSelfRemovability<Type, inplace_plus, std_equal>, RandomGentor>;
+
+ case inplacePlusDistributivity:
+ if( itl::is_interval_container<Type>::value && itl::is_interval_splitter<Type>::value)
+ return new LawValidater<InplaceDistributivity<Type, inplace_plus, inplace_star, itl::element_equal>, RandomGentor>;
+ else
+ return new LawValidater<InplaceDistributivity<Type, inplace_plus, inplace_star, itl::std_equal>, RandomGentor>;
+
+ case inplaceStarDistributivity:
+ if( itl::is_interval_container<Type>::value && itl::is_interval_splitter<Type>::value)
+ return new LawValidater<InplaceDistributivity<Type, inplace_star, inplace_plus, element_equal>, RandomGentor>;
+ else
+ return new LawValidater<InplaceDistributivity<Type, inplace_star, inplace_plus, std_equal>, RandomGentor>;
+
+ case inplacePlusDashRightDistrib:
+ if( itl::is_interval_container<Type>::value && itl::is_interval_splitter<Type>::value)
+ return new LawValidater<InplaceRightDistributivity<Type, inplace_plus, inplace_minus, element_equal>, RandomGentor>;
+ else
+ return new LawValidater<InplaceRightDistributivity<Type, inplace_plus, inplace_minus, std_equal>, RandomGentor>;
+
+ case inplaceStarDashRightDistrib:
+ return new LawValidater<InplaceRightDistributivity<Type, inplace_star, inplace_minus>, RandomGentor>;
+
+ case inplacePlusDeMorgan:
+ return new LawValidater<InplaceDeMorgan<Type, inplace_plus, inplace_star, itl::std_equal>, RandomGentor>;
+
+ case inplaceStarDeMorgan:
+ if( itl::is_interval_container<Type>::value && itl::is_interval_splitter<Type>::value)
+ return new LawValidater<InplaceDeMorgan<Type, inplace_star, inplace_plus, itl::element_equal>, RandomGentor>;
+ else
+ return new LawValidater<InplaceDeMorgan<Type, inplace_star, inplace_plus, itl::std_equal>, RandomGentor>;
+
+ default: return NULL;
             }
         }
 
+
         void validate()
         {
             _validater = chooseValidater();
@@ -398,7 +489,6 @@
             collector += _violations;
         }
 
-
     private:
         ChoiceT _lawChoice;
         LawValidaterI* _validater;
@@ -408,39 +498,72 @@
     };
 
 
+
     template <typename Type>
- class InplaceSetValidater : public InplaceSetBaseValidater<Type>
+ class InplaceMapValidater :
+ public
+ mpl::if_
+ <
+ mpl::bool_<itl::is_set<typename Type::codomain_type>::value>,
+ InplaceSetValidater<Type>,
+ InplaceSetBaseValidater<Type>
+ >
+ ::type
     {
+ public:
+ typedef
+ typename mpl::if_
+ <
+ mpl::bool_<itl::is_set<typename Type::codomain_type>::value>,
+ InplaceSetValidater<Type>,
+ InplaceSetBaseValidater<Type>
+ >
+ ::type
+ SetValidaterT;
     public:
         enum Laws
         {
             inplaceSetBaseLaws,
             inplaceSymmetricDifference,
- inplaceUnionInvertability,
- inplacePlusDistributivity,
- inplaceStarDistributivity,
- inplacePlusDashRightDistrib,
- inplaceStarDashRightDistrib,
- inplacePlusDeMorgan,
- inplaceStarDeMorgan,
+ inplaceSelfRemovability,
+ inplaceInverseRemovability,
+ sectionAbsorbtion,
             Laws_size
         };
 
- InplaceSetValidater() {setProfile();}
+ InplaceMapValidater() {setProfile();}
 
         void setProfile()
         {
             _lawChoice.setSize(Laws_size);
             _lawChoice.setMaxWeights(100);
- _lawChoice[inplaceSetBaseLaws] = 44;
- _lawChoice[inplaceSymmetricDifference] = 7;
- _lawChoice[inplaceUnionInvertability] = 7;
- _lawChoice[inplacePlusDistributivity] = 7;
- _lawChoice[inplaceStarDistributivity] = 7;
- _lawChoice[inplacePlusDashRightDistrib] = 7;
- _lawChoice[inplaceStarDashRightDistrib] = 7;
- _lawChoice[inplacePlusDeMorgan] = 7;
- _lawChoice[inplaceStarDeMorgan] = 7;
+
+ if(is_set<typename Type::codomain_type>::value)
+ {
+ _lawChoice[inplaceSetBaseLaws] = 95;
+ _lawChoice[inplaceSymmetricDifference] = 0; // Is validated in base class
+ _lawChoice[inplaceSelfRemovability] = 0; // Is validated in base class
+ _lawChoice[inplaceInverseRemovability] = 0; // Is not valid for sets
+ _lawChoice[sectionAbsorbtion] = 5;
+ }
+ else if(!emits_neutrons<Type>::value)
+ {
+ //JODO A map of group values that does not emit neutrons always has a symmetric difference
+ BOOST_ASSERT(Type::has_symmetric_difference());
+ _lawChoice[inplaceSetBaseLaws] = 85;
+ _lawChoice[inplaceSymmetricDifference] = 5;
+ _lawChoice[inplaceSelfRemovability] = 5;
+ _lawChoice[inplaceInverseRemovability] = 0;
+ _lawChoice[sectionAbsorbtion] = 5;
+ }
+ else // !is_set && emits_neutrons //JODO && is_abelian_group<Type::value>
+ {
+ _lawChoice[inplaceSetBaseLaws] = 85;
+ _lawChoice[inplaceSymmetricDifference] = 0;
+ _lawChoice[inplaceSelfRemovability] = 5;
+ _lawChoice[inplaceInverseRemovability] = 5;
+ _lawChoice[sectionAbsorbtion] = 5;
+ }
             _lawChoice.init();
         }
 
@@ -449,16 +572,31 @@
         {
             switch(_lawChoice.some())
             {
- case inplaceSetBaseLaws: return InplaceSetBaseValidater<Type>::chooseValidater();
- case inplaceSymmetricDifference: return new LawValidater<InplaceSymmetricDifference<Type>, RandomGentor>;
- case inplaceUnionInvertability: return new LawValidater<InplaceUnionInvertability<Type>, RandomGentor>;
- case inplacePlusDistributivity: return new LawValidater<InplaceDistributivity<Type, inplace_plus, inplace_star, itl::element_equal>, RandomGentor>;
- case inplaceStarDistributivity: return new LawValidater<InplaceDistributivity<Type, inplace_star, inplace_plus>, RandomGentor>;
- case inplacePlusDashRightDistrib:return new LawValidater<InplaceRightDistributivity<Type, inplace_plus, inplace_minus>, RandomGentor>;
- case inplaceStarDashRightDistrib:return new LawValidater<InplaceRightDistributivity<Type, inplace_star, inplace_minus>, RandomGentor>;
- case inplacePlusDeMorgan: return new LawValidater<InplaceDeMorgan<Type, inplace_plus, inplace_star, itl::element_equal>, RandomGentor>;
- case inplaceStarDeMorgan: return new LawValidater<InplaceDeMorgan<Type, inplace_star, inplace_plus, itl::element_equal>, RandomGentor>;
- default: return NULL;
+ case inplaceSetBaseLaws:
+ return SetValidaterT::chooseValidater();
+ case inplaceSymmetricDifference:
+ return new LawValidater<InplaceSymmetricDifference<Type>, RandomGentor>;
+
+ case inplaceSelfRemovability:
+ if(is_map<Type>::value && !absorbs_neutrons<Type>::value)
+ return new LawValidater<InplaceSelfRemovability<Type, inplace_plus, protonic_equal>, RandomGentor >;
+ else
+ return new LawValidater<InplaceSelfRemovability<Type, inplace_plus, std_equal>, RandomGentor >;
+
+ case inplaceInverseRemovability:
+ if(is_map<Type>::value && !absorbs_neutrons<Type>::value)
+ return new LawValidater<InplaceInverseRemovability<Type, inplace_plus, protonic_equal>, RandomGentor >;
+ else
+ return new LawValidater<InplaceInverseRemovability<Type, inplace_plus, std_equal>, RandomGentor >;
+
+ case sectionAbsorbtion:
+ if(is_map<Type>::value && !absorbs_neutrons<Type>::value)
+ return new LawValidater<SectionAbsorbtion<Type,protonic_equal>, RandomGentor>;
+ else
+ return new LawValidater<SectionAbsorbtion<Type,std_equal>, RandomGentor>;
+
+ default:
+ return NULL;
             }
         }
 
@@ -481,6 +619,7 @@
             collector += _violations;
         }
 
+
     private:
         ChoiceT _lawChoice;
         LawValidaterI* _validater;
@@ -490,6 +629,7 @@
     };
 
 
+
     template <typename Type>
     class IntervalMorphicValidater : public AlgebraValidater
     {

Added: sandbox/itl/boost/validate/utility.hpp
==============================================================================
--- (empty file)
+++ sandbox/itl/boost/validate/utility.hpp 2009-01-02 18:52:40 EST (Fri, 02 Jan 2009)
@@ -0,0 +1,28 @@
+/*----------------------------------------------------------------------------+
+A Law Based Test Automaton 'LaBatea'
+Author: Joachim Faulhaber
+Copyright (c) 2007-2008: Joachim Faulhaber
++-----------------------------------------------------------------------------+
+ Distributed under the Boost Software License, Version 1.0.
+ (See accompanying file LICENCE.txt or copy at
+ http://www.boost.org/LICENSE_1_0.txt)
++----------------------------------------------------------------------------*/
+#pragma once
+
+#include <iostream>
+#include <stdio.h>
+
+#define ITL_LOCATION(message) location(__FILE__,__LINE__,message)
+
+namespace boost{namespace itl
+{
+ std::string location(const std::string& file, int line, const std::string& message)
+ {
+ std::string result = file;
+ result += "(" + to_string<int>::apply(line) + "): ";
+ result += message;
+ return result;
+ }
+
+}} // namespace itl boost
+

Modified: sandbox/itl/libs/itl/build/win32/vc9_all.sln
==============================================================================
--- sandbox/itl/libs/itl/build/win32/vc9_all.sln (original)
+++ sandbox/itl/libs/itl/build/win32/vc9_all.sln 2009-01-02 18:52:40 EST (Fri, 02 Jan 2009)
@@ -47,6 +47,12 @@
 EndProject
 Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "vc9_meta_functors", "..\..\..\itl_xt\test\meta_functors\vc9_meta_functors.vcproj", "{EF64A2C7-DE78-46C2-953F-C4685A5D2A98}"
 EndProject
+Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "vc9_labat_itv_map_settic", "..\..\..\validate\example\labat_itv_map_settic\vc9_labat_itv_map_settic.vcproj", "{BF42574F-66E2-42DD-90D9-3A8FCE6F471A}"
+EndProject
+Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "vc9_labat_itv_map_groupig", "..\..\..\validate\example\labat_itv_map_groupig\vc9_labat_itv_map_groupig.vcproj", "{BF42574F-66E2-42DD-90D9-3A8FCE6F471B}"
+EndProject
+Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "vc9_labat_single", "..\..\..\validate\example\labat_single\vc9_labat_single.vcproj", "{BF42574F-66E2-42DD-90D9-3A8FCE6F471C}"
+EndProject
 Global
         GlobalSection(SolutionConfigurationPlatforms) = preSolution
                 Debug|Win32 = Debug|Win32
@@ -145,6 +151,18 @@
                 {EF64A2C7-DE78-46C2-953F-C4685A5D2A98}.Debug|Win32.Build.0 = Debug|Win32
                 {EF64A2C7-DE78-46C2-953F-C4685A5D2A98}.Release|Win32.ActiveCfg = Release|Win32
                 {EF64A2C7-DE78-46C2-953F-C4685A5D2A98}.Release|Win32.Build.0 = Release|Win32
+ {BF42574F-66E2-42DD-90D9-3A8FCE6F471A}.Debug|Win32.ActiveCfg = Debug|Win32
+ {BF42574F-66E2-42DD-90D9-3A8FCE6F471A}.Debug|Win32.Build.0 = Debug|Win32
+ {BF42574F-66E2-42DD-90D9-3A8FCE6F471A}.Release|Win32.ActiveCfg = Release|Win32
+ {BF42574F-66E2-42DD-90D9-3A8FCE6F471A}.Release|Win32.Build.0 = Release|Win32
+ {BF42574F-66E2-42DD-90D9-3A8FCE6F471B}.Debug|Win32.ActiveCfg = Debug|Win32
+ {BF42574F-66E2-42DD-90D9-3A8FCE6F471B}.Debug|Win32.Build.0 = Debug|Win32
+ {BF42574F-66E2-42DD-90D9-3A8FCE6F471B}.Release|Win32.ActiveCfg = Release|Win32
+ {BF42574F-66E2-42DD-90D9-3A8FCE6F471B}.Release|Win32.Build.0 = Release|Win32
+ {BF42574F-66E2-42DD-90D9-3A8FCE6F471C}.Debug|Win32.ActiveCfg = Debug|Win32
+ {BF42574F-66E2-42DD-90D9-3A8FCE6F471C}.Debug|Win32.Build.0 = Debug|Win32
+ {BF42574F-66E2-42DD-90D9-3A8FCE6F471C}.Release|Win32.ActiveCfg = Release|Win32
+ {BF42574F-66E2-42DD-90D9-3A8FCE6F471C}.Release|Win32.Build.0 = Release|Win32
         EndGlobalSection
         GlobalSection(SolutionProperties) = preSolution
                 HideSolutionNode = FALSE

Modified: sandbox/itl/libs/itl/doc/interface.qbk
==============================================================================
--- sandbox/itl/libs/itl/doc/interface.qbk (original)
+++ sandbox/itl/libs/itl/doc/interface.qbk 2009-01-02 18:52:40 EST (Fri, 02 Jan 2009)
@@ -228,6 +228,23 @@
 `[2,43) == [2,42]`. Such computations always need only
 one in- or decrementation, if `DomainT` is an integral type.
 
+[h5 Requirements on Interval]
+
+Requirements on the `Interval` parameter are closely related to the
+`DomainT` parameter. `template Interval` has two template parameters
+itself for an element type and a compare order and it is of course
+internally always instantiated as `Interval<DomainT,Compare>`.
+`Interval<DomainT,Compare>` then has to implement an order called
+`exclusive_less`. Two intervals `x, y` are exclusive_less
+``x.exclusive_less(y)``
+if all `DomainT` elements of `x` are less than elements of `y` in the
+`Compare` order.
+
+[table
+[[Parameter] [Operators] [Requirement] ]
+[[`Interval`] [`exclusive_less`] [`IsExclusiveLessComparable<Interval<DomainT,Compare> >`] ]
+]
+
 [h4 Requirements on CodomainT]
 
 Summarized in the next table are requirements for template parameter

Added: sandbox/itl/libs/validate/example/labat_itv_map_groupig/labat_itv_map_groupig.cpp
==============================================================================
--- (empty file)
+++ sandbox/itl/libs/validate/example/labat_itv_map_groupig/labat_itv_map_groupig.cpp 2009-01-02 18:52:40 EST (Fri, 02 Jan 2009)
@@ -0,0 +1,52 @@
+/*----------------------------------------------------------------------------+
+A Law Based Test Automaton 'LaBatea'
+Author: Joachim Faulhaber
+Copyright (c) 2007-2008: Joachim Faulhaber
++-----------------------------------------------------------------------------+
+ Distributed under the Boost Software License, Version 1.0.
+ (See accompanying file LICENCE.txt or copy at
+ http://www.boost.org/LICENSE_1_0.txt)
++----------------------------------------------------------------------------*/
+#include <iostream>
+#include <stdio.h>
+
+#include <boost/itl/ptime.hpp> //CL (4 a quick test only)
+
+#include <boost/validate/loki_xt/Tuple.h>
+#include <boost/itl/set.hpp>
+#include <boost/itl/map.hpp>
+#include <boost/validate/lawvalidater.h>
+#include <boost/validate/laws/monoid.h>
+#include <boost/validate/gentor/gentorprofile.h>
+#include <boost/validate/gentor/rangegentor.h>
+
+#include <boost/validate/itv_map_groupig_validater.hpp>
+#include <boost/itl/interval_set.hpp>
+#include <boost/itl_xt/numbergentor.hpp>
+#include <boost/itl_xt/setgentor.hpp>
+#include <boost/itl/functors.hpp>
+
+using namespace std;
+using namespace Loki;
+using namespace boost;
+using namespace boost::itl;
+using namespace boost::posix_time;
+
+void test_ItvMapGroupigValidater()
+{
+ ItvMapGroupigValidater validater;
+ cout <<
+ ">> ------------------------------------------------------ <<\n"
+ ">> -------- Law based test automaton 'LaBatea' ---------- <<\n"
+ ">> Output will be generated in a few seconds\n"
+ ">> terminate by typing <CTRL>C\n"
+ ">> ------------------------------------------------------ <<\n";
+ validater.validate();
+};
+
+
+int main()
+{
+ test_ItvMapGroupigValidater();
+ return 0;
+}

Added: sandbox/itl/libs/validate/example/labat_itv_map_groupig/vc9_labat_itv_map_groupig.vcproj
==============================================================================
--- (empty file)
+++ sandbox/itl/libs/validate/example/labat_itv_map_groupig/vc9_labat_itv_map_groupig.vcproj 2009-01-02 18:52:40 EST (Fri, 02 Jan 2009)
@@ -0,0 +1,247 @@
+<?xml version="1.0" encoding="Windows-1252"?>
+<VisualStudioProject
+ ProjectType="Visual C++"
+ Version="9,00"
+ Name="vc9_labat_itv_map_groupig"
+ ProjectGUID="{BF42574F-66E2-42DD-90D9-3A8FCE6F471B}"
+ RootNamespace="vc9_labat_itv_map_groupig"
+ Keyword="Win32Proj"
+ TargetFrameworkVersion="131072"
+ >
+ <Platforms>
+ <Platform
+ Name="Win32"
+ />
+ </Platforms>
+ <ToolFiles>
+ </ToolFiles>
+ <Configurations>
+ <Configuration
+ Name="Debug|Win32"
+ OutputDirectory="../../../../bin/debug"
+ IntermediateDirectory="../../../../bin/obj/$(ProjectName)/debug"
+ ConfigurationType="1"
+ CharacterSet="1"
+ >
+ <Tool
+ Name="VCPreBuildEventTool"
+ />
+ <Tool
+ Name="VCCustomBuildTool"
+ />
+ <Tool
+ Name="VCXMLDataGeneratorTool"
+ />
+ <Tool
+ Name="VCWebServiceProxyGeneratorTool"
+ />
+ <Tool
+ Name="VCMIDLTool"
+ />
+ <Tool
+ Name="VCCLCompilerTool"
+ Optimization="0"
+ AdditionalIncludeDirectories="../../../../; ../../../../boost_1_35_0"
+ PreprocessorDefinitions="WIN32;_DEBUG;_CONSOLE"
+ MinimalRebuild="true"
+ BasicRuntimeChecks="3"
+ RuntimeLibrary="3"
+ UsePrecompiledHeader="0"
+ WarningLevel="3"
+ Detect64BitPortabilityProblems="false"
+ DebugInformationFormat="4"
+ />
+ <Tool
+ Name="VCManagedResourceCompilerTool"
+ />
+ <Tool
+ Name="VCResourceCompilerTool"
+ />
+ <Tool
+ Name="VCPreLinkEventTool"
+ />
+ <Tool
+ Name="VCLinkerTool"
+ LinkIncremental="2"
+ AdditionalLibraryDirectories="../../../../lib; ../../../../stage/lib"
+ GenerateDebugInformation="true"
+ SubSystem="1"
+ RandomizedBaseAddress="1"
+ DataExecutionPrevention="0"
+ TargetMachine="1"
+ />
+ <Tool
+ Name="VCALinkTool"
+ />
+ <Tool
+ Name="VCManifestTool"
+ />
+ <Tool
+ Name="VCXDCMakeTool"
+ />
+ <Tool
+ Name="VCBscMakeTool"
+ />
+ <Tool
+ Name="VCFxCopTool"
+ />
+ <Tool
+ Name="VCAppVerifierTool"
+ />
+ <Tool
+ Name="VCPostBuildEventTool"
+ />
+ </Configuration>
+ <Configuration
+ Name="Release|Win32"
+ OutputDirectory="../../../../bin/release"
+ IntermediateDirectory="../../../../bin/obj/$(ProjectName)/release"
+ ConfigurationType="1"
+ CharacterSet="1"
+ WholeProgramOptimization="1"
+ >
+ <Tool
+ Name="VCPreBuildEventTool"
+ />
+ <Tool
+ Name="VCCustomBuildTool"
+ />
+ <Tool
+ Name="VCXMLDataGeneratorTool"
+ />
+ <Tool
+ Name="VCWebServiceProxyGeneratorTool"
+ />
+ <Tool
+ Name="VCMIDLTool"
+ />
+ <Tool
+ Name="VCCLCompilerTool"
+ WholeProgramOptimization="true"
+ AdditionalIncludeDirectories="../../../../; ../../../../boost_1_35_0"
+ PreprocessorDefinitions="WIN32;NDEBUG;_CONSOLE"
+ ExceptionHandling="1"
+ RuntimeLibrary="2"
+ UsePrecompiledHeader="0"
+ WarningLevel="3"
+ Detect64BitPortabilityProblems="false"
+ DebugInformationFormat="3"
+ />
+ <Tool
+ Name="VCManagedResourceCompilerTool"
+ />
+ <Tool
+ Name="VCResourceCompilerTool"
+ />
+ <Tool
+ Name="VCPreLinkEventTool"
+ />
+ <Tool
+ Name="VCLinkerTool"
+ LinkIncremental="1"
+ AdditionalLibraryDirectories="../../../../lib; ../../../../stage/lib"
+ GenerateDebugInformation="true"
+ SubSystem="1"
+ OptimizeReferences="2"
+ EnableCOMDATFolding="2"
+ LinkTimeCodeGeneration="1"
+ RandomizedBaseAddress="1"
+ DataExecutionPrevention="0"
+ TargetMachine="1"
+ />
+ <Tool
+ Name="VCALinkTool"
+ />
+ <Tool
+ Name="VCManifestTool"
+ />
+ <Tool
+ Name="VCXDCMakeTool"
+ />
+ <Tool
+ Name="VCBscMakeTool"
+ />
+ <Tool
+ Name="VCFxCopTool"
+ />
+ <Tool
+ Name="VCAppVerifierTool"
+ />
+ <Tool
+ Name="VCPostBuildEventTool"
+ />
+ </Configuration>
+ </Configurations>
+ <References>
+ </References>
+ <Files>
+ <Filter
+ Name="Quelldateien"
+ Filter="cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx"
+ UniqueIdentifier="{4FC737F1-C7A5-4376-A066-2A32D752A2FF}"
+ >
+ <File
+ RelativePath="..\..\src\gentor\gentorprofile.cpp"
+ >
+ </File>
+ <File
+ RelativePath="..\labat_itv_map_groupig\labat_itv_map_groupig.cpp"
+ >
+ </File>
+ </Filter>
+ <Filter
+ Name="Headerdateien"
+ Filter="h;hpp;hxx;hm;inl;inc;xsd"
+ UniqueIdentifier="{93995380-89BD-4b04-88EB-625FBE52EBFB}"
+ >
+ <File
+ RelativePath="..\..\..\..\boost\validate\law.h"
+ >
+ </File>
+ <File
+ RelativePath="..\..\..\..\boost\validate\lawvalidater.h"
+ >
+ </File>
+ <File
+ RelativePath="..\..\..\..\boost\validate\lawviolations.h"
+ >
+ </File>
+ <File
+ RelativePath="..\..\..\..\boost\validate\laws\monoid.h"
+ >
+ </File>
+ <File
+ RelativePath="..\..\..\..\boost\validate\laws\order.h"
+ >
+ </File>
+ <File
+ RelativePath="..\..\..\..\boost\validate\laws\pushouts.h"
+ >
+ </File>
+ <File
+ RelativePath="..\..\..\..\boost\validate\realmvalidater.h"
+ >
+ </File>
+ <File
+ RelativePath="..\..\..\..\boost\validate\laws\set_laws.h"
+ >
+ </File>
+ <File
+ RelativePath="..\..\..\..\boost\validate\typevalidater.h"
+ >
+ </File>
+ </Filter>
+ <Filter
+ Name="Ressourcendateien"
+ Filter="rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx;tiff;tif;png;wav"
+ UniqueIdentifier="{67DA6AB6-F800-4c08-8B7A-83BB121AAD01}"
+ >
+ </Filter>
+ <File
+ RelativePath=".\ReadMe.txt"
+ >
+ </File>
+ </Files>
+ <Globals>
+ </Globals>
+</VisualStudioProject>

Added: sandbox/itl/libs/validate/example/labat_itv_map_settic/labat_itv_map_settic.cpp
==============================================================================
--- (empty file)
+++ sandbox/itl/libs/validate/example/labat_itv_map_settic/labat_itv_map_settic.cpp 2009-01-02 18:52:40 EST (Fri, 02 Jan 2009)
@@ -0,0 +1,52 @@
+/*----------------------------------------------------------------------------+
+A Law Based Test Automaton 'LaBatea'
+Author: Joachim Faulhaber
+Copyright (c) 2007-2008: Joachim Faulhaber
++-----------------------------------------------------------------------------+
+ Distributed under the Boost Software License, Version 1.0.
+ (See accompanying file LICENCE.txt or copy at
+ http://www.boost.org/LICENSE_1_0.txt)
++----------------------------------------------------------------------------*/
+#include <iostream>
+#include <stdio.h>
+
+#include <boost/itl/ptime.hpp> //CL (4 a quick test only)
+
+#include <boost/validate/loki_xt/Tuple.h>
+#include <boost/itl/set.hpp>
+#include <boost/itl/map.hpp>
+#include <boost/validate/lawvalidater.h>
+#include <boost/validate/laws/monoid.h>
+#include <boost/validate/gentor/gentorprofile.h>
+#include <boost/validate/gentor/rangegentor.h>
+
+#include <boost/validate/itv_map_settic_validater.hpp>
+#include <boost/itl/interval_set.hpp>
+#include <boost/itl_xt/numbergentor.hpp>
+#include <boost/itl_xt/setgentor.hpp>
+#include <boost/itl/functors.hpp>
+
+using namespace std;
+using namespace Loki;
+using namespace boost;
+using namespace boost::itl;
+using namespace boost::posix_time;
+
+void test_ItvMapSetticValidater()
+{
+ ItvMapSetticValidater validater;
+ cout <<
+ ">> ------------------------------------------------------ <<\n"
+ ">> -------- Law based test automaton 'LaBatea' ---------- <<\n"
+ ">> Output will be generated in a few seconds\n"
+ ">> terminate by typing <CTRL>C\n"
+ ">> ------------------------------------------------------ <<\n";
+ validater.validate();
+};
+
+
+int main()
+{
+ test_ItvMapSetticValidater();
+ return 0;
+}

Added: sandbox/itl/libs/validate/example/labat_itv_map_settic/vc9_labat_itv_map_settic.vcproj
==============================================================================
--- (empty file)
+++ sandbox/itl/libs/validate/example/labat_itv_map_settic/vc9_labat_itv_map_settic.vcproj 2009-01-02 18:52:40 EST (Fri, 02 Jan 2009)
@@ -0,0 +1,247 @@
+<?xml version="1.0" encoding="Windows-1252"?>
+<VisualStudioProject
+ ProjectType="Visual C++"
+ Version="9,00"
+ Name="vc9_labat_itv_map_settic"
+ ProjectGUID="{BF42574F-66E2-42DD-90D9-3A8FCE6F471A}"
+ RootNamespace="vc9_labat_itv_map_settic"
+ Keyword="Win32Proj"
+ TargetFrameworkVersion="131072"
+ >
+ <Platforms>
+ <Platform
+ Name="Win32"
+ />
+ </Platforms>
+ <ToolFiles>
+ </ToolFiles>
+ <Configurations>
+ <Configuration
+ Name="Debug|Win32"
+ OutputDirectory="../../../../bin/debug"
+ IntermediateDirectory="../../../../bin/obj/$(ProjectName)/debug"
+ ConfigurationType="1"
+ CharacterSet="1"
+ >
+ <Tool
+ Name="VCPreBuildEventTool"
+ />
+ <Tool
+ Name="VCCustomBuildTool"
+ />
+ <Tool
+ Name="VCXMLDataGeneratorTool"
+ />
+ <Tool
+ Name="VCWebServiceProxyGeneratorTool"
+ />
+ <Tool
+ Name="VCMIDLTool"
+ />
+ <Tool
+ Name="VCCLCompilerTool"
+ Optimization="0"
+ AdditionalIncludeDirectories="../../../../; ../../../../boost_1_35_0"
+ PreprocessorDefinitions="WIN32;_DEBUG;_CONSOLE"
+ MinimalRebuild="true"
+ BasicRuntimeChecks="3"
+ RuntimeLibrary="3"
+ UsePrecompiledHeader="0"
+ WarningLevel="3"
+ Detect64BitPortabilityProblems="false"
+ DebugInformationFormat="4"
+ />
+ <Tool
+ Name="VCManagedResourceCompilerTool"
+ />
+ <Tool
+ Name="VCResourceCompilerTool"
+ />
+ <Tool
+ Name="VCPreLinkEventTool"
+ />
+ <Tool
+ Name="VCLinkerTool"
+ LinkIncremental="2"
+ AdditionalLibraryDirectories="../../../../lib; ../../../../stage/lib"
+ GenerateDebugInformation="true"
+ SubSystem="1"
+ RandomizedBaseAddress="1"
+ DataExecutionPrevention="0"
+ TargetMachine="1"
+ />
+ <Tool
+ Name="VCALinkTool"
+ />
+ <Tool
+ Name="VCManifestTool"
+ />
+ <Tool
+ Name="VCXDCMakeTool"
+ />
+ <Tool
+ Name="VCBscMakeTool"
+ />
+ <Tool
+ Name="VCFxCopTool"
+ />
+ <Tool
+ Name="VCAppVerifierTool"
+ />
+ <Tool
+ Name="VCPostBuildEventTool"
+ />
+ </Configuration>
+ <Configuration
+ Name="Release|Win32"
+ OutputDirectory="../../../../bin/release"
+ IntermediateDirectory="../../../../bin/obj/$(ProjectName)/release"
+ ConfigurationType="1"
+ CharacterSet="1"
+ WholeProgramOptimization="1"
+ >
+ <Tool
+ Name="VCPreBuildEventTool"
+ />
+ <Tool
+ Name="VCCustomBuildTool"
+ />
+ <Tool
+ Name="VCXMLDataGeneratorTool"
+ />
+ <Tool
+ Name="VCWebServiceProxyGeneratorTool"
+ />
+ <Tool
+ Name="VCMIDLTool"
+ />
+ <Tool
+ Name="VCCLCompilerTool"
+ WholeProgramOptimization="true"
+ AdditionalIncludeDirectories="../../../../; ../../../../boost_1_35_0"
+ PreprocessorDefinitions="WIN32;NDEBUG;_CONSOLE"
+ ExceptionHandling="1"
+ RuntimeLibrary="2"
+ UsePrecompiledHeader="0"
+ WarningLevel="3"
+ Detect64BitPortabilityProblems="false"
+ DebugInformationFormat="3"
+ />
+ <Tool
+ Name="VCManagedResourceCompilerTool"
+ />
+ <Tool
+ Name="VCResourceCompilerTool"
+ />
+ <Tool
+ Name="VCPreLinkEventTool"
+ />
+ <Tool
+ Name="VCLinkerTool"
+ LinkIncremental="1"
+ AdditionalLibraryDirectories="../../../../lib; ../../../../stage/lib"
+ GenerateDebugInformation="true"
+ SubSystem="1"
+ OptimizeReferences="2"
+ EnableCOMDATFolding="2"
+ LinkTimeCodeGeneration="1"
+ RandomizedBaseAddress="1"
+ DataExecutionPrevention="0"
+ TargetMachine="1"
+ />
+ <Tool
+ Name="VCALinkTool"
+ />
+ <Tool
+ Name="VCManifestTool"
+ />
+ <Tool
+ Name="VCXDCMakeTool"
+ />
+ <Tool
+ Name="VCBscMakeTool"
+ />
+ <Tool
+ Name="VCFxCopTool"
+ />
+ <Tool
+ Name="VCAppVerifierTool"
+ />
+ <Tool
+ Name="VCPostBuildEventTool"
+ />
+ </Configuration>
+ </Configurations>
+ <References>
+ </References>
+ <Files>
+ <Filter
+ Name="Quelldateien"
+ Filter="cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx"
+ UniqueIdentifier="{4FC737F1-C7A5-4376-A066-2A32D752A2FF}"
+ >
+ <File
+ RelativePath="..\..\src\gentor\gentorprofile.cpp"
+ >
+ </File>
+ <File
+ RelativePath="..\labat_itv_map_settic\labat_itv_map_settic.cpp"
+ >
+ </File>
+ </Filter>
+ <Filter
+ Name="Headerdateien"
+ Filter="h;hpp;hxx;hm;inl;inc;xsd"
+ UniqueIdentifier="{93995380-89BD-4b04-88EB-625FBE52EBFB}"
+ >
+ <File
+ RelativePath="..\..\..\..\boost\validate\law.h"
+ >
+ </File>
+ <File
+ RelativePath="..\..\..\..\boost\validate\lawvalidater.h"
+ >
+ </File>
+ <File
+ RelativePath="..\..\..\..\boost\validate\lawviolations.h"
+ >
+ </File>
+ <File
+ RelativePath="..\..\..\..\boost\validate\laws\monoid.h"
+ >
+ </File>
+ <File
+ RelativePath="..\..\..\..\boost\validate\laws\order.h"
+ >
+ </File>
+ <File
+ RelativePath="..\..\..\..\boost\validate\laws\pushouts.h"
+ >
+ </File>
+ <File
+ RelativePath="..\..\..\..\boost\validate\realmvalidater.h"
+ >
+ </File>
+ <File
+ RelativePath="..\..\..\..\boost\validate\laws\set_laws.h"
+ >
+ </File>
+ <File
+ RelativePath="..\..\..\..\boost\validate\typevalidater.h"
+ >
+ </File>
+ </Filter>
+ <Filter
+ Name="Ressourcendateien"
+ Filter="rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx;tiff;tif;png;wav"
+ UniqueIdentifier="{67DA6AB6-F800-4c08-8B7A-83BB121AAD01}"
+ >
+ </Filter>
+ <File
+ RelativePath=".\ReadMe.txt"
+ >
+ </File>
+ </Files>
+ <Globals>
+ </Globals>
+</VisualStudioProject>

Added: sandbox/itl/libs/validate/example/labat_single/labat_single.cpp
==============================================================================
--- (empty file)
+++ sandbox/itl/libs/validate/example/labat_single/labat_single.cpp 2009-01-02 18:52:40 EST (Fri, 02 Jan 2009)
@@ -0,0 +1,95 @@
+/*----------------------------------------------------------------------------+
+A Law Based Test Automaton 'LaBatea'
+Author: Joachim Faulhaber
+Copyright (c) 2007-2008: Joachim Faulhaber
++-----------------------------------------------------------------------------+
+ Distributed under the Boost Software License, Version 1.0.
+ (See accompanying file LICENCE.txt or copy at
+ http://www.boost.org/LICENSE_1_0.txt)
++----------------------------------------------------------------------------*/
+#include <iostream>
+#include <stdio.h>
+
+#include <boost/itl/ptime.hpp> //CL (4 a quick test only)
+
+#include <boost/validate/loki_xt/Tuple.h>
+#include <boost/itl/set.hpp>
+#include <boost/itl/map.hpp>
+#include <boost/validate/lawvalidater.h>
+#include <boost/validate/laws/monoid.h>
+#include <boost/validate/gentor/gentorprofile.h>
+#include <boost/validate/gentor/rangegentor.h>
+
+#include <boost/validate/single_law_validater.hpp>
+#include <boost/itl/interval_set.hpp>
+//#include <boost/itl_xt/numbergentor.hpp>
+//#include <boost/itl_xt/setgentor.hpp>
+#include <boost/itl/functors.hpp>
+
+using namespace std;
+using namespace Loki;
+using namespace boost;
+using namespace boost::itl;
+using namespace boost::posix_time;
+
+
+void test_LawValidater()
+{
+ //typedef BinaryPushout<itl::split_interval_map<int,double>, itl::map<int,double>, Interval::Atomize, inplace_plus>
+ // Map_Atomize_Union_DiagramT;
+ //LawValidater<Map_Atomize_Union_DiagramT, RandomGentor> map_atomize_plus_pushout;
+ //map_atomize_plus_pushout.setTrialsCount(1000);
+ //map_atomize_plus_pushout.run();
+
+ //typedef BinaryPushout<itl::map<int,double>, itl::split_interval_map<int,double>, Interval::Cluster, inplace_star>
+ // Map_Cluster_Intersect_DiagramT;
+ //LawValidater<Map_Cluster_Intersect_DiagramT, RandomGentor> map_cluster_star_pushout;
+ //map_cluster_star_pushout.setTrialsCount(1000);
+ //map_cluster_star_pushout.run();
+
+ //typedef InplaceSymmetricDifference<interval_map<int, itl::set<int>, neutron_emitter_and_enricher >, std_equal> TestLawT;
+ //LawValidater<TestLawT, RandomGentor> test_law;
+ //test_law.setTrialsCount(1000);
+ //test_law.run();
+
+ //typedef InplaceDistributivity
+ // <split_interval_map<int, itl::set<int>, neutron_absorber >,
+ // inplace_star, inplace_plus, itl::std_equal> TestLawT;
+ //LawValidater<TestLawT, RandomGentor> test_law;
+ //test_law.setTrialsCount(1000);
+
+ typedef InplaceSelfRemovability
+ <split_interval_map<int, itl::set<int>, neutron_emitter >,
+ itl::inplace_plus, itl::protonic_equal> TestLawT;
+ LawValidater<TestLawT, RandomGentor> test_law;
+ test_law.setTrialsCount(1000);
+
+ //typedef InplaceAssociativity
+ // <interval_map<int, int, neutron_absorber >, inplace_plus> TestLawT;
+ //LawValidater<TestLawT, RandomGentor> test_law;
+ //test_law.setTrialsCount(1000);
+
+ //typedef InplaceCommutativity
+ // <split_interval_map<int, int, neutron_emitter>, inplace_plus> TestLawT;
+ //LawValidater<TestLawT, RandomGentor> test_law;
+ //test_law.setTrialsCount(1000);
+
+ //typedef ProtonicEquality
+ // <split_interval_map<int, int, neutron_enricher > > TestLawT;
+ //LawValidater<TestLawT, RandomGentor> test_law;
+ //test_law.setTrialsCount(1000);
+
+ std::cout << "Start\n";
+ ptime start(microsec_clock::local_time());
+ test_law.run();
+ ptime stop(microsec_clock::local_time());
+ std::cout << "Stop. Time elapsed: " << stop - start << endl;
+}
+
+
+
+int main()
+{
+ test_LawValidater();
+ return 0;
+}

Added: sandbox/itl/libs/validate/example/labat_single/vc9_labat_single.vcproj
==============================================================================
--- (empty file)
+++ sandbox/itl/libs/validate/example/labat_single/vc9_labat_single.vcproj 2009-01-02 18:52:40 EST (Fri, 02 Jan 2009)
@@ -0,0 +1,247 @@
+<?xml version="1.0" encoding="Windows-1252"?>
+<VisualStudioProject
+ ProjectType="Visual C++"
+ Version="9,00"
+ Name="vc9_labat_single"
+ ProjectGUID="{BF42574F-66E2-42DD-90D9-3A8FCE6F471C}"
+ RootNamespace="vc9_labat_single"
+ Keyword="Win32Proj"
+ TargetFrameworkVersion="131072"
+ >
+ <Platforms>
+ <Platform
+ Name="Win32"
+ />
+ </Platforms>
+ <ToolFiles>
+ </ToolFiles>
+ <Configurations>
+ <Configuration
+ Name="Debug|Win32"
+ OutputDirectory="../../../../bin/debug"
+ IntermediateDirectory="../../../../bin/obj/$(ProjectName)/debug"
+ ConfigurationType="1"
+ CharacterSet="1"
+ >
+ <Tool
+ Name="VCPreBuildEventTool"
+ />
+ <Tool
+ Name="VCCustomBuildTool"
+ />
+ <Tool
+ Name="VCXMLDataGeneratorTool"
+ />
+ <Tool
+ Name="VCWebServiceProxyGeneratorTool"
+ />
+ <Tool
+ Name="VCMIDLTool"
+ />
+ <Tool
+ Name="VCCLCompilerTool"
+ Optimization="0"
+ AdditionalIncludeDirectories="../../../../; ../../../../boost_1_35_0"
+ PreprocessorDefinitions="WIN32;_DEBUG;_CONSOLE"
+ MinimalRebuild="true"
+ BasicRuntimeChecks="3"
+ RuntimeLibrary="3"
+ UsePrecompiledHeader="0"
+ WarningLevel="3"
+ Detect64BitPortabilityProblems="false"
+ DebugInformationFormat="4"
+ />
+ <Tool
+ Name="VCManagedResourceCompilerTool"
+ />
+ <Tool
+ Name="VCResourceCompilerTool"
+ />
+ <Tool
+ Name="VCPreLinkEventTool"
+ />
+ <Tool
+ Name="VCLinkerTool"
+ LinkIncremental="2"
+ AdditionalLibraryDirectories="../../../../lib; ../../../../stage/lib"
+ GenerateDebugInformation="true"
+ SubSystem="1"
+ RandomizedBaseAddress="1"
+ DataExecutionPrevention="0"
+ TargetMachine="1"
+ />
+ <Tool
+ Name="VCALinkTool"
+ />
+ <Tool
+ Name="VCManifestTool"
+ />
+ <Tool
+ Name="VCXDCMakeTool"
+ />
+ <Tool
+ Name="VCBscMakeTool"
+ />
+ <Tool
+ Name="VCFxCopTool"
+ />
+ <Tool
+ Name="VCAppVerifierTool"
+ />
+ <Tool
+ Name="VCPostBuildEventTool"
+ />
+ </Configuration>
+ <Configuration
+ Name="Release|Win32"
+ OutputDirectory="../../../../bin/release"
+ IntermediateDirectory="../../../../bin/obj/$(ProjectName)/release"
+ ConfigurationType="1"
+ CharacterSet="1"
+ WholeProgramOptimization="1"
+ >
+ <Tool
+ Name="VCPreBuildEventTool"
+ />
+ <Tool
+ Name="VCCustomBuildTool"
+ />
+ <Tool
+ Name="VCXMLDataGeneratorTool"
+ />
+ <Tool
+ Name="VCWebServiceProxyGeneratorTool"
+ />
+ <Tool
+ Name="VCMIDLTool"
+ />
+ <Tool
+ Name="VCCLCompilerTool"
+ WholeProgramOptimization="true"
+ AdditionalIncludeDirectories="../../../../; ../../../../boost_1_35_0"
+ PreprocessorDefinitions="WIN32;NDEBUG;_CONSOLE"
+ ExceptionHandling="1"
+ RuntimeLibrary="2"
+ UsePrecompiledHeader="0"
+ WarningLevel="3"
+ Detect64BitPortabilityProblems="false"
+ DebugInformationFormat="3"
+ />
+ <Tool
+ Name="VCManagedResourceCompilerTool"
+ />
+ <Tool
+ Name="VCResourceCompilerTool"
+ />
+ <Tool
+ Name="VCPreLinkEventTool"
+ />
+ <Tool
+ Name="VCLinkerTool"
+ LinkIncremental="1"
+ AdditionalLibraryDirectories="../../../../lib; ../../../../stage/lib"
+ GenerateDebugInformation="true"
+ SubSystem="1"
+ OptimizeReferences="2"
+ EnableCOMDATFolding="2"
+ LinkTimeCodeGeneration="1"
+ RandomizedBaseAddress="1"
+ DataExecutionPrevention="0"
+ TargetMachine="1"
+ />
+ <Tool
+ Name="VCALinkTool"
+ />
+ <Tool
+ Name="VCManifestTool"
+ />
+ <Tool
+ Name="VCXDCMakeTool"
+ />
+ <Tool
+ Name="VCBscMakeTool"
+ />
+ <Tool
+ Name="VCFxCopTool"
+ />
+ <Tool
+ Name="VCAppVerifierTool"
+ />
+ <Tool
+ Name="VCPostBuildEventTool"
+ />
+ </Configuration>
+ </Configurations>
+ <References>
+ </References>
+ <Files>
+ <Filter
+ Name="Quelldateien"
+ Filter="cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx"
+ UniqueIdentifier="{4FC737F1-C7A5-4376-A066-2A32D752A2FF}"
+ >
+ <File
+ RelativePath="..\..\src\gentor\gentorprofile.cpp"
+ >
+ </File>
+ <File
+ RelativePath="..\labat_single\labat_single.cpp"
+ >
+ </File>
+ </Filter>
+ <Filter
+ Name="Headerdateien"
+ Filter="h;hpp;hxx;hm;inl;inc;xsd"
+ UniqueIdentifier="{93995380-89BD-4b04-88EB-625FBE52EBFB}"
+ >
+ <File
+ RelativePath="..\..\..\..\boost\validate\law.h"
+ >
+ </File>
+ <File
+ RelativePath="..\..\..\..\boost\validate\lawvalidater.h"
+ >
+ </File>
+ <File
+ RelativePath="..\..\..\..\boost\validate\lawviolations.h"
+ >
+ </File>
+ <File
+ RelativePath="..\..\..\..\boost\validate\laws\monoid.h"
+ >
+ </File>
+ <File
+ RelativePath="..\..\..\..\boost\validate\laws\order.h"
+ >
+ </File>
+ <File
+ RelativePath="..\..\..\..\boost\validate\laws\pushouts.h"
+ >
+ </File>
+ <File
+ RelativePath="..\..\..\..\boost\validate\realmvalidater.h"
+ >
+ </File>
+ <File
+ RelativePath="..\..\..\..\boost\validate\laws\set_laws.h"
+ >
+ </File>
+ <File
+ RelativePath="..\..\..\..\boost\validate\typevalidater.h"
+ >
+ </File>
+ </Filter>
+ <Filter
+ Name="Ressourcendateien"
+ Filter="rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx;tiff;tif;png;wav"
+ UniqueIdentifier="{67DA6AB6-F800-4c08-8B7A-83BB121AAD01}"
+ >
+ </Filter>
+ <File
+ RelativePath=".\ReadMe.txt"
+ >
+ </File>
+ </Files>
+ <Globals>
+ </Globals>
+</VisualStudioProject>

Modified: sandbox/itl/libs/validate/example/labatea/labatea.cpp
==============================================================================
--- sandbox/itl/libs/validate/example/labatea/labatea.cpp (original)
+++ sandbox/itl/libs/validate/example/labatea/labatea.cpp 2009-01-02 18:52:40 EST (Fri, 02 Jan 2009)
@@ -36,11 +36,13 @@
 
 void test_Validater()
 {
- GentorProfileSgl::it()->set_range_int(-10, 10);
- GentorProfileSgl::it()->set_range_double(-10.0, 10.0);
- GentorProfileSgl::it()->set_range_ContainerSize(0, 20);
- GentorProfileSgl::it()->set_range_interval_int(-20, 20);
- GentorProfileSgl::it()->set_maxIntervalLength(5);
+ //GentorProfileSgl::it()->set_range_int(-10, 10);
+ //GentorProfileSgl::it()->set_range_nat(0, 64);
+ //GentorProfileSgl::it()->set_range_double(-10.0, 10.0);
+ //GentorProfileSgl::it()->set_range_ContainerSize(0, 20);
+ //GentorProfileSgl::it()->set_range_interval_int(-20, 20);
+ //GentorProfileSgl::it()->set_maxIntervalLength(5);
+ //GentorProfileSgl::it()->set_range_element_ContainerSize(0,5);
 
 
     //typedef BinaryPushout<itl::split_interval_map<int,double>, itl::map<int,double>, Interval::Atomize, inplace_plus>
@@ -55,23 +57,38 @@
     //map_cluster_star_pushout.setTrialsCount(1000);
     //map_cluster_star_pushout.run();
 
- //typedef InplaceSymmetricDifference<interval_map<int, int, neutron_absorber >, std_equal> TestLawT;
+ //typedef InplaceSymmetricDifference<interval_map<int, itl::set<int>, neutron_emitter_and_enricher >, std_equal> TestLawT;
         //LawValidater<TestLawT, RandomGentor> test_law;
         //test_law.setTrialsCount(1000);
         //test_law.run();
 
         //typedef InplaceDistributivity
- // <interval_map<int, int, neutron_absorber >,
- // inplace_plus, inplace_star, itl::protonic_equal> TestLawT;
+ // <split_interval_map<int, itl::set<int>, neutron_absorber >,
+ // inplace_star, inplace_plus, itl::std_equal> TestLawT;
         //LawValidater<TestLawT, RandomGentor> test_law;
         //test_law.setTrialsCount(1000);
- //test_law.run();
 
- typedef InplaceAssociativity
- <interval_map<int, int, neutron_absorber >, inplace_plus> TestLawT;
+ typedef InplaceSelfRemovability
+ <split_interval_map<int, itl::set<int>, neutron_emitter >,
+ itl::inplace_plus, itl::protonic_equal> TestLawT;
         LawValidater<TestLawT, RandomGentor> test_law;
         test_law.setTrialsCount(1000);
 
+ //typedef InplaceAssociativity
+ // <interval_map<int, int, neutron_absorber >, inplace_plus> TestLawT;
+ //LawValidater<TestLawT, RandomGentor> test_law;
+ //test_law.setTrialsCount(1000);
+
+ //typedef InplaceCommutativity
+ // <split_interval_map<int, int, neutron_emitter>, inplace_plus> TestLawT;
+ //LawValidater<TestLawT, RandomGentor> test_law;
+ //test_law.setTrialsCount(1000);
+
+ //typedef ProtonicEquality
+ // <split_interval_map<int, int, neutron_enricher > > TestLawT;
+ //LawValidater<TestLawT, RandomGentor> test_law;
+ //test_law.setTrialsCount(1000);
+
         std::cout << "Start\n";
         ptime start(microsec_clock::local_time());
         test_law.run();
@@ -79,7 +96,6 @@
         std::cout << "Stop. Time elapsed: " << stop - start << endl;
 }
 
-
 void test_realmvalidater()
 {
     RealmValidater validater;
@@ -92,7 +108,6 @@
     validater.validate();
 };
 
-
 int main()
 {
     //test_Validater();

Modified: sandbox/itl/libs/validate/src/gentor/gentorprofile.cpp
==============================================================================
--- sandbox/itl/libs/validate/src/gentor/gentorprofile.cpp (original)
+++ sandbox/itl/libs/validate/src/gentor/gentorprofile.cpp 2009-01-02 18:52:40 EST (Fri, 02 Jan 2009)
@@ -29,28 +29,32 @@
 {
     //---------------------------------
     //standard values
- set_range_int(-10, 10);
- set_range_double(0.0, 1.0);
- set_range_ContainerSize(0,10);
+ //set_range_int(-10, 10);
+ //set_range_nat(0, 64);
+ //set_range_unsigned_short(0, 64);
+ //set_range_double(0.0, 1.0);
+ //set_range_ContainerSize(0,10);
 
- set_range_interval_int(-10, 10);
- set_maxIntervalLength(8);
+ //set_range_interval_int(-10, 10);
+ //set_maxIntervalLength(8);
 
- set_range_element_ContainerSize(0,5);
+ //set_range_element_ContainerSize(0,5);
 
     //---------------------------------
     //small values
- //set_range_int(0, 10);
- //set_range_double(0.0, 1.0);
- //set_range_ContainerSize(0,4);
+ set_range_int(0, 10);
+ set_range_nat(0, 16);
+ set_range_double(0.0, 1.0);
+ set_range_ContainerSize(0,4);
 
- //set_range_interval_int(0, 10);
- //set_maxIntervalLength(5);
- //set_range_element_ContainerSize(0,4);
+ set_range_interval_int(0, 10);
+ set_maxIntervalLength(5);
+ set_range_element_ContainerSize(0,4);
 
     //---------------------------------
     //current values
     //set_range_int(-5, 5);
+ //set_range_nat(0, 16);
     //set_range_double(0.0, 1.0);
     //set_range_ContainerSize(0,6);
 


Boost-Commit list run by bdawes at acm.org, david.abrahams at rcn.com, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk