suite_biobj_utilities.c File Reference

Implementation of some functions (mostly handling instances) used by the bi-objective suites. More...

Data Structures

struct  suite_biobj_new_inst_t
 A structure containing information about the new instances. More...
 

Functions

static void suite_biobj_new_inst_free (void *stuff)
 Frees the memory of the given suite_biobj_new_inst_t object. More...
 
static int suite_biobj_check_inst_consistency (const size_t dimension, size_t function1, size_t instance1, size_t function2, size_t instance2)
 Performs a few checks and returns whether the two given problem instances should break the search for new instances in suite_biobj_get_new_instance(). More...
 
static size_t suite_biobj_get_new_instance (suite_biobj_new_inst_t *new_inst_data, const size_t instance, const size_t instance1, const size_t *bbob_functions, const size_t num_bbob_functions, const size_t *sel_bbob_functions, const size_t num_sel_bbob_functions, const size_t *dimensions, const size_t num_dimensions)
 Computes the instance number of the second problem/objective so that the resulting bi-objective problem has more than a single optimal solution. More...
 
static coco_problem_tcoco_get_biobj_problem (const size_t function, const size_t dimension, const size_t instance, const coco_get_problem_function_t coco_get_problem_function, suite_biobj_new_inst_t **new_inst_data, const size_t num_new_instances, const size_t *dimensions, const size_t num_dimensions)
 Creates and returns a bi-objective problem without needing a suite. More...
 
static double suite_biobj_get_best_hyp_value (const char *suite_name, const char *key)
 Returns the best known value for the hypervolume indicator matching the given key if the key is found, and throws a coco_error otherwise. More...
 

Variables

static const size_t suite_biobj_instances [][3]
 The array of triples biobj_instance - problem1_instance - problem2_instance connecting bi-objective suite instances to the instances of the bbob suite. More...
 

Detailed Description

Implementation of some functions (mostly handling instances) used by the bi-objective suites.

Note
Because some bi-objective problems constructed from two single-objective ones have a single optimal value, some care must be taken when selecting the instances. The already verified instances are stored in suite_biobj_instances. If a new instance of the problem is called, a check ensures that the two underlying single-objective instances create a true bi-objective problem. However, these new instances need to be manually added to suite_biobj_instances, otherwise they will be computed each time the suite constructor is invoked with these instances.

Function Documentation

static coco_problem_t* coco_get_biobj_problem ( const size_t  function,
const size_t  dimension,
const size_t  instance,
const coco_get_problem_function_t  coco_get_problem_function,
suite_biobj_new_inst_t **  new_inst_data,
const size_t  num_new_instances,
const size_t *  dimensions,
const size_t  num_dimensions 
)
static

Creates and returns a bi-objective problem without needing a suite.

Useful for creating suites based on the bi-objective problems.

Creates the bi-objective problem by constructing it from two single-objective problems. If the invoked instance number is not in suite_biobj_instances, the function uses the following formula to construct a new appropriate instance: problem1_instance = 2 * biobj_instance + 1 problem2_instance = problem1_instance + 1

If needed, problem2_instance is increased (see also the explanation in suite_biobj_get_new_instance).

Parameters
functionFunction
dimensionDimension
instanceInstance
coco_get_problem_functionThe function that is used to access the single-objective problem.
new_inst_dataStructure containing information on new instance data.
num_new_instancesThe number of new instances.
dimensionsAn array of dimensions to take into account when creating new instances.
num_dimensionsThe number of dimensions to take into account when creating new instances.
Returns
The problem that corresponds to the given parameters.
static int suite_biobj_check_inst_consistency ( const size_t  dimension,
size_t  function1,
size_t  instance1,
size_t  function2,
size_t  instance2 
)
static

Performs a few checks and returns whether the two given problem instances should break the search for new instances in suite_biobj_get_new_instance().

static double suite_biobj_get_best_hyp_value ( const char *  suite_name,
const char *  key 
)
static

Returns the best known value for the hypervolume indicator matching the given key if the key is found, and throws a coco_error otherwise.

Note
This function needs to be updated when a new biobjective suite is added to COCO.
static size_t suite_biobj_get_new_instance ( suite_biobj_new_inst_t new_inst_data,
const size_t  instance,
const size_t  instance1,
const size_t *  bbob_functions,
const size_t  num_bbob_functions,
const size_t *  sel_bbob_functions,
const size_t  num_sel_bbob_functions,
const size_t *  dimensions,
const size_t  num_dimensions 
)
static

Computes the instance number of the second problem/objective so that the resulting bi-objective problem has more than a single optimal solution.

Starts by setting instance2 = instance1 + 1 and increases this number until an appropriate instance has been found (or until a maximum number of tries has been reached, in which case it throws a coco_error). An appropriate instance is the one for which the resulting bi-objective problem (in any considered dimension) has the ideal and nadir points apart enough in the objective space and the extreme optimal points apart enough in the decision space. When the instance has been found, it is output through coco_warning, so that the user can see it and eventually manually add it to suite_biobj_instances.

static void suite_biobj_new_inst_free ( void *  stuff)
static

Frees the memory of the given suite_biobj_new_inst_t object.

Variable Documentation

const size_t suite_biobj_instances[][3]
static
Initial value:
= {
{ 1, 2, 4 },
{ 2, 3, 5 },
{ 3, 7, 8 },
{ 4, 9, 10 },
{ 5, 11, 12 },
{ 6, 13, 14 },
{ 7, 15, 16 },
{ 8, 17, 18 },
{ 9, 19, 21 },
{ 10, 21, 22 },
{ 11, 23, 24 },
{ 12, 25, 26 },
{ 13, 27, 28 },
{ 14, 29, 30 },
{ 15, 31, 34 }
}

The array of triples biobj_instance - problem1_instance - problem2_instance connecting bi-objective suite instances to the instances of the bbob suite.

It should be updated with new instances when/if they are chosen.