Load_Problem: Load the optimization problem into Julia environment...

Description Usage Arguments Details Value See Also Examples

View source: R/Load_problem.R

Description

Load_Problem loads the optimization problem into Julia environment. When using each of the Optimize functions, Load_Problem will be automatically called prior to solving the problem. However, the user may want to use Load_Problem to ensure that there is no error in the process of loading the problem and setting up Julia.

Usage

1
2
Load_Problem(First_Objective=0, Second_Objective=0, Risk_Objective=0,
                    Solver="SCIP", Silence= FALSE, Env= .GlobalEnv)

Arguments

First_Objective

A binary parameter: If 1, the first objective function (First_Objectove) will be included in optimization. If 0, it will not be included in optimization.

Second_Objective

A binary parameter: If 1, the second objective function (Second_Objectove) will be included in optimization. If 0, it will not be included in optimization.

Risk_Objective

A binary parameter: If 1, the Risk objective function (Risk_Objectove) will be included in optimization. If 0, it will not be included in optimization.

Solver

A string: defining the solver to be used to solve the problem. (Default= "SCIP")

Silence

A binary parameter: if FALSE, the function will report a summary message. If TRUE, the function will be silent. (Default: FALSE)

Env

the environment where the package should create or access variables. By default the package works in the R's Global environment. (Default: .GlobalEnv)

Details

Load_Problem sets up the Julia environment and creats the necessary variables and functions in Julia. It will also create the optimization model without solving it.

Based on the existance of variables named "Budget", "Connectivity", "Disconnectivity", and "Constraints", Load_Problem will include their respective constraints in the model. If the user does not want to include any of these constraints in the model, its respective variable should not exists in the environment. In other words, if exists("Budget", envir= *)==TRUE, the function will create the Budget constraints in the model, and if exists("Budget", envir= *)==FALSE, no Budget constraint will be included in the optimization model. (Note: * refers to the environment passed to the function as Env parameter.)

Value

NULL (creates some variables in the environment but returns nothing)

See Also

Other Optimizer Functions: Optimize_First_Objective(), Optimize_NBP(), Optimize_Second_Objective(), Optimize_WSO()

Examples

1
2
3
4
5
6
7
8
## Not run: 

## to load objective one and two, but not the risk objective, into Julia environment ##

Load_Problem(First_Objective=1, Second_Objective=1, Risk_Objective=0, Solver="SCIP")


## End(Not run)

paymanghasemi/SiteOpt documentation built on April 8, 2021, 3:44 a.m.