Skip to content
GitLab
Menu
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
ACS
Public
Power System Simulation and Optimization
DPsim
DPsim
Commits
36b60faa
Commit
36b60faa
authored
Dec 19, 2017
by
Viviane Sapucaia
Browse files
fixed mistake in fault clearing function
Former-commit-id:
2a1ce1dd
parent
09739a05
Changes
1
Hide whitespace changes
Inline
Side-by-side
Source/Simulation.cpp
View file @
36b60faa
...
...
@@ -295,33 +295,6 @@ void Simulation::clearFault(Int Node1, Int Node2, Int Node3) {
if
(
NumClearedPhases
==
3
)
ClearingFault
=
false
;
}
else
{
ClearingFault
=
true
;
mIShifta
=
getRightSideVector
()(
Node1
-
1
)
*
cos
(
2.
*
PI
*
60.
*
mTime
)
+
getRightSideVector
()(
Node1
-
1
+
mSystemModel
.
getCompOffset
())
*
sin
(
2.
*
PI
*
60.
*
mTime
);
mIShiftb
=
getRightSideVector
()(
Node2
-
1
)
*
cos
(
2.
*
PI
*
60.
*
mTime
)
+
getRightSideVector
()(
Node2
-
1
+
mSystemModel
.
getCompOffset
())
*
sin
(
2.
*
PI
*
60.
*
mTime
);
mIShiftc
=
getRightSideVector
()(
Node3
-
1
)
*
cos
(
2.
*
PI
*
60.
*
mTime
)
+
getRightSideVector
()(
Node3
-
1
+
mSystemModel
.
getCompOffset
())
*
sin
(
2.
*
PI
*
60.
*
mTime
);
if
(
FirstTime
==
true
)
{
mIShifta_hist
=
mIShifta
;
mIShiftb_hist
=
mIShiftb
;
mIShiftc_hist
=
mIShiftc
;
FirstTime
=
false
;
}
if
(
signbit
(
mIShifta
)
!=
signbit
(
mIShifta_hist
)
&&
!
aCleared
)
{
mElements
.
erase
(
mElements
.
begin
()
+
1
);
addSystemTopology
(
mElements
);
switchSystemMatrix
(
mSwitchEventVector
.
size
()
+
NumClearedPhases
);
NumClearedPhases
++
;
aCleared
=
true
;
}
}
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment