[FEATURE] Provide a generic_branch3
Closed this issue · 1 comments
petersalemink95 commented
Following the discussion in #642 it was concluded that the implementation of a generic branch could be an addition to Power Grid Model.
We can make a new component generic_branch3
, which model a branch3
as a Pi model; i.e. the user can specify:
k_12
/k_13
/k_23
: transformer ratio (float)theta_12
/theta_13
/theta_23
: angle shiftr_series_12
/r_series_13
/r_series_23
x_series_12
/x_series_13
/x_series_23
g_shunt_12
/g_shunt_13
/g_shunt_23
b_shunt_12
/b_shunt_13
/b_shunt_23
generic_branch
is implemented in #729.
##steps to follow
In order to add a new component to Power Grid Model the following steps need to be taken:
- Check if the available input/update/output data suffices (check
power-grid-model/power_grid_model_c/power_grid_model/include/power_grid_model/auxiliary/
input.hpp
/update.hpp
/output.hpp
or in the documentation directly) - If not, add the new data format to
code_generation/data/attribute_classes/
input.json
/update.json
/output.json
+ runcode_generation/code_gen.py
- Create a new component in a new
power-grid-model/power_grid_model_c/power_grid_model/include/power_grid_model/component/[component].hpp
file that at least inherits from Base, but in this caseGenericBranch3
should inherit fromBranch3
- If necessary: add new enums or exceptions
- Create the necessary unit tests in
power-grid-model/tests/cpp_unit_tests/test_[component].cpp
- Add the
test_[component].cpp
topower-grid-model/tests/cpp_unit_tests/CMakeLists.txt
- Add component to
power_grid_model_c/power_grid_model/include/power_grid_model/all_components.hpp
- Not necessary for this component (If necessary update
main_core/topology.hpp
/input.hpp
/output.hpp
/update.hpp
) - Add component to
code_generation/data/dataset_class_maps/dataset_definitions.json
+ re-runcode_generation/code_gen.py
- Add validation test cases to
tests/data
- Update input/update data validator for the new component:
src/power_grid_model/validation/validation.py
+ add corresponding tests
Note: the order is recommended, but not necessary
petersalemink95 commented
Closing the issue, because "generic" three winding transformers should be modelled through three separate generic_branch
(#729)