Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
V
VILLASdataprocessing
Manage
Activity
Members
Code
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Analyze
Contributor analytics
CI/CD analytics
Repository analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
ACS
Public
VILLASframework
VILLASdataprocessing
Commits
098f7b8d
Commit
098f7b8d
authored
7 years ago
by
Markus Mirz
Browse files
Options
Downloads
Patches
Plain Diff
added dpsim module
parent
9efcf2ad
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
dataprocessing/dpsim.py
+16
-0
16 additions, 0 deletions
dataprocessing/dpsim.py
dataprocessing/timeseries.py
+0
-8
0 additions, 8 deletions
dataprocessing/timeseries.py
with
16 additions
and
8 deletions
dataprocessing/dpsim.py
0 → 100644
+
16
−
0
View file @
098f7b8d
from
dataprocessing.readtools
import
*
from
dataprocessing.timeseries
import
*
def
get_node_voltage_phasors
(
dpsim_timeseries_list
):
"""
Calculate voltage phasors of all nodes
:param dpsim_timeseries_list: timeseries list retrieved from dpsim results
:return:
"""
voltage_phasor_list
=
{}
for
ts
in
dpsim_timeseries_list
:
ts_abs
=
ts
.
abs
(
ts
.
name
+
'
_abs
'
)
ts_phase
=
ts
.
phase
(
ts
.
name
+
'
_phase
'
)
ts_phasor
=
[
ts_abs
,
ts_phase
]
voltage_phasor_list
[
ts
.
name
]
=
ts_phasor
return
voltage_phasor_list
This diff is collapsed.
Click to expand it.
dataprocessing/timeseries.py
+
0
−
8
View file @
098f7b8d
...
...
@@ -32,14 +32,6 @@ class TimeSeries:
ts_scaled
=
TimeSeries
(
name
,
self
.
time
,
self
.
values
*
factor
)
return
ts_scaled
@staticmethod
def
complex_abs_dep
(
name
,
ts_real
,
ts_imag
):
"""
Calculate absolute value of complex variable.
Assumes the same time steps for both timeseries.
"""
ts_abs
=
TimeSeries
(
name
,
ts_real
.
time
,
np
.
sqrt
(
ts_real
.
values
**
2
+
ts_imag
.
values
**
2
))
return
ts_abs
@staticmethod
def
complex_abs
(
name
,
ts_real
,
ts_imag
):
"""
Calculate absolute value of complex variable.
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment