Code view:

A painting is a person's account of this edit as text, recorded independently of the node mapping - a rendering often has several equally defensible answers where the mapping has one. Deletions and insertions carry no position on the opposite side in a painting, so that panel draws no caret for them.

Before

…lines 1–331 unchanged (331 lines)
332 List<Integer> columnsToDrop = new ArrayList<Integer>();
333 columnsToDrop.add(0);
334
335 // positive cost non-artificial variables
336 for (int i = getNumObjectiveFunctions(); i < getArtificialVariableOffset(); i++) {
337 final double entry = tableau.getEntry(0, i);
338 if (Precision.compareTo(entry, 0d, maxUlps) > 0) {
339 columnsToDrop.add(i);
340 }
341 }
342
343 // non-basic artificial variables
344 for (int i = 0; i < getNumArtificialVariables(); i++) {
…lines 345–624 unchanged (280 lines)

After

…lines 1–331 unchanged (331 lines)
332 List<Integer> columnsToDrop = new ArrayList<Integer>();
333 columnsToDrop.add(0);
334
335 // positive cost non-artificial variables
336 for (int i = getNumObjectiveFunctions(); i < getArtificialVariableOffset(); i++) {
337 final double entry = tableau.getEntry(0, i);
338 if (Precision.compareTo(entry, 0d, epsilon) > 0) {
339 columnsToDrop.add(i);
340 }
341 }
342
343 // non-basic artificial variables
344 for (int i = 0; i < getNumArtificialVariables(); i++) {
…lines 345–624 unchanged (280 lines)

Before

program
block_comment "/*\n * Licensed to the Apache Software Foundation (ASF) under"...
package_declaration
package "package"
scoped_identifier
scoped_identifier
scoped_identifier
scoped_identifier
scoped_identifier
identifier "org"
. "."
identifier "apache"
. "."
identifier "commons"
. "."
identifier "math3"
. "."
identifier "optimization"
. "."
identifier "linear"
; ";"
import_declaration
import "import"
scoped_identifier
scoped_identifier
identifier "java"
. "."
identifier "io"
. "."
identifier "IOException"
; ";"
import_declaration
import "import"
scoped_identifier
scoped_identifier
identifier "java"
. "."
identifier "io"
. "."
identifier "ObjectInputStream"
; ";"
import_declaration
import "import"
scoped_identifier
scoped_identifier
identifier "java"
. "."
identifier "io"
. "."
identifier "ObjectOutputStream"
; ";"
import_declaration
import "import"
scoped_identifier
scoped_identifier
identifier "java"
. "."
identifier "io"
. "."
identifier "Serializable"
; ";"
import_declaration
import "import"
scoped_identifier
scoped_identifier
identifier "java"
. "."
identifier "util"
. "."
identifier "ArrayList"
; ";"
import_declaration
import "import"
scoped_identifier
scoped_identifier
identifier "java"
. "."
identifier "util"
. "."
identifier "Collection"
; ";"
import_declaration
import "import"
scoped_identifier
scoped_identifier
identifier "java"
. "."
identifier "util"
. "."
identifier "HashSet"
; ";"
import_declaration
import "import"
scoped_identifier
scoped_identifier
identifier "java"
. "."
identifier "util"
. "."
identifier "List"
; ";"
import_declaration
import "import"
scoped_identifier
scoped_identifier
identifier "java"
. "."
identifier "util"
. "."
identifier "Set"
; ";"
import_declaration
import "import"
scoped_identifier
scoped_identifier
scoped_identifier
scoped_identifier
scoped_identifier
identifier "org"
. "."
identifier "apache"
. "."
identifier "commons"
. "."
identifier "math3"
. "."
identifier "linear"
. "."
identifier "Array2DRowRealMatrix"
; ";"
import_declaration
import "import"
scoped_identifier
scoped_identifier
scoped_identifier
scoped_identifier
scoped_identifier
identifier "org"
. "."
identifier "apache"
. "."
identifier "commons"
. "."
identifier "math3"
. "."
identifier "linear"
. "."
identifier "MatrixUtils"
; ";"
import_declaration
import "import"
scoped_identifier
scoped_identifier
scoped_identifier
scoped_identifier
scoped_identifier
identifier "org"
. "."
identifier "apache"
. "."
identifier "commons"
. "."
identifier "math3"
. "."
identifier "linear"
. "."
identifier "RealMatrix"
; ";"
import_declaration
import "import"
scoped_identifier
scoped_identifier
scoped_identifier
scoped_identifier
scoped_identifier
identifier "org"
. "."
identifier "apache"
. "."
identifier "commons"
. "."
identifier "math3"
. "."
identifier "linear"
. "."
identifier "RealVector"
; ";"
import_declaration
import "import"
scoped_identifier
scoped_identifier
scoped_identifier
scoped_identifier
scoped_identifier
identifier "org"
. "."
identifier "apache"
. "."
identifier "commons"
. "."
identifier "math3"
. "."
identifier "optimization"
. "."
identifier "GoalType"
; ";"
import_declaration
import "import"
scoped_identifier
scoped_identifier
scoped_identifier
scoped_identifier
scoped_identifier
identifier "org"
. "."
identifier "apache"
. "."
identifier "commons"
. "."
identifier "math3"
. "."
identifier "optimization"
. "."
identifier "PointValuePair"
; ";"
import_declaration
import "import"
scoped_identifier
scoped_identifier
scoped_identifier
scoped_identifier
scoped_identifier
identifier "org"
. "."
identifier "apache"
. "."
identifier "commons"
. "."
identifier "math3"
. "."
identifier "util"
. "."
identifier "Precision"
; ";"
block_comment "/**\n * A tableau for use in the Simplex method.\n *\n * <p>\n *"...
class_declaration
class "class"
identifier "SimplexTableau"
super_interfaces
implements "implements"
type_list
type_identifier "Serializable"
class_body
{ "{"
block_comment "/** Column label for negative vars. */"
field_declaration
modifiers
private "private"
static "static"
final "final"
type_identifier "String"
variable_declarator
identifier "NEGATIVE_VAR_COLUMN_LABEL"
= "="
string_literal
" "\""
string_fragment "x-"
" "\""
; ";"
block_comment "/** Default amount of error to accept in floating point comp"...
field_declaration
modifiers
private "private"
static "static"
final "final"
integral_type
int "int"
variable_declarator
identifier "DEFAULT_ULPS"
= "="
decimal_integer_literal "10"
; ";"
block_comment "/** Serializable version identifier. */"
field_declaration
modifiers
private "private"
static "static"
final "final"
integral_type
long "long"
variable_declarator
identifier "serialVersionUID"
= "="
unary_expression
- "-"
decimal_integer_literal "1369660067587938365L"
; ";"
block_comment "/** Linear objective function. */"
field_declaration
modifiers
private "private"
final "final"
type_identifier "LinearObjectiveFunction"
variable_declarator
identifier "f"
; ";"
block_comment "/** Linear constraints. */"
field_declaration
modifiers
private "private"
final "final"
generic_type
type_identifier "List"
type_arguments
< "<"
type_identifier "LinearConstraint"
> ">"
variable_declarator
identifier "constraints"
; ";"
block_comment "/** Whether to restrict the variables to non-negative values"...
field_declaration
modifiers
private "private"
final "final"
boolean_type "boolean"
variable_declarator
identifier "restrictToNonNegative"
; ";"
block_comment "/** The variables each column represents */"
field_declaration (+25 nodes collapsed)
block_comment "/** Simple tableau. */"
field_declaration
modifiers
private "private"
transient "transient"
type_identifier "RealMatrix"
variable_declarator
identifier "tableau"
; ";"
block_comment "/** Number of decision variables. */"
field_declaration
modifiers
private "private"
final "final"
integral_type
int "int"
variable_declarator
identifier "numDecisionVariables"
; ";"
block_comment "/** Number of slack variables. */"
field_declaration
modifiers
private "private"
final "final"
integral_type
int "int"
variable_declarator
identifier "numSlackVariables"
; ";"
block_comment "/** Number of artificial variables. */"
field_declaration
modifiers
private "private"
integral_type
int "int"
variable_declarator
identifier "numArtificialVariables"
; ";"
block_comment "/** Amount of error to accept when checking for optimality. "...
field_declaration
modifiers
private "private"
final "final"
floating_point_type
double "double"
variable_declarator
identifier "epsilon"
; ";"
block_comment "/** Amount of error to accept in floating point comparisons."...
field_declaration
modifiers
private "private"
final "final"
integral_type
int "int"
variable_declarator
identifier "maxUlps"
; ";"
block_comment "/**\n * Build a tableau for a linear problem.\n * @par"...
constructor_declaration (+60 nodes collapsed)
block_comment "/**\n * Build a tableau for a linear problem.\n * @par"...
constructor_declaration (+215 nodes collapsed)
block_comment "/**\n * Initialize the labels for the columns.\n */"
method_declaration (+216 nodes collapsed)
block_comment "/**\n * Create the tableau by itself.\n * @param maxim"...
method_declaration (+684 nodes collapsed)
block_comment "/**\n * Get new versions of the constraints which have po"...
method_declaration (+76 nodes collapsed)
block_comment "/**\n * Get a new equation equivalent to this one with a "...
method_declaration (+118 nodes collapsed)
block_comment "/**\n * Get the number of objective functions in this tab"...
method_declaration (+28 nodes collapsed)
block_comment "/**\n * Get a count of constraints corresponding to a spe"...
method_declaration (+65 nodes collapsed)
block_comment "/**\n * Get the -1 times the sum of all coefficients in t"...
method_declaration (+54 nodes collapsed)
block_comment "/**\n * Checks whether the given column is basic.\n * "...
method_declaration (+134 nodes collapsed)
block_comment "/**\n * Removes the phase 1 objective function, positive "...
method_declaration
modifiers
protected "protected"
void_type "void"
identifier "dropPhase1Objective"
formal_parameters
( "("
) ")"
block
{ "{"
if_statement
if "if"
parenthesized_expression
( "("
binary_expression
method_invocation
identifier "getNumObjectiveFunctions"
argument_list
( "("
) ")"
== "=="
decimal_integer_literal "1"
) ")"
block
{ "{"
return_statement
return "return"
; ";"
} "}"
local_variable_declaration (+22 nodes collapsed)
expression_statement
method_invocation
identifier "columnsToDrop"
. "."
identifier "add"
argument_list
( "("
decimal_integer_literal "0"
) ")"
; ";"
line_comment "// positive cost non-artificial variables"
for_statement
for "for"
( "("
local_variable_declaration
integral_type
int "int"
variable_declarator
identifier "i"
= "="
method_invocation
identifier "getNumObjectiveFunctions"
argument_list
( "("
) ")"
; ";"
binary_expression
identifier "i"
< "<"
method_invocation
identifier "getArtificialVariableOffset"
argument_list
( "("
) ")"
; ";"
update_expression
identifier "i"
++ "++"
) ")"
block
{ "{"
local_variable_declaration
modifiers
final "final"
floating_point_type
double "double"
variable_declarator
identifier "entry"
= "="
method_invocation
identifier "tableau"
. "."
identifier "getEntry"
argument_list
( "("
decimal_integer_literal "0"
, ","
identifier "i"
) ")"
; ";"
if_statement
if "if"
parenthesized_expression
( "("
binary_expression
method_invocation
identifier "Precision"
. "."
identifier "compareTo"
argument_list
( "("
identifier "entry"
, ","
decimal_floating_point_literal "0d"
, ","
identifier "maxUlps"
) ")"
> ">"
decimal_integer_literal "0"
) ")"
block
{ "{"
expression_statement
method_invocation
identifier "columnsToDrop"
. "."
identifier "add"
argument_list
( "("
identifier "i"
) ")"
; ";"
} "}"
} "}"
line_comment "// non-basic artificial variables"
for_statement (+69 nodes collapsed)
local_variable_declaration (+45 nodes collapsed)
for_statement (+108 nodes collapsed)
for_statement (+54 nodes collapsed)
expression_statement
assignment_expression
field_access
this "this"
. "."
identifier "tableau"
= "="
object_creation_expression
new "new"
type_identifier "Array2DRowRealMatrix"
argument_list
( "("
identifier "matrix"
) ")"
; ";"
expression_statement
assignment_expression
field_access
this "this"
. "."
identifier "numArtificialVariables"
= "="
decimal_integer_literal "0"
; ";"
} "}"
block_comment "/**\n * @param src the source array\n * @param dest th"...
method_declaration (+57 nodes collapsed)
block_comment "/**\n * Returns whether the problem is at an optimal stat"...
method_declaration (+93 nodes collapsed)
block_comment "/**\n * Get the current solution.\n *\n * @return c"...
method_declaration (+349 nodes collapsed)
block_comment "/**\n * Subtracts a multiple of one row from another.\n "...
method_declaration (+77 nodes collapsed)
block_comment "/**\n * Subtracts a multiple of one row from another.\n "...
method_declaration (+71 nodes collapsed)
block_comment "/**\n * Get the width of the tableau.\n * @return widt"...
method_declaration (+23 nodes collapsed)
block_comment "/**\n * Get the height of the tableau.\n * @return hei"...
method_declaration (+23 nodes collapsed)
block_comment "/** Get an entry of the tableau.\n * @param row row index"...
method_declaration (+39 nodes collapsed)
block_comment "/** Set an entry of the tableau.\n * @param row row index"...
method_declaration (+46 nodes collapsed)
block_comment "/**\n * Get the offset of the first slack variable.\n "...
method_declaration (+24 nodes collapsed)
block_comment "/**\n * Get the offset of the first artificial variable.\n"...
method_declaration (+27 nodes collapsed)
block_comment "/**\n * Get the offset of the right hand side.\n * @re"...
method_declaration (+24 nodes collapsed)
block_comment "/**\n * Get the number of decision variables.\n * <p>\n"...
method_declaration
modifiers
protected "protected"
final "final"
integral_type
int "int"
identifier "getNumDecisionVariables"
formal_parameters
( "("
) ")"
block
{ "{"
return_statement
return "return"
identifier "numDecisionVariables"
; ";"
} "}"
block_comment "/**\n * Get the original number of decision variables.\n "...
method_declaration (+29 nodes collapsed)
block_comment "/**\n * Get the number of slack variables.\n * @return"...
method_declaration
modifiers
protected "protected"
final "final"
integral_type
int "int"
identifier "getNumSlackVariables"
formal_parameters
( "("
) ")"
block
{ "{"
return_statement
return "return"
identifier "numSlackVariables"
; ";"
} "}"
block_comment "/**\n * Get the number of artificial variables.\n * @r"...
method_declaration
modifiers
protected "protected"
final "final"
integral_type
int "int"
identifier "getNumArtificialVariables"
formal_parameters
( "("
) ")"
block
{ "{"
return_statement
return "return"
identifier "numArtificialVariables"
; ";"
} "}"
block_comment "/**\n * Get the tableau data.\n * @return tableau data"...
method_declaration (+29 nodes collapsed)
block_comment "/** {@inheritDoc} */"
method_declaration (+172 nodes collapsed)
block_comment "/** {@inheritDoc} */"
method_declaration (+87 nodes collapsed)
block_comment "/** Serialize the instance.\n * @param oos stream where o"...
method_declaration (+38 nodes collapsed)
block_comment "/** Deserialize the instance.\n * @param ois stream from "...
method_declaration (+45 nodes collapsed)
} "}"

After

program
block_comment "/*\n * Licensed to the Apache Software Foundation (ASF) under"...
package_declaration
package "package"
scoped_identifier
scoped_identifier
scoped_identifier
scoped_identifier
scoped_identifier
identifier "org"
. "."
identifier "apache"
. "."
identifier "commons"
. "."
identifier "math3"
. "."
identifier "optimization"
. "."
identifier "linear"
; ";"
import_declaration
import "import"
scoped_identifier
scoped_identifier
identifier "java"
. "."
identifier "io"
. "."
identifier "IOException"
; ";"
import_declaration
import "import"
scoped_identifier
scoped_identifier
identifier "java"
. "."
identifier "io"
. "."
identifier "ObjectInputStream"
; ";"
import_declaration
import "import"
scoped_identifier
scoped_identifier
identifier "java"
. "."
identifier "io"
. "."
identifier "ObjectOutputStream"
; ";"
import_declaration
import "import"
scoped_identifier
scoped_identifier
identifier "java"
. "."
identifier "io"
. "."
identifier "Serializable"
; ";"
import_declaration
import "import"
scoped_identifier
scoped_identifier
identifier "java"
. "."
identifier "util"
. "."
identifier "ArrayList"
; ";"
import_declaration
import "import"
scoped_identifier
scoped_identifier
identifier "java"
. "."
identifier "util"
. "."
identifier "Collection"
; ";"
import_declaration
import "import"
scoped_identifier
scoped_identifier
identifier "java"
. "."
identifier "util"
. "."
identifier "HashSet"
; ";"
import_declaration
import "import"
scoped_identifier
scoped_identifier
identifier "java"
. "."
identifier "util"
. "."
identifier "List"
; ";"
import_declaration
import "import"
scoped_identifier
scoped_identifier
identifier "java"
. "."
identifier "util"
. "."
identifier "Set"
; ";"
import_declaration
import "import"
scoped_identifier
scoped_identifier
scoped_identifier
scoped_identifier
scoped_identifier
identifier "org"
. "."
identifier "apache"
. "."
identifier "commons"
. "."
identifier "math3"
. "."
identifier "linear"
. "."
identifier "Array2DRowRealMatrix"
; ";"
import_declaration
import "import"
scoped_identifier
scoped_identifier
scoped_identifier
scoped_identifier
scoped_identifier
identifier "org"
. "."
identifier "apache"
. "."
identifier "commons"
. "."
identifier "math3"
. "."
identifier "linear"
. "."
identifier "MatrixUtils"
; ";"
import_declaration
import "import"
scoped_identifier
scoped_identifier
scoped_identifier
scoped_identifier
scoped_identifier
identifier "org"
. "."
identifier "apache"
. "."
identifier "commons"
. "."
identifier "math3"
. "."
identifier "linear"
. "."
identifier "RealMatrix"
; ";"
import_declaration
import "import"
scoped_identifier
scoped_identifier
scoped_identifier
scoped_identifier
scoped_identifier
identifier "org"
. "."
identifier "apache"
. "."
identifier "commons"
. "."
identifier "math3"
. "."
identifier "linear"
. "."
identifier "RealVector"
; ";"
import_declaration
import "import"
scoped_identifier
scoped_identifier
scoped_identifier
scoped_identifier
scoped_identifier
identifier "org"
. "."
identifier "apache"
. "."
identifier "commons"
. "."
identifier "math3"
. "."
identifier "optimization"
. "."
identifier "GoalType"
; ";"
import_declaration
import "import"
scoped_identifier
scoped_identifier
scoped_identifier
scoped_identifier
scoped_identifier
identifier "org"
. "."
identifier "apache"
. "."
identifier "commons"
. "."
identifier "math3"
. "."
identifier "optimization"
. "."
identifier "PointValuePair"
; ";"
import_declaration
import "import"
scoped_identifier
scoped_identifier
scoped_identifier
scoped_identifier
scoped_identifier
identifier "org"
. "."
identifier "apache"
. "."
identifier "commons"
. "."
identifier "math3"
. "."
identifier "util"
. "."
identifier "Precision"
; ";"
block_comment "/**\n * A tableau for use in the Simplex method.\n *\n * <p>\n *"...
class_declaration
class "class"
identifier "SimplexTableau"
super_interfaces
implements "implements"
type_list
type_identifier "Serializable"
class_body
{ "{"
block_comment "/** Column label for negative vars. */"
field_declaration
modifiers
private "private"
static "static"
final "final"
type_identifier "String"
variable_declarator
identifier "NEGATIVE_VAR_COLUMN_LABEL"
= "="
string_literal
" "\""
string_fragment "x-"
" "\""
; ";"
block_comment "/** Default amount of error to accept in floating point comp"...
field_declaration
modifiers
private "private"
static "static"
final "final"
integral_type
int "int"
variable_declarator
identifier "DEFAULT_ULPS"
= "="
decimal_integer_literal "10"
; ";"
block_comment "/** Serializable version identifier. */"
field_declaration
modifiers
private "private"
static "static"
final "final"
integral_type
long "long"
variable_declarator
identifier "serialVersionUID"
= "="
unary_expression
- "-"
decimal_integer_literal "1369660067587938365L"
; ";"
block_comment "/** Linear objective function. */"
field_declaration
modifiers
private "private"
final "final"
type_identifier "LinearObjectiveFunction"
variable_declarator
identifier "f"
; ";"
block_comment "/** Linear constraints. */"
field_declaration
modifiers
private "private"
final "final"
generic_type
type_identifier "List"
type_arguments
< "<"
type_identifier "LinearConstraint"
> ">"
variable_declarator
identifier "constraints"
; ";"
block_comment "/** Whether to restrict the variables to non-negative values"...
field_declaration
modifiers
private "private"
final "final"
boolean_type "boolean"
variable_declarator
identifier "restrictToNonNegative"
; ";"
block_comment "/** The variables each column represents */"
field_declaration (+25 nodes collapsed)
block_comment "/** Simple tableau. */"
field_declaration
modifiers
private "private"
transient "transient"
type_identifier "RealMatrix"
variable_declarator
identifier "tableau"
; ";"
block_comment "/** Number of decision variables. */"
field_declaration
modifiers
private "private"
final "final"
integral_type
int "int"
variable_declarator
identifier "numDecisionVariables"
; ";"
block_comment "/** Number of slack variables. */"
field_declaration
modifiers
private "private"
final "final"
integral_type
int "int"
variable_declarator
identifier "numSlackVariables"
; ";"
block_comment "/** Number of artificial variables. */"
field_declaration
modifiers
private "private"
integral_type
int "int"
variable_declarator
identifier "numArtificialVariables"
; ";"
block_comment "/** Amount of error to accept when checking for optimality. "...
field_declaration
modifiers
private "private"
final "final"
floating_point_type
double "double"
variable_declarator
identifier "epsilon"
; ";"
block_comment "/** Amount of error to accept in floating point comparisons."...
field_declaration
modifiers
private "private"
final "final"
integral_type
int "int"
variable_declarator
identifier "maxUlps"
; ";"
block_comment "/**\n * Build a tableau for a linear problem.\n * @par"...
constructor_declaration (+60 nodes collapsed)
block_comment "/**\n * Build a tableau for a linear problem.\n * @par"...
constructor_declaration (+215 nodes collapsed)
block_comment "/**\n * Initialize the labels for the columns.\n */"
method_declaration (+216 nodes collapsed)
block_comment "/**\n * Create the tableau by itself.\n * @param maxim"...
method_declaration (+684 nodes collapsed)
block_comment "/**\n * Get new versions of the constraints which have po"...
method_declaration (+76 nodes collapsed)
block_comment "/**\n * Get a new equation equivalent to this one with a "...
method_declaration (+118 nodes collapsed)
block_comment "/**\n * Get the number of objective functions in this tab"...
method_declaration (+28 nodes collapsed)
block_comment "/**\n * Get a count of constraints corresponding to a spe"...
method_declaration (+65 nodes collapsed)
block_comment "/**\n * Get the -1 times the sum of all coefficients in t"...
method_declaration (+54 nodes collapsed)
block_comment "/**\n * Checks whether the given column is basic.\n * "...
method_declaration (+134 nodes collapsed)
block_comment "/**\n * Removes the phase 1 objective function, positive "...
method_declaration
modifiers
protected "protected"
void_type "void"
identifier "dropPhase1Objective"
formal_parameters
( "("
) ")"
block
{ "{"
if_statement
if "if"
parenthesized_expression
( "("
binary_expression
method_invocation
identifier "getNumObjectiveFunctions"
argument_list
( "("
) ")"
== "=="
decimal_integer_literal "1"
) ")"
block
{ "{"
return_statement
return "return"
; ";"
} "}"
local_variable_declaration (+22 nodes collapsed)
expression_statement
method_invocation
identifier "columnsToDrop"
. "."
identifier "add"
argument_list
( "("
decimal_integer_literal "0"
) ")"
; ";"
line_comment "// positive cost non-artificial variables"
for_statement
for "for"
( "("
local_variable_declaration
integral_type
int "int"
variable_declarator
identifier "i"
= "="
method_invocation
identifier "getNumObjectiveFunctions"
argument_list
( "("
) ")"
; ";"
binary_expression
identifier "i"
< "<"
method_invocation
identifier "getArtificialVariableOffset"
argument_list
( "("
) ")"
; ";"
update_expression
identifier "i"
++ "++"
) ")"
block
{ "{"
local_variable_declaration
modifiers
final "final"
floating_point_type
double "double"
variable_declarator
identifier "entry"
= "="
method_invocation
identifier "tableau"
. "."
identifier "getEntry"
argument_list
( "("
decimal_integer_literal "0"
, ","
identifier "i"
) ")"
; ";"
if_statement
if "if"
parenthesized_expression
( "("
binary_expression
method_invocation
identifier "Precision"
. "."
identifier "compareTo"
argument_list
( "("
identifier "entry"
, ","
decimal_floating_point_literal "0d"
, ","
identifier "epsilon"
) ")"
> ">"
decimal_integer_literal "0"
) ")"
block
{ "{"
expression_statement
method_invocation
identifier "columnsToDrop"
. "."
identifier "add"
argument_list
( "("
identifier "i"
) ")"
; ";"
} "}"
} "}"
line_comment "// non-basic artificial variables"
for_statement (+69 nodes collapsed)
local_variable_declaration (+45 nodes collapsed)
for_statement (+108 nodes collapsed)
for_statement (+54 nodes collapsed)
expression_statement
assignment_expression
field_access
this "this"
. "."
identifier "tableau"
= "="
object_creation_expression
new "new"
type_identifier "Array2DRowRealMatrix"
argument_list
( "("
identifier "matrix"
) ")"
; ";"
expression_statement
assignment_expression
field_access
this "this"
. "."
identifier "numArtificialVariables"
= "="
decimal_integer_literal "0"
; ";"
} "}"
block_comment "/**\n * @param src the source array\n * @param dest th"...
method_declaration (+57 nodes collapsed)
block_comment "/**\n * Returns whether the problem is at an optimal stat"...
method_declaration (+93 nodes collapsed)
block_comment "/**\n * Get the current solution.\n *\n * @return c"...
method_declaration (+349 nodes collapsed)
block_comment "/**\n * Subtracts a multiple of one row from another.\n "...
method_declaration (+77 nodes collapsed)
block_comment "/**\n * Subtracts a multiple of one row from another.\n "...
method_declaration (+71 nodes collapsed)
block_comment "/**\n * Get the width of the tableau.\n * @return widt"...
method_declaration (+23 nodes collapsed)
block_comment "/**\n * Get the height of the tableau.\n * @return hei"...
method_declaration (+23 nodes collapsed)
block_comment "/** Get an entry of the tableau.\n * @param row row index"...
method_declaration (+39 nodes collapsed)
block_comment "/** Set an entry of the tableau.\n * @param row row index"...
method_declaration (+46 nodes collapsed)
block_comment "/**\n * Get the offset of the first slack variable.\n "...
method_declaration (+24 nodes collapsed)
block_comment "/**\n * Get the offset of the first artificial variable.\n"...
method_declaration (+27 nodes collapsed)
block_comment "/**\n * Get the offset of the right hand side.\n * @re"...
method_declaration (+24 nodes collapsed)
block_comment "/**\n * Get the number of decision variables.\n * <p>\n"...
method_declaration
modifiers
protected "protected"
final "final"
integral_type
int "int"
identifier "getNumDecisionVariables"
formal_parameters
( "("
) ")"
block
{ "{"
return_statement
return "return"
identifier "numDecisionVariables"
; ";"
} "}"
block_comment "/**\n * Get the original number of decision variables.\n "...
method_declaration (+29 nodes collapsed)
block_comment "/**\n * Get the number of slack variables.\n * @return"...
method_declaration
modifiers
protected "protected"
final "final"
integral_type
int "int"
identifier "getNumSlackVariables"
formal_parameters
( "("
) ")"
block
{ "{"
return_statement
return "return"
identifier "numSlackVariables"
; ";"
} "}"
block_comment "/**\n * Get the number of artificial variables.\n * @r"...
method_declaration
modifiers
protected "protected"
final "final"
integral_type
int "int"
identifier "getNumArtificialVariables"
formal_parameters
( "("
) ")"
block
{ "{"
return_statement
return "return"
identifier "numArtificialVariables"
; ";"
} "}"
block_comment "/**\n * Get the tableau data.\n * @return tableau data"...
method_declaration (+29 nodes collapsed)
block_comment "/** {@inheritDoc} */"
method_declaration (+172 nodes collapsed)
block_comment "/** {@inheritDoc} */"
method_declaration (+87 nodes collapsed)
block_comment "/** Serialize the instance.\n * @param oos stream where o"...
method_declaration (+38 nodes collapsed)
block_comment "/** Deserialize the instance.\n * @param ois stream from "...
method_declaration (+45 nodes collapsed)
} "}"