0

How does psspy.machine_chng_2 work?

I tried using psspy.machinechng2 to change the Pgen of some machine, but I always get error at it. Here some line of the programme:

P=-1 while 1: P=P+1
ierr = psspy.machinechng2(81000, s, [i, _i, _i, _i, _i, 1], [P,]) psspy.fdns( options1=0, options2=0, options3=0, options4=0, options5=1, options6=1, options7=0, options8=0, )

ierr = psspy.solved() if ierr!=0:break H=P-1

What should I do?

kad's avatar
7
kad
asked 2017-05-23 00:08:12 -0500, updated 2017-05-23 00:10:22 -0500
edit flag offensive 0 remove flag close merge delete

Comments

add a comment see more comments

1 Answer

0

Replace variabel s with the generator id, e.g. '1'. You have also written i instead of _i for the first integer. The correct line is shown below:

ierr = psspy.machine_chng_2(81000, '1', [_i, _i, _i, _i, _i, 1], [P,])
perolofl's avatar
3.8k
perolofl
answered 2017-05-23 01:43:33 -0500
edit flag offensive 0 remove flag delete link

Comments

Hi! thank you for answering me, I change it, but I do still have the same error " AttributeError: 'module' object has no attribute 'machine_chng_2' "

kad's avatar kad (2017-05-23 06:01:18 -0500) edit

Which PSSE-version are you using? Is API machine_data_2 working? If not try machine_data instead!

perolofl's avatar perolofl (2017-05-24 01:30:26 -0500) edit

I'm using PSSE-32, and i think that was the problem. I did use machine_data_2 and it did work.Tthank you

kad's avatar kad (2017-05-24 04:34:57 -0500) edit
add a comment see more comments

Your Answer

Login/Signup to Answer