Vaucanson  1.4.1
concept/tropical_semiring.hh
1 // tropical_semiring.hh: this file is part of the Vaucanson project.
2 //
3 // Vaucanson, a generic library for finite state machines.
4 //
5 // Copyright (C) 2001, 2002, 2003, 2004, 2005 The Vaucanson Group.
6 //
7 // This program is free software; you can redistribute it and/or
8 // modify it under the terms of the GNU General Public License
9 // as published by the Free Software Foundation; either version 2
10 // of the License, or (at your option) any later version.
11 //
12 // The complete GNU General Public Licence Notice can be found as the
13 // `COPYING' file in the root directory.
14 //
15 // The Vaucanson Group consists of people listed in the `AUTHORS' file.
16 //
17 #ifndef VCSN_ALGEBRA_CONCEPT_TROPICAL_SEMIRING_HH
18 # define VCSN_ALGEBRA_CONCEPT_TROPICAL_SEMIRING_HH
19 
20 # include <vaucanson/algebra/concept/semiring_base.hh>
21 
22 namespace vcsn {
23 
24  namespace algebra {
25 
26  template <class TropicalKind>
27  struct TropicalSemiring;
28 
29  } // algebra
30 
34  /*-----------------------------------------------------------.
35  | dynamic_traits : traits about the set of tropical semiring |
36  `-----------------------------------------------------------*/
37 
39  template<class TropicalKind>
40  struct dynamic_traits<algebra::TropicalSemiring<TropicalKind> >
41  : dynamic_traits<algebra::SemiringBase<algebra::TropicalSemiring<TropicalKind> > >
42  {
43  };
44 
45  template<class TropicalKind>
46  struct virtual_types<algebra::TropicalSemiring<TropicalKind> >
47  : virtual_types<algebra::SemiringBase<algebra::TropicalSemiring<TropicalKind> > >
48  {
49  };
50 
51 
55  namespace algebra {
56 
60  /*-----------------.
61  | Kind of tropical |
62  `-----------------*/
63 
65  struct TropicalMin
66  {
67  };
68 
70  struct TropicalMax
71  {
72  };
73 
74  /*-----------------.
75  | TropicalSemiring |
76  `-----------------*/
77 
79  template <class TropicalKind>
81  : SemiringBase<TropicalSemiring<TropicalKind> >
82  {
83  bool operator == (const TropicalSemiring&) const;
84  };
85 
89  } // algebra
90 
94  /*---------------------------------------.
95  | MetaElement<TropicalSemiring<Kind>, T> |
96  `---------------------------------------*/
97 
99  template<class TropicalKind, typename T>
100  struct MetaElement<algebra::TropicalSemiring<TropicalKind> , T>
101  : MetaElement<algebra::SemiringBase<algebra::TropicalSemiring<TropicalKind> >, T>
102  {};
103 
107 } // vcsn
108 
109 
110 # if !defined VCSN_USE_INTERFACE_ONLY || defined VCSN_USE_LIB
111 # include <vaucanson/algebra/concept/tropical_semiring.hxx>
112 # endif // VCSN_USE_INTERFACE_ONLY
113 
114 
115 #endif // ! VCSN_ALGEBRA_CONCEPT_TROPICAL_SEMIRING_HH