First time here? We are a friendly community of Power Systems Engineers. Check out the FAQ!

Ask Your Question
0

How to I get the contribution of neighboring buses, after the ascc_currents api runs?

asked Dec 6 '18

g.valentim gravatar image

I ran the ascc_currents API to get the three-phase fault currents in the buses of the working case and I wanted to know if it's possible to get the contribution of the neighboring buses to that current of a specific bus.

Assuming the working case has only 3 buses, if I get the three-phase fault current of bus 2, what is the contribution of buses 1 and 3 to that bus 2 fault current?

1 answer

Sort by » oldest newest most voted
0

answered Dec 9 '18

nelak gravatar image

I generate a report when I run my ASCC analysis, the report always has the contributions listed for me.

Are you running these manually or through the API?

If you're using the API this may help you find a way to implement it:

    def __ASCC(self, out_file_identifier, out_file_path, subsystem, gen_scfiles=False):
    """
    :param out_file_identifier: increments file names
    :param out_file_path: gives folder to place reports in
    :param subsystem: specifies subsystem id for psspy.ascc api
    :param gen_scfiles: option flag for scfile output of psspy.ascc api
    :return:
    """
    if not os.path.isfile(os.path.join(out_file_path, '%d_ASCC_rawData.txt' % out_file_identifier)):
        self.log('Running ASCC for segment %d' % out_file_identifier)
        ierr = self.psspy.report_output(2, os.path.join(out_file_path, '%d_ASCC_rawData.txt' % out_file_identifier))
        if ierr: self.log('Error on ASCC reporting for segment %s ierr %s' % (out_file_identifier, ierr), 'error')
        # class fault analysis conditions
        # ierr = self.psspy.flat_2([1, 1, 1, 2, 1, 2, 1, 3], [1, 1])

        if gen_scfiles:
            if not os.path.exists(os.path.join(out_file_path, 'scfiles')):
                os.makedirs(os.path.join(out_file_path, 'scfiles'))
            scfile_path = os.path.join(out_file_path, 'scfiles', '%d_scfile.sc' % out_file_identifier)
        else:
            scfile_path = ""
        # this flats the case and stuff
        ierr = self.psspy.ascc_3(subsystem, 0, [1, 1, 0, 1, 0, 2, 0, 1, 0, 1, 1, 0, 0, 2, 2, 1, 1], [1],
                                 '', '', scfile_path)
        if ierr: self.log('Error on ASCC segment %s ierr %s', 'error')

    else:
        self.log('skipping %d_ASCC_rawData.txt' % out_file_identifier)
link

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.
Want to format code in your answer? Here is a one minute demo on Youtube

Add Answer

[hide preview]

Question Tools

2 followers

Stats

Asked: Dec 6 '18

Seen: 526 times

Last updated: Dec 08 '18