Skip to content

Add DanglingLineData and TwtData (#379)#432

Open
sebalaig wants to merge 4 commits into
integration/v1.6.0from
issue379-vAndAngle
Open

Add DanglingLineData and TwtData (#379)#432
sebalaig wants to merge 4 commits into
integration/v1.6.0from
issue379-vAndAngle

Conversation

@sebalaig

@sebalaig sebalaig commented Apr 29, 2022

Copy link
Copy Markdown
Contributor

Please check if the PR fulfills these requirements (please use '[x]' to check the checkboxes, or submit the PR and then click the checkboxes)

  • The commit message follows our guidelines
  • Tests for the changes have been added (for bug fixes / features)
  • Docs have been added / updated (for bug fixes / features)

Does this PR already have an issue describing the problem ? If so, link to this issue using '#XXX' and skip the rest
Closes #379

What kind of change does this PR introduce? (Bug fix, feature, docs update, ...)

What is the current behavior? (You can also link to an open issue here)

What is the new behavior (if this is a feature change)?

Does this PR introduce a breaking change or deprecate an API? If yes, check the following:

  • The Breaking Change or Deprecated label has been added
  • The migration guide has been updated in the github wiki (What changes might users need to make in their application due to this PR?)

Other information:

(if any of the questions/checkboxes don't apply, please delete them entirely)

@sebalaig sebalaig self-assigned this Apr 29, 2022
@sebalaig sebalaig force-pushed the issue379-vAndAngle branch from 6ed23d1 to 0b44f0a Compare May 6, 2022 13:43
@sebalaig sebalaig linked an issue May 6, 2022 that may be closed by this pull request
@sebalaig sebalaig force-pushed the issue379-vAndAngle branch from 0b44f0a to ecfd366 Compare May 6, 2022 15:09
@sebalaig sebalaig changed the title WIP: Add DanglingLineData and TwtData (#379) Add DanglingLineData and TwtData (#379) May 6, 2022
@sebalaig sebalaig force-pushed the issue379-vAndAngle branch from ecfd366 to 22b9d7d Compare May 6, 2022 17:19
@sebalaig sebalaig requested a review from mathbagu May 6, 2022 18:10
Comment thread include/powsybl/iidm/util/DanglingLineData.hpp Outdated
Comment thread include/powsybl/iidm/util/LinkData.hpp Outdated
Comment thread include/powsybl/iidm/util/LinkData.hpp
Comment thread src/iidm/util/DanglingLineData.cpp Outdated
Comment thread src/iidm/util/LinkData.cpp Outdated
Comment thread src/iidm/util/LinkData.cpp Outdated
Comment thread src/iidm/util/LinkData.cpp Outdated
Comment thread src/iidm/util/TwtData.cpp
m_ratedU0(twt.getRatedU0()) {
m_rho1 = rho(twt.getLeg1(), m_ratedU0);
m_rho2 = rho(twt.getLeg2(), m_ratedU0);
m_rho3 = rho(twt.getLeg3(), m_ratedU0);

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why these variables are not initialized in the initialization list?

@sebalaig sebalaig May 24, 2022

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Because m_ratedU0 needs to be initialized, and we cannot initialize m_rho1 in initializer list after m_ratedU0 without having a compiler warning. The solution could be to reorder attributes so that m_rho{1,2,3} are declared after m_ratedU0 ?

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No need to use m_rated0 because it’s equivalent to twt.getRated0()

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes it is needed because it is returned by TwtData::getRatedU0()

Comment thread src/iidm/util/TwtData.cpp Outdated
Comment thread src/iidm/util/TwtData.cpp Outdated
sebalaig added 3 commits May 24, 2022 11:04
… implementation to use it

Signed-off-by: Sébastien LAIGRE <slaigre@silicom.fr>
Signed-off-by: Sébastien LAIGRE <slaigre@silicom.fr>
Signed-off-by: Sébastien LAIGRE <slaigre@silicom.fr>
@sonarqubecloud

Copy link
Copy Markdown

Kudos, SonarCloud Quality Gate passed!    Quality Gate passed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 9 Code Smells

59.9% 59.9% Coverage
0.0% 0.0% Duplication

@sonarqubecloud

Copy link
Copy Markdown

Kudos, SonarCloud Quality Gate passed!    Quality Gate passed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 8 Code Smells

59.9% 59.9% Coverage
0.0% 0.0% Duplication

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Voltage and angle in 3wt star buses and boundary nodes

2 participants