My Project
Cone Class Referenceabstract

The in-memory representation of a generic cone Specific cone types are derived from this generic class. More...

#include <OSInstance.h>

Inheritance diagram for Cone:
CompletelyPositiveMatricesCone CopositiveMatricesCone DualCone IntersectionCone NonnegativeCone NonpositiveCone OrthantCone PolarCone PolyhedralCone ProductCone QuadraticCone RotatedQuadraticCone SemidefiniteCone

Public Member Functions

 Cone ()
 The Cone class constructor.
 
virtual ~Cone ()
 The Cone class destructor.
 
virtual std::string getConeName ()
 
virtual std::string getConeInXML ()=0
 Write a Cone object in XML format.
 
bool IsEqual (Cone *that)
 A function to check for the equality of two objects.
 
bool setRandom (double density, bool conformant, int iMin, int iMax)
 A function to make a random instance of this class.
 
bool deepCopyFrom (Cone *that)
 A function to make a deep copy of an instance of this class.
 

Public Attributes

int numberOfRows
 Every cone has (at least) two dimensions; no distinction is made between vector cones and matrix cones.
 
int numberOfColumns
 
int numberOfOtherIndexes
 Cones can also be formed by Multidimensional tensors.
 
int * otherIndexes
 
ENUM_CONE_TYPE coneType
 The type of the cone.
 
std::string name
 The cone can have a name for easier identification.
 
int idx
 cones are referenced by an (automatically created) index
 

Detailed Description

The in-memory representation of a generic cone Specific cone types are derived from this generic class.

Definition at line 530 of file OSInstance.h.

Constructor & Destructor Documentation

◆ Cone()

Cone::Cone ( )

The Cone class constructor.

Definition at line 987 of file OSInstance.cpp.

◆ ~Cone()

Cone::~Cone ( )
virtual

The Cone class destructor.

Definition at line 1000 of file OSInstance.cpp.

Member Function Documentation

◆ getConeName()

std::string Cone::getConeName ( )
virtual

◆ getConeInXML()

std::string Cone::getConeInXML ( )
pure virtual

Write a Cone object in XML format.

This is used by OSiLWriter to write a <cone> element.

Returns
the cone and its children as an XML string.

Implemented in CompletelyPositiveMatricesCone, CopositiveMatricesCone, IntersectionCone, NonnegativeCone, NonpositiveCone, OrthantCone, PolyhedralCone, ProductCone, QuadraticCone, RotatedQuadraticCone, and SemidefiniteCone.

Definition at line 7821 of file OSInstance.cpp.

◆ IsEqual()

bool Cone::IsEqual ( Cone * that)

A function to check for the equality of two objects.

Definition at line 8728 of file OSInstance.cpp.

◆ setRandom()

bool Cone::setRandom ( double density,
bool conformant,
int iMin,
int iMax )

A function to make a random instance of this class.

Parameters
densitycorresponds to the probability that a particular child element is created
conformantif true enforces side constraints not enforceable in the schema (e.g., agreement of "numberOfXXX" attributes and <XXX> children)
iMinlowest index value (inclusive) that a variable reference in this matrix can take
iMaxgreatest index value (inclusive) that a variable reference in this matrix can take

◆ deepCopyFrom()

bool Cone::deepCopyFrom ( Cone * that)

A function to make a deep copy of an instance of this class.

Parameters
thatthe instance from which information is to be copied
Returns
whether the copy was created successfully

Member Data Documentation

◆ numberOfRows

int Cone::numberOfRows

Every cone has (at least) two dimensions; no distinction is made between vector cones and matrix cones.

Definition at line 543 of file OSInstance.h.

◆ numberOfColumns

int Cone::numberOfColumns

Definition at line 544 of file OSInstance.h.

◆ numberOfOtherIndexes

int Cone::numberOfOtherIndexes

Cones can also be formed by Multidimensional tensors.

(the Kronecker product, for instance, can be thought of as a four-dimensional tensor). We therefore allow additional dimensions, although they have not yet been implemented.

Definition at line 552 of file OSInstance.h.

◆ otherIndexes

int* Cone::otherIndexes

Definition at line 553 of file OSInstance.h.

◆ coneType

ENUM_CONE_TYPE Cone::coneType

The type of the cone.

Definition at line 556 of file OSInstance.h.

◆ name

std::string Cone::name

The cone can have a name for easier identification.

Definition at line 559 of file OSInstance.h.

◆ idx

int Cone::idx

cones are referenced by an (automatically created) index

Definition at line 562 of file OSInstance.h.


The documentation for this class was generated from the following files: