lemon/lp_base.h
changeset 1929 84d87d6024af
parent 1900 b16ca599472f
child 1956 a055123339d5
equal deleted inserted replaced
24:857e83c9f7d0 25:4646c29fe7a0
   230     ///  s+=i->second;
   230     ///  s+=i->second;
   231     ///\endcode
   231     ///\endcode
   232     ///(This code computes the sum of all coefficients).
   232     ///(This code computes the sum of all coefficients).
   233     ///- Numbers (<tt>double</tt>'s)
   233     ///- Numbers (<tt>double</tt>'s)
   234     ///and variables (\ref Col "Col"s) directly convert to an
   234     ///and variables (\ref Col "Col"s) directly convert to an
   235     ///\ref Expr and the usual linear operations are defined so  
   235     ///\ref Expr and the usual linear operations are defined, so  
   236     ///\code
   236     ///\code
   237     ///v+w
   237     ///v+w
   238     ///2*v-3.12*(v-w/2)+2
   238     ///2*v-3.12*(v-w/2)+2
   239     ///v*2.1+(3*v+(v*12+w+6)*3)/2
   239     ///v*2.1+(3*v+(v*12+w+6)*3)/2
   240     ///\endcode
   240     ///\endcode
   356     ///  are defined between expressions, or even between constraints whenever
   356     ///  are defined between expressions, or even between constraints whenever
   357     ///  it makes sense. Therefore if \c e and \c f are linear expressions and
   357     ///  it makes sense. Therefore if \c e and \c f are linear expressions and
   358     ///  \c s and \c t are numbers, then the followings are valid expressions
   358     ///  \c s and \c t are numbers, then the followings are valid expressions
   359     ///  and thus they can be used directly e.g. in \ref addRow() whenever
   359     ///  and thus they can be used directly e.g. in \ref addRow() whenever
   360     ///  it makes sense.
   360     ///  it makes sense.
   361     ///  \code
   361     ///\code
   362     ///  e<=s
   362     ///  e<=s
   363     ///  e<=f
   363     ///  e<=f
       
   364     ///  e==f
   364     ///  s<=e<=t
   365     ///  s<=e<=t
   365     ///  e>=t
   366     ///  e>=t
   366     ///  \endcode
   367     ///\endcode
   367     ///\warning The validity of a constraint is checked only at run time, so
   368     ///\warning The validity of a constraint is checked only at run time, so
   368     ///e.g. \ref addRow(<tt>x[1]\<=x[2]<=5</tt>) will compile, but will throw a
   369     ///e.g. \ref addRow(<tt>x[1]\<=x[2]<=5</tt>) will compile, but will throw a
   369     ///\ref LogicError exception.
   370     ///\ref LogicError exception.
   370     class Constr
   371     class Constr
   371     {
   372     {
   461     ///  s+=i->second;
   462     ///  s+=i->second;
   462     ///\endcode
   463     ///\endcode
   463     ///(This code computes the sum of all coefficients).
   464     ///(This code computes the sum of all coefficients).
   464     ///- Numbers (<tt>double</tt>'s)
   465     ///- Numbers (<tt>double</tt>'s)
   465     ///and variables (\ref Row "Row"s) directly convert to an
   466     ///and variables (\ref Row "Row"s) directly convert to an
   466     ///\ref DualExpr and the usual linear operations are defined so  
   467     ///\ref DualExpr and the usual linear operations are defined, so
   467     ///\code
   468     ///\code
   468     ///v+w
   469     ///v+w
   469     ///2*v-3.12*(v-w/2)
   470     ///2*v-3.12*(v-w/2)
   470     ///v*2.1+(3*v+(v*12+w)*3)/2
   471     ///v*2.1+(3*v+(v*12+w)*3)/2
   471     ///\endcode
   472     ///\endcode