system2mpc#

ams.io.matpower.system2mpc(system) dict[source]#

Convert data from an AMS system to an mpc dict.

In the gen section, slack generators preceeds PV generators.

Compared to the andes.io.matpower.system2mpc, this function includes the generator cost data in the gencost section. Additionally, c2 and c1 are scaled by base_mva to match MATPOWER unit MW.

Parameters:
systemams.core.system.System

AMS system

Returns:
mpc: dict

MATPOWER mpc dict