Learn R Programming

highs (version 1.10.0-1)

hi_solver_set_sense: Set the optimization sense of the solver instance.

Description

This function updates the optimization sense for the given solver instance. Use TRUE for maximization and FALSE for minimization.

Usage

hi_solver_set_sense(solver, maximum)

Value

The updated solver instance with the new optimization sense.

Arguments

solver

An object of class "highs_solver".

maximum

A boolean indicating whether to set maximization (TRUE) or minimization (FALSE).

Examples

Run this code
solver <- example_solver()
hi_solver_set_sense(solver, TRUE)

Run the code above in your browser using DataLab