Bpp/Graph_problem
Min_cost_tension
Structure
C++
 
 
DESCRIPTION
 

This module provides structures for the minimum cost tension problem in graphs.

 
SOURCE FILES
 

This section allows you to access the C++ source files of the module.

 
PARENT MODULE
 

This module is part of Bpp/Graph_problem/Min_cost_tension.

 
INCLUDED FILES
 

The files listed below are included in the interface part of the module. So any module dependent of this module is also dependent of the files listed here.

  • <bpp/graph.hpp>

  • <bpp/linear_system.hpp>

 
NEEDED FILES
 

The files listed below are needed by the implementation part of the module. But a module dependent of this module is not necessary dependent of the files listed here.

  • <bpp/modules.hpp>

 
INTEGRATED NAMESPACES
 

The namespaces listed below are integrated in this module. That means any element declared in one of those namespaces can now be directly used by or from this module.

  • graph

 
TYPES
 

Here are listed the types defined in the module. To use one of them, you have to specify the namespace of the module.

  • type clArc<clBinaryArcData,clNodeData> clBinaryArc
    Arc of a graph with a minimum cost tension problem with binary costs.

  • type clGraph<clBinaryArcData,clNodeData> clBinaryGraph
    Graph with a minimum cost tension problem with binary costs.

  • type clNode<clBinaryArcData,clNodeData> clBinaryNode
    Node of a graph with a minimum cost tension problem with binary costs.

  • type clArc<clConvexArcData1,clNodeData> clConvexArc1
    Arc of a graph with a minimum cost tension problem with convex quadratic costs.

  • type clGraph<clConvexArcData1,clNodeData> clConvexGraph1
    Graph with a minimum cost tension problem with convex quadratic costs.

  • type clNode<clConvexArcData1,clNodeData> clConvexNode1
    Node of a graph with a minimum cost tension problem with convex quadratic costs.

  • type clArc<clConvexArcData2,clNodeData> clConvexArc2
    Arc of a graph with a minimum cost tension problem with convex exponential costs.

  • type clGraph<clConvexArcData2,clNodeData> clConvexGraph2
    Graph with a minimum cost tension problem with convex exponential costs.

  • type clNode<clConvexArcData2,clNodeData> clConvexNode2
    Node of a graph with a minimum cost tension problem with convex exponential costs.

  • type clArc<clDiscreteArcData,clNodeData> clDiscreteArc
    Arc of a graph with a minimum cost tension problem with discrete tensions and linear costs.

  • type clGraph<clDiscreteArcData,clNodeData> clDiscreteGraph
    Graph with a minimum cost tension problem with discrete tensions and linear costs.

  • type clNode<clDiscreteArcData,clNodeData> clDiscreteNode
    Node of a graph with a minimum cost tension problem with discrete tensions and linear costs.

  • type clArc<clLinearArcData,clNodeData> clLinearArc
    Arc of a graph with a minimum cost tension problem with linear costs.

  • type clGraph<clLinearArcData,clNodeData> clLinearGraph
    Graph with a minimum cost tension problem with linear costs.

  • type clNode<clLinearArcData,clNodeData> clLinearNode
    Node of a graph with a minimum cost tension problem with linear costs.

  • type clArc<clPiecewiseArcData,clNodeData> clPiecewiseArc
    Arc of a graph with a minimum cost tension problem with piecewise linear costs.

  • type clGraph<clPiecewiseArcData,clNodeData> clPiecewiseGraph
    Graph with a minimum cost tension problem with piecewise linear costs.

  • type clNode<clPiecewiseArcData,clNodeData> clPiecewiseNode
    Node of a graph with a minimum cost tension problem with piecewise linear costs.

  • type linearSystemStructure::clConstraint<public_area::clVariableContent> clTensionConstraint
    Constraint of a linear program that models the minimum cost tension problem.

  • type linearSystemStructure::clObjective<public_area::clVariableContent> clTensionObjective
    Objective of a linear program that models the minimum cost tension problem.

  • type linearSystemStructure::clLinearSystem<public_area::clVariableContent> clTensionSystem
    Linear program that models the minimum cost tension problem.

  • type linearSystemStructure::clVariable<public_area::clVariableContent> clTensionVariable
    Variable of a linear program that models the minimum cost tension problem.

  • type linearSystemSolver::clSolver<public_area::clVariableContent> clTensionSystemSolver
    Solver of linear programs that model the minimum cost tension problem.

  • enumeration { tension, shrinking, stretching, potential, binary } tyVariableSignificance
    Symbolic constants to associate a significance with each variable of a linear program modeling the minimum cost tension problem.

 
ERRORS
 

Here are listed the errors that are supported or generated by the module. To use one of them, you do not have to specify the namespace of the module.

  • erInconsistentPiecewiseCost
    The piecewise cost is inconsistent.

  • erInvalidVariableSignificanceString
    Invalid variable significance string.

  • erNegativeTension
    A tension can not be negative.

  • erOptimalTensionOutOfBound
    The optimal tension of an arc is out of the feasible bounds.

 
FUNCTIONS
 

Here are listed the functions provided by the module. To use one of them, you have to specify the namespace of the module.

 
CLASSES
 

Here are listed the classes provided by the module. To use one of them, you have to specify the namespace of the module.

 
clBinaryArcData
 
 
Declaration

class clBinaryArcData

 
Description

Represents the data carried by an arc of a graph with a minimum cost tension problem. The arc has a minimum tension, a maximum tension and a wanted, optimum, tension. The cost associated with the tension of an arc is a binary function equal to 0 if tension = optimum or weight else.

 
Attributes
  • tyReal minimum()
    Minimum tension of the arc. Reading and writing access.

  • tyReal maximum()
    Maximum tension of the arc. Reading and writing access.

  • tyReal optimum()
    Optimum tension of the arc. Reading and writing access.

  • tyReal weight()
    Cost weight of the arc. Reading and writing access.

  • tyReal expected()
    Resolved tension of the arc (also called the expected tension). Reading and writing access.

  • tyReal flow()
    Flow that goes through the arc. Reading and writing access.

 
Methods
 
clConvexArcData1
 
 
Declaration

class clConvexArcData1

 
Description

Represents the data carried by an arc of a graph with a minimum cost tension problem. The arc has a minimum tension, a maximum tension and a wanted, optimum, tension. The cost associated with the tension of an arc is a quadratic function of the form costAcceleration*(tension-optimum)*(tension-optimum).

 
Attributes
  • tyReal minimum()
    Minimum tension of the arc. Reading and writing access.

  • tyReal maximum()
    Maximum tension of the arc. Reading and writing access.

  • tyReal optimum()
    Optimum tension of the arc. Reading and writing access.

  • tyReal costAcceleration()
    It is a parameter of the cost function of the arc. We call it "cost acceleration". Reading and writing access.

  • tyReal expected()
    Resolved tension of the arc (also called the expected tension). Reading and writing access.

  • tyReal flow()
    Flow that goes through the arc. Reading and writing access.

 
Methods
 
clConvexArcData2
 
 
Declaration

class clConvexArcData2

 
Description

Represents the data carried by an arc of a graph with a minimum cost tension problem. The arc has a wanted, optimum, tension and a given tolerance t is accepted around it. The cost associated with the tension of an arc is a function of the form: log(t*t/(tension-(optimum-t))*((optimum+t)-tension)).

 
Attributes
  • tyReal optimum()
    Optimum tension of the arc. Reading and writing access.

  • tyReal tolerance()
    Tolerance around the optimum tension of the arc. Reading and writing access.

  • tyReal expected()
    Resolved tension of the arc (also called the expected tension). Reading and writing access.

  • tyReal flow()
    Flow that goes through the arc. Reading and writing access.

 
Methods
 
clDiscreteArcData
 
 
Declaration

class clDiscreteArcData

 
Description

Represents the data carried by an arc of a graph with a minimum cost tension problem. The arc has a set of feasible tensions and a wanted, optimum, tension. The cost associated with the tension of an arc is a two-part linear function of the form stretchingCost*(tension-optimum) if tension > optimum or shrinkingCost*(optimum-tension) else.

 
Types
  • type std_vector(tyReal) clFeasibleS
    Type of the list of feasible tensions.

 
Attributes
  • clFeasibleS feasibles()
    Feasible tensions of the arc. Reading access only.

  • tyReal optimum()
    Optimum tension of the arc. Reading and writing access.

  • tyReal shrinkingCost()
    Shrinking cost of the arc. Reading and writing access.

  • tyReal stretchingCost()
    Stretching cost of the arc. Reading and writing access.

  • tyReal expected()
    Resolved tension of the arc (also called the expected tension). Reading and writing access.

  • tyReal flow()
    Flow that goes through the arc. Reading and writing access.

 
Methods
 
clLinearArcData
 
 
Declaration

class clLinearArcData

 
Description

Represents the data carried by an arc of a graph with a minimum cost tension problem. The arc has a minimum tension, a maximum tension and a wanted, optimum, tension. The cost associated with the tension of an arc is a two-part linear function of the form stretchingCost*(tension-optimum) if tension > optimum or shrinkingCost*(optimum-tension) else.

 
Attributes
  • tyReal minimum()
    Minimum tension of the arc. Reading and writing access.

  • tyReal maximum()
    Maximum tension of the arc. Reading and writing access.

  • tyReal optimum()
    Optimum tension of the arc. Reading and writing access.

  • tyReal shrinkingCost()
    Shrinking cost of the arc. Reading and writing access.

  • tyReal stretchingCost()
    Stretching cost of the arc. Reading and writing access.

  • tyReal expected()
    Resolved tension of the arc (also called the expected tension). Reading and writing access.

  • tyReal flow()
    Flow that goes through the arc. Reading and writing access.

 
Methods
 
clNodeData
 
 
Declaration

class clNodeData

 
Description

Represents the data carried by a node of a graph with a minimum cost tension problem.

 
Attributes
  • tyReal minimum()
    Minimum potential of the node. Reading and writing access.

  • tyReal maximum()
    Maximum potential of the node. Reading and writing access.

  • tyReal value()
    Resolved potential of the node. Reading and writing access.

 
Methods
 
clPiecewiseArcData
 
 
Declaration

class clPiecewiseArcData

 
Description

Represents the data carried by an arc of a graph with a minimum cost tension problem. The arc has a minimum tension, a maximum tension and a wanted, optimum, tension. The cost associated with the tension of an arc is a convex piecewise linear function. Two vectors of pairs (length;cost) represent the pieces of the cost to decrease or increase the tension from the optimum value.

 
Attributes
  • tyReal minimum()
    Minimum tension of the arc. Reading and writing access.

  • tyReal maximum()
    Maximum tension of the arc. Reading and writing access.

  • tyReal optimum()
    Optimum tension of the arc. Reading and writing access.

  • clCostS shrinkingCosts()
    Shrinking costs of the arc (vector representing the pieces of the cost function at the left of the expected tension). Reading and writing access.

  • clCostS stretchingCosts()
    Stretching costs of the arc (vector representing the pieces of the cost function at the right of the expected tension). Reading and writing access.

  • tyReal expected()
    Resolved tension of the arc (also called the expected tension). Reading and writing access.

  • tyReal flow()
    Flow that goes through the arc. Reading and writing access.

 
Methods
 
clVariableContent
 
 
Declaration

class clVariableContent

 
Description

Represents the data carried by a variable of a linear program that models the minimum cost tension problem.

 
Attributes
  • tyVariableSignificance significance()
    Significance of the variable according to the minimum cost tension problem. Reading and writing access.

  • tyArcKey arc()
    Key of the arc the variable is associated with. Reading and writing access.

  • tyArcKey node()
    Key of the node the variable is associated with. Reading and writing access.

 
Methods
 
 
Copyright (c) 1999-2016 - Bruno Bachelet - bruno@nawouak.net - http://www.nawouak.net
Permission is granted to copy, distribute and/or modify this document under the terms of the GNU Free Documentation License, Version 1.1 or any later version published by the Free Software Foundation. See this license for more details (http://www.gnu.org).