queso-0.51.1
ConcatenationSubset.h
Go to the documentation of this file.
1 //-----------------------------------------------------------------------bl-
2 //--------------------------------------------------------------------------
3 //
4 // QUESO - a library to support the Quantification of Uncertainty
5 // for Estimation, Simulation and Optimization
6 //
7 // Copyright (C) 2008,2009,2010,2011,2012,2013 The PECOS Development Team
8 //
9 // This library is free software; you can redistribute it and/or
10 // modify it under the terms of the Version 2.1 GNU Lesser General
11 // Public License as published by the Free Software Foundation.
12 //
13 // This library is distributed in the hope that it will be useful,
14 // but WITHOUT ANY WARRANTY; without even the implied warranty of
15 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
16 // Lesser General Public License for more details.
17 //
18 // You should have received a copy of the GNU Lesser General Public
19 // License along with this library; if not, write to the Free Software
20 // Foundation, Inc. 51 Franklin Street, Fifth Floor,
21 // Boston, MA 02110-1301 USA
22 //
23 //-----------------------------------------------------------------------el-
24 
25 #ifndef UQ_CONCATENATION_SUBSET_H
26 #define UQ_CONCATENATION_SUBSET_H
27 
28 #include <queso/VectorSpace.h>
29 #include <queso/VectorSubset.h>
30 
31 namespace QUESO {
32 
39 template<class V, class M>
40 class ConcatenationSubset : public VectorSubset<V,M> {
41 public:
43 
44 
47  ConcatenationSubset(const char* prefix,
49  const VectorSet<V,M>& set1,
50  const VectorSet<V,M>& set2);
51 
53 
55  ConcatenationSubset(const char* prefix,
56  const VectorSpace<V,M>& vectorSpace,
57  double volume,
58  const std::vector<const VectorSet<V,M>* >& sets);
62 
64 
65  bool contains(const V& vec) const;
68 
70 
71  void print (std::ostream& os) const;
74 protected:
79 
80  std::vector<const VectorSet<V,M>* > m_sets;
81 };
82 
83 } // End namespace QUESO
84 
85 #endif // UQ_CONCATENATION_SUBSET_H
const std::string & prefix() const
Access to private attribute m_prefix.
Definition: VectorSet.C:88
A templated class for handling sets.
Definition: VectorSet.h:49
A templated class representing the concatenation of two vector subsets.
const VectorSpace< V, M > & vectorSpace() const
Vector space to which this set belongs to. See template specialization.
Definition: VectorSubset.C:80
std::vector< const VectorSet< V, M > * > m_sets
A templated class for handling subsets.
Definition: VectorSubset.h:44
ConcatenationSubset(const char *prefix, const VectorSpace< V, M > &vectorSpace, const VectorSet< V, M > &set1, const VectorSet< V, M > &set2)
Constructor - two sets only.
bool contains(const V &vec) const
Determines whether each one of the subsets m_sets (class&#39; private attributes) contains vector vec...
A class representing a vector space.
Definition: VectorSet.h:46
double volume() const
Set volume; access to private attribute m_volume.
Definition: VectorSet.C:95
void print(std::ostream &os) const
Prints the subsets (via protected attribute m_sets).

Generated on Thu Apr 23 2015 19:26:14 for queso-0.51.1 by  doxygen 1.8.5