class LinearProgram extends AnyRef
DSL for LinearPrograms. Not thread-safe per instance. Make multiple instances
Basic example:
val lp = new LP import lp._ val x = new Positive("x") val y = new Positive("y") val result = maximize ( (3 * x+ 4 * y) subjectTo( x <= 3, y <= 1)) result.valueOf(x) // 3
Linear Supertypes
Ordering
- Alphabetic
- By Inheritance
Inherited
- LinearProgram
- AnyRef
- Any
- Hide All
- Show All
Visibility
- Public
- All
Instance Constructors
- new LinearProgram()
Type Members
- case class Binary(name: String = "x_" + nextId) extends Variable with Product with Serializable
- sealed trait Constraint extends AnyRef
-
sealed
trait
Expression extends Problem
Anything that can be built up from adding/subtracting/dividing and multiplying by constants
- case class Integer(name: String = "x_" + nextId) extends Variable with Product with Serializable
- sealed trait Problem extends AnyRef
- case class Real(name: String = "x_" + nextId) extends Variable with Product with Serializable
- sealed abstract class Relation extends AnyRef
- case class Result(result: DenseVector[Double], problem: Problem) extends Product with Serializable
- sealed trait Variable extends Expression
Value Members
-
final
def
!=(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
final
def
##(): Int
- Definition Classes
- AnyRef → Any
-
final
def
==(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
final
def
asInstanceOf[T0]: T0
- Definition Classes
- Any
-
def
clone(): AnyRef
- Attributes
- protected[java.lang]
- Definition Classes
- AnyRef
- Annotations
- @native() @HotSpotIntrinsicCandidate() @throws( ... )
-
final
def
eq(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
-
def
equals(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
final
def
getClass(): Class[_]
- Definition Classes
- AnyRef → Any
- Annotations
- @native() @HotSpotIntrinsicCandidate()
-
def
hashCode(): Int
- Definition Classes
- AnyRef → Any
- Annotations
- @native() @HotSpotIntrinsicCandidate()
-
final
def
isInstanceOf[T0]: Boolean
- Definition Classes
- Any
- def maximize(objective: Problem)(implicit solver: Solver): Result
- def minimize(objective: Problem)(implicit solver: Solver): Result
-
final
def
ne(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
-
final
def
notify(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native() @HotSpotIntrinsicCandidate()
-
final
def
notifyAll(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native() @HotSpotIntrinsicCandidate()
-
final
def
synchronized[T0](arg0: ⇒ T0): T0
- Definition Classes
- AnyRef
-
def
toString(): String
- Definition Classes
- AnyRef → Any
-
final
def
wait(arg0: Long, arg1: Int): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )
-
final
def
wait(arg0: Long): Unit
- Definition Classes
- AnyRef
- Annotations
- @native() @throws( ... )
-
final
def
wait(): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )
- object EQ extends Relation with Product with Serializable
- object GTE extends Relation with Product with Serializable
- object LTE extends Relation with Product with Serializable