aGrUM  0.20.3
a C++ library for (probabilistic) graphical models
gum::SpanningForest Class Referenceabstract

Base class for computing min cost spanning trees or forests. More...

#include <spanningForest.h>

+ Inheritance diagram for gum::SpanningForest:

Public Member Functions

Accessors / Modifiers
virtual const EdgeSetedgesInSpanningForest ()=0
 Returns the edges in a min cost spanning forest. More...
 
virtual const UndiGraphspanningForest ()=0
 Construct the spanning forest. More...
 
virtual float costOfSpanningForest ()=0
 Returns the cost of the spanning forest. More...
 

Constructors / Destructors

virtual ~SpanningForest ()
 Destructor. More...
 
 SpanningForest ()
 default constructor More...
 
 SpanningForest (const SpanningForest &toCopy)
 Copy constructor. More...
 
SpanningForestoperator= (const SpanningForest &toCopy)
 Copy operator. More...
 

Detailed Description

Base class for computing min cost spanning trees or forests.

Definition at line 42 of file spanningForest.h.

Constructor & Destructor Documentation

◆ ~SpanningForest()

virtual gum::SpanningForest::~SpanningForest ( )
virtual

Destructor.

◆ SpanningForest() [1/2]

gum::SpanningForest::SpanningForest ( )
protected

default constructor

You should use SpanningForestPrim or SpanningForestKuskal to create appropriate spanning trees algorithms.

◆ SpanningForest() [2/2]

gum::SpanningForest::SpanningForest ( const SpanningForest toCopy)
protected

Copy constructor.

Member Function Documentation

◆ costOfSpanningForest()

virtual float gum::SpanningForest::costOfSpanningForest ( )
pure virtual

Returns the cost of the spanning forest.

Returns
cost of the spanning forest

Implemented in gum::SpanningForestPrim.

◆ edgesInSpanningForest()

virtual const EdgeSet& gum::SpanningForest::edgesInSpanningForest ( )
pure virtual

Returns the edges in a min cost spanning forest.

Returns
edges in the spanning forest

Implemented in gum::SpanningForestPrim.

◆ operator=()

SpanningForest& gum::SpanningForest::operator= ( const SpanningForest toCopy)
protected

Copy operator.

avoid copying the interface from scratch: this would prevent, in particular, that a Prim algorithm be initialized by a Kruskal algo.

◆ spanningForest()

virtual const UndiGraph& gum::SpanningForest::spanningForest ( )
pure virtual

Construct the spanning forest.

Returns
the spanning forest

Implemented in gum::SpanningForestPrim.


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