diff --git a/open-reac/src/test/java/com/powsybl/openreac/optimization/AbstractOpenReacRunnerTest.java b/open-reac/src/test/java/com/powsybl/openreac/optimization/AbstractOpenReacRunnerTest.java index fa2db175..f45e326b 100644 --- a/open-reac/src/test/java/com/powsybl/openreac/optimization/AbstractOpenReacRunnerTest.java +++ b/open-reac/src/test/java/com/powsybl/openreac/optimization/AbstractOpenReacRunnerTest.java @@ -29,6 +29,7 @@ import java.io.InputStream; import java.nio.file.FileSystem; import java.nio.file.Path; +import java.util.ArrayList; import java.util.List; import java.util.Objects; import java.util.concurrent.ForkJoinPool; @@ -82,29 +83,56 @@ protected void testAllModifAndLoadFlow(Network network, String subFolder, OpenRe /** * Runs OpenReac and apply the results on the network. + * The application of the voltage plan calculated by optimization is optional. */ protected void runAndApplyAllModifications(Network network, String subFolder, OpenReacParameters parameters, - boolean updateNetworkWithVoltages, ReportNode reportNode) throws IOException { + boolean updateNetworkWithVoltages, ReportNode reportNode) throws IOException { + OpenReacResult openReacResult = runOpenReac(network, subFolder, parameters, false, reportNode); + assertEquals(OpenReacStatus.OK, openReacResult.getStatus()); + openReacResult.setUpdateNetworkWithVoltages(updateNetworkWithVoltages); + openReacResult.applyAllModifications(network); + } + + /** + * Runs OpenReac and returns associated result. + */ + protected OpenReacResult runOpenReac(Network network, String subFolder, boolean onlyIndicators) throws IOException { + return runOpenReac(network, subFolder, new OpenReacParameters(), onlyIndicators); + } + + /** + * Runs OpenReac and returns associated result. + */ + protected OpenReacResult runOpenReac(Network network, String subFolder, OpenReacParameters parameters, boolean onlyIndicators) throws IOException { + return runOpenReac(network, subFolder, parameters, onlyIndicators, ReportNode.NO_OP); + } + + /** + * Runs OpenReac and returns associated result. + * Note that OpenReac is not really executed by default. If the execution line is not uncommented, + * the results are retrieved and stored in an {@link OpenReacResult} object. + */ + protected OpenReacResult runOpenReac(Network network, String subFolder, OpenReacParameters parameters, + boolean onlyIndicators, ReportNode reportNode) throws IOException { // set default voltage limits to every voltage levels of the network setDefaultVoltageLimits(network); - LocalCommandExecutor localCommandExecutor = new TestLocalCommandExecutor( - List.of(subFolder + "/reactiveopf_results_generators.csv", - subFolder + "/reactiveopf_results_indic.txt", - subFolder + "/reactiveopf_results_rtc.csv", - subFolder + "/reactiveopf_results_shunts.csv", - subFolder + "/reactiveopf_results_static_var_compensators.csv", - subFolder + "/reactiveopf_results_vsc_converter_stations.csv", - subFolder + "/reactiveopf_results_voltages.csv")); + List outputFileNames = new ArrayList<>(List.of(subFolder + "/reactiveopf_results_indic.txt")); + if (!onlyIndicators) { + outputFileNames.addAll(List.of( + subFolder + "/reactiveopf_results_rtc.csv", + subFolder + "/reactiveopf_results_shunts.csv", + subFolder + "/reactiveopf_results_static_var_compensators.csv", + subFolder + "/reactiveopf_results_vsc_converter_stations.csv", + subFolder + "/reactiveopf_results_voltages.csv" + )); + } + LocalCommandExecutor localCommandExecutor = new TestLocalCommandExecutor(outputFileNames); // To really run open reac, use the commentede line below. Be sure that open-reac/src/test/resources/com/powsybl/config/test/config.yml contains your ampl path // try (ComputationManager computationManager = new LocalComputationManager()) { try (ComputationManager computationManager = new LocalComputationManager(new LocalComputationConfig(tmpDir), localCommandExecutor, ForkJoinPool.commonPool())) { - OpenReacResult openReacResult = OpenReacRunner.run(network, - network.getVariantManager().getWorkingVariantId(), parameters, + return OpenReacRunner.run(network, network.getVariantManager().getWorkingVariantId(), parameters, new OpenReacConfig(true), computationManager, reportNode, null); - assertEquals(OpenReacStatus.OK, openReacResult.getStatus()); - openReacResult.setUpdateNetworkWithVoltages(updateNetworkWithVoltages); - openReacResult.applyAllModifications(network); } } diff --git a/open-reac/src/test/java/com/powsybl/openreac/optimization/OpecReacOptimizationBoundsTest.java b/open-reac/src/test/java/com/powsybl/openreac/optimization/OpecReacOptimizationBoundsTest.java new file mode 100644 index 00000000..33c27b80 --- /dev/null +++ b/open-reac/src/test/java/com/powsybl/openreac/optimization/OpecReacOptimizationBoundsTest.java @@ -0,0 +1,127 @@ +/** + * Copyright (c) 2024, RTE (http://www.rte-france.com) + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at http://mozilla.org/MPL/2.0/. + * SPDX-License-Identifier: MPL-2.0 + */ +package com.powsybl.openreac.optimization; + +import com.powsybl.iidm.network.Network; +import com.powsybl.openreac.network.VoltageControlNetworkFactory; +import com.powsybl.openreac.parameters.input.OpenReacParameters; +import com.powsybl.openreac.parameters.output.OpenReacResult; +import com.powsybl.openreac.parameters.output.OpenReacStatus; +import org.junit.jupiter.api.Test; + +import java.io.IOException; + +import static org.junit.jupiter.api.Assertions.*; + +/** + * Test the generator bounds in OpenReac optimization. + * + * @author Pierre ARVY {@literal } + */ +class OpecReacOptimizationBoundsTest extends AbstractOpenReacRunnerTest { + + @Test + void testGeneratorsMaxPBounds() throws IOException { + Network network = VoltageControlNetworkFactory.createWithTwoVoltageControls(); + // due to the disconnection, the network is now imbalanced + // and max p of generators is not enough to provide balance + network.getLine("l45").disconnect(); + OpenReacResult result = runOpenReac(network, "optimization/bounds/generators-pmax-too-small", true); + assertEquals(OpenReacStatus.NOT_OK, result.getStatus()); + + // increase max p of generators to allow power balance + network.getGenerator("g2").setMaxP(2.5); + network.getGenerator("g3").setMaxP(2.5); + result = runOpenReac(network, "optimization/bounds/generators-pmax", true); + assertEquals(OpenReacStatus.OK, result.getStatus()); + } + + @Test + void testGeneratorsMinPBounds() throws IOException { + Network network = VoltageControlNetworkFactory.createWithTwoVoltageControls(); + // due to the modifications, the network is now imbalanced + // and min p of generators is not small enough to provide balance + network.getLine("l45").disconnect(); + network.getLoad("l4").setP0(3); + network.getGenerator("g2").setMinP(2); + network.getGenerator("g3").setMinP(2); + OpenReacResult result = runOpenReac(network, "optimization/bounds/generators-pmin-too-high", true); + assertEquals(OpenReacStatus.NOT_OK, result.getStatus()); + + // decrease min p of generators to allow power balance + // but targetP will be fixed in optimization, because it is too close of maxP + network.getGenerator("g2").setMinP(1); + network.getGenerator("g3").setMinP(1); + result = runOpenReac(network, "optimization/bounds/generators-target-p-too-close-pmax", true); + assertEquals(OpenReacStatus.NOT_OK, result.getStatus()); + + // increase max p of generators to allow modification of targetP in optimization + network.getGenerator("g2").setMaxP(2.5); + network.getGenerator("g3").setMaxP(2.5); + result = runOpenReac(network, "optimization/bounds/generators-pmin", true); + assertEquals(OpenReacStatus.OK, result.getStatus()); + } + + @Test + void testGeneratorRectangularQBounds() throws IOException { + Network network = VoltageControlNetworkFactory.createWithTwoVoltageControls(); + network.getLine("l45").disconnect(); + network.getLoad("l4").setP0(4).setQ0(2); + + // set reactive limits to both generators + network.getGenerator("g2").newReactiveCapabilityCurve() + .beginPoint() + .setP(0) + .setMinQ(-0.25) + .setMaxQ(0.25) + .endPoint() + .beginPoint() + .setP(2) + .setMinQ(-2) + .setMaxQ(2) + .endPoint() + .add(); + network.getGenerator("g3").newReactiveCapabilityCurve() + .beginPoint() + .setP(0) + .setMinQ(-0.25) + .setMaxQ(0.25) + .endPoint() + .beginPoint() + .setP(2) + .setMinQ(-2) + .setMaxQ(2) + .endPoint() + .add(); + + OpenReacResult result = runOpenReac(network, "optimization/bounds/generator-rectangular-bounds", true); + assertEquals(OpenReacStatus.OK, result.getStatus()); + // rectangular bounds in ACOPF implies Q bounds are not large enough to remove reactive slacks in optimization + assertTrue(Integer.parseInt(result.getIndicators().get("nb_reactive_slacks")) > 0); + } + + @Test + void testGeneratorQmaxPmaxRatioBounds() throws IOException { + Network network = VoltageControlNetworkFactory.createWithTwoVoltageControls(); + network.getLine("l45").disconnect(); + network.getLoad("l4").setP0(4).setQ0(2); + + OpenReacParameters parameters = new OpenReacParameters(); + OpenReacResult result = runOpenReac(network, "optimization/bounds/qmax-pmax-default-ratio", parameters, true); + assertEquals(OpenReacStatus.OK, result.getStatus()); + // there are slacks as Q bounds are not large enough + assertTrue(Integer.parseInt(result.getIndicators().get("nb_reactive_slacks")) > 0); + + parameters.setDefaultQmaxPmaxRatio(1); + result = runOpenReac(network, "optimization/bounds/same-qmax-pmax", parameters, true); + assertEquals(OpenReacStatus.OK, result.getStatus()); + // Q bounds are large enough to remove reactive slacks in optimization + assertEquals(0, Integer.parseInt(result.getIndicators().get("nb_reactive_slacks"))); + } + +} diff --git a/open-reac/src/test/java/com/powsybl/openreac/optimization/OpenReacAmplIOTest.java b/open-reac/src/test/java/com/powsybl/openreac/optimization/OpenReacAmplIOTest.java index b2fb76c6..a811899d 100644 --- a/open-reac/src/test/java/com/powsybl/openreac/optimization/OpenReacAmplIOTest.java +++ b/open-reac/src/test/java/com/powsybl/openreac/optimization/OpenReacAmplIOTest.java @@ -134,6 +134,7 @@ void testOutputFileParsing() throws IOException { assertEquals(7, openReacResult.getGeneratorModifications().size()); assertEquals(3, openReacResult.getVoltageProfile().size()); assertEquals(76, openReacResult.getIndicators().size()); + assertTrue(openReacResult.getReactiveSlacks().isEmpty()); } } diff --git a/open-reac/src/test/java/com/powsybl/openreac/optimization/OpenReacOptimizationIndicatorsTest.java b/open-reac/src/test/java/com/powsybl/openreac/optimization/OpenReacOptimizationIndicatorsTest.java new file mode 100644 index 00000000..ceff1c4c --- /dev/null +++ b/open-reac/src/test/java/com/powsybl/openreac/optimization/OpenReacOptimizationIndicatorsTest.java @@ -0,0 +1,281 @@ +/** + * Copyright (c) 2024, RTE (http://www.rte-france.com) + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at http://mozilla.org/MPL/2.0/. + * SPDX-License-Identifier: MPL-2.0 + */ +package com.powsybl.openreac.optimization; + +import com.powsybl.ieeecdf.converter.IeeeCdfNetworkFactory; +import com.powsybl.iidm.network.Network; +import com.powsybl.iidm.network.StaticVarCompensator; +import com.powsybl.openreac.network.HvdcNetworkFactory; +import com.powsybl.openreac.network.ShuntNetworkFactory; +import com.powsybl.openreac.network.VoltageControlNetworkFactory; +import com.powsybl.openreac.parameters.input.OpenReacParameters; +import com.powsybl.openreac.parameters.input.algo.OpenReacAmplLogLevel; +import com.powsybl.openreac.parameters.input.algo.OpenReacOptimisationObjective; +import com.powsybl.openreac.parameters.input.algo.OpenReacSolverLogLevel; +import com.powsybl.openreac.parameters.input.algo.ReactiveSlackBusesMode; +import com.powsybl.openreac.parameters.output.OpenReacResult; +import com.powsybl.openreac.parameters.output.OpenReacStatus; +import org.junit.jupiter.api.Test; + +import java.io.IOException; +import java.util.List; + +import static org.junit.jupiter.api.Assertions.assertEquals; + +/** + * Test the indicators returned by OpenReac optimization. + * Note that some indicators might depend on optimization process, + * and can not be tested in unit tests. + * + * @author Pierre ARVY {@literal } + */ +class OpenReacOptimizationIndicatorsTest extends AbstractOpenReacRunnerTest { + + @Test + void testParametrizationIndicators() throws IOException { + Network network = IeeeCdfNetworkFactory.create57(); + OpenReacParameters parameters = new OpenReacParameters() + .setObjective(OpenReacOptimisationObjective.SPECIFIC_VOLTAGE_PROFILE) + .setObjectiveDistance(70) + .setLogLevelAmpl(OpenReacAmplLogLevel.WARNING) + .setLogLevelSolver(OpenReacSolverLogLevel.ONLY_RESULTS) + .setMinPlausibleLowVoltageLimit(0.655) + .setMaxPlausibleHighVoltageLimit(1.425) + .setReactiveSlackBusesMode(ReactiveSlackBusesMode.NO_GENERATION) + .setActivePowerVariationRate(0.999) + .setMinPlausibleActivePowerThreshold(0.02) + .setLowImpedanceThreshold(1e-5) + .setMinNominalVoltageIgnoredBus(0.75) + .setMinNominalVoltageIgnoredVoltageBounds(0.85) + .setPQMax(4001) + .setLowActivePowerDefaultLimit(0.1) + .setHighActivePowerDefaultLimit(1001) + .setDefaultQmaxPmaxRatio(0.2) + .setDefaultMinimalQPRange(2.) + .setDefaultVariableScalingFactor(1.001) + .setDefaultConstraintScalingFactor(0.999) + .setReactiveSlackVariableScalingFactor(1e-2) + .setTwoWindingTransformerRatioVariableScalingFactor(2e-3) + .setShuntVariableScalingFactor(0.11); + OpenReacResult result = runOpenReac(network, "optimization/indicators/input-parameters-test", parameters, true); + + assertEquals("WARNING", result.getIndicators().get("log_level_ampl")); + assertEquals(1, Integer.parseInt(result.getIndicators().get("log_level_knitro"))); + assertEquals(2, Integer.parseInt(result.getIndicators().get("objective_choice"))); + assertEquals(0.7, Double.parseDouble(result.getIndicators().get("ratio_voltage_target"))); + assertEquals(0.999, Double.parseDouble(result.getIndicators().get("coeff_alpha"))); + assertEquals(0.02, Double.parseDouble(result.getIndicators().get("Pnull"))); + assertEquals(1e-5, Double.parseDouble(result.getIndicators().get("Znull"))); + assertEquals(0.75, Double.parseDouble(result.getIndicators().get("epsilon_nominal_voltage"))); + assertEquals(0.655, Double.parseDouble(result.getIndicators().get("min_plausible_low_voltage_limit"))); + assertEquals(1.425, Double.parseDouble(result.getIndicators().get("max_plausible_high_voltage_limit"))); + assertEquals(0.85, Double.parseDouble(result.getIndicators().get("ignore_voltage_bounds"))); + assertEquals("NO_GENERATION", result.getIndicators().get("buses_with_reactive_slacks")); + assertEquals(4001, Double.parseDouble(result.getIndicators().get("PQmax"))); + assertEquals(1001, Double.parseDouble(result.getIndicators().get("defaultPmax"))); + assertEquals(0.1, Double.parseDouble(result.getIndicators().get("defaultPmin"))); + assertEquals(0.2, Double.parseDouble(result.getIndicators().get("defaultQmaxPmaxRatio"))); + assertEquals(-200.2, Double.parseDouble(result.getIndicators().get("defaultQmin"))); + assertEquals(200.2, Double.parseDouble(result.getIndicators().get("defaultQmax"))); + assertEquals(2.0, Double.parseDouble(result.getIndicators().get("minimalQPrange"))); + assertEquals(1.001, Double.parseDouble(result.getIndicators().get("default_variable_scaling_factor"))); + assertEquals(0.999, Double.parseDouble(result.getIndicators().get("default_constraint_scaling_factor"))); + assertEquals(0.01, Double.parseDouble(result.getIndicators().get("reactive_slack_variable_scaling_factor"))); + assertEquals(0.002, Double.parseDouble(result.getIndicators().get("transformer_ratio_variable_scaling_factor"))); + assertEquals(0.11, Double.parseDouble(result.getIndicators().get("shunt_variable_scaling_factor"))); + } + + @Test + void testBusIndicators() throws IOException { + Network network = HvdcNetworkFactory.createLccWithBiggerComponents(); + network.getBusBreakerView().getBus("b1").setV(400); + OpenReacResult result = runOpenReac(network, "optimization/indicators/bus-test", true); + + assertEquals(OpenReacStatus.OK, result.getStatus()); + assertEquals(16, Integer.parseInt(result.getIndicators().get("nb_substations"))); + assertEquals(16, Integer.parseInt(result.getIndicators().get("nb_bus_in_data_file"))); + assertEquals(16, Integer.parseInt(result.getIndicators().get("nb_bus_in_ACDC_CC"))); + // verify buses outside main SC have been excluded + assertEquals(12, Integer.parseInt(result.getIndicators().get("nb_bus_in_AC_CC"))); + assertEquals(4, Integer.parseInt(result.getIndicators().get("nb_bus_in_ACDC_but_out_AC_CC"))); + assertEquals(1, Integer.parseInt(result.getIndicators().get("nb_bus_with_voltage_value"))); + } + + @Test + void testBranchesIndicators() throws IOException { + Network network = VoltageControlNetworkFactory.createWithSimpleRemoteControl(); + network.getLine("l12").getTerminal2().disconnect(); + network.getLine("l24").getTerminal1().disconnect(); + // due to disconnected lines, increase max P of generators in main CC + network.getGenerator("g3").setMaxP(3); + network.getGenerator("g4").setMaxP(3); + OpenReacResult result = runOpenReac(network, "optimization/indicators/branches-test", true); + + assertEquals(OpenReacStatus.OK, result.getStatus()); + assertEquals(4, Integer.parseInt(result.getIndicators().get("nb_branch_in_data_file"))); + // verify opened branches have been excluded + assertEquals(2, Integer.parseInt(result.getIndicators().get("nb_branch_in_AC_CC"))); + assertEquals(1, Integer.parseInt(result.getIndicators().get("nb_branch_with_nonsmall_impedance"))); + assertEquals(1, Integer.parseInt(result.getIndicators().get("nb_branch_with_zero_or_small_impedance"))); + } + + @Test + void testGeneratorIndicators() throws IOException { + Network network = VoltageControlNetworkFactory.createWithGeneratorRemoteControl(); + network.getGenerator("g1").setTargetQ(50); + OpenReacParameters parameters = new OpenReacParameters(); + parameters.addConstantQGenerators(List.of("g1", "g3")); + OpenReacResult result = runOpenReac(network, "optimization/indicators/generators-test", parameters, true); + + assertEquals(OpenReacStatus.OK, result.getStatus()); + assertEquals(3, Integer.parseInt(result.getIndicators().get("nb_unit_in_data_file"))); + assertEquals(3, Integer.parseInt(result.getIndicators().get("nb_unit_in_AC_CC"))); + assertEquals(3, Integer.parseInt(result.getIndicators().get("nb_unit_up_and_running"))); + // verify that only the generators indicated as constant and with defined target Q are fixed in optimization + assertEquals(1, Integer.parseInt(result.getIndicators().get("nb_unit_with_fixed_reactive_power"))); + // verify other generators are optimized + assertEquals(2, Integer.parseInt(result.getIndicators().get("nb_unit_with_variable_reactive_power"))); + } + + @Test + void testTransformersIndicators() throws IOException { + Network network = VoltageControlNetworkFactory.createNetworkWith2T2wt(); + OpenReacParameters parameters = new OpenReacParameters(); + parameters.addVariableTwoWindingsTransformers(List.of("T2wT1")); + OpenReacResult result = runOpenReac(network, "optimization/indicators/transfo-test", parameters, true); + + // verify only one rtc has been optimized + assertEquals(OpenReacStatus.OK, result.getStatus()); + assertEquals(1, Integer.parseInt(result.getIndicators().get("nb_transformers_with_variable_ratio"))); + assertEquals(1, Integer.parseInt(result.getIndicators().get("nb_transformers_with_fixed_ratio"))); + } + + @Test + void testVscIndicators() throws IOException { + Network network = HvdcNetworkFactory.createVsc(); + // FIXME : should not depend on P/Q values on terminal + network.getVscConverterStation("cs2").getTerminal().setP(2).setQ(1); + OpenReacResult result = runOpenReac(network, "optimization/indicators/vsc-test", true); + + assertEquals(OpenReacStatus.OK, result.getStatus()); + assertEquals(2, Integer.parseInt(result.getIndicators().get("nb_vsc_converter_in_data_file"))); + // verify only vsc in main cc is optimized + assertEquals(1, Integer.parseInt(result.getIndicators().get("nb_vsc_converter_up_and_running"))); + } + + @Test + void testLccIndicators() throws IOException { + Network network = HvdcNetworkFactory.createLcc(); + // FIXME : should not depend on P/Q values on terminal + network.getLccConverterStation("cs2").getTerminal().setP(2).setQ(1); + OpenReacResult result = runOpenReac(network, "optimization/indicators/lcc-test", true); + + assertEquals(OpenReacStatus.OK, result.getStatus()); + assertEquals(2, Integer.parseInt(result.getIndicators().get("nb_lcc_converter_in_data_file"))); + // verify only lcc in main cc is considered in optimization + assertEquals(1, Integer.parseInt(result.getIndicators().get("nb_lcc_converter_up_and_running"))); + } + + @Test + void testShuntsIndicators() throws IOException { + Network network = ShuntNetworkFactory.createWithLinearModel(); + // add one shunt that will be fixed in optimization + network.getVoltageLevel("vl3").newShuntCompensator() + .setId("SHUNT2") + .setBus("b3") + .setConnectableBus("b3") + .setSectionCount(0) + .setVoltageRegulatorOn(true) + .setTargetV(393) + .setTargetDeadband(5.0) + .newLinearModel() + .setMaximumSectionCount(25) + .setBPerSection(1e-3) + .add() + .add(); + // add one shunt that will not be considered in optimization, as it is neither optimized nor connected + network.getVoltageLevel("vl3").newShuntCompensator() + .setId("SHUNT3") + // .setBus("b3") + .setConnectableBus("b3") + .setSectionCount(0) + .setVoltageRegulatorOn(true) + .setTargetV(393) + .setTargetDeadband(5.0) + .newLinearModel() + .setMaximumSectionCount(25) + .setBPerSection(1e-3) + .add() + .add(); + OpenReacParameters parameters = new OpenReacParameters(); + parameters.addVariableShuntCompensators(List.of("SHUNT")); + OpenReacResult result = runOpenReac(network, "optimization/indicators/shunt-test", parameters, true); + + assertEquals(OpenReacStatus.OK, result.getStatus()); + assertEquals(3, Integer.parseInt(result.getIndicators().get("nb_shunt_in_data_file"))); + assertEquals(3, Integer.parseInt(result.getIndicators().get("nb_shunt_connectable_or_in_AC_CC"))); + // verify disconnected shunt, and not optimized, is not considered in shunts with fixed values + assertEquals(1, Integer.parseInt(result.getIndicators().get("nb_shunt_with_fixed_value"))); + // verify only one shunt has been optimized (even if it was disconnected) + assertEquals(1, Integer.parseInt(result.getIndicators().get("nb_shunt_with_variable_value"))); + } + + @Test + void testSvcIndicators() throws IOException { + Network network = VoltageControlNetworkFactory.createWithStaticVarCompensator(); + network.getVoltageLevel("vl2").newStaticVarCompensator() + .setId("svc2") + .setConnectableBus("b2") + .setBus("b2") + .setRegulationMode(StaticVarCompensator.RegulationMode.VOLTAGE) + .setVoltageSetpoint(400) + .setBmin(-0.008) + .setBmax(0.008) + .add(); + OpenReacResult result = runOpenReac(network, "optimization/indicators/svc-test", true); + + assertEquals(OpenReacStatus.OK, result.getStatus()); + assertEquals(2, Integer.parseInt(result.getIndicators().get("nb_svc_in_data_file"))); + assertEquals(2, Integer.parseInt(result.getIndicators().get("nb_svc_in_AC_CC"))); + // verify only one svc is regulating + assertEquals(1, Integer.parseInt(result.getIndicators().get("nb_svc_up_and_operating"))); + } + + @Test + void testBatteryIndicators() throws IOException { + Network network = VoltageControlNetworkFactory.createWithGeneratorRemoteControl(); + network.getVoltageLevel("vl4") + .newBattery() + .setId("bat1") + .setMinP(-10) + .setMaxP(10) + .setTargetP(2) + .setBus("b4") + .setConnectableBus("b4") + .setTargetQ(0) + .add(); + network.getVoltageLevel("vl1") + .newBattery() + .setId("bat2") + .setMinP(-9) + .setMaxP(11) + .setTargetP(1) + .setBus("b1") + .setConnectableBus("b1") + .setTargetQ(0.2) + .add(); + OpenReacResult result = runOpenReac(network, "optimization/indicators/battery-test", true); + + assertEquals(OpenReacStatus.OK, result.getStatus()); + assertEquals(2, Integer.parseInt(result.getIndicators().get("nb_batteries"))); + // verify the sum of max and min active power of the batteries + assertEquals(21, Double.parseDouble(result.getIndicators().get("sum_batteries_pmax"))); + assertEquals(-19, Double.parseDouble(result.getIndicators().get("sum_batteries_pmin"))); + } + +} diff --git a/open-reac/src/test/resources/optimization/bounds/generator-rectangular-bounds/reactiveopf_results_indic.txt b/open-reac/src/test/resources/optimization/bounds/generator-rectangular-bounds/reactiveopf_results_indic.txt new file mode 100644 index 00000000..09e8c47b --- /dev/null +++ b/open-reac/src/test/resources/optimization/bounds/generator-rectangular-bounds/reactiveopf_results_indic.txt @@ -0,0 +1,80 @@ +final_status OK +dcopf_status OK + +log_level_ampl INFO +log_level_knitro 2 +objective_choice 0 +ratio_voltage_target 0.500000 +coeff_alpha 1.000000 +Pnull 0.010000 +Znull 0.000100 +epsilon_nominal_voltage 1.000000 +min_plausible_low_voltage_limit 0.500000 +max_plausible_high_voltage_limit 1.500000 +ignore_voltage_bounds 0.000000 +buses_with_reactive_slacks ALL +PQmax 9000.000000 +defaultPmax 1000.000000 +defaultPmin 0.000000 +defaultQmaxPmaxRatio 0.300000 +defaultQmin -300.000000 +defaultQmax 300.000000 +minimalQPrange 1.000000 +default_variable_scaling_factor 1.000000 +default_constraint_scaling_factor 1.000000 +reactive_slack_variable_scaling_factor 0.100000 +transformer_ratio_variable_scaling_factor 0.001000 +shunt_variable_scaling_factor 0.100000 + +nb_substations 5 +nb_bus_in_data_file 5 +nb_bus_in_ACDC_CC 4 +nb_bus_in_AC_CC 4 +nb_bus_in_ACDC_but_out_AC_CC 0 +nb_bus_with_voltage_value 0 +nb_bus_with_reactive_slacks 4 +nb_bus_without_reactive_slacks 0 +nb_branch_in_data_file 4 +nb_branch_in_AC_CC 3 +nb_branch_with_nonsmall_impedance 3 +nb_branch_with_zero_or_small_impedance 0 +nb_unit_in_data_file 3 +nb_unit_in_AC_CC 2 +nb_unit_up_and_running 2 +nb_unit_with_variable_reactive_power 2 +nb_unit_with_fixed_reactive_power 0 +nb_load_in_data_file 2 +nb_load_in_AC_CC 1 +nb_shunt_in_data_file 0 +nb_shunt_connectable_or_in_AC_CC 0 +nb_shunt_with_fixed_value 0 +nb_shunt_with_variable_value 0 +nb_transformers_with_variable_ratio 0 +nb_transformers_with_fixed_ratio 0 +nb_svc_in_data_file 0 +nb_svc_in_AC_CC 0 +nb_svc_up_and_operating 0 +nb_vsc_converter_in_data_file 0 +nb_vsc_converter_up_and_running 0 +nb_lcc_converter_in_data_file 0 +nb_lcc_converter_up_and_running 0 +nb_batteries 0 +sum_batteries_pmax 0.0 +sum_batteries_pmin 0.0 + +max_teta_dc 0.02 +max_teta_ac 0.01 +teta_max 3.02 +min_teta_dc -0.04 +min_teta_ac -0.02 +teta_min -3.04 +max_delta_teta_dc 0.040000 +max_delta_teta_ac 0.017957 +min_delta_teta_dc -0.020000 +min_delta_teta_ac -0.008898 + +nb_reactive_slacks 2 +nb_slacks_condensator 2 +sum_slacks_condensator 1.6 +nb_slacks_self 0 +sum_slacks_self 0.0 diff --git a/open-reac/src/test/resources/optimization/bounds/generators-pmax-too-small/reactiveopf_results_indic.txt b/open-reac/src/test/resources/optimization/bounds/generators-pmax-too-small/reactiveopf_results_indic.txt new file mode 100644 index 00000000..05fa077c --- /dev/null +++ b/open-reac/src/test/resources/optimization/bounds/generators-pmax-too-small/reactiveopf_results_indic.txt @@ -0,0 +1,81 @@ +final_status NOK +dcopf_status OK + +log_level_ampl INFO +log_level_knitro 2 +objective_choice 0 +ratio_voltage_target 0.500000 +coeff_alpha 1.000000 +Pnull 0.010000 +Znull 0.000100 +epsilon_nominal_voltage 1.000000 +min_plausible_low_voltage_limit 0.500000 +max_plausible_high_voltage_limit 1.500000 +ignore_voltage_bounds 0.000000 +buses_with_reactive_slacks ALL +PQmax 9000.000000 +defaultPmax 1000.000000 +defaultPmin 0.000000 +defaultQmaxPmaxRatio 0.300000 +defaultQmin -300.000000 +defaultQmax 300.000000 +minimalQPrange 1.000000 +default_variable_scaling_factor 1.000000 +default_constraint_scaling_factor 1.000000 +reactive_slack_variable_scaling_factor 0.100000 +transformer_ratio_variable_scaling_factor 0.001000 +shunt_variable_scaling_factor 0.100000 + +nb_substations 5 +nb_bus_in_data_file 5 +nb_bus_in_ACDC_CC 4 +nb_bus_in_AC_CC 4 +nb_bus_in_ACDC_but_out_AC_CC 0 +nb_bus_with_voltage_value 0 +nb_bus_with_reactive_slacks 4 +nb_bus_without_reactive_slacks 0 +nb_branch_in_data_file 4 +nb_branch_in_AC_CC 3 +nb_branch_with_nonsmall_impedance 3 +nb_branch_with_zero_or_small_impedance 0 +nb_unit_in_data_file 3 +nb_unit_in_AC_CC 2 +nb_unit_up_and_running 2 +nb_unit_with_variable_reactive_power 2 +nb_unit_with_fixed_reactive_power 0 +nb_load_in_data_file 2 +nb_load_in_AC_CC 1 +nb_shunt_in_data_file 0 +nb_shunt_connectable_or_in_AC_CC 0 +nb_shunt_with_fixed_value 0 +nb_shunt_with_variable_value 0 +nb_transformers_with_variable_ratio 0 +nb_transformers_with_fixed_ratio 0 +nb_svc_in_data_file 0 +nb_svc_in_AC_CC 0 +nb_svc_up_and_operating 0 +nb_vsc_converter_in_data_file 0 +nb_vsc_converter_up_and_running 0 +nb_lcc_converter_in_data_file 0 +nb_lcc_converter_up_and_running 0 +nb_batteries 0 +sum_batteries_pmax 0.0 +sum_batteries_pmin 0.0 + +max_teta_dc 0.02 +max_teta_ac 0.01 +teta_max 3.02 +min_teta_dc -0.05 +min_teta_ac -0.03 +teta_min -3.05 +max_delta_teta_dc 0.050000 +max_delta_teta_ac 0.030638 +min_delta_teta_dc -0.025000 +min_delta_teta_ac -0.014361 + +nb_reactive_slacks 4 +nb_slacks_condensator 4 +sum_slacks_condensator 2.6 +nb_slacks_self 4 +sum_slacks_self 2.5 +messageInfo1 'Acopf optimization was ***not*** successfull - Convergence to an infeasible solution' diff --git a/open-reac/src/test/resources/optimization/bounds/generators-pmax/reactiveopf_results_indic.txt b/open-reac/src/test/resources/optimization/bounds/generators-pmax/reactiveopf_results_indic.txt new file mode 100644 index 00000000..55fc4313 --- /dev/null +++ b/open-reac/src/test/resources/optimization/bounds/generators-pmax/reactiveopf_results_indic.txt @@ -0,0 +1,80 @@ +final_status OK +dcopf_status OK + +log_level_ampl INFO +log_level_knitro 2 +objective_choice 0 +ratio_voltage_target 0.500000 +coeff_alpha 1.000000 +Pnull 0.010000 +Znull 0.000100 +epsilon_nominal_voltage 1.000000 +min_plausible_low_voltage_limit 0.500000 +max_plausible_high_voltage_limit 1.500000 +ignore_voltage_bounds 0.000000 +buses_with_reactive_slacks ALL +PQmax 9000.000000 +defaultPmax 1000.000000 +defaultPmin 0.000000 +defaultQmaxPmaxRatio 0.300000 +defaultQmin -300.000000 +defaultQmax 300.000000 +minimalQPrange 1.000000 +default_variable_scaling_factor 1.000000 +default_constraint_scaling_factor 1.000000 +reactive_slack_variable_scaling_factor 0.100000 +transformer_ratio_variable_scaling_factor 0.001000 +shunt_variable_scaling_factor 0.100000 + +nb_substations 5 +nb_bus_in_data_file 5 +nb_bus_in_ACDC_CC 4 +nb_bus_in_AC_CC 4 +nb_bus_in_ACDC_but_out_AC_CC 0 +nb_bus_with_voltage_value 0 +nb_bus_with_reactive_slacks 4 +nb_bus_without_reactive_slacks 0 +nb_branch_in_data_file 4 +nb_branch_in_AC_CC 3 +nb_branch_with_nonsmall_impedance 3 +nb_branch_with_zero_or_small_impedance 0 +nb_unit_in_data_file 3 +nb_unit_in_AC_CC 2 +nb_unit_up_and_running 2 +nb_unit_with_variable_reactive_power 2 +nb_unit_with_fixed_reactive_power 0 +nb_load_in_data_file 2 +nb_load_in_AC_CC 1 +nb_shunt_in_data_file 0 +nb_shunt_connectable_or_in_AC_CC 0 +nb_shunt_with_fixed_value 0 +nb_shunt_with_variable_value 0 +nb_transformers_with_variable_ratio 0 +nb_transformers_with_fixed_ratio 0 +nb_svc_in_data_file 0 +nb_svc_in_AC_CC 0 +nb_svc_up_and_operating 0 +nb_vsc_converter_in_data_file 0 +nb_vsc_converter_up_and_running 0 +nb_lcc_converter_in_data_file 0 +nb_lcc_converter_up_and_running 0 +nb_batteries 0 +sum_batteries_pmax 0.0 +sum_batteries_pmin 0.0 + +max_teta_dc 0.02 +max_teta_ac 0.03 +teta_max 3.02 +min_teta_dc -0.05 +min_teta_ac -0.05 +teta_min -3.05 +max_delta_teta_dc 0.050000 +max_delta_teta_ac 0.051670 +min_delta_teta_dc -0.025000 +min_delta_teta_ac -0.025352 + +nb_reactive_slacks 0 +nb_slacks_condensator 0 +sum_slacks_condensator 0.0 +nb_slacks_self 0 +sum_slacks_self 0.0 diff --git a/open-reac/src/test/resources/optimization/bounds/generators-pmin-too-high/reactiveopf_results_indic.txt b/open-reac/src/test/resources/optimization/bounds/generators-pmin-too-high/reactiveopf_results_indic.txt new file mode 100644 index 00000000..2b8c5047 --- /dev/null +++ b/open-reac/src/test/resources/optimization/bounds/generators-pmin-too-high/reactiveopf_results_indic.txt @@ -0,0 +1,81 @@ +final_status NOK +dcopf_status OK + +log_level_ampl INFO +log_level_knitro 2 +objective_choice 0 +ratio_voltage_target 0.500000 +coeff_alpha 1.000000 +Pnull 0.010000 +Znull 0.000100 +epsilon_nominal_voltage 1.000000 +min_plausible_low_voltage_limit 0.500000 +max_plausible_high_voltage_limit 1.500000 +ignore_voltage_bounds 0.000000 +buses_with_reactive_slacks ALL +PQmax 9000.000000 +defaultPmax 1000.000000 +defaultPmin 0.000000 +defaultQmaxPmaxRatio 0.300000 +defaultQmin -300.000000 +defaultQmax 300.000000 +minimalQPrange 1.000000 +default_variable_scaling_factor 1.000000 +default_constraint_scaling_factor 1.000000 +reactive_slack_variable_scaling_factor 0.100000 +transformer_ratio_variable_scaling_factor 0.001000 +shunt_variable_scaling_factor 0.100000 + +nb_substations 5 +nb_bus_in_data_file 5 +nb_bus_in_ACDC_CC 4 +nb_bus_in_AC_CC 4 +nb_bus_in_ACDC_but_out_AC_CC 0 +nb_bus_with_voltage_value 0 +nb_bus_with_reactive_slacks 4 +nb_bus_without_reactive_slacks 0 +nb_branch_in_data_file 4 +nb_branch_in_AC_CC 3 +nb_branch_with_nonsmall_impedance 3 +nb_branch_with_zero_or_small_impedance 0 +nb_unit_in_data_file 3 +nb_unit_in_AC_CC 2 +nb_unit_up_and_running 2 +nb_unit_with_variable_reactive_power 2 +nb_unit_with_fixed_reactive_power 0 +nb_load_in_data_file 2 +nb_load_in_AC_CC 1 +nb_shunt_in_data_file 0 +nb_shunt_connectable_or_in_AC_CC 0 +nb_shunt_with_fixed_value 0 +nb_shunt_with_variable_value 0 +nb_transformers_with_variable_ratio 0 +nb_transformers_with_fixed_ratio 0 +nb_svc_in_data_file 0 +nb_svc_in_AC_CC 0 +nb_svc_up_and_operating 0 +nb_vsc_converter_in_data_file 0 +nb_vsc_converter_up_and_running 0 +nb_lcc_converter_in_data_file 0 +nb_lcc_converter_up_and_running 0 +nb_batteries 0 +sum_batteries_pmax 0.0 +sum_batteries_pmin 0.0 + +max_teta_dc 0.01 +max_teta_ac 0.02 +teta_max 3.01 +min_teta_dc -0.03 +min_teta_ac -0.04 +teta_min -3.03 +max_delta_teta_dc 0.030000 +max_delta_teta_ac 0.035331 +min_delta_teta_dc -0.015000 +min_delta_teta_ac -0.018693 + +nb_reactive_slacks 4 +nb_slacks_condensator 4 +sum_slacks_condensator 1.3 +nb_slacks_self 4 +sum_slacks_self 1.2 +messageInfo1 'Acopf optimization was ***not*** successfull - Convergence to an infeasible solution' diff --git a/open-reac/src/test/resources/optimization/bounds/generators-pmin/reactiveopf_results_indic.txt b/open-reac/src/test/resources/optimization/bounds/generators-pmin/reactiveopf_results_indic.txt new file mode 100644 index 00000000..d78f4798 --- /dev/null +++ b/open-reac/src/test/resources/optimization/bounds/generators-pmin/reactiveopf_results_indic.txt @@ -0,0 +1,80 @@ +final_status OK +dcopf_status OK + +log_level_ampl INFO +log_level_knitro 2 +objective_choice 0 +ratio_voltage_target 0.500000 +coeff_alpha 1.000000 +Pnull 0.010000 +Znull 0.000100 +epsilon_nominal_voltage 1.000000 +min_plausible_low_voltage_limit 0.500000 +max_plausible_high_voltage_limit 1.500000 +ignore_voltage_bounds 0.000000 +buses_with_reactive_slacks ALL +PQmax 9000.000000 +defaultPmax 1000.000000 +defaultPmin 0.000000 +defaultQmaxPmaxRatio 0.300000 +defaultQmin -300.000000 +defaultQmax 300.000000 +minimalQPrange 1.000000 +default_variable_scaling_factor 1.000000 +default_constraint_scaling_factor 1.000000 +reactive_slack_variable_scaling_factor 0.100000 +transformer_ratio_variable_scaling_factor 0.001000 +shunt_variable_scaling_factor 0.100000 + +nb_substations 5 +nb_bus_in_data_file 5 +nb_bus_in_ACDC_CC 4 +nb_bus_in_AC_CC 4 +nb_bus_in_ACDC_but_out_AC_CC 0 +nb_bus_with_voltage_value 0 +nb_bus_with_reactive_slacks 4 +nb_bus_without_reactive_slacks 0 +nb_branch_in_data_file 4 +nb_branch_in_AC_CC 3 +nb_branch_with_nonsmall_impedance 3 +nb_branch_with_zero_or_small_impedance 0 +nb_unit_in_data_file 3 +nb_unit_in_AC_CC 2 +nb_unit_up_and_running 2 +nb_unit_with_variable_reactive_power 2 +nb_unit_with_fixed_reactive_power 0 +nb_load_in_data_file 2 +nb_load_in_AC_CC 1 +nb_shunt_in_data_file 0 +nb_shunt_connectable_or_in_AC_CC 0 +nb_shunt_with_fixed_value 0 +nb_shunt_with_variable_value 0 +nb_transformers_with_variable_ratio 0 +nb_transformers_with_fixed_ratio 0 +nb_svc_in_data_file 0 +nb_svc_in_AC_CC 0 +nb_svc_up_and_operating 0 +nb_vsc_converter_in_data_file 0 +nb_vsc_converter_up_and_running 0 +nb_lcc_converter_in_data_file 0 +nb_lcc_converter_up_and_running 0 +nb_batteries 0 +sum_batteries_pmax 0.0 +sum_batteries_pmin 0.0 + +max_teta_dc 0.01 +max_teta_ac 0.03 +teta_max 3.01 +min_teta_dc -0.03 +min_teta_ac -0.05 +teta_min -3.03 +max_delta_teta_dc 0.030000 +max_delta_teta_ac 0.054735 +min_delta_teta_dc -0.015000 +min_delta_teta_ac -0.026527 + +nb_reactive_slacks 0 +nb_slacks_condensator 0 +sum_slacks_condensator 0.0 +nb_slacks_self 0 +sum_slacks_self 0.0 diff --git a/open-reac/src/test/resources/optimization/bounds/generators-target-p-too-close-pmax/reactiveopf_results_indic.txt b/open-reac/src/test/resources/optimization/bounds/generators-target-p-too-close-pmax/reactiveopf_results_indic.txt new file mode 100644 index 00000000..2b8c5047 --- /dev/null +++ b/open-reac/src/test/resources/optimization/bounds/generators-target-p-too-close-pmax/reactiveopf_results_indic.txt @@ -0,0 +1,81 @@ +final_status NOK +dcopf_status OK + +log_level_ampl INFO +log_level_knitro 2 +objective_choice 0 +ratio_voltage_target 0.500000 +coeff_alpha 1.000000 +Pnull 0.010000 +Znull 0.000100 +epsilon_nominal_voltage 1.000000 +min_plausible_low_voltage_limit 0.500000 +max_plausible_high_voltage_limit 1.500000 +ignore_voltage_bounds 0.000000 +buses_with_reactive_slacks ALL +PQmax 9000.000000 +defaultPmax 1000.000000 +defaultPmin 0.000000 +defaultQmaxPmaxRatio 0.300000 +defaultQmin -300.000000 +defaultQmax 300.000000 +minimalQPrange 1.000000 +default_variable_scaling_factor 1.000000 +default_constraint_scaling_factor 1.000000 +reactive_slack_variable_scaling_factor 0.100000 +transformer_ratio_variable_scaling_factor 0.001000 +shunt_variable_scaling_factor 0.100000 + +nb_substations 5 +nb_bus_in_data_file 5 +nb_bus_in_ACDC_CC 4 +nb_bus_in_AC_CC 4 +nb_bus_in_ACDC_but_out_AC_CC 0 +nb_bus_with_voltage_value 0 +nb_bus_with_reactive_slacks 4 +nb_bus_without_reactive_slacks 0 +nb_branch_in_data_file 4 +nb_branch_in_AC_CC 3 +nb_branch_with_nonsmall_impedance 3 +nb_branch_with_zero_or_small_impedance 0 +nb_unit_in_data_file 3 +nb_unit_in_AC_CC 2 +nb_unit_up_and_running 2 +nb_unit_with_variable_reactive_power 2 +nb_unit_with_fixed_reactive_power 0 +nb_load_in_data_file 2 +nb_load_in_AC_CC 1 +nb_shunt_in_data_file 0 +nb_shunt_connectable_or_in_AC_CC 0 +nb_shunt_with_fixed_value 0 +nb_shunt_with_variable_value 0 +nb_transformers_with_variable_ratio 0 +nb_transformers_with_fixed_ratio 0 +nb_svc_in_data_file 0 +nb_svc_in_AC_CC 0 +nb_svc_up_and_operating 0 +nb_vsc_converter_in_data_file 0 +nb_vsc_converter_up_and_running 0 +nb_lcc_converter_in_data_file 0 +nb_lcc_converter_up_and_running 0 +nb_batteries 0 +sum_batteries_pmax 0.0 +sum_batteries_pmin 0.0 + +max_teta_dc 0.01 +max_teta_ac 0.02 +teta_max 3.01 +min_teta_dc -0.03 +min_teta_ac -0.04 +teta_min -3.03 +max_delta_teta_dc 0.030000 +max_delta_teta_ac 0.035331 +min_delta_teta_dc -0.015000 +min_delta_teta_ac -0.018693 + +nb_reactive_slacks 4 +nb_slacks_condensator 4 +sum_slacks_condensator 1.3 +nb_slacks_self 4 +sum_slacks_self 1.2 +messageInfo1 'Acopf optimization was ***not*** successfull - Convergence to an infeasible solution' diff --git a/open-reac/src/test/resources/optimization/bounds/qmax-pmax-default-ratio/reactiveopf_results_indic.txt b/open-reac/src/test/resources/optimization/bounds/qmax-pmax-default-ratio/reactiveopf_results_indic.txt new file mode 100644 index 00000000..11ef51d6 --- /dev/null +++ b/open-reac/src/test/resources/optimization/bounds/qmax-pmax-default-ratio/reactiveopf_results_indic.txt @@ -0,0 +1,80 @@ +final_status OK +dcopf_status OK + +log_level_ampl INFO +log_level_knitro 2 +objective_choice 0 +ratio_voltage_target 0.500000 +coeff_alpha 1.000000 +Pnull 0.010000 +Znull 0.000100 +epsilon_nominal_voltage 1.000000 +min_plausible_low_voltage_limit 0.500000 +max_plausible_high_voltage_limit 1.500000 +ignore_voltage_bounds 0.000000 +buses_with_reactive_slacks ALL +PQmax 9000.000000 +defaultPmax 1000.000000 +defaultPmin 0.000000 +defaultQmaxPmaxRatio 0.300000 +defaultQmin -300.000000 +defaultQmax 300.000000 +minimalQPrange 1.000000 +default_variable_scaling_factor 1.000000 +default_constraint_scaling_factor 1.000000 +reactive_slack_variable_scaling_factor 0.100000 +transformer_ratio_variable_scaling_factor 0.001000 +shunt_variable_scaling_factor 0.100000 + +nb_substations 5 +nb_bus_in_data_file 5 +nb_bus_in_ACDC_CC 4 +nb_bus_in_AC_CC 4 +nb_bus_in_ACDC_but_out_AC_CC 0 +nb_bus_with_voltage_value 0 +nb_bus_with_reactive_slacks 4 +nb_bus_without_reactive_slacks 0 +nb_branch_in_data_file 4 +nb_branch_in_AC_CC 3 +nb_branch_with_nonsmall_impedance 3 +nb_branch_with_zero_or_small_impedance 0 +nb_unit_in_data_file 3 +nb_unit_in_AC_CC 2 +nb_unit_up_and_running 2 +nb_unit_with_variable_reactive_power 2 +nb_unit_with_fixed_reactive_power 0 +nb_load_in_data_file 2 +nb_load_in_AC_CC 1 +nb_shunt_in_data_file 0 +nb_shunt_connectable_or_in_AC_CC 0 +nb_shunt_with_fixed_value 0 +nb_shunt_with_variable_value 0 +nb_transformers_with_variable_ratio 0 +nb_transformers_with_fixed_ratio 0 +nb_svc_in_data_file 0 +nb_svc_in_AC_CC 0 +nb_svc_up_and_operating 0 +nb_vsc_converter_in_data_file 0 +nb_vsc_converter_up_and_running 0 +nb_lcc_converter_in_data_file 0 +nb_lcc_converter_up_and_running 0 +nb_batteries 0 +sum_batteries_pmax 0.0 +sum_batteries_pmin 0.0 + +max_teta_dc 0.02 +max_teta_ac 0.01 +teta_max 3.02 +min_teta_dc -0.04 +min_teta_ac -0.02 +teta_min -3.04 +max_delta_teta_dc 0.040000 +max_delta_teta_ac 0.017964 +min_delta_teta_dc -0.020000 +min_delta_teta_ac -0.008913 + +nb_reactive_slacks 1 +nb_slacks_condensator 1 +sum_slacks_condensator 0.9 +nb_slacks_self 0 +sum_slacks_self 0.0 diff --git a/open-reac/src/test/resources/optimization/bounds/same-qmax-pmax/reactiveopf_results_indic.txt b/open-reac/src/test/resources/optimization/bounds/same-qmax-pmax/reactiveopf_results_indic.txt new file mode 100644 index 00000000..95dfe618 --- /dev/null +++ b/open-reac/src/test/resources/optimization/bounds/same-qmax-pmax/reactiveopf_results_indic.txt @@ -0,0 +1,80 @@ +final_status OK +dcopf_status OK + +log_level_ampl INFO +log_level_knitro 2 +objective_choice 0 +ratio_voltage_target 0.500000 +coeff_alpha 1.000000 +Pnull 0.010000 +Znull 0.000100 +epsilon_nominal_voltage 1.000000 +min_plausible_low_voltage_limit 0.500000 +max_plausible_high_voltage_limit 1.500000 +ignore_voltage_bounds 0.000000 +buses_with_reactive_slacks ALL +PQmax 9000.000000 +defaultPmax 1000.000000 +defaultPmin 0.000000 +defaultQmaxPmaxRatio 1.000000 +defaultQmin -1000.000000 +defaultQmax 1000.000000 +minimalQPrange 1.000000 +default_variable_scaling_factor 1.000000 +default_constraint_scaling_factor 1.000000 +reactive_slack_variable_scaling_factor 0.100000 +transformer_ratio_variable_scaling_factor 0.001000 +shunt_variable_scaling_factor 0.100000 + +nb_substations 5 +nb_bus_in_data_file 5 +nb_bus_in_ACDC_CC 4 +nb_bus_in_AC_CC 4 +nb_bus_in_ACDC_but_out_AC_CC 0 +nb_bus_with_voltage_value 0 +nb_bus_with_reactive_slacks 4 +nb_bus_without_reactive_slacks 0 +nb_branch_in_data_file 4 +nb_branch_in_AC_CC 3 +nb_branch_with_nonsmall_impedance 3 +nb_branch_with_zero_or_small_impedance 0 +nb_unit_in_data_file 3 +nb_unit_in_AC_CC 2 +nb_unit_up_and_running 2 +nb_unit_with_variable_reactive_power 2 +nb_unit_with_fixed_reactive_power 0 +nb_load_in_data_file 2 +nb_load_in_AC_CC 1 +nb_shunt_in_data_file 0 +nb_shunt_connectable_or_in_AC_CC 0 +nb_shunt_with_fixed_value 0 +nb_shunt_with_variable_value 0 +nb_transformers_with_variable_ratio 0 +nb_transformers_with_fixed_ratio 0 +nb_svc_in_data_file 0 +nb_svc_in_AC_CC 0 +nb_svc_up_and_operating 0 +nb_vsc_converter_in_data_file 0 +nb_vsc_converter_up_and_running 0 +nb_lcc_converter_in_data_file 0 +nb_lcc_converter_up_and_running 0 +nb_batteries 0 +sum_batteries_pmax 0.0 +sum_batteries_pmin 0.0 + +max_teta_dc 0.02 +max_teta_ac 0.01 +teta_max 3.02 +min_teta_dc -0.04 +min_teta_ac -0.02 +teta_min -3.04 +max_delta_teta_dc 0.040000 +max_delta_teta_ac 0.018117 +min_delta_teta_dc -0.020000 +min_delta_teta_ac -0.008933 + +nb_reactive_slacks 0 +nb_slacks_condensator 0 +sum_slacks_condensator 0.0 +nb_slacks_self 0 +sum_slacks_self 0.0 diff --git a/open-reac/src/test/resources/optimization/indicators/battery-test/reactiveopf_results_indic.txt b/open-reac/src/test/resources/optimization/indicators/battery-test/reactiveopf_results_indic.txt new file mode 100644 index 00000000..fbff2832 --- /dev/null +++ b/open-reac/src/test/resources/optimization/indicators/battery-test/reactiveopf_results_indic.txt @@ -0,0 +1,80 @@ +final_status OK +dcopf_status OK + +log_level_ampl INFO +log_level_knitro 2 +objective_choice 0 +ratio_voltage_target 0.500000 +coeff_alpha 1.000000 +Pnull 0.010000 +Znull 0.000100 +epsilon_nominal_voltage 1.000000 +min_plausible_low_voltage_limit 0.500000 +max_plausible_high_voltage_limit 1.500000 +ignore_voltage_bounds 0.000000 +buses_with_reactive_slacks ALL +PQmax 9000.000000 +defaultPmax 1000.000000 +defaultPmin 0.000000 +defaultQmaxPmaxRatio 0.300000 +defaultQmin -300.000000 +defaultQmax 300.000000 +minimalQPrange 1.000000 +default_variable_scaling_factor 1.000000 +default_constraint_scaling_factor 1.000000 +reactive_slack_variable_scaling_factor 0.100000 +transformer_ratio_variable_scaling_factor 0.001000 +shunt_variable_scaling_factor 0.100000 + +nb_substations 4 +nb_bus_in_data_file 4 +nb_bus_in_ACDC_CC 4 +nb_bus_in_AC_CC 4 +nb_bus_in_ACDC_but_out_AC_CC 0 +nb_bus_with_voltage_value 0 +nb_bus_with_reactive_slacks 4 +nb_bus_without_reactive_slacks 0 +nb_branch_in_data_file 3 +nb_branch_in_AC_CC 3 +nb_branch_with_nonsmall_impedance 3 +nb_branch_with_zero_or_small_impedance 0 +nb_unit_in_data_file 3 +nb_unit_in_AC_CC 3 +nb_unit_up_and_running 3 +nb_unit_with_variable_reactive_power 3 +nb_unit_with_fixed_reactive_power 0 +nb_load_in_data_file 1 +nb_load_in_AC_CC 1 +nb_shunt_in_data_file 0 +nb_shunt_connectable_or_in_AC_CC 0 +nb_shunt_with_fixed_value 0 +nb_shunt_with_variable_value 0 +nb_transformers_with_variable_ratio 0 +nb_transformers_with_fixed_ratio 0 +nb_svc_in_data_file 0 +nb_svc_in_AC_CC 0 +nb_svc_up_and_operating 0 +nb_vsc_converter_in_data_file 0 +nb_vsc_converter_up_and_running 0 +nb_lcc_converter_in_data_file 0 +nb_lcc_converter_up_and_running 0 +nb_batteries 2 +sum_batteries_pmax 21.0 +sum_batteries_pmin -19.0 + +max_teta_dc 0.03 +max_teta_ac 0.02 +teta_max 3.03 +min_teta_dc 0.00 +min_teta_ac 0.00 +teta_min -3.00 +max_delta_teta_dc 0.030896 +max_delta_teta_ac 0.015495 +min_delta_teta_dc 0.018725 +min_delta_teta_ac 0.009609 + +nb_reactive_slacks 1 +nb_slacks_condensator 1 +sum_slacks_condensator 25.4 +nb_slacks_self 0 +sum_slacks_self 0.0 diff --git a/open-reac/src/test/resources/optimization/indicators/branches-test/reactiveopf_results_indic.txt b/open-reac/src/test/resources/optimization/indicators/branches-test/reactiveopf_results_indic.txt new file mode 100644 index 00000000..22f2bbae --- /dev/null +++ b/open-reac/src/test/resources/optimization/indicators/branches-test/reactiveopf_results_indic.txt @@ -0,0 +1,80 @@ +final_status OK +dcopf_status OK + +log_level_ampl INFO +log_level_knitro 2 +objective_choice 0 +ratio_voltage_target 0.500000 +coeff_alpha 1.000000 +Pnull 0.010000 +Znull 0.000100 +epsilon_nominal_voltage 1.000000 +min_plausible_low_voltage_limit 0.500000 +max_plausible_high_voltage_limit 1.500000 +ignore_voltage_bounds 0.000000 +buses_with_reactive_slacks ALL +PQmax 9000.000000 +defaultPmax 1000.000000 +defaultPmin 0.000000 +defaultQmaxPmaxRatio 0.300000 +defaultQmin -300.000000 +defaultQmax 300.000000 +minimalQPrange 1.000000 +default_variable_scaling_factor 1.000000 +default_constraint_scaling_factor 1.000000 +reactive_slack_variable_scaling_factor 0.100000 +transformer_ratio_variable_scaling_factor 0.001000 +shunt_variable_scaling_factor 0.100000 + +nb_substations 4 +nb_bus_in_data_file 4 +nb_bus_in_ACDC_CC 3 +nb_bus_in_AC_CC 3 +nb_bus_in_ACDC_but_out_AC_CC 0 +nb_bus_with_voltage_value 0 +nb_bus_with_reactive_slacks 3 +nb_bus_without_reactive_slacks 0 +nb_branch_in_data_file 4 +nb_branch_in_AC_CC 2 +nb_branch_with_nonsmall_impedance 1 +nb_branch_with_zero_or_small_impedance 1 +nb_unit_in_data_file 3 +nb_unit_in_AC_CC 2 +nb_unit_up_and_running 2 +nb_unit_with_variable_reactive_power 2 +nb_unit_with_fixed_reactive_power 0 +nb_load_in_data_file 2 +nb_load_in_AC_CC 2 +nb_shunt_in_data_file 0 +nb_shunt_connectable_or_in_AC_CC 0 +nb_shunt_with_fixed_value 0 +nb_shunt_with_variable_value 0 +nb_transformers_with_variable_ratio 0 +nb_transformers_with_fixed_ratio 0 +nb_svc_in_data_file 0 +nb_svc_in_AC_CC 0 +nb_svc_up_and_operating 0 +nb_vsc_converter_in_data_file 0 +nb_vsc_converter_up_and_running 0 +nb_lcc_converter_in_data_file 0 +nb_lcc_converter_up_and_running 0 +nb_batteries 0 +sum_batteries_pmax 0.0 +sum_batteries_pmin 0.0 + +max_teta_dc 0.03 +max_teta_ac 0.01 +teta_max 3.03 +min_teta_dc -0.00 +min_teta_ac -0.00 +teta_min -3.00 +max_delta_teta_dc 0.030000 +max_delta_teta_ac 0.013386 +min_delta_teta_dc 0.000001 +min_delta_teta_ac 0.000000 + +nb_reactive_slacks 2 +nb_slacks_condensator 2 +sum_slacks_condensator 0.2 +nb_slacks_self 0 +sum_slacks_self 0.0 diff --git a/open-reac/src/test/resources/optimization/indicators/bus-test/reactiveopf_results_indic.txt b/open-reac/src/test/resources/optimization/indicators/bus-test/reactiveopf_results_indic.txt new file mode 100644 index 00000000..dd20c88f --- /dev/null +++ b/open-reac/src/test/resources/optimization/indicators/bus-test/reactiveopf_results_indic.txt @@ -0,0 +1,80 @@ +final_status OK +dcopf_status OK + +log_level_ampl INFO +log_level_knitro 2 +objective_choice 0 +ratio_voltage_target 0.500000 +coeff_alpha 1.000000 +Pnull 0.010000 +Znull 0.000100 +epsilon_nominal_voltage 1.000000 +min_plausible_low_voltage_limit 0.500000 +max_plausible_high_voltage_limit 1.500000 +ignore_voltage_bounds 0.000000 +buses_with_reactive_slacks ALL +PQmax 9000.000000 +defaultPmax 1000.000000 +defaultPmin 0.000000 +defaultQmaxPmaxRatio 0.300000 +defaultQmin -300.000000 +defaultQmax 300.000000 +minimalQPrange 1.000000 +default_variable_scaling_factor 1.000000 +default_constraint_scaling_factor 1.000000 +reactive_slack_variable_scaling_factor 0.100000 +transformer_ratio_variable_scaling_factor 0.001000 +shunt_variable_scaling_factor 0.100000 + +nb_substations 16 +nb_bus_in_data_file 16 +nb_bus_in_ACDC_CC 16 +nb_bus_in_AC_CC 12 +nb_bus_in_ACDC_but_out_AC_CC 4 +nb_bus_with_voltage_value 1 +nb_bus_with_reactive_slacks 12 +nb_bus_without_reactive_slacks 0 +nb_branch_in_data_file 14 +nb_branch_in_AC_CC 11 +nb_branch_with_nonsmall_impedance 1 +nb_branch_with_zero_or_small_impedance 10 +nb_unit_in_data_file 3 +nb_unit_in_AC_CC 1 +nb_unit_up_and_running 1 +nb_unit_with_variable_reactive_power 1 +nb_unit_with_fixed_reactive_power 0 +nb_load_in_data_file 2 +nb_load_in_AC_CC 1 +nb_shunt_in_data_file 0 +nb_shunt_connectable_or_in_AC_CC 0 +nb_shunt_with_fixed_value 0 +nb_shunt_with_variable_value 0 +nb_transformers_with_variable_ratio 0 +nb_transformers_with_fixed_ratio 0 +nb_svc_in_data_file 0 +nb_svc_in_AC_CC 0 +nb_svc_up_and_operating 0 +nb_vsc_converter_in_data_file 0 +nb_vsc_converter_up_and_running 0 +nb_lcc_converter_in_data_file 2 +nb_lcc_converter_up_and_running 0 +nb_batteries 0 +sum_batteries_pmax 0.0 +sum_batteries_pmin 0.0 + +max_teta_dc 0.00 +max_teta_ac 0.00 +teta_max 3.00 +min_teta_dc -0.00 +min_teta_ac -0.00 +teta_min -3.00 +max_delta_teta_dc 0.000937 +max_delta_teta_ac 0.003363 +min_delta_teta_dc 0.000000 +min_delta_teta_ac -0.000000 + +nb_reactive_slacks 0 +nb_slacks_condensator 0 +sum_slacks_condensator 0.0 +nb_slacks_self 0 +sum_slacks_self 0.0 diff --git a/open-reac/src/test/resources/optimization/indicators/generators-test/reactiveopf_results_indic.txt b/open-reac/src/test/resources/optimization/indicators/generators-test/reactiveopf_results_indic.txt new file mode 100644 index 00000000..fc02cf9d --- /dev/null +++ b/open-reac/src/test/resources/optimization/indicators/generators-test/reactiveopf_results_indic.txt @@ -0,0 +1,80 @@ +final_status OK +dcopf_status OK + +log_level_ampl INFO +log_level_knitro 2 +objective_choice 0 +ratio_voltage_target 0.500000 +coeff_alpha 1.000000 +Pnull 0.010000 +Znull 0.000100 +epsilon_nominal_voltage 1.000000 +min_plausible_low_voltage_limit 0.500000 +max_plausible_high_voltage_limit 1.500000 +ignore_voltage_bounds 0.000000 +buses_with_reactive_slacks ALL +PQmax 9000.000000 +defaultPmax 1000.000000 +defaultPmin 0.000000 +defaultQmaxPmaxRatio 0.300000 +defaultQmin -300.000000 +defaultQmax 300.000000 +minimalQPrange 1.000000 +default_variable_scaling_factor 1.000000 +default_constraint_scaling_factor 1.000000 +reactive_slack_variable_scaling_factor 0.100000 +transformer_ratio_variable_scaling_factor 0.001000 +shunt_variable_scaling_factor 0.100000 + +nb_substations 4 +nb_bus_in_data_file 4 +nb_bus_in_ACDC_CC 4 +nb_bus_in_AC_CC 4 +nb_bus_in_ACDC_but_out_AC_CC 0 +nb_bus_with_voltage_value 0 +nb_bus_with_reactive_slacks 4 +nb_bus_without_reactive_slacks 0 +nb_branch_in_data_file 3 +nb_branch_in_AC_CC 3 +nb_branch_with_nonsmall_impedance 3 +nb_branch_with_zero_or_small_impedance 0 +nb_unit_in_data_file 3 +nb_unit_in_AC_CC 3 +nb_unit_up_and_running 3 +nb_unit_with_variable_reactive_power 2 +nb_unit_with_fixed_reactive_power 1 +nb_load_in_data_file 1 +nb_load_in_AC_CC 1 +nb_shunt_in_data_file 0 +nb_shunt_connectable_or_in_AC_CC 0 +nb_shunt_with_fixed_value 0 +nb_shunt_with_variable_value 0 +nb_transformers_with_variable_ratio 0 +nb_transformers_with_fixed_ratio 0 +nb_svc_in_data_file 0 +nb_svc_in_AC_CC 0 +nb_svc_up_and_operating 0 +nb_vsc_converter_in_data_file 0 +nb_vsc_converter_up_and_running 0 +nb_lcc_converter_in_data_file 0 +nb_lcc_converter_up_and_running 0 +nb_batteries 0 +sum_batteries_pmax 0.0 +sum_batteries_pmin 0.0 + +max_teta_dc 0.03 +max_teta_ac 0.02 +teta_max 3.03 +min_teta_dc 0.00 +min_teta_ac 0.00 +teta_min -3.00 +max_delta_teta_dc 0.031208 +max_delta_teta_ac 0.015617 +min_delta_teta_dc 0.018725 +min_delta_teta_ac 0.009685 + +nb_reactive_slacks 1 +nb_slacks_condensator 1 +sum_slacks_condensator 35.9 +nb_slacks_self 0 +sum_slacks_self 0.0 diff --git a/open-reac/src/test/resources/optimization/indicators/input-parameters-test/reactiveopf_results_indic.txt b/open-reac/src/test/resources/optimization/indicators/input-parameters-test/reactiveopf_results_indic.txt new file mode 100644 index 00000000..34df3341 --- /dev/null +++ b/open-reac/src/test/resources/optimization/indicators/input-parameters-test/reactiveopf_results_indic.txt @@ -0,0 +1,80 @@ +final_status OK +dcopf_status OK + +log_level_ampl WARNING +log_level_knitro 1 +objective_choice 2 +ratio_voltage_target 0.700000 +coeff_alpha 0.999000 +Pnull 0.020000 +Znull 0.000010 +epsilon_nominal_voltage 0.750000 +min_plausible_low_voltage_limit 0.655000 +max_plausible_high_voltage_limit 1.425000 +ignore_voltage_bounds 0.850000 +buses_with_reactive_slacks NO_GENERATION +PQmax 4001.000000 +defaultPmax 1001.000000 +defaultPmin 0.100000 +defaultQmaxPmaxRatio 0.200000 +defaultQmin -200.200000 +defaultQmax 200.200000 +minimalQPrange 2.000000 +default_variable_scaling_factor 1.001000 +default_constraint_scaling_factor 0.999000 +reactive_slack_variable_scaling_factor 0.010000 +transformer_ratio_variable_scaling_factor 0.002000 +shunt_variable_scaling_factor 0.110000 + +nb_substations 42 +nb_bus_in_data_file 57 +nb_bus_in_ACDC_CC 57 +nb_bus_in_AC_CC 57 +nb_bus_in_ACDC_but_out_AC_CC 0 +nb_bus_with_voltage_value 57 +nb_bus_with_reactive_slacks 53 +nb_bus_without_reactive_slacks 4 +nb_branch_in_data_file 80 +nb_branch_in_AC_CC 80 +nb_branch_with_nonsmall_impedance 80 +nb_branch_with_zero_or_small_impedance 0 +nb_unit_in_data_file 7 +nb_unit_in_AC_CC 7 +nb_unit_up_and_running 4 +nb_unit_with_variable_reactive_power 4 +nb_unit_with_fixed_reactive_power 0 +nb_load_in_data_file 42 +nb_load_in_AC_CC 42 +nb_shunt_in_data_file 3 +nb_shunt_connectable_or_in_AC_CC 3 +nb_shunt_with_fixed_value 3 +nb_shunt_with_variable_value 0 +nb_transformers_with_variable_ratio 0 +nb_transformers_with_fixed_ratio 0 +nb_svc_in_data_file 0 +nb_svc_in_AC_CC 0 +nb_svc_up_and_operating 0 +nb_vsc_converter_in_data_file 0 +nb_vsc_converter_up_and_running 0 +nb_lcc_converter_in_data_file 0 +nb_lcc_converter_up_and_running 0 +nb_batteries 0 +sum_batteries_pmax 0.0 +sum_batteries_pmin 0.0 + +max_teta_dc 0.21 +max_teta_ac 0.13 +teta_max 3.21 +min_teta_dc -0.17 +min_teta_ac -0.17 +teta_min -3.17 +max_delta_teta_dc 0.146072 +max_delta_teta_ac 0.105543 +min_delta_teta_dc -0.144911 +min_delta_teta_ac -0.088988 + +nb_reactive_slacks 0 +nb_slacks_condensator 0 +sum_slacks_condensator 0.0 +nb_slacks_self 0 +sum_slacks_self 0.0 diff --git a/open-reac/src/test/resources/optimization/indicators/lcc-test/reactiveopf_results_indic.txt b/open-reac/src/test/resources/optimization/indicators/lcc-test/reactiveopf_results_indic.txt new file mode 100644 index 00000000..3add2771 --- /dev/null +++ b/open-reac/src/test/resources/optimization/indicators/lcc-test/reactiveopf_results_indic.txt @@ -0,0 +1,80 @@ +final_status OK +dcopf_status OK + +log_level_ampl INFO +log_level_knitro 2 +objective_choice 0 +ratio_voltage_target 0.500000 +coeff_alpha 1.000000 +Pnull 0.010000 +Znull 0.000100 +epsilon_nominal_voltage 1.000000 +min_plausible_low_voltage_limit 0.500000 +max_plausible_high_voltage_limit 1.500000 +ignore_voltage_bounds 0.000000 +buses_with_reactive_slacks ALL +PQmax 9000.000000 +defaultPmax 1000.000000 +defaultPmin 0.000000 +defaultQmaxPmaxRatio 0.300000 +defaultQmin -300.000000 +defaultQmax 300.000000 +minimalQPrange 1.000000 +default_variable_scaling_factor 1.000000 +default_constraint_scaling_factor 1.000000 +reactive_slack_variable_scaling_factor 0.100000 +transformer_ratio_variable_scaling_factor 0.001000 +shunt_variable_scaling_factor 0.100000 + +nb_substations 3 +nb_bus_in_data_file 3 +nb_bus_in_ACDC_CC 3 +nb_bus_in_AC_CC 2 +nb_bus_in_ACDC_but_out_AC_CC 1 +nb_bus_with_voltage_value 0 +nb_bus_with_reactive_slacks 2 +nb_bus_without_reactive_slacks 0 +nb_branch_in_data_file 1 +nb_branch_in_AC_CC 1 +nb_branch_with_nonsmall_impedance 1 +nb_branch_with_zero_or_small_impedance 0 +nb_unit_in_data_file 2 +nb_unit_in_AC_CC 1 +nb_unit_up_and_running 1 +nb_unit_with_variable_reactive_power 1 +nb_unit_with_fixed_reactive_power 0 +nb_load_in_data_file 2 +nb_load_in_AC_CC 1 +nb_shunt_in_data_file 0 +nb_shunt_connectable_or_in_AC_CC 0 +nb_shunt_with_fixed_value 0 +nb_shunt_with_variable_value 0 +nb_transformers_with_variable_ratio 0 +nb_transformers_with_fixed_ratio 0 +nb_svc_in_data_file 0 +nb_svc_in_AC_CC 0 +nb_svc_up_and_operating 0 +nb_vsc_converter_in_data_file 0 +nb_vsc_converter_up_and_running 0 +nb_lcc_converter_in_data_file 2 +nb_lcc_converter_up_and_running 1 +nb_batteries 0 +sum_batteries_pmax 0.0 +sum_batteries_pmin 0.0 + +max_teta_dc 0.00 +max_teta_ac 0.00 +teta_max 3.00 +min_teta_dc 0.00 +min_teta_ac 0.00 +teta_min -3.00 +max_delta_teta_dc 0.000975 +max_delta_teta_ac 0.001211 +min_delta_teta_dc 0.000975 +min_delta_teta_ac 0.001211 + +nb_reactive_slacks 0 +nb_slacks_condensator 0 +sum_slacks_condensator 0.0 +nb_slacks_self 0 +sum_slacks_self 0.0 diff --git a/open-reac/src/test/resources/optimization/indicators/shunt-test/reactiveopf_results_indic.txt b/open-reac/src/test/resources/optimization/indicators/shunt-test/reactiveopf_results_indic.txt new file mode 100644 index 00000000..f735ad7a --- /dev/null +++ b/open-reac/src/test/resources/optimization/indicators/shunt-test/reactiveopf_results_indic.txt @@ -0,0 +1,80 @@ +final_status OK +dcopf_status OK + +log_level_ampl INFO +log_level_knitro 2 +objective_choice 0 +ratio_voltage_target 0.500000 +coeff_alpha 1.000000 +Pnull 0.010000 +Znull 0.000100 +epsilon_nominal_voltage 1.000000 +min_plausible_low_voltage_limit 0.500000 +max_plausible_high_voltage_limit 1.500000 +ignore_voltage_bounds 0.000000 +buses_with_reactive_slacks ALL +PQmax 9000.000000 +defaultPmax 1000.000000 +defaultPmin 0.000000 +defaultQmaxPmaxRatio 0.300000 +defaultQmin -300.000000 +defaultQmax 300.000000 +minimalQPrange 1.000000 +default_variable_scaling_factor 1.000000 +default_constraint_scaling_factor 1.000000 +reactive_slack_variable_scaling_factor 0.100000 +transformer_ratio_variable_scaling_factor 0.001000 +shunt_variable_scaling_factor 0.100000 + +nb_substations 3 +nb_bus_in_data_file 3 +nb_bus_in_ACDC_CC 3 +nb_bus_in_AC_CC 3 +nb_bus_in_ACDC_but_out_AC_CC 0 +nb_bus_with_voltage_value 0 +nb_bus_with_reactive_slacks 3 +nb_bus_without_reactive_slacks 0 +nb_branch_in_data_file 2 +nb_branch_in_AC_CC 2 +nb_branch_with_nonsmall_impedance 2 +nb_branch_with_zero_or_small_impedance 0 +nb_unit_in_data_file 1 +nb_unit_in_AC_CC 1 +nb_unit_up_and_running 1 +nb_unit_with_variable_reactive_power 1 +nb_unit_with_fixed_reactive_power 0 +nb_load_in_data_file 1 +nb_load_in_AC_CC 1 +nb_shunt_in_data_file 3 +nb_shunt_connectable_or_in_AC_CC 3 +nb_shunt_with_fixed_value 1 +nb_shunt_with_variable_value 1 +nb_transformers_with_variable_ratio 0 +nb_transformers_with_fixed_ratio 0 +nb_svc_in_data_file 0 +nb_svc_in_AC_CC 0 +nb_svc_up_and_operating 0 +nb_vsc_converter_in_data_file 0 +nb_vsc_converter_up_and_running 0 +nb_lcc_converter_in_data_file 0 +nb_lcc_converter_up_and_running 0 +nb_batteries 0 +sum_batteries_pmax 0.0 +sum_batteries_pmin 0.0 + +max_teta_dc 0.00 +max_teta_ac 0.00 +teta_max 3.00 +min_teta_dc 0.00 +min_teta_ac -0.00 +teta_min -3.00 +max_delta_teta_dc 0.001894 +max_delta_teta_ac 0.001642 +min_delta_teta_dc 0.000000 +min_delta_teta_ac -0.000773 + +nb_reactive_slacks 0 +nb_slacks_condensator 0 +sum_slacks_condensator 0.0 +nb_slacks_self 0 +sum_slacks_self 0.0 diff --git a/open-reac/src/test/resources/optimization/indicators/svc-test/reactiveopf_results_indic.txt b/open-reac/src/test/resources/optimization/indicators/svc-test/reactiveopf_results_indic.txt new file mode 100644 index 00000000..78fe35f3 --- /dev/null +++ b/open-reac/src/test/resources/optimization/indicators/svc-test/reactiveopf_results_indic.txt @@ -0,0 +1,80 @@ +final_status OK +dcopf_status OK + +log_level_ampl INFO +log_level_knitro 2 +objective_choice 0 +ratio_voltage_target 0.500000 +coeff_alpha 1.000000 +Pnull 0.010000 +Znull 0.000100 +epsilon_nominal_voltage 1.000000 +min_plausible_low_voltage_limit 0.500000 +max_plausible_high_voltage_limit 1.500000 +ignore_voltage_bounds 0.000000 +buses_with_reactive_slacks ALL +PQmax 9000.000000 +defaultPmax 1000.000000 +defaultPmin 0.000000 +defaultQmaxPmaxRatio 0.300000 +defaultQmin -300.000000 +defaultQmax 300.000000 +minimalQPrange 1.000000 +default_variable_scaling_factor 1.000000 +default_constraint_scaling_factor 1.000000 +reactive_slack_variable_scaling_factor 0.100000 +transformer_ratio_variable_scaling_factor 0.001000 +shunt_variable_scaling_factor 0.100000 + +nb_substations 2 +nb_bus_in_data_file 2 +nb_bus_in_ACDC_CC 2 +nb_bus_in_AC_CC 2 +nb_bus_in_ACDC_but_out_AC_CC 0 +nb_bus_with_voltage_value 0 +nb_bus_with_reactive_slacks 2 +nb_bus_without_reactive_slacks 0 +nb_branch_in_data_file 1 +nb_branch_in_AC_CC 1 +nb_branch_with_nonsmall_impedance 1 +nb_branch_with_zero_or_small_impedance 0 +nb_unit_in_data_file 1 +nb_unit_in_AC_CC 1 +nb_unit_up_and_running 1 +nb_unit_with_variable_reactive_power 1 +nb_unit_with_fixed_reactive_power 0 +nb_load_in_data_file 1 +nb_load_in_AC_CC 1 +nb_shunt_in_data_file 0 +nb_shunt_connectable_or_in_AC_CC 0 +nb_shunt_with_fixed_value 0 +nb_shunt_with_variable_value 0 +nb_transformers_with_variable_ratio 0 +nb_transformers_with_fixed_ratio 0 +nb_svc_in_data_file 2 +nb_svc_in_AC_CC 2 +nb_svc_up_and_operating 1 +nb_vsc_converter_in_data_file 0 +nb_vsc_converter_up_and_running 0 +nb_lcc_converter_in_data_file 0 +nb_lcc_converter_up_and_running 0 +nb_batteries 0 +sum_batteries_pmax 0.0 +sum_batteries_pmin 0.0 + +max_teta_dc 0.00 +max_teta_ac 0.00 +teta_max 3.00 +min_teta_dc 0.00 +min_teta_ac 0.00 +teta_min -3.00 +max_delta_teta_dc 0.001894 +max_delta_teta_ac 0.001258 +min_delta_teta_dc 0.001894 +min_delta_teta_ac 0.001258 + +nb_reactive_slacks 0 +nb_slacks_condensator 0 +sum_slacks_condensator 0.0 +nb_slacks_self 0 +sum_slacks_self 0.0 diff --git a/open-reac/src/test/resources/optimization/indicators/transfo-test/reactiveopf_results_indic.txt b/open-reac/src/test/resources/optimization/indicators/transfo-test/reactiveopf_results_indic.txt new file mode 100644 index 00000000..7e932de7 --- /dev/null +++ b/open-reac/src/test/resources/optimization/indicators/transfo-test/reactiveopf_results_indic.txt @@ -0,0 +1,80 @@ +final_status OK +dcopf_status OK + +log_level_ampl INFO +log_level_knitro 2 +objective_choice 0 +ratio_voltage_target 0.500000 +coeff_alpha 1.000000 +Pnull 0.010000 +Znull 0.000100 +epsilon_nominal_voltage 1.000000 +min_plausible_low_voltage_limit 0.500000 +max_plausible_high_voltage_limit 1.500000 +ignore_voltage_bounds 0.000000 +buses_with_reactive_slacks ALL +PQmax 9000.000000 +defaultPmax 1000.000000 +defaultPmin 0.000000 +defaultQmaxPmaxRatio 0.300000 +defaultQmin -300.000000 +defaultQmax 300.000000 +minimalQPrange 1.000000 +default_variable_scaling_factor 1.000000 +default_constraint_scaling_factor 1.000000 +reactive_slack_variable_scaling_factor 0.100000 +transformer_ratio_variable_scaling_factor 0.001000 +shunt_variable_scaling_factor 0.100000 + +nb_substations 3 +nb_bus_in_data_file 3 +nb_bus_in_ACDC_CC 3 +nb_bus_in_AC_CC 3 +nb_bus_in_ACDC_but_out_AC_CC 0 +nb_bus_with_voltage_value 0 +nb_bus_with_reactive_slacks 3 +nb_bus_without_reactive_slacks 0 +nb_branch_in_data_file 3 +nb_branch_in_AC_CC 3 +nb_branch_with_nonsmall_impedance 3 +nb_branch_with_zero_or_small_impedance 0 +nb_unit_in_data_file 1 +nb_unit_in_AC_CC 1 +nb_unit_up_and_running 1 +nb_unit_with_variable_reactive_power 1 +nb_unit_with_fixed_reactive_power 0 +nb_load_in_data_file 2 +nb_load_in_AC_CC 2 +nb_shunt_in_data_file 0 +nb_shunt_connectable_or_in_AC_CC 0 +nb_shunt_with_fixed_value 0 +nb_shunt_with_variable_value 0 +nb_transformers_with_variable_ratio 1 +nb_transformers_with_fixed_ratio 1 +nb_svc_in_data_file 0 +nb_svc_in_AC_CC 0 +nb_svc_up_and_operating 0 +nb_vsc_converter_in_data_file 0 +nb_vsc_converter_up_and_running 0 +nb_lcc_converter_in_data_file 0 +nb_lcc_converter_up_and_running 0 +nb_batteries 0 +sum_batteries_pmax 0.0 +sum_batteries_pmin 0.0 + +max_teta_dc 0.01 +max_teta_ac 0.02 +teta_max 3.01 +min_teta_dc -0.02 +min_teta_ac -0.04 +teta_min -3.02 +max_delta_teta_dc 0.022957 +max_delta_teta_ac 0.037399 +min_delta_teta_dc 0.009298 +min_delta_teta_ac 0.016902 + +nb_reactive_slacks 0 +nb_slacks_condensator 0 +sum_slacks_condensator 0.0 +nb_slacks_self 0 +sum_slacks_self 0.0 diff --git a/open-reac/src/test/resources/optimization/indicators/vsc-test/reactiveopf_results_indic.txt b/open-reac/src/test/resources/optimization/indicators/vsc-test/reactiveopf_results_indic.txt new file mode 100644 index 00000000..42a8e2fa --- /dev/null +++ b/open-reac/src/test/resources/optimization/indicators/vsc-test/reactiveopf_results_indic.txt @@ -0,0 +1,80 @@ +final_status OK +dcopf_status OK + +log_level_ampl INFO +log_level_knitro 2 +objective_choice 0 +ratio_voltage_target 0.500000 +coeff_alpha 1.000000 +Pnull 0.010000 +Znull 0.000100 +epsilon_nominal_voltage 1.000000 +min_plausible_low_voltage_limit 0.500000 +max_plausible_high_voltage_limit 1.500000 +ignore_voltage_bounds 0.000000 +buses_with_reactive_slacks ALL +PQmax 9000.000000 +defaultPmax 1000.000000 +defaultPmin 0.000000 +defaultQmaxPmaxRatio 0.300000 +defaultQmin -300.000000 +defaultQmax 300.000000 +minimalQPrange 1.000000 +default_variable_scaling_factor 1.000000 +default_constraint_scaling_factor 1.000000 +reactive_slack_variable_scaling_factor 0.100000 +transformer_ratio_variable_scaling_factor 0.001000 +shunt_variable_scaling_factor 0.100000 + +nb_substations 3 +nb_bus_in_data_file 3 +nb_bus_in_ACDC_CC 3 +nb_bus_in_AC_CC 2 +nb_bus_in_ACDC_but_out_AC_CC 1 +nb_bus_with_voltage_value 0 +nb_bus_with_reactive_slacks 2 +nb_bus_without_reactive_slacks 0 +nb_branch_in_data_file 1 +nb_branch_in_AC_CC 1 +nb_branch_with_nonsmall_impedance 1 +nb_branch_with_zero_or_small_impedance 0 +nb_unit_in_data_file 1 +nb_unit_in_AC_CC 1 +nb_unit_up_and_running 1 +nb_unit_with_variable_reactive_power 1 +nb_unit_with_fixed_reactive_power 0 +nb_load_in_data_file 2 +nb_load_in_AC_CC 1 +nb_shunt_in_data_file 0 +nb_shunt_connectable_or_in_AC_CC 0 +nb_shunt_with_fixed_value 0 +nb_shunt_with_variable_value 0 +nb_transformers_with_variable_ratio 0 +nb_transformers_with_fixed_ratio 0 +nb_svc_in_data_file 0 +nb_svc_in_AC_CC 0 +nb_svc_up_and_operating 0 +nb_vsc_converter_in_data_file 2 +nb_vsc_converter_up_and_running 1 +nb_lcc_converter_in_data_file 0 +nb_lcc_converter_up_and_running 0 +nb_batteries 0 +sum_batteries_pmax 0.0 +sum_batteries_pmin 0.0 + +max_teta_dc 0.00 +max_teta_ac 0.00 +teta_max 3.00 +min_teta_dc 0.00 +min_teta_ac 0.00 +teta_min -3.00 +max_delta_teta_dc 0.000975 +max_delta_teta_ac 0.001335 +min_delta_teta_dc 0.000975 +min_delta_teta_ac 0.001335 + +nb_reactive_slacks 0 +nb_slacks_condensator 0 +sum_slacks_condensator 0.0 +nb_slacks_self 0 +sum_slacks_self 0.0