VeraGridEngine.Simulations.CatalogueOptimization.Problems packageο
Submodulesο
VeraGridEngine.Simulations.CatalogueOptimization.Problems.catalogue_problem moduleο
- class VeraGridEngine.Simulations.CatalogueOptimization.Problems.catalogue_problem.CatalogueOptimizationProblem(grid: MultiCircuit, pf_options: PowerFlowOptions, selected_branches: List[Line | Transformer2W], voltage_tolerance: float = 0.1)[source]ο
Bases:
BlackBoxProblemTemplateMulti-objective black-box problem that selects, for each user-pre-selected branch, a template from the gridβs catalogue so as to minimise the six techno-economic scores (losses, overload, voltage module, voltage angle, financial, technical).
The decision vector x is integer-valued: x[i] is the index of the chosen template within the pool associated with branch branches[i].
- get_objectives_names() ndarray[tuple[Any, ...], dtype[str_]][source]ο
Get the human-readable names for the elements of f.
- Returns:
array of objective names matching the order of objective_functionβs output.
- get_vars_names() ndarray[tuple[Any, ...], dtype[str_]][source]ο
Get the human-readable names for the elements of x.
- Returns:
array of branch names; one entry per decision slot.
- n_objectives() int[source]ο
Number of objectives in f.
- Returns:
6 (losses, overload, voltage module, voltage angle, financial, technical).
- n_vars() int[source]ο
Number of decision variables in x.
- Returns:
number of optimisable branch slots.
- objective_function(x: ndarray[tuple[Any, ...], dtype[float64]] | ndarray[tuple[Any, ...], dtype[int64]]) ndarray[tuple[Any, ...], dtype[float64]][source]ο
Evaluate the objective function f(x).
- Strategy:
Apply the chosen templates to every branch and compute the financial cost.
Run a power flow on the modified grid and compute the four technical scores.
Restore every branch to its baseline state, regardless of whether the PF succeeded.
Return the six-objective vector.
- Parameters:
x β integer decision vector with x[i] indexing the template within pools[i].
- Returns:
array of six objective values.