# Parma_Polyhedra_Library::NNC_Polyhedron Class Reference

A not necessarily closed convex polyhedron. More...

Inherits Parma_Polyhedra_Library::Polyhedron.

List of all members.

## Public Member Functions

| NNC_Polyhedron (dimension_type num_dimensions=0, Degenerate_Kind kind=UNIVERSE)
| Builds either the universe or the empty NNC polyhedron.
| NNC_Polyhedron (const ConSys &cs)
| Builds an NNC polyhedron from a system of constraints.
| NNC_Polyhedron (ConSys &cs)
| Builds an NNC polyhedron recycling a system of constraints.
| NNC_Polyhedron (const GenSys &gs)
| Builds an NNC polyhedron from a system of generators.
| NNC_Polyhedron (GenSys &gs)
| Builds an NNC polyhedron recycling a system of generators.
| NNC_Polyhedron (const C_Polyhedron &y)
| Builds an NNC polyhedron from the C polyhedron `y`.
template<typename Box> | NNC_Polyhedron (const Box &box, From_Bounding_Box dummy)
| Builds an NNC polyhedron out of a generic, interval-based bounding box.
| NNC_Polyhedron (const NNC_Polyhedron &y)
| Ordinary copy-constructor.
NNC_Polyhedron & | operator= (const NNC_Polyhedron &y)
| The assignment operator. (`*this` and `y` can be dimension-incompatible.).
| ~NNC_Polyhedron ()
| Destructor.

## Static Public Member Functions

dimension_type | max_space_dimension ()
| Returns the maximum space dimension a C_Polyhedron can handle.

## Detailed Description

A not necessarily closed convex polyhedron.

An object of the class NNC_Polyhedron represents a not necessarily closed (NNC) convex polyhedron in the vector space .

Note:
  Since NNC polyhedra are a generalization of closed polyhedra, any object of the class C_Polyhedron can be (explicitly) converted into an object of the class NNC_Polyhedron. The reason for defining two different classes is that objects of the class C_Polyhedron are characterized by a more efficient implementation, requiring less time and memory resources.

## Constructor & Destructor Documentation

Parma_Polyhedra_Library::NNC_Polyhedron::NNC_Polyhedron | ( | dimension_type | num_dimensions = `0`,
|  | Degenerate_Kind | kind = `UNIVERSE`
| ) | `[explicit]`

Builds either the universe or the empty NNC polyhedron.

Parameters:

  | num_dimensions | The number of dimensions of the vector space enclosing the NNC polyhedron;
  | kind | Specifies whether a universe or an empty NNC polyhedron should be built.

Exceptions:

  | std::length_error | Thrown if `num_dimensions` exceeds the maximum allowed space dimension.

Both parameters are optional: by default, a 0-dimension space universe NNC polyhedron is built.

Parma_Polyhedra_Library::NNC_Polyhedron::NNC_Polyhedron | ( | const ConSys & | cs | ) |

Builds an NNC polyhedron from a system of constraints.

The polyhedron inherits the space dimension of the constraint system.

Parameters:

  | cs | The system of constraints defining the polyhedron. It is not declared `const` because its data-structures will be recycled to build the polyhedron.

Parma_Polyhedra_Library::NNC_Polyhedron::NNC_Polyhedron | ( | ConSys & | cs | ) |

Builds an NNC polyhedron recycling a system of constraints.

The polyhedron inherits the space dimension of the constraint system.

Parameters:

  | cs | The system of constraints defining the polyhedron. It is not declared `const` because its data-structures will be recycled to build the polyhedron.

Parma_Polyhedra_Library::NNC_Polyhedron::NNC_Polyhedron | ( | const GenSys & | gs | ) |

Builds an NNC polyhedron from a system of generators.

The polyhedron inherits the space dimension of the generator system.

Parameters:

  | gs | The system of generators defining the polyhedron. It is not declared `const` because its data-structures will be recycled to build the polyhedron.

Exceptions:

  | std::invalid_argument | Thrown if the system of generators is not empty but has no points.

Parma_Polyhedra_Library::NNC_Polyhedron::NNC_Polyhedron | ( | GenSys & | gs | ) |

Builds an NNC polyhedron recycling a system of generators.

The polyhedron inherits the space dimension of the generator system.

Parameters:

  | gs | The system of generators defining the polyhedron. It is not declared `const` because its data-structures will be recycled to build the polyhedron.

Exceptions:

  | std::invalid_argument | Thrown if the system of generators is not empty but has no points.

template<typename Box>
Parma_Polyhedra_Library::NNC_Polyhedron::NNC_Polyhedron | ( | const Box & | box,
|  | From_Bounding_Box | dummy
| ) |

Builds an NNC polyhedron out of a generic, interval-based bounding box.

For a description of the methods that should be provided by the template class Box, see the documentation of the protected method: template <typename Box> Polyhedron::Polyhedron(Topology topol, const Box& box);

Parameters:

  | box | The bounding box representing the polyhedron to be built;
  | dummy | A dummy tag to syntactically differentiate this one from the other constructors.