diff --git a/docs/user_manual/calculations.md b/docs/user_manual/calculations.md index 0fc9736f0..3d75877c0 100644 --- a/docs/user_manual/calculations.md +++ b/docs/user_manual/calculations.md @@ -364,9 +364,10 @@ Multiple appliance measurements (power measurements) on one bus are aggregated a $$ \begin{eqnarray} - \underline{S} = \sum_{k=1}^{N_{appliance}} \underline{S}_k + \underline{S} = \sum_{k=1}^{N_{appliance}} \underline{S}_k \quad\text{and}\quad \sigma_P^2 = \sum_{k=1}^{N_{appliance}} \sigma_{P,k}^2 + \quad\text{and}\quad \sigma_Q^2 = \sum_{k=1}^{N_{appliance}} \sigma_{Q,k}^2 \end{eqnarray} $$ diff --git a/tests/data/state_estimation/unbalanced-power-measurements/input.json b/tests/data/state_estimation/unbalanced-power-measurements/input.json new file mode 100644 index 000000000..5056323ce --- /dev/null +++ b/tests/data/state_estimation/unbalanced-power-measurements/input.json @@ -0,0 +1,98 @@ +{ + "version": "1.0", + "type": "input", + "is_batch": false, + "attributes": {}, + "data": { + "node": [ + { + "id": 1, + "u_rated": 10.5e3 + }, + { + "id": 2, + "u_rated": 10.5e3 + }, + { + "id": 3, + "u_rated": 10.5e3 + } + ], + "line": [ + { + "id": 4, + "from_node": 1, + "to_node": 2, + "from_status": 1, + "to_status": 1, + "r1": 0.11, + "x1": 0.5, + "c1": 1.0e-4, + "tan1": 1.0, + "i_n": 510.0 + }, + { + "id": 5, + "from_node": 2, + "to_node": 3, + "from_status": 1, + "to_status": 1, + "r1": 0.15, + "x1": 0.5, + "c1": 1.0e-4, + "tan1": 1.0, + "i_n": 520.0 + } + ], + "source": [ + { + "id": 6, + "node": 1, + "status": 1, + "u_ref": 1.01047619047619, + "sk": 200e6 + } + ], + "sym_load": [ + { + "id": 7, + "node": 2, + "status": 1, + "type": 4 + }, + { + "id": 8, + "node": 3, + "status": 1, + "type": 4 + } + ], + "sym_voltage_sensor": [ + { + "id": 101, + "measured_object": 1, + "u_measured": 10751.072595758282, + "u_angle_measured": 0.0, + "u_sigma": 105.0 + } + ], + "sym_power_sensor": [ + { + "id": 701, + "measured_object": 7, + "measured_terminal_type": 4, + "p_measured": 1010000.0, + "q_measured": 210000.0, + "power_sigma": 10316.0 + }, + { + "id": 801, + "measured_object": 8, + "measured_terminal_type": 4, + "p_measured": 1020000.0, + "q_measured": 220000.0, + "power_sigma": 10435.0 + } + ] + } +} \ No newline at end of file diff --git a/tests/data/state_estimation/unbalanced-power-measurements/input.json.license b/tests/data/state_estimation/unbalanced-power-measurements/input.json.license new file mode 100644 index 000000000..ebe16ce85 --- /dev/null +++ b/tests/data/state_estimation/unbalanced-power-measurements/input.json.license @@ -0,0 +1,3 @@ +SPDX-FileCopyrightText: 2022 Contributors to the Power Grid Model project + +SPDX-License-Identifier: MPL-2.0 \ No newline at end of file diff --git a/tests/data/state_estimation/unbalanced-power-measurements/params.json b/tests/data/state_estimation/unbalanced-power-measurements/params.json new file mode 100644 index 000000000..d1df53f8d --- /dev/null +++ b/tests/data/state_estimation/unbalanced-power-measurements/params.json @@ -0,0 +1,8 @@ +{ + "calculation_method": "iterative_linear", + "rtol": 1e-8, + "atol": { + "default": 1e-8, + ".+_residual": 5e-4 + } +} \ No newline at end of file diff --git a/tests/data/state_estimation/unbalanced-power-measurements/params.json.license b/tests/data/state_estimation/unbalanced-power-measurements/params.json.license new file mode 100644 index 000000000..ebe16ce85 --- /dev/null +++ b/tests/data/state_estimation/unbalanced-power-measurements/params.json.license @@ -0,0 +1,3 @@ +SPDX-FileCopyrightText: 2022 Contributors to the Power Grid Model project + +SPDX-License-Identifier: MPL-2.0 \ No newline at end of file diff --git a/tests/data/state_estimation/unbalanced-power-measurements/sym_output.json.license b/tests/data/state_estimation/unbalanced-power-measurements/sym_output.json.license new file mode 100644 index 000000000..ebe16ce85 --- /dev/null +++ b/tests/data/state_estimation/unbalanced-power-measurements/sym_output.json.license @@ -0,0 +1,3 @@ +SPDX-FileCopyrightText: 2022 Contributors to the Power Grid Model project + +SPDX-License-Identifier: MPL-2.0 \ No newline at end of file diff --git a/tests/data/state_estimation/unbalanced-power-measurements/sym_output_batch.json b/tests/data/state_estimation/unbalanced-power-measurements/sym_output_batch.json new file mode 100644 index 000000000..a75525830 --- /dev/null +++ b/tests/data/state_estimation/unbalanced-power-measurements/sym_output_batch.json @@ -0,0 +1,41 @@ +{ + "version": "1.0", + "type": "sym_output", + "is_batch": true, + "attributes": {}, + "data": [ + { + "node": [ + {"id": 1, "u": 10751.07259575828, "u_angle": 0}, + {"id": 2, "u": 10901.81945984043, "u_angle": -0.03749215598206366}, + {"id": 3, "u": 10936.7944291905, "u_angle": -0.05173620864857323} + ], + "sym_power_sensor": [ + {"id": 701, "p_residual": -0.0007460998485697701, "q_residual": 0.0006035038024876371}, + {"id": 801, "p_residual": -0.001219558232179452, "q_residual": 0.0009965786529342324} + ] + }, + { + "node": [ + {"id": 1, "u": 10751.07259575828, "u_angle": 0}, + {"id": 2, "u": 10901.81945984043, "u_angle": -0.03749215598206366}, + {"id": 3, "u": 10936.7944291905, "u_angle": -0.05173620864857323} + ], + "sym_power_sensor": [ + {"id": 701, "p_residual": -0.0007460998485697701, "q_residual": 0.0006035038024876371}, + {"id": 801, "p_residual": -0.001219558232179452, "q_residual": 0.0009965786529342324} + ] + }, + { + "node": [ + {"id": 1, "u": 10751.07259575828, "u_angle": 0}, + {"id": 2, "u": 10901.81945984043, "u_angle": -0.03749215598206366}, + {"id": 3, "u": 10936.7944291905, "u_angle": -0.05173620864857323} + ], + "sym_power_sensor": [ + {"id": 701, "p_residual": -0.0007460998485697701, "q_residual": 0.0006035038024876371}, + {"id": 801, "p_residual": -0.001219558232179452, "q_residual": 0.0009965786529342324} + ] + } + ] +} \ No newline at end of file diff --git a/tests/data/state_estimation/unbalanced-power-measurements/update_batch.json b/tests/data/state_estimation/unbalanced-power-measurements/update_batch.json new file mode 100644 index 000000000..242bec098 --- /dev/null +++ b/tests/data/state_estimation/unbalanced-power-measurements/update_batch.json @@ -0,0 +1,33 @@ +{ + "version": "1.0", + "type": "update", + "is_batch": true, + "attributes": { + "sym_power_sensor": [ + "id", + "power_sigma", + "p_measured", + "q_measured" + ] + }, + "data": [ + { + "sym_power_sensor": [ + {"id": 701, "p_sigma": 7294.513554720424, "q_sigma": 7294.513554720424}, + {"id": 801, "p_sigma": 7378.659261681623, "q_sigma": 7378.659261681623} + ] + }, + { + "sym_power_sensor": [ + {"id": 701, "p_sigma": 72.94513554720425, "q_sigma": 10315.484187104355}, + {"id": 801, "p_sigma": 73.78659261681624, "q_sigma": 10434.478236955598} + ] + }, + { + "sym_power_sensor": [ + {"id": 701, "p_sigma": 10315.484187104353, "q_sigma": 72.94513554720425}, + {"id": 801, "p_sigma": 10434.478236955598, "q_sigma": 73.78659261681624} + ] + } + ] +} \ No newline at end of file diff --git a/tests/data/state_estimation/unbalanced-power-measurements/update_batch.json.license b/tests/data/state_estimation/unbalanced-power-measurements/update_batch.json.license new file mode 100644 index 000000000..ebe16ce85 --- /dev/null +++ b/tests/data/state_estimation/unbalanced-power-measurements/update_batch.json.license @@ -0,0 +1,3 @@ +SPDX-FileCopyrightText: 2022 Contributors to the Power Grid Model project + +SPDX-License-Identifier: MPL-2.0 \ No newline at end of file