Class: OPL::VariableCoefficientPair

Inherits:
Object
  • Object
show all
Defined in:
lib/opl.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(variable, coefficient, variable_type = 1) ⇒ VariableCoefficientPair

Returns a new instance of VariableCoefficientPair.



864
865
866
867
868
# File 'lib/opl.rb', line 864

def initialize(variable, coefficient, variable_type=1)
  @variable = variable
  @coefficient = coefficient
  @variable_type = variable_type
end

Instance Attribute Details

#coefficientObject

Returns the value of attribute coefficient.



859
860
861
# File 'lib/opl.rb', line 859

def coefficient
  @coefficient
end

#lower_boundObject

Returns the value of attribute lower_bound.



861
862
863
# File 'lib/opl.rb', line 861

def lower_bound
  @lower_bound
end

#upper_boundObject

Returns the value of attribute upper_bound.



862
863
864
# File 'lib/opl.rb', line 862

def upper_bound
  @upper_bound
end

#variableObject

Returns the value of attribute variable.



858
859
860
# File 'lib/opl.rb', line 858

def variable
  @variable
end

#variable_typeObject

Returns the value of attribute variable_type.



860
861
862
# File 'lib/opl.rb', line 860

def variable_type
  @variable_type
end