Ask Your Question

terrytian's profile - activity

2015-10-05 21:02:21 -0500 received badge  Taxonomist
2014-09-29 02:20:23 -0500 received badge  Famous Question (source)
2014-09-29 02:20:23 -0500 received badge  Notable Question (source)
2014-09-29 02:20:21 -0500 received badge  Famous Question (source)
2014-09-26 20:15:03 -0500 received badge  Famous Question (source)
2014-09-24 22:49:27 -0500 received badge  Notable Question (source)
2014-09-18 18:54:29 -0500 received badge  Popular Question (source)
2014-09-17 20:21:10 -0500 asked a question Variables in dynamic simulation

I have a questions regarding the definitions of variables in dynamic simulation. It is a conceptual question not that relevant to PSS/E but I think it is helpful to know.

So my questions is: Since the simulation time step (delta t) in PSS/E dynamic simulation is 0.5 cycle, then why the voltage output is constant (say, voltage = 1.05 pu) during the simulation? To my understanding, the voltage simulation output should be sinusoidal, because the voltage is sinusoidal. Similarly, what is the definition of power (P) in the dynamic simulation? Is is the instantaneous value? Or is it a phasor value?

Thank you

2014-04-19 12:46:58 -0500 received badge  Popular Question (source)
2014-04-10 00:22:38 -0500 received badge  Notable Question (source)
2014-04-05 13:14:27 -0500 asked a question Generator internal voltage, retrieve

Hello,

As we know, the generator internal voltage:

E = I * Zsource + Vbus

where Zsource is the generator impedance Vbus is the bus voltage

Of course the internal voltage can be calculated by bus voltage, generator impedance, and generator output current.

My question is: Is there a way to retrieve the generator internal voltage 'E' using PSS/E API?

Thank you very much.

2014-02-22 06:31:47 -0500 received badge  Famous Question (source)
2014-01-30 22:44:07 -0500 received badge  Good Answer (source)
2014-01-30 22:44:07 -0500 received badge  Enlightened (source)
2014-01-28 20:27:15 -0500 received badge  Popular Question (source)
2014-01-27 10:15:05 -0500 received badge  Scholar (source)
2014-01-23 18:54:35 -0500 commented answer import cmath module error

yes, to use the native python interpreter will solve the problem. it takes me long time to troubleshoot my code, until i found the problem exist in the cmath module. Thank you.

2014-01-23 17:34:24 -0500 asked a question import cmath module error

Have someone notice that the cmath python module has a conflict with PSSE?

I mean, if you type:

import cmath

in the PSSE GUI command line, the PSSE GUI will crash.

anybody have same problem?

My PSSE version is 33.5

2014-01-02 22:05:08 -0500 commented answer Can't open .sav file

good point, yours is even better. It account for a non-windows platform.

2013-12-31 22:25:11 -0500 received badge  Nice Answer (source)
2013-12-31 22:16:25 -0500 received badge  Nice Answer (source)
2013-12-13 15:50:23 -0500 answered a question import pssexcel

Which PSS/E version are you using?

The 'pssexcel' module needs the 'win32api' module, and the 'win32api' is not installed with the original python. So you need to install pywin32 in order to import win32api module to python. The pywin32 can be downloaded from internet.

If you run your python code directly within the PSS/E version 33 GUI, you probably have some problem with the win32api module. This is because there is a conflict between PSS/E 33 GUI and win32api module. I don't know how to solve this problem.

However, you can use an alternative method, that is to run python on top of PSS/E, in other words, run python independently without running PSS/E. What you need to do is to tell python where the module psspy and pssexcel located in your computer. You can find this method in this forum. This has been discussed time and time again.

Your question is very similar to the previous question titled 'Exporting PV curve data from PSS/E to excel'. Your can search that question in this forum for some information.

2013-12-07 00:12:35 -0500 answered a question Can't open .sav file

this two lines are wrong:

os.environ['PATH'] +=PSSE_PATH + ';'
os.environ['PATH'] += File_Path + ';'

replace that two lines with:

os.environ['PATH'] += ';' + PSSE_PATH
os.environ['PATH'] += ';' + File_Path
2013-12-05 21:48:58 -0500 received badge  Notable Question (source)
2013-11-27 15:08:28 -0500 received badge  Citizen Patrol
2013-11-26 12:58:13 -0500 answered a question Exporting PV curve data from PSS/E to excel

I recommend you to run python on top of PSS/E. In other words, run the python script without PSS/E.

You can search this topic in this forum.

The basic idea is to add the following lines before your original python script to let it know where your PSS/E library installed.

import sys
import os

PSSE_LOCATION = r'C:\Program Files (x86)\PTI\PSSE33\PSSBIN' # your location may be different
sys.path.append(PSSE_LOCATION)
os.environ['PATH'] = os.environ['PATH'] + ';' +  PSSE_LOCATION

import psspy
import pssarrays
from psspy import _i, _f, _c
import redirect
redirect.psse2py()

import pssexcel # now this module can be loaded without error
psspy.psseinit() # this start the pss/e in python
2013-11-19 20:54:35 -0500 received badge  Editor (source)
2013-11-19 16:42:45 -0500 received badge  Teacher (source)
2013-11-19 15:06:57 -0500 answered a question WxPython crashing PSSE

Seems that your wxpython program did not actually quit the main-loop at the first time even you close the window.

Since you have:

app.MainLoop()

I am not familiar with wxpython. But I think you should add some code to let your program leave the main loop at the 'close button' function.

2013-11-19 15:01:49 -0500 answered a question Do we need to model delta-Y transformer 30 degree phase shift?

Thank you~

2013-11-19 15:00:33 -0500 received badge  Popular Question (source)
2013-11-19 11:25:27 -0500 answered a question Anyone can help me to debug the Python program?

This is because the list sys.argv contains only one element, that is your python script name, 'E:\007\21.py'.

Since python index starts from 0, the list element sys.argv[1] is actually the second element of the list sys.arg.

so you should use the following:

case_root = os.path.splitext(sys.argv[0])[0]

oh, in that case you should use:

case_root = os.path.splitext(CASE)[0]
2013-11-14 14:37:14 -0500 answered a question Can anybody help me with this PV Analysis Problem?

can you post your code?

2013-11-14 14:30:10 -0500 answered a question running PSSPY from Matlab

The PSSE 33 python module psspy.pyc is in python version 2.7.

Your python interpreter that is initiated by matlab is not version 2.7. So you get a bad magic number error.

Only the python 2.7 interpreter can import version 2.7 python module 'XXX.pyc'

You can know your python interpreter version by the following python code:

import sys
print sys.version
2013-11-08 10:46:19 -0500 asked a question Do we need to model delta-Y transformer 30 degree phase shift?

The delta-Y transformer has a 30 degree phase shift.

If we model the 30 degree phase shift in raw data file, the power flow result will have a 30 degree difference between from bus and to bus of a transformer. It is both weird and not intuitive for dynamic analysis.

However, if we don't model the 30 degree phase shift, the short circuit result is not accurate.

So what is the general rule of the Y-delta transformer modelling in PSSE?

Thank you.