60 typedef std::pair<Interface,bool>
base;
72 const bool &
inside()
const {
return this->second; }
79 class OPENMEEG_EXPORT
Domain:
public std::vector<HalfSpace> {
81 typedef std::vector<HalfSpace>
base;
85 Domain(): name_(
""), sigma_(-1.), outermost_(false) { }
91 std::string&
name() {
return name_; }
92 const std::string&
name()
const {
return name_; }
96 double&
sigma() {
return sigma_; }
97 const double&
sigma()
const {
return sigma_; }
113 for (Domain::const_iterator hit = begin();hit!=end();++hit)
114 for (Interface::const_iterator omit = hit->interface().begin();omit!=hit->interface().end();++omit)
115 if (&omit->mesh()==&m)
116 return ((hit->inside()) ? omit->orientation() : -omit->orientation());
a Domain is a vector of HalfSpace A Domain is the intersection of simple domains (of type HalfSpace).
const std::string & name() const
std::string name_
Name of the domain.
bool outermost_
Is it an outermost domain.
int mesh_orientation(const Mesh &m) const
bool contains_point(const Vect3 &) const
Does this point belongs to the domain ?
std::string & name()
The name of the domain.
const bool & outermost() const
void info() const
print info about the domain
double & sigma()
The conductivity of the domain.
const double & sigma() const
double sigma_
Conductivity of the domain.
std::vector< HalfSpace > base
bool & outermost()
Returns the outermost state of the domain.
a HalfSpace is a pair of Interface and boolean A simple domain (HalfSpace) is given by an interface (...
HalfSpace(Interface &_interface, const bool _inside)
std::pair< Interface, bool > base
const Interface & interface() const
const bool & inside() const
Interface class An interface is a closed-shape composed of oriented meshes (here pointer to meshes)
std::vector< Domain > Domains
A vector of Domain is called Domains.