VeraGridEngine.Devices.Branches packageο
Submodulesο
VeraGridEngine.Devices.Branches.branch moduleο
- class VeraGridEngine.Devices.Branches.branch.Branch(bus_from: Bus = None, bus_to: Bus = None, name='Branch', idtag=None, r=1e-20, x=1e-05, g=1e-20, b=1e-20, design_rate: float = 9999.0, rate=9999.0, tap=1.0, shift_angle=0, active=True, tolerance=0.0, cost=0.0, mttf=0, mttr=0, r_fault=0.0, x_fault=0.0, fault_pos=0.5, branch_type: BranchType = line, length=1.0, vset=1.0, temp_base=20, temp_oper=20, alpha=0.0033, bus_to_regulated=False, template=None)[source]ο
Bases:
BranchParent- property B: floatο
Get
B.- Returns:
float
- CLASS_NON_EDITABLE_PROPERTIES: Tuple[str, ...] = ('idtag', 'selected_to_merge', 'diff_changes', 'bus_from', 'bus_to')ο
- CLASS_PROPERTIES_WITH_PROFILE: Dict[str, str] = {'Cost': 'Cost_prof', 'active': 'active_prof', 'contingency_factor': 'contingency_factor_prof', 'protection_rating_factor': 'protection_rating_factor_prof', 'rate': 'rate_prof', 'temp_oper': 'temp_oper_prof'}ο
- CLASS_PROPERTY_DECLARATIONS: Tuple[GCProp, ...] = (prop:idtag, prop:name, prop:code, prop:rdfid, prop:action, prop:selected_to_merge, prop:comment, prop:diff_changes, prop:modelling_authority, prop:commissioned_date, prop:decommissioned_date, prop:build_status, prop:owners, prop:rms_model, prop:emt_model, prop:rms_template, prop:emt_template, prop:rms_fmu_template, prop:emt_fmu_template, prop:rms_fmu_import_config, prop:emt_fmu_import_config, prop:rms_fmu_me_import_config, prop:emt_fmu_me_import_config, prop:bus_from, prop:bus_to, prop:active, prop:reducible, prop:design_rate, prop:rate, prop:contingency_factor, prop:protection_rating_factor, prop:monitor_loading, prop:mttf, prop:mttr, prop:Cost, prop:capex, prop:opex, prop:group, prop:color, prop:bus_from_pos, prop:bus_to_pos, prop:temp_base, prop:temp_oper, prop:alpha, prop:R, prop:X, prop:B, prop:G, prop:tolerance, prop:length, prop:tap_module, prop:angle, prop:bus_to_regulated, prop:vset, prop:r_fault, prop:x_fault, prop:fault_pos)ο
- CLASS_PROPERTY_LIST: Tuple[GCProp, ...] = (prop:idtag, prop:name, prop:code, prop:rdfid, prop:action, prop:selected_to_merge, prop:comment, prop:diff_changes, prop:modelling_authority, prop:commissioned_date, prop:decommissioned_date, prop:build_status, prop:owners, prop:rms_model, prop:emt_model, prop:rms_template, prop:emt_template, prop:rms_fmu_template, prop:emt_fmu_template, prop:rms_fmu_import_config, prop:emt_fmu_import_config, prop:rms_fmu_me_import_config, prop:emt_fmu_me_import_config, prop:bus_from, prop:bus_to, prop:active, prop:reducible, prop:design_rate, prop:rate, prop:contingency_factor, prop:protection_rating_factor, prop:monitor_loading, prop:mttf, prop:mttr, prop:Cost, prop:capex, prop:opex, prop:group, prop:color, prop:bus_from_pos, prop:bus_to_pos, prop:temp_base, prop:temp_oper, prop:alpha, prop:R, prop:X, prop:B, prop:G, prop:tolerance, prop:length, prop:tap_module, prop:angle, prop:bus_to_regulated, prop:vset, prop:r_fault, prop:x_fault, prop:fault_pos)ο
- CLASS_REGISTERED_PROPERTIES: Dict[str, GCProp] = {'B': prop:B, 'Cost': prop:Cost, 'G': prop:G, 'R': prop:R, 'X': prop:X, 'action': prop:action, 'active': prop:active, 'alpha': prop:alpha, 'angle': prop:angle, 'build_status': prop:build_status, 'bus_from': prop:bus_from, 'bus_from_pos': prop:bus_from_pos, 'bus_to': prop:bus_to, 'bus_to_pos': prop:bus_to_pos, 'bus_to_regulated': prop:bus_to_regulated, 'capex': prop:capex, 'code': prop:code, 'color': prop:color, 'comment': prop:comment, 'commissioned_date': prop:commissioned_date, 'contingency_factor': prop:contingency_factor, 'decommissioned_date': prop:decommissioned_date, 'design_rate': prop:design_rate, 'diff_changes': prop:diff_changes, 'emt_fmu_import_config': prop:emt_fmu_import_config, 'emt_fmu_me_import_config': prop:emt_fmu_me_import_config, 'emt_fmu_template': prop:emt_fmu_template, 'emt_model': prop:emt_model, 'emt_template': prop:emt_template, 'fault_pos': prop:fault_pos, 'group': prop:group, 'idtag': prop:idtag, 'length': prop:length, 'modelling_authority': prop:modelling_authority, 'monitor_loading': prop:monitor_loading, 'mttf': prop:mttf, 'mttr': prop:mttr, 'name': prop:name, 'opex': prop:opex, 'owners': prop:owners, 'protection_rating_factor': prop:protection_rating_factor, 'r_fault': prop:r_fault, 'rate': prop:rate, 'rdfid': prop:rdfid, 'reducible': prop:reducible, 'rms_fmu_import_config': prop:rms_fmu_import_config, 'rms_fmu_me_import_config': prop:rms_fmu_me_import_config, 'rms_fmu_template': prop:rms_fmu_template, 'rms_model': prop:rms_model, 'rms_template': prop:rms_template, 'selected_to_merge': prop:selected_to_merge, 'tap_module': prop:tap_module, 'temp_base': prop:temp_base, 'temp_oper': prop:temp_oper, 'tolerance': prop:tolerance, 'vset': prop:vset, 'x_fault': prop:x_fault}ο
- property G: floatο
Get
G.- Returns:
float
- LOCAL_PROPERTY_DECLARATIONS: Tuple[GCProp, ...] = (prop:R, prop:X, prop:B, prop:G, prop:tolerance, prop:length, prop:tap_module, prop:angle, prop:bus_to_regulated, prop:vset, prop:r_fault, prop:x_fault, prop:fault_pos)ο
- property R: floatο
Get
R.- Returns:
float
- property R_correctedο
Returns a temperature corrected resistance based on a formula provided by: NFPA 70-2005, National Electrical Code, Table 8, footnote #2; and https://en.wikipedia.org/wiki/Electrical_resistivity_and_conductivity#Linear_approximation (version of 2019-01-03 at 15:20 EST).
- property X: floatο
Get
X.- Returns:
float
- property angle: floatο
Get
angle.- Returns:
float
- apply_tap_changer(tap_changer: TapChanger)[source]ο
Apply a new tap changer
Argument:
tap_changer (
VeraGridEngine.Devices.branch.TapChanger): Tap changer object
- branch_typeο
- branch_type_converter(val_string)[source]ο
function to convert the branch type string into the BranchType :param val_string: :return: branch type conversion
- property bus_to_regulated: boolο
Get
bus_to_regulated.- Returns:
bool
- convο
- copy(bus_dict=None)[source]ο
Returns a copy of the branch @return: A new with the same content as this
- property fault_pos: floatο
Get
fault_pos.- Returns:
float
- get_equivalent_line(index: DatetimeIndex | None = None) Line[source]ο
Get the equivalent line object :return:
- get_equivalent_transformer(index: DatetimeIndex | None = None) Transformer2W[source]ο
Convert this line into a transformer This is necessary if the busesβ voltage differ too much :return: Transformer2W
- inv_convο
- property length: floatο
Get
length.- Returns:
float
- measurementsο
- plot_profiles(time_series=None, my_index=0, show_fig=True)[source]ο
Plot the time series results of this object :param time_series: TimeSeries Instance :param my_index: index of this object in the simulation :param show_fig: Show the figure?
- property r_fault: floatο
Get
r_fault.- Returns:
float
- property rate_prof: ProfileFloatο
Cost profile :return: Profile
- tap_changerο
- property tap_module: floatο
Get
tap_module.- Returns:
float
- property temp_oper_prof: ProfileFloatο
Cost profile :return: Profile
- templateο
- property tolerance: floatο
Get
tolerance.- Returns:
float
- property vset: floatο
Get
vset.- Returns:
float
- property x_fault: floatο
Get
x_fault.- Returns:
float
- class VeraGridEngine.Devices.Branches.branch.BranchType(value)[source]ο
Bases:
Enum- Branch = 'branch'ο
- BranchTemplate = 'BranchTemplate'ο
- DCLine = 'DC-line'ο
- Line = 'line'ο
- Reactance = 'reactance'ο
- Switch = 'switch'ο
- Transformer = 'transformer'ο
- UPFC = 'UPFC'ο
- VSC = 'VSC'ο
- Winding = 'Winding'ο
- VeraGridEngine.Devices.Branches.branch.SQRT3 = np.float64(1.7320508075688772)ο
- NOTE: This device is legacy and unsupported
It only exists because older VeraGrid versions used it Now when this devices is used it is immediately converted to either a line or transformer
VeraGridEngine.Devices.Branches.dc_line moduleο
- class VeraGridEngine.Devices.Branches.dc_line.DcLine(bus_from: Bus | None = None, bus_to: Bus | None = None, name: str = 'Dc Line', idtag: str | None = None, code: str = '', r=1e-20, design_rate: float = 9999, rate=9999.0, active=True, tolerance=0, cost=0.0, mttf=0, mttr=0, r_fault=0.0, fault_pos=0.5, length=1, temp_base=20, temp_oper=20, alpha=0.0033, template=None, contingency_factor=1.0, protection_rating_factor: float = 1.4, contingency_enabled=True, monitor_loading=True, capex=0, opex=0, build_status: BuildStatus = Commissioned)[source]ο
Bases:
BranchParent- CLASS_NON_EDITABLE_PROPERTIES: Tuple[str, ...] = ('idtag', 'selected_to_merge', 'diff_changes', 'bus_from', 'bus_to', 'template', 'locations')ο
- CLASS_PROPERTIES_WITH_PROFILE: Dict[str, str] = {'Cost': 'Cost_prof', 'active': 'active_prof', 'contingency_factor': 'contingency_factor_prof', 'protection_rating_factor': 'protection_rating_factor_prof', 'rate': 'rate_prof', 'temp_oper': 'temp_oper_prof'}ο
- CLASS_PROPERTY_DECLARATIONS: Tuple[GCProp, ...] = (prop:idtag, prop:name, prop:code, prop:rdfid, prop:action, prop:selected_to_merge, prop:comment, prop:diff_changes, prop:modelling_authority, prop:commissioned_date, prop:decommissioned_date, prop:build_status, prop:owners, prop:rms_model, prop:emt_model, prop:rms_template, prop:emt_template, prop:rms_fmu_template, prop:emt_fmu_template, prop:rms_fmu_import_config, prop:emt_fmu_import_config, prop:rms_fmu_me_import_config, prop:emt_fmu_me_import_config, prop:bus_from, prop:bus_to, prop:active, prop:reducible, prop:design_rate, prop:rate, prop:contingency_factor, prop:protection_rating_factor, prop:monitor_loading, prop:mttf, prop:mttr, prop:Cost, prop:capex, prop:opex, prop:group, prop:color, prop:bus_from_pos, prop:bus_to_pos, prop:temp_base, prop:temp_oper, prop:alpha, prop:R, prop:length, prop:r_fault, prop:fault_pos, prop:template, prop:locations)ο
- CLASS_PROPERTY_LIST: Tuple[GCProp, ...] = (prop:idtag, prop:name, prop:code, prop:rdfid, prop:action, prop:selected_to_merge, prop:comment, prop:diff_changes, prop:modelling_authority, prop:commissioned_date, prop:decommissioned_date, prop:build_status, prop:owners, prop:rms_model, prop:emt_model, prop:rms_template, prop:emt_template, prop:rms_fmu_template, prop:emt_fmu_template, prop:rms_fmu_import_config, prop:emt_fmu_import_config, prop:rms_fmu_me_import_config, prop:emt_fmu_me_import_config, prop:bus_from, prop:bus_to, prop:active, prop:reducible, prop:design_rate, prop:rate, prop:contingency_factor, prop:protection_rating_factor, prop:monitor_loading, prop:mttf, prop:mttr, prop:Cost, prop:capex, prop:opex, prop:group, prop:color, prop:bus_from_pos, prop:bus_to_pos, prop:temp_base, prop:temp_oper, prop:alpha, prop:R, prop:length, prop:r_fault, prop:fault_pos, prop:template, prop:locations)ο
- CLASS_REGISTERED_PROPERTIES: Dict[str, GCProp] = {'Cost': prop:Cost, 'R': prop:R, 'action': prop:action, 'active': prop:active, 'alpha': prop:alpha, 'build_status': prop:build_status, 'bus_from': prop:bus_from, 'bus_from_pos': prop:bus_from_pos, 'bus_to': prop:bus_to, 'bus_to_pos': prop:bus_to_pos, 'capex': prop:capex, 'code': prop:code, 'color': prop:color, 'comment': prop:comment, 'commissioned_date': prop:commissioned_date, 'contingency_factor': prop:contingency_factor, 'decommissioned_date': prop:decommissioned_date, 'design_rate': prop:design_rate, 'diff_changes': prop:diff_changes, 'emt_fmu_import_config': prop:emt_fmu_import_config, 'emt_fmu_me_import_config': prop:emt_fmu_me_import_config, 'emt_fmu_template': prop:emt_fmu_template, 'emt_model': prop:emt_model, 'emt_template': prop:emt_template, 'fault_pos': prop:fault_pos, 'group': prop:group, 'idtag': prop:idtag, 'length': prop:length, 'locations': prop:locations, 'modelling_authority': prop:modelling_authority, 'monitor_loading': prop:monitor_loading, 'mttf': prop:mttf, 'mttr': prop:mttr, 'name': prop:name, 'opex': prop:opex, 'owners': prop:owners, 'protection_rating_factor': prop:protection_rating_factor, 'r_fault': prop:r_fault, 'rate': prop:rate, 'rdfid': prop:rdfid, 'reducible': prop:reducible, 'rms_fmu_import_config': prop:rms_fmu_import_config, 'rms_fmu_me_import_config': prop:rms_fmu_me_import_config, 'rms_fmu_template': prop:rms_fmu_template, 'rms_model': prop:rms_model, 'rms_template': prop:rms_template, 'selected_to_merge': prop:selected_to_merge, 'temp_base': prop:temp_base, 'temp_oper': prop:temp_oper, 'template': prop:template}ο
- LOCAL_PROPERTY_DECLARATIONS: Tuple[GCProp, ...] = (prop:R, prop:length, prop:r_fault, prop:fault_pos, prop:template, prop:locations)ο
- property R: floatο
Get
R.- Returns:
float
- property R_correctedο
Returns a temperature corrected resistance based on a formula provided by: NFPA 70-2005, National Electrical Code, Table 8, footnote #2; and https://en.wikipedia.org/wiki/Electrical_resistivity_and_conductivity#Linear_approximation (version of 2019-01-03 at 15:20 EST).
- copy(bus_dict=None)[source]ο
Returns a copy of the dc line @return: A new with the same content as this
- property fault_pos: floatο
Get
fault_pos.- Returns:
float
- property length: floatο
Line length in km :return: float
- property locations: LineLocationsο
Cost profile :return: Profile
- measurementsο
- plot_profiles(time_series=None, my_index=0, show_fig=True)[source]ο
Plot the time series results of this object :param time_series: TimeSeries Instance :param my_index: index of this object in the simulation :param show_fig: Show the figure?
- property r_fault: floatο
Get
r_fault.- Returns:
float
- property temp_oper_prof: ProfileFloatο
Cost profile :return: Profile
- templateο
- toleranceο
VeraGridEngine.Devices.Branches.hvdc_line moduleο
- class VeraGridEngine.Devices.Branches.hvdc_line.HvdcLine[source]ο
Bases:
BranchParent- CLASS_NON_EDITABLE_PROPERTIES: Tuple[str, ...] = ('idtag', 'selected_to_merge', 'diff_changes', 'bus_from', 'bus_to', 'locations')ο
- CLASS_PROPERTIES_WITH_PROFILE: Dict[str, str] = {'Cost': 'Cost_prof', 'Pset': 'Pset_prof', 'Vset_f': 'Vset_f_prof', 'Vset_t': 'Vset_t_prof', 'active': 'active_prof', 'angle_droop': 'angle_droop_prof', 'contingency_factor': 'contingency_factor_prof', 'protection_rating_factor': 'protection_rating_factor_prof', 'rate': 'rate_prof', 'temp_oper': 'temp_oper_prof'}ο
- CLASS_PROPERTY_DECLARATIONS: Tuple[GCProp, ...] = (prop:idtag, prop:name, prop:code, prop:rdfid, prop:action, prop:selected_to_merge, prop:comment, prop:diff_changes, prop:modelling_authority, prop:commissioned_date, prop:decommissioned_date, prop:build_status, prop:owners, prop:rms_model, prop:emt_model, prop:rms_template, prop:emt_template, prop:rms_fmu_template, prop:emt_fmu_template, prop:rms_fmu_import_config, prop:emt_fmu_import_config, prop:rms_fmu_me_import_config, prop:emt_fmu_me_import_config, prop:bus_from, prop:bus_to, prop:active, prop:reducible, prop:design_rate, prop:rate, prop:contingency_factor, prop:protection_rating_factor, prop:monitor_loading, prop:mttf, prop:mttr, prop:Cost, prop:capex, prop:opex, prop:group, prop:color, prop:bus_from_pos, prop:bus_to_pos, prop:temp_base, prop:temp_oper, prop:alpha, prop:dispatchable, prop:control_mode, prop:Pset, prop:r, prop:dc_link_voltage, prop:angle_droop, prop:Vset_f, prop:Vset_t, prop:min_firing_angle_f, prop:max_firing_angle_f, prop:min_firing_angle_t, prop:max_firing_angle_t, prop:length, prop:locations)ο
- CLASS_PROPERTY_LIST: Tuple[GCProp, ...] = (prop:idtag, prop:name, prop:code, prop:rdfid, prop:action, prop:selected_to_merge, prop:comment, prop:diff_changes, prop:modelling_authority, prop:commissioned_date, prop:decommissioned_date, prop:build_status, prop:owners, prop:rms_model, prop:emt_model, prop:rms_template, prop:emt_template, prop:rms_fmu_template, prop:emt_fmu_template, prop:rms_fmu_import_config, prop:emt_fmu_import_config, prop:rms_fmu_me_import_config, prop:emt_fmu_me_import_config, prop:bus_from, prop:bus_to, prop:active, prop:reducible, prop:design_rate, prop:rate, prop:contingency_factor, prop:protection_rating_factor, prop:monitor_loading, prop:mttf, prop:mttr, prop:Cost, prop:capex, prop:opex, prop:group, prop:color, prop:bus_from_pos, prop:bus_to_pos, prop:temp_base, prop:temp_oper, prop:alpha, prop:dispatchable, prop:control_mode, prop:Pset, prop:r, prop:dc_link_voltage, prop:angle_droop, prop:Vset_f, prop:Vset_t, prop:min_firing_angle_f, prop:max_firing_angle_f, prop:min_firing_angle_t, prop:max_firing_angle_t, prop:length, prop:locations)ο
- CLASS_REGISTERED_PROPERTIES: Dict[str, GCProp] = {'Cost': prop:Cost, 'Pset': prop:Pset, 'Vset_f': prop:Vset_f, 'Vset_t': prop:Vset_t, 'action': prop:action, 'active': prop:active, 'alpha': prop:alpha, 'angle_droop': prop:angle_droop, 'build_status': prop:build_status, 'bus_from': prop:bus_from, 'bus_from_pos': prop:bus_from_pos, 'bus_to': prop:bus_to, 'bus_to_pos': prop:bus_to_pos, 'capex': prop:capex, 'code': prop:code, 'color': prop:color, 'comment': prop:comment, 'commissioned_date': prop:commissioned_date, 'contingency_factor': prop:contingency_factor, 'control_mode': prop:control_mode, 'dc_link_voltage': prop:dc_link_voltage, 'decommissioned_date': prop:decommissioned_date, 'design_rate': prop:design_rate, 'diff_changes': prop:diff_changes, 'dispatchable': prop:dispatchable, 'emt_fmu_import_config': prop:emt_fmu_import_config, 'emt_fmu_me_import_config': prop:emt_fmu_me_import_config, 'emt_fmu_template': prop:emt_fmu_template, 'emt_model': prop:emt_model, 'emt_template': prop:emt_template, 'group': prop:group, 'idtag': prop:idtag, 'length': prop:length, 'locations': prop:locations, 'max_firing_angle_f': prop:max_firing_angle_f, 'max_firing_angle_t': prop:max_firing_angle_t, 'min_firing_angle_f': prop:min_firing_angle_f, 'min_firing_angle_t': prop:min_firing_angle_t, 'modelling_authority': prop:modelling_authority, 'monitor_loading': prop:monitor_loading, 'mttf': prop:mttf, 'mttr': prop:mttr, 'name': prop:name, 'opex': prop:opex, 'owners': prop:owners, 'protection_rating_factor': prop:protection_rating_factor, 'r': prop:r, 'rate': prop:rate, 'rdfid': prop:rdfid, 'reducible': prop:reducible, 'rms_fmu_import_config': prop:rms_fmu_import_config, 'rms_fmu_me_import_config': prop:rms_fmu_me_import_config, 'rms_fmu_template': prop:rms_fmu_template, 'rms_model': prop:rms_model, 'rms_template': prop:rms_template, 'selected_to_merge': prop:selected_to_merge, 'temp_base': prop:temp_base, 'temp_oper': prop:temp_oper}ο
- LOCAL_PROPERTY_DECLARATIONS: Tuple[GCProp, ...] = (prop:dispatchable, prop:control_mode, prop:Pset, prop:r, prop:dc_link_voltage, prop:angle_droop, prop:Vset_f, prop:Vset_t, prop:min_firing_angle_f, prop:max_firing_angle_f, prop:min_firing_angle_t, prop:max_firing_angle_t, prop:length, prop:locations)ο
- property Pset: floatο
Get
Pset.- Returns:
float
- property Pset_prof: ProfileFloatο
Cost profile :return: Profile
- property Vset_f: floatο
Get
Vset_f.- Returns:
float
- property Vset_f_prof: ProfileFloatο
Cost profile :return: Profile
- property Vset_t: floatο
Get
Vset_t.- Returns:
float
- property Vset_t_prof: ProfileFloatο
Cost profile :return: Profile
- property angle_droop: floatο
Get
angle_droop.- Returns:
float
- property angle_droop_prof: ProfileFloatο
Cost profile :return: Profile
- build_statusο
- capexο
- control_mode: HvdcControlTypeο
- property dc_link_voltage: floatο
Get
dc_link_voltage.- Returns:
float
- property dispatchable: boolο
Get
dispatchable.- Returns:
bool
- get_from_and_to_power(theta_f, theta_t, Sbase, in_pu=False)[source]ο
Get the power set at both ends accounting for meaningful losses :return: power from, power to
- get_from_and_to_power_at(t, theta_f, theta_t, Sbase, in_pu=False)[source]ο
Get the power set at both ends accounting for meaningful losses :return: power from, power to
- get_q_limits(P: float) Tuple[float, float, float, float][source]ο
Get reactive power limits :param P: Pset value :return: Qmin_f, Qmax_f, Qmin_t, Qmax_t
- property length: floatο
Line length in km :return: float
- property locations: LineLocationsο
Cost profile :return: Profile
- loss_factorο
- property max_firing_angle_f: floatο
Get
max_firing_angle_f.- Returns:
float
- property max_firing_angle_t: floatο
Get
max_firing_angle_t.- Returns:
float
- property min_firing_angle_f: floatο
Get
min_firing_angle_f.- Returns:
float
- property min_firing_angle_t: floatο
Get
min_firing_angle_t.- Returns:
float
- mttfο
- mttrο
- opexο
- plot_profiles(time_series=None, my_index=0, show_fig=True)[source]ο
Plot the time series results of this object :param time_series: TimeSeries Instance :param my_index: index of this object in the simulation :param show_fig: Show the figure?
- property r: floatο
Get
r.- Returns:
float
- VeraGridEngine.Devices.Branches.hvdc_line.firing_angles_to_reactive_limits(P: float, alphamin: float, alphamax: float) Tuple[float, float][source]ο
Convert firing angles to reactive power limits :param P: Active power (MW) :param alphamin: minimum firing angle (rad) :param alphamax: Maximum firing angle (rad) :return: Qmin (MVAr), Qmax (MVAr)
- VeraGridEngine.Devices.Branches.hvdc_line.getFromAndToPowerAt(Pset: float, theta_f: float, theta_t: float, Vnf: float, Vnt: float, v_set_f: float, v_set_t: float, Sbase: float, r1: float, angle_droop: float, rate: float, free: bool, in_pu: bool = False)[source]ο
Compute the power and losses :param Pset: set power in MW :param theta_f: angle from (rad) :param theta_t: angle to (rad) :param Vnf: nominal voltage from (kV) :param Vnt: nominal voltage to (kV) :param v_set_f: control voltage from (p.u.) :param v_set_t: control voltage to (p.u.) :param Sbase: base power MVA :param r1: line resistance (ohm) :param angle_droop: angle droop control (MW/deg) :param rate: Rate (MW) :param free: is free to use the angle droop? :param in_pu: return power in per unit? otherwise the power comes in MW :return: Pf, Pt, losses (in MW or p.u. depending on in_pu)
VeraGridEngine.Devices.Branches.line moduleο
- class VeraGridEngine.Devices.Branches.line.Line(bus_from: Bus = None, bus_to: Bus = None, name='Line', idtag=None, code='', r=1e-20, x=1e-05, b=1e-20, design_rate: float = 9999.0, rate=9999.0, active=True, tolerance=0.0, cost=100.0, mttf=0.0, mttr=0, r_fault=0.0, x_fault=0.0, fault_pos=0.5, length=1.0, temp_base=20, temp_oper=20, alpha=0.0033, template=None, contingency_factor=1.0, protection_rating_factor: float = 1.4, contingency_enabled=True, monitor_loading=True, r0=1e-20, x0=1e-20, b0=1e-20, r2=1e-20, x2=1e-20, b2=1e-20, capex=0, opex=0, circuit_idx: int = 1, build_status: BuildStatus = Commissioned)[source]ο
Bases:
BranchParent- property Bο
- property B0ο
- property B2ο
- CLASS_NON_EDITABLE_PROPERTIES: Tuple[str, ...] = ('idtag', 'selected_to_merge', 'diff_changes', 'bus_from', 'bus_to', 'ys', 'ysh', 'circuit_idx', 'template', 'locations')ο
- CLASS_PROPERTIES_WITH_PROFILE: Dict[str, str] = {'Cost': 'Cost_prof', 'active': 'active_prof', 'contingency_factor': 'contingency_factor_prof', 'protection_rating_factor': 'protection_rating_factor_prof', 'rate': 'rate_prof', 'temp_oper': 'temp_oper_prof'}ο
- CLASS_PROPERTY_DECLARATIONS: Tuple[GCProp, ...] = (prop:idtag, prop:name, prop:code, prop:rdfid, prop:action, prop:selected_to_merge, prop:comment, prop:diff_changes, prop:modelling_authority, prop:commissioned_date, prop:decommissioned_date, prop:build_status, prop:owners, prop:rms_model, prop:emt_model, prop:rms_template, prop:emt_template, prop:rms_fmu_template, prop:emt_fmu_template, prop:rms_fmu_import_config, prop:emt_fmu_import_config, prop:rms_fmu_me_import_config, prop:emt_fmu_me_import_config, prop:bus_from, prop:bus_to, prop:active, prop:reducible, prop:design_rate, prop:rate, prop:contingency_factor, prop:protection_rating_factor, prop:monitor_loading, prop:mttf, prop:mttr, prop:Cost, prop:capex, prop:opex, prop:group, prop:color, prop:bus_from_pos, prop:bus_to_pos, prop:temp_base, prop:temp_oper, prop:alpha, prop:R, prop:X, prop:B, prop:R0, prop:X0, prop:B0, prop:R2, prop:X2, prop:B2, prop:ys, prop:ysh, prop:tolerance, prop:circuit_idx, prop:length, prop:template, prop:locations, prop:possible_tower_types, prop:possible_underground_line_types, prop:possible_sequence_line_types)ο
- CLASS_PROPERTY_LIST: Tuple[GCProp, ...] = (prop:idtag, prop:name, prop:code, prop:rdfid, prop:action, prop:selected_to_merge, prop:comment, prop:diff_changes, prop:modelling_authority, prop:commissioned_date, prop:decommissioned_date, prop:build_status, prop:owners, prop:rms_model, prop:emt_model, prop:rms_template, prop:emt_template, prop:rms_fmu_template, prop:emt_fmu_template, prop:rms_fmu_import_config, prop:emt_fmu_import_config, prop:rms_fmu_me_import_config, prop:emt_fmu_me_import_config, prop:bus_from, prop:bus_to, prop:active, prop:reducible, prop:design_rate, prop:rate, prop:contingency_factor, prop:protection_rating_factor, prop:monitor_loading, prop:mttf, prop:mttr, prop:Cost, prop:capex, prop:opex, prop:group, prop:color, prop:bus_from_pos, prop:bus_to_pos, prop:temp_base, prop:temp_oper, prop:alpha, prop:R, prop:X, prop:B, prop:R0, prop:X0, prop:B0, prop:R2, prop:X2, prop:B2, prop:ys, prop:ysh, prop:tolerance, prop:circuit_idx, prop:length, prop:template, prop:locations, prop:possible_tower_types, prop:possible_underground_line_types, prop:possible_sequence_line_types)ο
- CLASS_REGISTERED_PROPERTIES: Dict[str, GCProp] = {'B': prop:B, 'B0': prop:B0, 'B2': prop:B2, 'Cost': prop:Cost, 'R': prop:R, 'R0': prop:R0, 'R2': prop:R2, 'X': prop:X, 'X0': prop:X0, 'X2': prop:X2, 'action': prop:action, 'active': prop:active, 'alpha': prop:alpha, 'build_status': prop:build_status, 'bus_from': prop:bus_from, 'bus_from_pos': prop:bus_from_pos, 'bus_to': prop:bus_to, 'bus_to_pos': prop:bus_to_pos, 'capex': prop:capex, 'circuit_idx': prop:circuit_idx, 'code': prop:code, 'color': prop:color, 'comment': prop:comment, 'commissioned_date': prop:commissioned_date, 'contingency_factor': prop:contingency_factor, 'decommissioned_date': prop:decommissioned_date, 'design_rate': prop:design_rate, 'diff_changes': prop:diff_changes, 'emt_fmu_import_config': prop:emt_fmu_import_config, 'emt_fmu_me_import_config': prop:emt_fmu_me_import_config, 'emt_fmu_template': prop:emt_fmu_template, 'emt_model': prop:emt_model, 'emt_template': prop:emt_template, 'group': prop:group, 'idtag': prop:idtag, 'length': prop:length, 'locations': prop:locations, 'modelling_authority': prop:modelling_authority, 'monitor_loading': prop:monitor_loading, 'mttf': prop:mttf, 'mttr': prop:mttr, 'name': prop:name, 'opex': prop:opex, 'owners': prop:owners, 'possible_sequence_line_types': prop:possible_sequence_line_types, 'possible_tower_types': prop:possible_tower_types, 'possible_underground_line_types': prop:possible_underground_line_types, 'protection_rating_factor': prop:protection_rating_factor, 'rate': prop:rate, 'rdfid': prop:rdfid, 'reducible': prop:reducible, 'rms_fmu_import_config': prop:rms_fmu_import_config, 'rms_fmu_me_import_config': prop:rms_fmu_me_import_config, 'rms_fmu_template': prop:rms_fmu_template, 'rms_model': prop:rms_model, 'rms_template': prop:rms_template, 'selected_to_merge': prop:selected_to_merge, 'temp_base': prop:temp_base, 'temp_oper': prop:temp_oper, 'template': prop:template, 'tolerance': prop:tolerance, 'ys': prop:ys, 'ysh': prop:ysh}ο
- LOCAL_PROPERTY_DECLARATIONS: Tuple[GCProp, ...] = (prop:R, prop:X, prop:B, prop:R0, prop:X0, prop:B0, prop:R2, prop:X2, prop:B2, prop:ys, prop:ysh, prop:tolerance, prop:circuit_idx, prop:length, prop:template, prop:locations, prop:possible_tower_types, prop:possible_underground_line_types, prop:possible_sequence_line_types)ο
- Pfο
- Ptο
- Qfο
- Qtο
- property Rο
- property R0ο
- property R2ο
- property R_correctedο
Returns a temperature corrected resistance based on a formula provided by: NFPA 70-2005, National Electrical Code, Table 8, footnote #2; and https://en.wikipedia.org/wiki/Electrical_resistivity_and_conductivity#Linear_approximation (version of 2019-01-03 at 15:20 EST).
- Vafο
- Vatο
- Vmfο
- Vmtο
- property Xο
- property X0ο
- property X2ο
- alphaο
- apply_template(obj: OverheadLineType | UndergroundLineType | SequenceLineType, Sbase: float, freq: float, logger=<VeraGridEngine.basic_structures.Logger object>, decimals_rounding: int = 6)[source]ο
Apply a line template to this object :param obj: OverheadLineType, UndergroundLineType, SequenceLineType :param Sbase: Nominal power in MVA :param freq: Frequency in Hz :param logger: Logger :param decimals_rounding: Number of decimals to round to
- change_base(Sbase_old: float, Sbase_new: float)[source]ο
Change the impedance base :param Sbase_old: old base (MVA) :param Sbase_new: new base (MVA)
- property circuit_idxο
- Returns:
- property fault_pos: floatο
Get
fault_pos.- Returns:
float
- fill_design_properties(r_ohm: float, x_ohm: float, c_nf: float, length: float, Imax: float, freq: float, Sbase: float, apply_to_profile: bool = True, logger: Logger = <VeraGridEngine.basic_structures.Logger object>) Line[source]ο
Fill R, X, B from not-in-per-unit parameters :param r_ohm: Resistance per km in OHM/km :param x_ohm: Reactance per km in OHM/km :param c_nf: Capacitance per km in nF/km :param length: length in kn :param Imax: Maximum current in kA :param freq: System frequency in Hz :param Sbase: Base power in MVA (take always 100 MVA) :param apply_to_profile: modify the ratings profile if checked :param logger: Logger :return self pointer
- fix_inconsistencies(logger: Logger) bool[source]ο
Fix the inconsistencies :param logger: :return: any error
- get_equivalent_transformer(index: DatetimeIndex | None = None) Transformer2W[source]ο
Convert this line into a transformer This is necessary if the busesβ voltage differ too much :return: Transformer2W
- get_line_type() SequenceLineType[source]ο
Get the equivalent sequence line type of this line :return: SequenceLineType
- get_tau(w: float) float[source]ο
get EMT delay parameter (tau) in seconds :param w: 2 * pi * freq :return: tau value
- get_weight() float[source]ο
Get a weight of this line for graph purposes the weight is the impedance module (sqrt(r^2 + x^2)) :return: weight value
- property length: floatο
Line length in km :return: float
- property locations: LineLocationsο
Cost profile :return: Profile
- possible_sequence_line_types: Associationsο
- possible_tower_types: Associationsο
- possible_underground_line_types: Associationsο
- property r_fault: floatο
Get
r_fault.- Returns:
float
- set_circuit_idx(val: int, obj: OverheadLineType | UndergroundLineType | SequenceLineType)[source]ο
Set the circuit_idx with additional behavior based on the is_user_action flag. Ensure that the template exists and is valid. :param val: The value to set :param obj: Template
- set_length(val: float)[source]ο
Set the line length and change the electric parameters of the line as a consequence. :param val: value in km
- temp_baseο
- temp_operο
- template: OverheadLineType | SequenceLineType | UndergroundLineType | Noneο
- property tolerance: floatο
Get
tolerance.- Returns:
float
- property x_fault: floatο
Get
x_fault.- Returns:
float
- property ys: AdmittanceMatrixο
- Returns:
- property ysh: AdmittanceMatrixο
- Returns:
- VeraGridEngine.Devices.Branches.line.accept_line_connection(V1: float, V2: float, branch_connection_voltage_tolerance=0.1) float[source]ο
This function checks if a line can be connected between 2 voltages :param V1: Voltage 1 :param V2: Voltage 2 :param branch_connection_voltage_tolerance: :return: Can be connected?
VeraGridEngine.Devices.Branches.line_locations moduleο
- class VeraGridEngine.Devices.Branches.line_locations.LineLocation(lat: float, lon: float, z: float, seq: int = 0, name: str = '', idtag: str | None = None, code: str = '')[source]ο
Bases:
EditableDeviceLine location object
- CLASS_NON_EDITABLE_PROPERTIES: Tuple[str, ...] = ('idtag', 'selected_to_merge', 'diff_changes')ο
- CLASS_PROPERTIES_WITH_PROFILE: Dict[str, str] = {}ο
- CLASS_PROPERTY_DECLARATIONS: Tuple[GCProp, ...] = (prop:idtag, prop:name, prop:code, prop:rdfid, prop:action, prop:selected_to_merge, prop:comment, prop:diff_changes)ο
- CLASS_PROPERTY_LIST: Tuple[GCProp, ...] = (prop:idtag, prop:name, prop:code, prop:rdfid, prop:action, prop:selected_to_merge, prop:comment, prop:diff_changes)ο
- CLASS_REGISTERED_PROPERTIES: Dict[str, GCProp] = {'action': prop:action, 'code': prop:code, 'comment': prop:comment, 'diff_changes': prop:diff_changes, 'idtag': prop:idtag, 'name': prop:name, 'rdfid': prop:rdfid, 'selected_to_merge': prop:selected_to_merge}ο
- action: ActionTypeο
- comment: strο
- device_type: DeviceTypeο
- diff_changesο
- selected_to_mergeο
- class VeraGridEngine.Devices.Branches.line_locations.LineLocations[source]ο
Bases:
EditableDevice- CLASS_NON_EDITABLE_PROPERTIES: Tuple[str, ...] = ('idtag', 'selected_to_merge', 'diff_changes')ο
- CLASS_PROPERTIES_WITH_PROFILE: Dict[str, str] = {}ο
- CLASS_PROPERTY_DECLARATIONS: Tuple[GCProp, ...] = (prop:idtag, prop:name, prop:code, prop:rdfid, prop:action, prop:selected_to_merge, prop:comment, prop:diff_changes)ο
- CLASS_PROPERTY_LIST: Tuple[GCProp, ...] = (prop:idtag, prop:name, prop:code, prop:rdfid, prop:action, prop:selected_to_merge, prop:comment, prop:diff_changes)ο
- CLASS_REGISTERED_PROPERTIES: Dict[str, GCProp] = {'action': prop:action, 'code': prop:code, 'comment': prop:comment, 'diff_changes': prop:diff_changes, 'idtag': prop:idtag, 'name': prop:name, 'rdfid': prop:rdfid, 'selected_to_merge': prop:selected_to_merge}ο
- add(sequence: int, latitude: float, longitude: float, altitude: float = 0.0, idtag: str = '')[source]ο
Append row to this object (very slow) :param sequence: Sequence of the point :param latitude: Latitude (deg) :param longitude: Longitude (deg) :param altitude: Altitude (m) :param idtag: Known idtag
- add_location(lat: float, long: float, alt: float = 0.0)[source]ο
Add a location to the line :param lat: Latitude (deg) :param long: Longitude (deg) :param alt: Altitude (m)
- data: List[LineLocation]ο
- get_locations() List[LineLocation][source]ο
Get list of LineLocation
- parse(data: List[Tuple[int, float, float, float] | Tuple[int, float, float, float, str]])[source]ο
Parse Json data :param data: List of lists with (latitude, longitude, altitude)
- remove(loc: LineLocation)[source]ο
VeraGridEngine.Devices.Branches.overhead_line_type moduleο
- class VeraGridEngine.Devices.Branches.overhead_line_type.ListOfWires[source]ο
Bases:
object- append(elm: WireInTower)[source]ο
- data: List[WireInTower]ο
- class VeraGridEngine.Devices.Branches.overhead_line_type.OverheadLineType(name='Tower', idtag: str | None = None, Vnom: float = 1.0, earth_resistivity: float = 100, frequency: float = 50, capex: float = 0.0, opex: float = 0.0)[source]ο
Bases:
DynamicDevice- CLASS_NON_EDITABLE_PROPERTIES: Tuple[str, ...] = ('idtag', 'selected_to_merge', 'diff_changes', 'wires_in_tower')ο
- CLASS_PROPERTIES_WITH_PROFILE: Dict[str, str] = {}ο
- CLASS_PROPERTY_DECLARATIONS: Tuple[GCProp, ...] = (prop:idtag, prop:name, prop:code, prop:rdfid, prop:action, prop:selected_to_merge, prop:comment, prop:diff_changes, prop:modelling_authority, prop:commissioned_date, prop:decommissioned_date, prop:build_status, prop:owners, prop:rms_model, prop:emt_model, prop:rms_template, prop:emt_template, prop:rms_fmu_template, prop:emt_fmu_template, prop:rms_fmu_import_config, prop:emt_fmu_import_config, prop:rms_fmu_me_import_config, prop:emt_fmu_me_import_config, prop:earth_resistivity, prop:frequency, prop:Vnom, prop:wires_in_tower, prop:capex, prop:opex)ο
- CLASS_PROPERTY_LIST: Tuple[GCProp, ...] = (prop:idtag, prop:name, prop:code, prop:rdfid, prop:action, prop:selected_to_merge, prop:comment, prop:diff_changes, prop:modelling_authority, prop:commissioned_date, prop:decommissioned_date, prop:build_status, prop:owners, prop:rms_model, prop:emt_model, prop:rms_template, prop:emt_template, prop:rms_fmu_template, prop:emt_fmu_template, prop:rms_fmu_import_config, prop:emt_fmu_import_config, prop:rms_fmu_me_import_config, prop:emt_fmu_me_import_config, prop:earth_resistivity, prop:frequency, prop:Vnom, prop:wires_in_tower, prop:capex, prop:opex)ο
- CLASS_REGISTERED_PROPERTIES: Dict[str, GCProp] = {'Vnom': prop:Vnom, 'action': prop:action, 'build_status': prop:build_status, 'capex': prop:capex, 'code': prop:code, 'comment': prop:comment, 'commissioned_date': prop:commissioned_date, 'decommissioned_date': prop:decommissioned_date, 'diff_changes': prop:diff_changes, 'earth_resistivity': prop:earth_resistivity, 'emt_fmu_import_config': prop:emt_fmu_import_config, 'emt_fmu_me_import_config': prop:emt_fmu_me_import_config, 'emt_fmu_template': prop:emt_fmu_template, 'emt_model': prop:emt_model, 'emt_template': prop:emt_template, 'frequency': prop:frequency, 'idtag': prop:idtag, 'modelling_authority': prop:modelling_authority, 'name': prop:name, 'opex': prop:opex, 'owners': prop:owners, 'rdfid': prop:rdfid, 'rms_fmu_import_config': prop:rms_fmu_import_config, 'rms_fmu_me_import_config': prop:rms_fmu_me_import_config, 'rms_fmu_template': prop:rms_fmu_template, 'rms_model': prop:rms_model, 'rms_template': prop:rms_template, 'selected_to_merge': prop:selected_to_merge, 'wires_in_tower': prop:wires_in_tower}ο
- property Imax: ndarray[tuple[Any, ...], dtype[float64]] | Noneο
Current rating of the tower in kA.
- LOCAL_PROPERTY_DECLARATIONS: Tuple[GCProp, ...] = (prop:earth_resistivity, prop:frequency, prop:Vnom, prop:wires_in_tower, prop:capex, prop:opex)ο
- property Vnom: floatο
- Returns:
- add_wire_relationship(wire: Wire, xpos: float = 0.0, ypos: float = 0.0, phase: int = 1)[source]ο
Wire in a tower :param wire: Wire instance :param xpos: x position in m :param ypos: y position in m :param phase: 0->Neutral, 1->A, 2->B, 3->C
- property capex: floatο
Get
capex.- Returns:
float
- check(logger=<VeraGridEngine.basic_structures.Logger object>)[source]ο
Check that the wires configuration make sense :return:
- compute_rating()[source]ο
Compute the sum of the wires max current in A :return: vector of max current (I) of the circuits in A
- property earth_resistivity: floatο
Get
earth_resistivity.- Returns:
float
- property frequency: floatο
Get
frequency.- Returns:
float
- get_sequence_values(circuit_idx: int, seq: int = 1)[source]ο
Get the positive sequence values R1 [Ohm], X1[Ohm] and Bsh1 [S]. :param circuit_idx: Circuit indexation (starts at 1) :param seq: Sequence number (0, 1, 2) :return: R1 [Ohm], X1[Ohm] and Bsh1 [S]
- get_values(Sbase, length, circuit_index: int = 1, round_vals: bool = False, Vnom: float | None = None)[source]ο
Get the sequence values of the template :param Sbase: Base power :param length: Length of the line :param circuit_index: index of the circuit :param round_vals: Boolean to round parameter values :param Vnom: nominal voltage for the per unit calculation (kV) :return: Line parameters and rate
- get_ys(circuit_idx: int, Sbase: float, length: float, Vnom: float) AdmittanceMatrix[source]ο
get the series admittance matrix in p.u. (total) :param circuit_idx: Circuit index (starting by 1) :param Sbase: Base power (MVA) :param length: Line length (km) :param Vnom: Nominal voltage (kV) :return: AdmittanceMatrix with series admittance in p.u.
- get_ysh(circuit_idx: int, Sbase: float, length: float, Vnom: float) AdmittanceMatrix[source]ο
get the shunt admittance matrix in p.u. (total) :param circuit_idx: Circuit index (starting by 1) :param Sbase: Base power (MVA) :param length: Line length (km) :param Vnom: Nominal voltage (kV) :return: AdmittanceMatrix with shunt admittance in p.u.
- has_sequence_data() bool[source]ο
Boolean that tells if the template has already been computed or not :return: if computed or not
- is_computed() bool[source]ο
Boolean that tells if the template has already been computed or not :return: if computed or not
- property n_circuits: intο
Get the number of circuits :return:
- property opex: floatο
Get
opex.- Returns:
float
- wires_in_tower: ListOfWiresο
- property y_0123: ndarray[tuple[Any, ...], dtype[complex128]] | Noneο
- Returns:
- property y_abc: ndarray[tuple[Any, ...], dtype[complex128]] | Noneο
- Returns:
- property y_nabc: ndarray[tuple[Any, ...], dtype[complex128]] | Noneο
- Returns:
- property y_phases_abc: ndarray[tuple[Any, ...], dtype[complex128]] | Noneο
- Returns:
- property y_phases_nabc: ndarray[tuple[Any, ...], dtype[complex128]] | Noneο
- Returns:
- property y_seq: ndarray[tuple[Any, ...], dtype[complex128]] | Noneο
- Returns:
- property z_0123: ndarray[tuple[Any, ...], dtype[complex128]] | Noneο
- Returns:
- property z_abc: ndarray[tuple[Any, ...], dtype[complex128]]ο
- Returns:
- property z_nabc: ndarray[tuple[Any, ...], dtype[complex128]] | Noneο
- Returns:
- property z_phases_abc: ndarray[tuple[Any, ...], dtype[complex128]] | Noneο
- Returns:
- property z_phases_nabc: ndarray[tuple[Any, ...], dtype[complex128]] | Noneο
- Returns:
- property z_seq: ndarray[tuple[Any, ...], dtype[complex128]] | Noneο
- Returns:
- class VeraGridEngine.Devices.Branches.overhead_line_type.WireInTower(wire: Wire, xpos: float = 0.0, ypos: float = 0.0, phase: int = 1)[source]ο
Bases:
objectWire -> Tower association
- circuit_index: intο
- device_typeο
- name: strο
- parse(data: Dict[str, str | int | float], wire_dict: dict[str, Wire])[source]ο
Parse data from json dictionary :param data: data to parse :param wire_dict: wires dictionary :return:
- property phaseο
- phase_type: strο
- set_phase(phase: int)[source]ο
Pase setter
A B C circuit_idx
7 8 9 3 β¦
- Parameters:
phase
- Returns:
None
- xpos: floatο
- ypos: floatο
- VeraGridEngine.Devices.Branches.overhead_line_type.abc_2_seq(mat)[source]ο
Convert ABC to sequence components :param mat: ABC impedances matrix (3x3, 6x6, 9x9, etcβ¦) Returns: Sequence matrix (3x3, 6x6, 9x9, etcβ¦) where the 3x3 blocks are the sequences
- VeraGridEngine.Devices.Branches.overhead_line_type.build_y_4x4(y_nxn: ndarray, circuit_idx: int) ndarray[source]ο
- Parameters:
y_nxn
circuit_idx
- Returns:
- VeraGridEngine.Devices.Branches.overhead_line_type.calc_GMR(is_tube: bool, r: float, q: float)[source]ο
Calculates geometric mean radius (GMR) of solid or tubular conductor Note that calculations assume uniform current distribution in the conductor, thus conductor stranding is not taken into account.
- Parameters:
is_tube
r β radius of the conductor [m]
q β radius of the inner tube [m] (only relevant for tubes)
- Returns:
GMR the geometric mean radius [m]
- VeraGridEngine.Devices.Branches.overhead_line_type.calc_L_int(is_tube, r, q)[source]ο
Calculates internal inductance of solid or tubular conductor Note that calculations assume uniform current distribution in the conductor, thus conductor stranding is not taken into account.
- Usage:
L_int = calc_L_int(type, r, q)
- where:
- type is βsolidβ or βtubeβ
r is the radius of the conductor [m] q is the radius of the inner tube [m]
- Returns:
L_int the internal inductance of the conductor [H/m]
- VeraGridEngine.Devices.Branches.overhead_line_type.calc_y_matrix(wires_in_tower: ListOfWires, f: float = 50)[source]ο
Impedance matrix :param wires_in_tower: ListOfWires :param f: system frequency (Hz) :return: 4 by 4 impedance matrix where the order of the phases is: N, A, B, C
- VeraGridEngine.Devices.Branches.overhead_line_type.calc_z_ii(R_int, is_tube, r_outer, r_inner, y_i, f, rho, err_tol=1e-06, use_dubanton_aprox: bool = False)[source]ο
Calculates self impedance term [Ohm/km] NOTE: No allowance has been made for skin effects :param R_int: AC conductor resistance [Ohm/km] :param is_tube: is it a tube conductor? otherwise is solid :param r_outer: radius of the conductor [m] :param r_inner: radius of the inner tube [m] :param y_i: height of conductor i above ground [m] :param f: frequency [Hz] :param rho: earth resistivity [Ohm.m] :param err_tol: error tolerance for the calculation (default = 1e-6) :param use_dubanton_aprox: Use dubantonβs approximation (default = False) :return: self impedance term of line impedance matrix [Ohm/km]
- VeraGridEngine.Devices.Branches.overhead_line_type.calc_z_ij(y_i, y_j, x_i, x_j, f, rho, err_tol=1e-06, use_dubanton_aprox: bool = False)[source]ο
Calculates mutual impedance term [Ohm/km] :param y_i: height of conductor i above ground [m] :param y_j: height of conductor j above ground [m] :param x_i: x position of the conductor i [m] :param x_j: x position of the conductor j [m] :param f: frequency [Hz] :param rho: earth resistivity [ohmΒ·m] :param err_tol: error tolerance for the calculation (default = 1e-6) :param use_dubanton_aprox: Use dubantonβs approximation (default = False) :return:self impedance term of line impedance matrix (Ohm/km)
- VeraGridEngine.Devices.Branches.overhead_line_type.calc_z_matrix(wires_in_tower: ListOfWires, f: float = 50, rho: float = 100, use_dubanton_aprox: bool = False)[source]ο
Impedance matrix :param wires_in_tower: WireInTower :param f: system frequency (Hz) :param rho: earth resistivity :param use_dubanton_aprox: Use dubantonβs approximation (default = False) :return: 4 by 4 impedance matrix where the order of the phases is: N, A, B, C
- VeraGridEngine.Devices.Branches.overhead_line_type.carsons(is_self: bool, h_i: float, h_k: float, x_ik: float, f: float, rho: float, err_tol: float = 1e-06)[source]ο
Calculates Carsonβs earth return correction factors Rp and Xp for both self and mutual terms. The number of terms evaluated in the infinite loop is based on convergence to the desired error tolerance.
- Usage:
Rp, Xp = carsons(type, h_i, h_k, x_ik, f, rho, err_tol)
- where type is βselfβ or βmutualβ
h_i is the height of conductor i above ground (m) h_k is the height of conductor k above ground (m) x_ik is the horizontal distance between conductors i and k (m) f is the frequency (Hz) rho is the earth resistivity (Ohm.m) err_tol is the error tolerance for the calculation (default = 1e-6)
- Returns:
Rp, Xp the Carson earth return correction factors (in Ohm/km)
- VeraGridEngine.Devices.Branches.overhead_line_type.create_known_abc_overhead_template(name: str, z_nabc: ndarray[tuple[Any, ...], dtype[complex128]], ysh_nabc: ndarray[tuple[Any, ...], dtype[complex128]], phases: ndarray[tuple[Any, ...], dtype[int64]], Vnom: float = 1.0, earth_resistivity: float = 100, frequency: float = 50) OverheadLineType[source]ο
- Parameters:
name
z_nabc
ysh_nabc
phases
Vnom
earth_resistivity
frequency
- Returns:
- VeraGridEngine.Devices.Branches.overhead_line_type.get_D_ij(xi, yi, xj, yj)[source]ο
Distance module between the wire i and the image of the wire j :param xi: x position of the wire i :param yi: y position of the wire i :param xj: x position of the wire j :param yj: y position of the wire j :return: Distance module between the wire i and the image of the wire j
- VeraGridEngine.Devices.Branches.overhead_line_type.get_d_ij(xi, yi, xj, yj)[source]ο
Distance module between wires :param xi: x position of the wire i :param yi: y position of the wire i :param xj: x position of the wire j :param yj: y position of the wire j :return: distance module
- VeraGridEngine.Devices.Branches.overhead_line_type.kron_reduction(mat, keep, embed)[source]ο
Perform the Kron reduction :param mat: primitive matrix :param keep: indices to keep :param embed: indices to delete / embed :return:
- VeraGridEngine.Devices.Branches.overhead_line_type.n_circuits(idx: ndarray[tuple[Any, ...], dtype[complex128]])[source]ο
- Parameters:
idx
- Returns:
- VeraGridEngine.Devices.Branches.overhead_line_type.phase2circuit(phase: int) int[source]ο
Convert a phase to a circuit number :param phase: phase index, starting at 1 to n (i.e. phase 5, would be B from circuit 2) :return: circuit number starting by 1
- VeraGridEngine.Devices.Branches.overhead_line_type.wire_bundling(phases_set: List[int], primitive: ndarray[tuple[Any, ...], dtype[float64]] | ndarray[tuple[int, int], dtype[float64]], phases_vector: ndarray[tuple[Any, ...], dtype[int64]])[source]ο
Algorithm to bundle wires per phase :param phases_set: set of phases (list with unique occurrences of each phase values, i.e. [0, 1, 2, 3]) :param primitive: Primitive matrix to reduce by bundling wires :param phases_vector: Vector that contains the phase of each wire :return: reduced primitive matrix, corresponding phases
VeraGridEngine.Devices.Branches.sequence_line_type moduleο
- class VeraGridEngine.Devices.Branches.sequence_line_type.SequenceLineType(name='SequenceLine', idtag: str | None = None, Imax: float = 1, Vnom: float = 1, R=1e-20, X=1e-20, B=1e-20, R0=1e-20, X0=1e-20, B0=1e-20, CnF=1e-20, CnF0=1e-20, use_conductance: bool = False, capex: float = 0.0, opex: float = 0.0, n_circuits: int = 1)[source]ο
Bases:
DynamicDevice- property B: floatο
Get
B.- Returns:
float
- property B0: floatο
Get
B0.- Returns:
float
- CLASS_NON_EDITABLE_PROPERTIES: Tuple[str, ...] = ('idtag', 'selected_to_merge', 'diff_changes')ο
- CLASS_PROPERTIES_WITH_PROFILE: Dict[str, str] = {}ο
- CLASS_PROPERTY_DECLARATIONS: Tuple[GCProp, ...] = (prop:idtag, prop:name, prop:code, prop:rdfid, prop:action, prop:selected_to_merge, prop:comment, prop:diff_changes, prop:modelling_authority, prop:commissioned_date, prop:decommissioned_date, prop:build_status, prop:owners, prop:rms_model, prop:emt_model, prop:rms_template, prop:emt_template, prop:rms_fmu_template, prop:emt_fmu_template, prop:rms_fmu_import_config, prop:emt_fmu_import_config, prop:rms_fmu_me_import_config, prop:emt_fmu_me_import_config, prop:Imax, prop:Vnom, prop:R, prop:X, prop:B, prop:R0, prop:X0, prop:B0, prop:Cnf, prop:Cnf0, prop:use_conductance, prop:n_circuits, prop:capex, prop:opex)ο
- CLASS_PROPERTY_LIST: Tuple[GCProp, ...] = (prop:idtag, prop:name, prop:code, prop:rdfid, prop:action, prop:selected_to_merge, prop:comment, prop:diff_changes, prop:modelling_authority, prop:commissioned_date, prop:decommissioned_date, prop:build_status, prop:owners, prop:rms_model, prop:emt_model, prop:rms_template, prop:emt_template, prop:rms_fmu_template, prop:emt_fmu_template, prop:rms_fmu_import_config, prop:emt_fmu_import_config, prop:rms_fmu_me_import_config, prop:emt_fmu_me_import_config, prop:Imax, prop:Vnom, prop:R, prop:X, prop:B, prop:R0, prop:X0, prop:B0, prop:Cnf, prop:Cnf0, prop:use_conductance, prop:n_circuits, prop:capex, prop:opex)ο
- CLASS_REGISTERED_PROPERTIES: Dict[str, GCProp] = {'B': prop:B, 'B0': prop:B0, 'Cnf': prop:Cnf, 'Cnf0': prop:Cnf0, 'Imax': prop:Imax, 'R': prop:R, 'R0': prop:R0, 'Vnom': prop:Vnom, 'X': prop:X, 'X0': prop:X0, 'action': prop:action, 'build_status': prop:build_status, 'capex': prop:capex, 'code': prop:code, 'comment': prop:comment, 'commissioned_date': prop:commissioned_date, 'decommissioned_date': prop:decommissioned_date, 'diff_changes': prop:diff_changes, 'emt_fmu_import_config': prop:emt_fmu_import_config, 'emt_fmu_me_import_config': prop:emt_fmu_me_import_config, 'emt_fmu_template': prop:emt_fmu_template, 'emt_model': prop:emt_model, 'emt_template': prop:emt_template, 'idtag': prop:idtag, 'modelling_authority': prop:modelling_authority, 'n_circuits': prop:n_circuits, 'name': prop:name, 'opex': prop:opex, 'owners': prop:owners, 'rdfid': prop:rdfid, 'rms_fmu_import_config': prop:rms_fmu_import_config, 'rms_fmu_me_import_config': prop:rms_fmu_me_import_config, 'rms_fmu_template': prop:rms_fmu_template, 'rms_model': prop:rms_model, 'rms_template': prop:rms_template, 'selected_to_merge': prop:selected_to_merge, 'use_conductance': prop:use_conductance}ο
- property Cnf: floatο
Get
Cnf.- Returns:
float
- property Cnf0: floatο
Get
Cnf0.- Returns:
float
- property Imax: floatο
Get
Imax.- Returns:
float
- LOCAL_PROPERTY_DECLARATIONS: Tuple[GCProp, ...] = (prop:Imax, prop:Vnom, prop:R, prop:X, prop:B, prop:R0, prop:X0, prop:B0, prop:Cnf, prop:Cnf0, prop:use_conductance, prop:n_circuits, prop:capex, prop:opex)ο
- property R: floatο
Get
R.- Returns:
float
- property R0: floatο
Get
R0.- Returns:
float
- property Vnom: floatο
Get
Vnom.- Returns:
float
- property X: floatο
Get
X.- Returns:
float
- property X0: floatο
Get
X0.- Returns:
float
- property capex: floatο
Get
capex.- Returns:
float
- get_values(Sbase: float, freq: float, length: float, line_Vnom: float, logger: Logger = <VeraGridEngine.basic_structures.Logger object>, decimals_rounding: int = 6)[source]ο
Get the per-unit values :param Sbase: Base power (MVA, always use 100MVA) :param freq: Frequency (Hz) :param length: length in km :param line_Vnom: Line nominal voltage :param logger: Logger instance :param decimals_rounding: Number of decimal digits to display :return: R (p.u.), x(p.u.), B(p.u.), Rate (MVA)
- get_ys_nabc() AdmittanceMatrix[source]ο
Get the series 3x3 admittance matrix :return: AdmittanceMatrix
- get_ysh_nabc() AdmittanceMatrix[source]ο
get the 3x3 shunt admittance matrix from the sequence values :return AdmittanceMatrix
- property n_circuits: intο
Get
n_circuits.- Returns:
int
- property opex: floatο
Get
opex.- Returns:
float
- property use_conductance: boolο
Get
use_conductance.- Returns:
bool
- VeraGridEngine.Devices.Branches.sequence_line_type.get_line_impedances_with_b(r_ohm: float, x_ohm: float, b_us: float, length: float, Imax: float, Sbase: float, Vnom: float, logger: Logger = <VeraGridEngine.basic_structures.Logger object>, decimals_rounding: int = 6) Tuple[float, float, float, float][source]ο
Fill R, X, B from not-in-per-unit parameters :param r_ohm: Resistance per km in OHM/km :param x_ohm: Reactance per km in OHM/km :param b_us: Susceptance per km in uS/km :param length: length in kn :param Imax: Maximum current in kA :param Sbase: Base power in MVA (take always 100 MVA) :param Vnom: nominal voltage (kV) :param logger: Logger (optional) :param decimals_rounding: number of decimals to round :return R, X, B, rate
- VeraGridEngine.Devices.Branches.sequence_line_type.get_line_impedances_with_c(r_ohm: float, x_ohm: float, c_nf: float, length: float, Imax: float, freq: float, Sbase: float, Vnom: float, logger: Logger = <VeraGridEngine.basic_structures.Logger object>, decimals_rounding: int = 6) Tuple[float, float, float, float][source]ο
Fill R, X, B from not-in-per-unit parameters :param r_ohm: Resistance per km in OHM/km :param x_ohm: Reactance per km in OHM/km :param c_nf: Capacitance per km in nF/km :param length: length in kn :param Imax: Maximum current in kA :param freq: System frequency in Hz :param Sbase: Base power in MVA (take always 100 MVA) :param Vnom: nominal voltage (kV) :param logger: logger :param decimals_rounding: Number of decimals to round to :return R, X, B, rate
VeraGridEngine.Devices.Branches.series_reactance moduleο
- class VeraGridEngine.Devices.Branches.series_reactance.SeriesReactance(bus_from: Bus = None, bus_to: Bus = None, name='SeriesReactance', idtag=None, code='', r=1e-20, x=1e-05, design_rate: float = 9999.0, rate=9999.0, active=True, tolerance=0, cost=100.0, mttf=0, mttr=0, r_fault=0.0, x_fault=0.0, fault_pos=0.5, temp_base=20, temp_oper=20, alpha=0.0033, contingency_factor=1.0, protection_rating_factor: float = 1.4, contingency_enabled=True, monitor_loading=True, r0=1e-20, x0=1e-20, r2=1e-20, x2=1e-20, capex=0, opex=0, build_status: BuildStatus = Commissioned)[source]ο
Bases:
BranchParent- CLASS_NON_EDITABLE_PROPERTIES: Tuple[str, ...] = ('idtag', 'selected_to_merge', 'diff_changes', 'bus_from', 'bus_to')ο
- CLASS_PROPERTIES_WITH_PROFILE: Dict[str, str] = {'Cost': 'Cost_prof', 'active': 'active_prof', 'contingency_factor': 'contingency_factor_prof', 'protection_rating_factor': 'protection_rating_factor_prof', 'rate': 'rate_prof', 'temp_oper': 'temp_oper_prof'}ο
- CLASS_PROPERTY_DECLARATIONS: Tuple[GCProp, ...] = (prop:idtag, prop:name, prop:code, prop:rdfid, prop:action, prop:selected_to_merge, prop:comment, prop:diff_changes, prop:modelling_authority, prop:commissioned_date, prop:decommissioned_date, prop:build_status, prop:owners, prop:rms_model, prop:emt_model, prop:rms_template, prop:emt_template, prop:rms_fmu_template, prop:emt_fmu_template, prop:rms_fmu_import_config, prop:emt_fmu_import_config, prop:rms_fmu_me_import_config, prop:emt_fmu_me_import_config, prop:bus_from, prop:bus_to, prop:active, prop:reducible, prop:design_rate, prop:rate, prop:contingency_factor, prop:protection_rating_factor, prop:monitor_loading, prop:mttf, prop:mttr, prop:Cost, prop:capex, prop:opex, prop:group, prop:color, prop:bus_from_pos, prop:bus_to_pos, prop:temp_base, prop:temp_oper, prop:alpha, prop:R, prop:X, prop:R0, prop:X0, prop:R2, prop:X2, prop:tolerance)ο
- CLASS_PROPERTY_LIST: Tuple[GCProp, ...] = (prop:idtag, prop:name, prop:code, prop:rdfid, prop:action, prop:selected_to_merge, prop:comment, prop:diff_changes, prop:modelling_authority, prop:commissioned_date, prop:decommissioned_date, prop:build_status, prop:owners, prop:rms_model, prop:emt_model, prop:rms_template, prop:emt_template, prop:rms_fmu_template, prop:emt_fmu_template, prop:rms_fmu_import_config, prop:emt_fmu_import_config, prop:rms_fmu_me_import_config, prop:emt_fmu_me_import_config, prop:bus_from, prop:bus_to, prop:active, prop:reducible, prop:design_rate, prop:rate, prop:contingency_factor, prop:protection_rating_factor, prop:monitor_loading, prop:mttf, prop:mttr, prop:Cost, prop:capex, prop:opex, prop:group, prop:color, prop:bus_from_pos, prop:bus_to_pos, prop:temp_base, prop:temp_oper, prop:alpha, prop:R, prop:X, prop:R0, prop:X0, prop:R2, prop:X2, prop:tolerance)ο
- CLASS_REGISTERED_PROPERTIES: Dict[str, GCProp] = {'Cost': prop:Cost, 'R': prop:R, 'R0': prop:R0, 'R2': prop:R2, 'X': prop:X, 'X0': prop:X0, 'X2': prop:X2, 'action': prop:action, 'active': prop:active, 'alpha': prop:alpha, 'build_status': prop:build_status, 'bus_from': prop:bus_from, 'bus_from_pos': prop:bus_from_pos, 'bus_to': prop:bus_to, 'bus_to_pos': prop:bus_to_pos, 'capex': prop:capex, 'code': prop:code, 'color': prop:color, 'comment': prop:comment, 'commissioned_date': prop:commissioned_date, 'contingency_factor': prop:contingency_factor, 'decommissioned_date': prop:decommissioned_date, 'design_rate': prop:design_rate, 'diff_changes': prop:diff_changes, 'emt_fmu_import_config': prop:emt_fmu_import_config, 'emt_fmu_me_import_config': prop:emt_fmu_me_import_config, 'emt_fmu_template': prop:emt_fmu_template, 'emt_model': prop:emt_model, 'emt_template': prop:emt_template, 'group': prop:group, 'idtag': prop:idtag, 'modelling_authority': prop:modelling_authority, 'monitor_loading': prop:monitor_loading, 'mttf': prop:mttf, 'mttr': prop:mttr, 'name': prop:name, 'opex': prop:opex, 'owners': prop:owners, 'protection_rating_factor': prop:protection_rating_factor, 'rate': prop:rate, 'rdfid': prop:rdfid, 'reducible': prop:reducible, 'rms_fmu_import_config': prop:rms_fmu_import_config, 'rms_fmu_me_import_config': prop:rms_fmu_me_import_config, 'rms_fmu_template': prop:rms_fmu_template, 'rms_model': prop:rms_model, 'rms_template': prop:rms_template, 'selected_to_merge': prop:selected_to_merge, 'temp_base': prop:temp_base, 'temp_oper': prop:temp_oper, 'tolerance': prop:tolerance}ο
- LOCAL_PROPERTY_DECLARATIONS: Tuple[GCProp, ...] = (prop:R, prop:X, prop:R0, prop:X0, prop:R2, prop:X2, prop:tolerance)ο
- property R: floatο
Get
R.- Returns:
float
- property R0: floatο
Get
R0.- Returns:
float
- property R2: floatο
Get
R2.- Returns:
float
- property R_correctedο
Returns a temperature corrected resistance based on a formula provided by: NFPA 70-2005, National Electrical Code, Table 8, footnote #2; and https://en.wikipedia.org/wiki/Electrical_resistivity_and_conductivity#Linear_approximation (version of 2019-01-03 at 15:20 EST).
- property X: floatο
Get
X.- Returns:
float
- property X0: floatο
Get
X0.- Returns:
float
- property X2: floatο
Get
X2.- Returns:
float
- change_base(Sbase_old, Sbase_new)[source]ο
Change the impedance base :param Sbase_old: old base (MVA) :param Sbase_new: new base (MVA)
- property fault_pos: floatο
Get
fault_pos.- Returns:
float
- fill_design_properties(r_ohm, x_ohm, length, Imax, Sbase)[source]ο
Fill R, X, B from not-in-per-unit parameters :param r_ohm: Resistance per km in OHM :param x_ohm: Reactance per km in OHM :param length: length in kn :param Imax: Maximum current in kA :param Sbase: Base power in MVA (take always 100 MVA)
- get_weight() float[source]ο
Get a weight of this line for graph purposes the weight is the impedance module (sqrt(r^2 + x^2)) :return: weight value
- property r_fault: floatο
Get
r_fault.- Returns:
float
- property tolerance: floatο
Get
tolerance.- Returns:
float
- property x_fault: floatο
Get
x_fault.- Returns:
float
VeraGridEngine.Devices.Branches.switch moduleο
- class VeraGridEngine.Devices.Branches.switch.Switch(bus_from: Bus = None, bus_to: Bus = None, name='Switch', idtag=None, code='', r=1e-20, x=1e-20, design_rate: float = 9999, rate=9999.0, active=True, contingency_factor=1.0, protection_rating_factor: float = 1.4, retained=False, normal_open=False, rated_current=0.0, graphic_type: SwitchGraphicType = CircuitBreaker)[source]ο
Bases:
BranchParentThe Switch class represents the connections between nodes (i.e. buses) in VeraGrid. A Switch is a devices that cuts or allows the flow.
- CLASS_NON_EDITABLE_PROPERTIES: Tuple[str, ...] = ('idtag', 'selected_to_merge', 'diff_changes', 'bus_from', 'bus_to')ο
- CLASS_PROPERTIES_WITH_PROFILE: Dict[str, str] = {'Cost': 'Cost_prof', 'active': 'active_prof', 'contingency_factor': 'contingency_factor_prof', 'protection_rating_factor': 'protection_rating_factor_prof', 'rate': 'rate_prof', 'temp_oper': 'temp_oper_prof'}ο
- CLASS_PROPERTY_DECLARATIONS: Tuple[GCProp, ...] = (prop:idtag, prop:name, prop:code, prop:rdfid, prop:action, prop:selected_to_merge, prop:comment, prop:diff_changes, prop:modelling_authority, prop:commissioned_date, prop:decommissioned_date, prop:build_status, prop:owners, prop:rms_model, prop:emt_model, prop:rms_template, prop:emt_template, prop:rms_fmu_template, prop:emt_fmu_template, prop:rms_fmu_import_config, prop:emt_fmu_import_config, prop:rms_fmu_me_import_config, prop:emt_fmu_me_import_config, prop:bus_from, prop:bus_to, prop:active, prop:reducible, prop:design_rate, prop:rate, prop:contingency_factor, prop:protection_rating_factor, prop:monitor_loading, prop:mttf, prop:mttr, prop:Cost, prop:capex, prop:opex, prop:group, prop:color, prop:bus_from_pos, prop:bus_to_pos, prop:temp_base, prop:temp_oper, prop:alpha, prop:R, prop:X, prop:retained, prop:normal_open, prop:rated_current, prop:graphic_type)ο
- CLASS_PROPERTY_LIST: Tuple[GCProp, ...] = (prop:idtag, prop:name, prop:code, prop:rdfid, prop:action, prop:selected_to_merge, prop:comment, prop:diff_changes, prop:modelling_authority, prop:commissioned_date, prop:decommissioned_date, prop:build_status, prop:owners, prop:rms_model, prop:emt_model, prop:rms_template, prop:emt_template, prop:rms_fmu_template, prop:emt_fmu_template, prop:rms_fmu_import_config, prop:emt_fmu_import_config, prop:rms_fmu_me_import_config, prop:emt_fmu_me_import_config, prop:bus_from, prop:bus_to, prop:active, prop:reducible, prop:design_rate, prop:rate, prop:contingency_factor, prop:protection_rating_factor, prop:monitor_loading, prop:mttf, prop:mttr, prop:Cost, prop:capex, prop:opex, prop:group, prop:color, prop:bus_from_pos, prop:bus_to_pos, prop:temp_base, prop:temp_oper, prop:alpha, prop:R, prop:X, prop:retained, prop:normal_open, prop:rated_current, prop:graphic_type)ο
- CLASS_REGISTERED_PROPERTIES: Dict[str, GCProp] = {'Cost': prop:Cost, 'R': prop:R, 'X': prop:X, 'action': prop:action, 'active': prop:active, 'alpha': prop:alpha, 'build_status': prop:build_status, 'bus_from': prop:bus_from, 'bus_from_pos': prop:bus_from_pos, 'bus_to': prop:bus_to, 'bus_to_pos': prop:bus_to_pos, 'capex': prop:capex, 'code': prop:code, 'color': prop:color, 'comment': prop:comment, 'commissioned_date': prop:commissioned_date, 'contingency_factor': prop:contingency_factor, 'decommissioned_date': prop:decommissioned_date, 'design_rate': prop:design_rate, 'diff_changes': prop:diff_changes, 'emt_fmu_import_config': prop:emt_fmu_import_config, 'emt_fmu_me_import_config': prop:emt_fmu_me_import_config, 'emt_fmu_template': prop:emt_fmu_template, 'emt_model': prop:emt_model, 'emt_template': prop:emt_template, 'graphic_type': prop:graphic_type, 'group': prop:group, 'idtag': prop:idtag, 'modelling_authority': prop:modelling_authority, 'monitor_loading': prop:monitor_loading, 'mttf': prop:mttf, 'mttr': prop:mttr, 'name': prop:name, 'normal_open': prop:normal_open, 'opex': prop:opex, 'owners': prop:owners, 'protection_rating_factor': prop:protection_rating_factor, 'rate': prop:rate, 'rated_current': prop:rated_current, 'rdfid': prop:rdfid, 'reducible': prop:reducible, 'retained': prop:retained, 'rms_fmu_import_config': prop:rms_fmu_import_config, 'rms_fmu_me_import_config': prop:rms_fmu_me_import_config, 'rms_fmu_template': prop:rms_fmu_template, 'rms_model': prop:rms_model, 'rms_template': prop:rms_template, 'selected_to_merge': prop:selected_to_merge, 'temp_base': prop:temp_base, 'temp_oper': prop:temp_oper}ο
- LOCAL_PROPERTY_DECLARATIONS: Tuple[GCProp, ...] = (prop:R, prop:X, prop:retained, prop:normal_open, prop:rated_current, prop:graphic_type)ο
- property R: floatο
Get
R.- Returns:
float
- property X: floatο
Get
X.- Returns:
float
- change_base(Sbase_old: float, Sbase_new: float)[source]ο
Change the impedance base :param Sbase_old: old base (MVA) :param Sbase_new: new base (MVA)
- graphic_type: SwitchGraphicTypeο
- property normal_open: boolο
Get
normal_open.- Returns:
bool
- property rated_current: floatο
Get
rated_current.- Returns:
float
- property retained: boolο
Get
retained.- Returns:
bool
VeraGridEngine.Devices.Branches.tap_changer moduleο
- class VeraGridEngine.Devices.Branches.tap_changer.TapChanger(total_positions: int = 5, neutral_position: int = 2, normal_position: int = 2, dV: float = 0.01, asymmetry_angle: float = 90.0, tc_type: TapChangerTypes = NoRegulation)[source]ο
Bases:
objectTap changer
- property asymmetry_angle: floatο
- copy() TapChanger[source]ο
- Returns:
- property dV: floatο
- get_tap_module() float[source]ο
Get the tap voltage regulation module :return: voltage regulation module
- get_tap_module2(tap_position: int | ndarray) float | ndarray[source]ο
Get the tap voltage regulation module :return: voltage regulation module (single value or array)
- get_tap_phase2(tap_position: int | ndarray) float | ndarray[source]ο
Get the tap phase in radians :return: phase in radians (single value or array)
- property impedance_correction_imag_array: ndarrayο
Get the imaginary impedance correction factors per tap position. A value of 1.0 at every position means no correction (default). :return: array of length total_positions
- init_from_cgmes(low: int, high: int, normal: int, neutral: int, stepVoltageIncrement: float, step: int, asymmetry_angle: float = 0.0, tc_type: TapChangerTypes = NoRegulation) None[source]ο
Import TapChanger object from CGMES
- Parameters:
low
high
normal
neutral
stepVoltageIncrement
step
asymmetry_angle
tc_type
- Returns:
- property neutral_position: intο
Get the neutral position :return: int
- property normal_position: intο
- parse(data: ~typing.Dict[str, str | float], logger: ~VeraGridEngine.basic_structures.Logger = <VeraGridEngine.basic_structures.Logger object>) None[source]ο
Parse the tap data :param data: dictionary representation of the tap :param logger: logger instance
- set_tap_module(tap_module: float) float[source]ο
Set the tap position closest to the tap module :param tap_module: float value of the tap module
- set_tap_phase(tap_phase: float) float[source]ο
Set the tap position closest to the tap phase :param tap_phase: float value of the tap phase
- property tap_angles_arrayο
- Returns:
- property tap_modules_arrayο
Get the tap modules array :return:
- property tap_position: intο
Get the tap position :return: int
- property tc_type: TapChangerTypesο
- property total_positions: intο
Tap changer total number of positions :return: int
VeraGridEngine.Devices.Branches.transformer moduleο
- class VeraGridEngine.Devices.Branches.transformer.Transformer2W(bus_from: Bus | None = None, bus_to: Bus | None = None, name='Branch', idtag: str | None = None, code: str = '', HV: float | None = None, LV: float | None = None, nominal_power: float = 0.001, copper_losses: float = 0.0, iron_losses: float = 0.0, no_load_current: float = 0.0, short_circuit_voltage: float = 0.0, r: float = 1e-20, x: float = 1e-05, g: float = 1e-20, b: float = 1e-20, design_rate: float = 9999.0, rate: float = 9999.0, tap_module: float = 1.0, tap_module_max: float = 1.2, tap_module_min: float = 0.5, tap_phase: float = 0.0, tap_phase_max: float = 6.28, tap_phase_min: float = -6.28, active: bool = True, reducible: bool = False, tolerance: float = 0.0, cost: float = 100.0, mttf: float = 0.0, mttr: float = 0.0, vset: float = 1.0, Pset: float = 0.0, Qset: float = 0.0, temp_base: float = 20.0, temp_oper: float = 20.0, alpha: float = 0.0033, tap_module_control_mode: TapModuleControl = Fixed, tap_phase_control_mode: TapPhaseControl = Fixed, template: TransformerType | None = None, contingency_factor: float = 1.0, protection_rating_factor: float = 1.4, contingency_enabled: bool = True, monitor_loading: bool = True, r0: float = 1e-20, x0: float = 1e-20, g0: float = 1e-20, b0: float = 1e-20, r2: float = 1e-20, x2: float = 1e-20, g2: float = 1e-20, b2: float = 1e-20, conn: WindingsConnection = GG, capex: float = 0.0, opex: float = 0.0, build_status: BuildStatus = Commissioned, tc_total_positions: int = 5, tc_neutral_position: int = 2, tc_normal_position: int = 2, tc_dV: float = 0.01, tc_asymmetry_angle=90, tc_type: TapChangerTypes = NoRegulation)[source]ο
Bases:
ControllableBranchParent- CLASS_NON_EDITABLE_PROPERTIES: Tuple[str, ...] = ('idtag', 'selected_to_merge', 'diff_changes', 'bus_from', 'bus_to', 'tap_changer', 'template')ο
- CLASS_PROPERTIES_WITH_PROFILE: Dict[str, str] = {'Cost': 'Cost_prof', 'Pset': 'Pset_prof', 'Qset': 'Qset_prof', 'active': 'active_prof', 'contingency_factor': 'contingency_factor_prof', 'protection_rating_factor': 'protection_rating_factor_prof', 'rate': 'rate_prof', 'tap_module': 'tap_module_prof', 'tap_module_control_mode': 'tap_module_control_mode_prof', 'tap_phase': 'tap_phase_prof', 'tap_phase_control_mode': 'tap_phase_control_mode_prof', 'temp_oper': 'temp_oper_prof', 'vset': 'vset_prof'}ο
- CLASS_PROPERTY_DECLARATIONS: Tuple[GCProp, ...] = (prop:idtag, prop:name, prop:code, prop:rdfid, prop:action, prop:selected_to_merge, prop:comment, prop:diff_changes, prop:modelling_authority, prop:commissioned_date, prop:decommissioned_date, prop:build_status, prop:owners, prop:rms_model, prop:emt_model, prop:rms_template, prop:emt_template, prop:rms_fmu_template, prop:emt_fmu_template, prop:rms_fmu_import_config, prop:emt_fmu_import_config, prop:rms_fmu_me_import_config, prop:emt_fmu_me_import_config, prop:bus_from, prop:bus_to, prop:active, prop:reducible, prop:design_rate, prop:rate, prop:contingency_factor, prop:protection_rating_factor, prop:monitor_loading, prop:mttf, prop:mttr, prop:Cost, prop:capex, prop:opex, prop:group, prop:color, prop:bus_from_pos, prop:bus_to_pos, prop:temp_base, prop:temp_oper, prop:alpha, prop:R, prop:X, prop:G, prop:B, prop:R0, prop:X0, prop:G0, prop:B0, prop:R2, prop:X2, prop:G2, prop:B2, prop:tolerance, prop:tap_changer, prop:tap_module, prop:tap_module_max, prop:tap_module_min, prop:tap_module_control_mode, prop:vset, prop:Qset, prop:regulation_bus, prop:tap_phase, prop:tap_phase_max, prop:tap_phase_min, prop:tap_phase_control_mode, prop:Pset, prop:HV, prop:LV, prop:Sn, prop:Pcu, prop:Pfe, prop:I0, prop:Vsc, prop:conn, prop:conn_f, prop:conn_t, prop:vector_group_number, prop:template)ο
- CLASS_PROPERTY_LIST: Tuple[GCProp, ...] = (prop:idtag, prop:name, prop:code, prop:rdfid, prop:action, prop:selected_to_merge, prop:comment, prop:diff_changes, prop:modelling_authority, prop:commissioned_date, prop:decommissioned_date, prop:build_status, prop:owners, prop:rms_model, prop:emt_model, prop:rms_template, prop:emt_template, prop:rms_fmu_template, prop:emt_fmu_template, prop:rms_fmu_import_config, prop:emt_fmu_import_config, prop:rms_fmu_me_import_config, prop:emt_fmu_me_import_config, prop:bus_from, prop:bus_to, prop:active, prop:reducible, prop:design_rate, prop:rate, prop:contingency_factor, prop:protection_rating_factor, prop:monitor_loading, prop:mttf, prop:mttr, prop:Cost, prop:capex, prop:opex, prop:group, prop:color, prop:bus_from_pos, prop:bus_to_pos, prop:temp_base, prop:temp_oper, prop:alpha, prop:R, prop:X, prop:G, prop:B, prop:R0, prop:X0, prop:G0, prop:B0, prop:R2, prop:X2, prop:G2, prop:B2, prop:tolerance, prop:tap_changer, prop:tap_module, prop:tap_module_max, prop:tap_module_min, prop:tap_module_control_mode, prop:vset, prop:Qset, prop:regulation_bus, prop:tap_phase, prop:tap_phase_max, prop:tap_phase_min, prop:tap_phase_control_mode, prop:Pset, prop:HV, prop:LV, prop:Sn, prop:Pcu, prop:Pfe, prop:I0, prop:Vsc, prop:conn, prop:conn_f, prop:conn_t, prop:vector_group_number, prop:template)ο
- CLASS_REGISTERED_PROPERTIES: Dict[str, GCProp] = {'B': prop:B, 'B0': prop:B0, 'B2': prop:B2, 'Cost': prop:Cost, 'G': prop:G, 'G0': prop:G0, 'G2': prop:G2, 'HV': prop:HV, 'I0': prop:I0, 'LV': prop:LV, 'Pcu': prop:Pcu, 'Pfe': prop:Pfe, 'Pset': prop:Pset, 'Qset': prop:Qset, 'R': prop:R, 'R0': prop:R0, 'R2': prop:R2, 'Sn': prop:Sn, 'Vsc': prop:Vsc, 'X': prop:X, 'X0': prop:X0, 'X2': prop:X2, 'action': prop:action, 'active': prop:active, 'alpha': prop:alpha, 'build_status': prop:build_status, 'bus_from': prop:bus_from, 'bus_from_pos': prop:bus_from_pos, 'bus_to': prop:bus_to, 'bus_to_pos': prop:bus_to_pos, 'capex': prop:capex, 'code': prop:code, 'color': prop:color, 'comment': prop:comment, 'commissioned_date': prop:commissioned_date, 'conn': prop:conn, 'conn_f': prop:conn_f, 'conn_t': prop:conn_t, 'contingency_factor': prop:contingency_factor, 'decommissioned_date': prop:decommissioned_date, 'design_rate': prop:design_rate, 'diff_changes': prop:diff_changes, 'emt_fmu_import_config': prop:emt_fmu_import_config, 'emt_fmu_me_import_config': prop:emt_fmu_me_import_config, 'emt_fmu_template': prop:emt_fmu_template, 'emt_model': prop:emt_model, 'emt_template': prop:emt_template, 'group': prop:group, 'idtag': prop:idtag, 'modelling_authority': prop:modelling_authority, 'monitor_loading': prop:monitor_loading, 'mttf': prop:mttf, 'mttr': prop:mttr, 'name': prop:name, 'opex': prop:opex, 'owners': prop:owners, 'protection_rating_factor': prop:protection_rating_factor, 'rate': prop:rate, 'rdfid': prop:rdfid, 'reducible': prop:reducible, 'regulation_bus': prop:regulation_bus, 'rms_fmu_import_config': prop:rms_fmu_import_config, 'rms_fmu_me_import_config': prop:rms_fmu_me_import_config, 'rms_fmu_template': prop:rms_fmu_template, 'rms_model': prop:rms_model, 'rms_template': prop:rms_template, 'selected_to_merge': prop:selected_to_merge, 'tap_changer': prop:tap_changer, 'tap_module': prop:tap_module, 'tap_module_control_mode': prop:tap_module_control_mode, 'tap_module_max': prop:tap_module_max, 'tap_module_min': prop:tap_module_min, 'tap_phase': prop:tap_phase, 'tap_phase_control_mode': prop:tap_phase_control_mode, 'tap_phase_max': prop:tap_phase_max, 'tap_phase_min': prop:tap_phase_min, 'temp_base': prop:temp_base, 'temp_oper': prop:temp_oper, 'template': prop:template, 'tolerance': prop:tolerance, 'vector_group_number': prop:vector_group_number, 'vset': prop:vset}ο
- property HV: floatο
Get
HV.- Returns:
float
- property I0: floatο
Get
I0.- Returns:
float
- LOCAL_PROPERTY_DECLARATIONS: Tuple[GCProp, ...] = (prop:HV, prop:LV, prop:Sn, prop:Pcu, prop:Pfe, prop:I0, prop:Vsc, prop:conn, prop:conn_f, prop:conn_t, prop:vector_group_number, prop:template)ο
- property LV: floatο
Get
LV.- Returns:
float
- property Pcu: floatο
Get
Pcu.- Returns:
float
- property Pfe: floatο
Get
Pfe.- Returns:
float
- property Sn: floatο
Get
Sn.- Returns:
float
- property Vsc: floatο
Get
Vsc.- Returns:
float
- apply_template(obj: TransformerType, Sbase: float, logger=<VeraGridEngine.basic_structures.Logger object>)[source]ο
Apply a branch template to this object :param obj: TransformerType or Tower object :param Sbase: circuit base power in MVA :param logger: Log list
- conn: WindingsConnectionο
- property conn_f: WindingTypeο
- property conn_t: WindingTypeο
- fill_design_properties(Pcu: float, Pfe: float, I0: float, Vsc: float, Sbase: float, round_vals: bool = False) Transformer2W[source]ο
Fill R, X, G, B from the short circuit study values :param Pcu: copper_losses (kW) :param Pfe: Iron losses (kW) :param I0: No load current in % :param Vsc: Short circuit voltage (%) :param Sbase: Base power in MVA (take always 100 MVA) :param round_vals: round the values? :return: self pointer
- fix_inconsistencies(logger: Logger, maximum_difference=0.1) bool[source]ο
Fix the inconsistencies :param logger: :param maximum_difference: proportion to be under or above (i.e. Transformer HV=41.9, bus HV=45 41.9/45 = 0.93 -> 0.9 <= 0.93 <= 1.1, so itβs ok :return: were there any errors?
- get_transformer_type(Sbase: float = 100.0) TransformerType[source]ο
Get the equivalent transformer type of this transformer :return: SequenceLineType :param Sbase: :return:
- get_vcc() float[source]ο
Get the short circuit voltage in % This is the value from the short circuit study :return: value in %
- get_virtual_taps() Tuple[float, float][source]ο
Get the branch virtual taps
The virtual taps generate when a transformer nominal winding voltage differs from the bus nominal voltage. :return: Virtual tap at the from side, tap_t (float, 1.0): Virtual tap at the to side
- property phases: ndarray[tuple[Any, ...], dtype[int64]]ο
- possible_transformer_typesο
- set_hv_and_lv(HV: float | None, LV: float | None)[source]ο
set the high and low voltage values :param HV: higher voltage value (kV) :param LV: lower voltage value (kV)
- template: TransformerType | Noneο
- transformer_admittance(vtap_f: float, vtap_t: float, logger: Logger) Tuple[ndarray[tuple[Any, ...], dtype[float64]] | ndarray[tuple[int, int], dtype[float64]], ndarray[tuple[Any, ...], dtype[float64]] | ndarray[tuple[int, int], dtype[float64]], ndarray[tuple[Any, ...], dtype[float64]] | ndarray[tuple[int, int], dtype[float64]], ndarray[tuple[Any, ...], dtype[float64]] | ndarray[tuple[int, int], dtype[float64]]][source]ο
Get the transformer 3-phase primitives :param vtap_f: virtual tap from :param vtap_t: virtual tap to :param logger: Logger :return: 3x3 matrices -> Yff, Yft, Ytf, Ytt
- property vector_group_number: intο
VeraGridEngine.Devices.Branches.transformer3w moduleο
- class VeraGridEngine.Devices.Branches.transformer3w.Transformer3W(idtag: str | None = None, code: str = '', name: str = 'Branch', bus0: Bus | None = None, bus1: Bus = None, bus2: Bus = None, bus3: Bus = None, w1_idtag: str | None = None, w2_idtag: str | None = None, w3_idtag: str | None = None, V1=10.0, V2=10.0, V3=10.0, active=True, r12=0.0, r23=0.0, r31=0.0, x12=0.0, x23=0.0, x31=0.0, rate12=0.0, rate23=0.0, rate31=0.0, x=0.0, y=0.0, build_status: BuildStatus = Commissioned)[source]ο
Bases:
DynamicDevice- CLASS_NON_EDITABLE_PROPERTIES: Tuple[str, ...] = ('idtag', 'selected_to_merge', 'diff_changes', 'bus0', 'bus1', 'bus2', 'bus3', 'winding1', 'winding2', 'winding3')ο
- CLASS_PROPERTIES_WITH_PROFILE: Dict[str, str] = {'active': 'active_prof'}ο
- CLASS_PROPERTY_DECLARATIONS: Tuple[GCProp, ...] = (prop:idtag, prop:name, prop:code, prop:rdfid, prop:action, prop:selected_to_merge, prop:comment, prop:diff_changes, prop:modelling_authority, prop:commissioned_date, prop:decommissioned_date, prop:build_status, prop:owners, prop:rms_model, prop:emt_model, prop:rms_template, prop:emt_template, prop:rms_fmu_template, prop:emt_fmu_template, prop:rms_fmu_import_config, prop:emt_fmu_import_config, prop:rms_fmu_me_import_config, prop:emt_fmu_me_import_config, prop:bus0, prop:bus1, prop:bus2, prop:bus3, prop:active, prop:winding1, prop:winding2, prop:winding3, prop:V1, prop:V2, prop:V3, prop:r12, prop:r23, prop:r31, prop:x12, prop:x23, prop:x31, prop:rate1, prop:rate2, prop:rate3, prop:Pcu12, prop:Pcu23, prop:Pcu31, prop:Vsc12, prop:Vsc23, prop:Vsc31, prop:Pfe, prop:I0, prop:x, prop:y)ο
- CLASS_PROPERTY_LIST: Tuple[GCProp, ...] = (prop:idtag, prop:name, prop:code, prop:rdfid, prop:action, prop:selected_to_merge, prop:comment, prop:diff_changes, prop:modelling_authority, prop:commissioned_date, prop:decommissioned_date, prop:build_status, prop:owners, prop:rms_model, prop:emt_model, prop:rms_template, prop:emt_template, prop:rms_fmu_template, prop:emt_fmu_template, prop:rms_fmu_import_config, prop:emt_fmu_import_config, prop:rms_fmu_me_import_config, prop:emt_fmu_me_import_config, prop:bus0, prop:bus1, prop:bus2, prop:bus3, prop:active, prop:winding1, prop:winding2, prop:winding3, prop:V1, prop:V2, prop:V3, prop:r12, prop:r23, prop:r31, prop:x12, prop:x23, prop:x31, prop:rate1, prop:rate2, prop:rate3, prop:Pcu12, prop:Pcu23, prop:Pcu31, prop:Vsc12, prop:Vsc23, prop:Vsc31, prop:Pfe, prop:I0, prop:x, prop:y)ο
- CLASS_REGISTERED_PROPERTIES: Dict[str, GCProp] = {'I0': prop:I0, 'Pcu12': prop:Pcu12, 'Pcu23': prop:Pcu23, 'Pcu31': prop:Pcu31, 'Pfe': prop:Pfe, 'V1': prop:V1, 'V2': prop:V2, 'V3': prop:V3, 'Vsc12': prop:Vsc12, 'Vsc23': prop:Vsc23, 'Vsc31': prop:Vsc31, 'action': prop:action, 'active': prop:active, 'build_status': prop:build_status, 'bus0': prop:bus0, 'bus1': prop:bus1, 'bus2': prop:bus2, 'bus3': prop:bus3, 'code': prop:code, 'comment': prop:comment, 'commissioned_date': prop:commissioned_date, 'decommissioned_date': prop:decommissioned_date, 'diff_changes': prop:diff_changes, 'emt_fmu_import_config': prop:emt_fmu_import_config, 'emt_fmu_me_import_config': prop:emt_fmu_me_import_config, 'emt_fmu_template': prop:emt_fmu_template, 'emt_model': prop:emt_model, 'emt_template': prop:emt_template, 'idtag': prop:idtag, 'modelling_authority': prop:modelling_authority, 'name': prop:name, 'owners': prop:owners, 'r12': prop:r12, 'r23': prop:r23, 'r31': prop:r31, 'rate1': prop:rate1, 'rate2': prop:rate2, 'rate3': prop:rate3, 'rdfid': prop:rdfid, 'rms_fmu_import_config': prop:rms_fmu_import_config, 'rms_fmu_me_import_config': prop:rms_fmu_me_import_config, 'rms_fmu_template': prop:rms_fmu_template, 'rms_model': prop:rms_model, 'rms_template': prop:rms_template, 'selected_to_merge': prop:selected_to_merge, 'winding1': prop:winding1, 'winding2': prop:winding2, 'winding3': prop:winding3, 'x': prop:x, 'x12': prop:x12, 'x23': prop:x23, 'x31': prop:x31, 'y': prop:y}ο
- property I0: floatο
- Returns:
- LOCAL_PROPERTY_DECLARATIONS: Tuple[GCProp, ...] = (prop:bus0, prop:bus1, prop:bus2, prop:bus3, prop:active, prop:winding1, prop:winding2, prop:winding3, prop:V1, prop:V2, prop:V3, prop:r12, prop:r23, prop:r31, prop:x12, prop:x23, prop:x31, prop:rate1, prop:rate2, prop:rate3, prop:Pcu12, prop:Pcu23, prop:Pcu31, prop:Vsc12, prop:Vsc23, prop:Vsc31, prop:Pfe, prop:I0, prop:x, prop:y)ο
- property Pcu12: floatο
- Returns:
- property Pcu23: floatο
- Returns:
- property Pcu31: floatο
- Returns:
- property Pfe: floatο
- Returns:
- property V1: floatο
Nominal voltage 1 in kV
- property V2ο
Nominal voltage 2 in kV
- property V3ο
Nominal voltage 3 in kV
- property Vsc12: floatο
- Returns:
- property Vsc23: floatο
- Returns:
- property Vsc31: floatο
- Returns:
- property active: boolο
Get
active.- Returns:
bool
- property active_prof: ProfileBoolο
Cost profile :return: Profile
- cn0ο
- compute_delta_to_star() None[source]ο
Perform the delta -> star transformation and apply it to the windings
- fill_from_design_values(V1: float, V2: float, V3: float, Sn1: float, Sn2: float, Sn3: float, Pcu12: float, Pcu23: float, Pcu31: float, Vsc12: float, Vsc23: float, Vsc31: float, Pfe: float, I0: float, Sbase: float)[source]ο
Fill winding per unit impedances from the short circuit study values :param V1: Primary voltage (kV) :param V2: Secondary voltage (kV) :param V3: Tertiary Voltage (kV) :param Sn1: Primary power (MVA) :param Sn2: Secondary power (MVA) :param Sn3: Tertiary power (MVA) :param Pcu12: Pcu 1-2(kW) :param Pcu23: Pcu 2-3(kW) :param Pcu31: Pcu 3-1(kW) :param Vsc12: Vsc 1-2(%) :param Vsc23: Vsc 2-3(%) :param Vsc31: Vsc 3-1(%) :param Pfe: Pfe(kW) :param I0: I0(%) :param Sbase: base power :return:
- fill_from_star(r1: float, r2: float, r3: float, x1: float, x2: float, x3: float) None[source]ο
Fill from Star values :param r1: resistance of branch 1 (p.u.) :param r2: resistance of branch 2 (p.u.) :param r3: resistance of branch 3 (p.u.) :param x1: reactance of branch 1 (p.u.) :param x2: reactance of branch 2 (p.u.) :param x3: reactance of branch 3 (p.u.)
- get_winding(i: int) Winding[source]ο
Get winding from an integer :param i: winding index :return: Winding at i
- property r12ο
1->2 measured resistance in p.u.
- property r23ο
2->3 measured resistance in p.u.
- property r31ο
3->1 measured resistance in p.u.
- property rate1ο
1 measured rate in MVA
- property rate2ο
2 measured rate in MVA
- property rate3ο
3->1 measured rate in MVA
- property x: floatο
Get
x.- Returns:
float
- property x12ο
1->2 measured reactance in p.u.
- property x23ο
2->3 measured reactance in p.u.
- property x31ο
3->1 measured reactance in p.u.
- property y: floatο
Get
y.- Returns:
float
- VeraGridEngine.Devices.Branches.transformer3w.delta_to_star(z12: float, z23: float, z31: float) Tuple[float, float, float][source]ο
Perform the delta->star transformation See: https://www.electronics-tutorials.ws/dccircuits/dcp_10.html :param z12: 1 to 2 delta value :param z23: 2 to 3 delta value :param z31: 3 to 1 delta value :return: 0->1, 0->2, 0->3 star values
- VeraGridEngine.Devices.Branches.transformer3w.star_to_delta(z1: float, z2: float, z3: float) Tuple[float, float, float][source]ο
Perform the star->delta transformation See: https://www.electronics-tutorials.ws/dccircuits/dcp_10.html :param z1: 0->1 impedance :param z2: 0->2 impedance :param z3: 0->3 impedance :return: z12, z23, z31 impedances
VeraGridEngine.Devices.Branches.transformerNw moduleο
- class VeraGridEngine.Devices.Branches.transformerNw.ImpedanceTriplet(i: int = 0, j: int = 0, imp: complex = 0j)[source]ο
Bases:
object- from_list(value: List[int | float]) ImpedanceTriplet[source]ο
- iο
- impο
- jο
- class VeraGridEngine.Devices.Branches.transformerNw.ImpedanceTripletList[source]ο
Bases:
object- append(imp: ImpedanceTriplet) None[source]ο
- to_list() List[ImpedanceTripletList][source]ο
- class VeraGridEngine.Devices.Branches.transformerNw.TransformerNW(idtag: str | None = None, code: str = '', name: str = 'TransformerNW', bus0: Bus | None = None, winding_count: int | None = None, buses: Sequence[Bus | None] | None = None, active: bool = True, Pfe: float = 0.0, I0: float = 0.0, x: float = 0.0, y: float = 0.0, build_status: BuildStatus = Commissioned)[source]ο
Bases:
PhysicalDeviceGeneric N-winding transformer represented as a set of windings connected to a common internal star bus.
The leakage data is stored per winding. Shared core-loss data is represented by
PfeandI0at the transformer level and mapped throughget_impedances. To avoid counting the magnetizing branch multiple times, the resulting shunt admittance is assigned to the first winding only.- CLASS_NON_EDITABLE_PROPERTIES: Tuple[str, ...] = ('idtag', 'selected_to_merge', 'diff_changes', 'bus0', 'winding_count')ο
- CLASS_PROPERTIES_WITH_PROFILE: Dict[str, str] = {'active': 'active_prof'}ο
- CLASS_PROPERTY_DECLARATIONS: Tuple[GCProp, ...] = (prop:idtag, prop:name, prop:code, prop:rdfid, prop:action, prop:selected_to_merge, prop:comment, prop:diff_changes, prop:modelling_authority, prop:commissioned_date, prop:decommissioned_date, prop:build_status, prop:owners, prop:bus0, prop:active, prop:winding_count, prop:Pfe, prop:I0, prop:x, prop:y, prop:internal_impedances)ο
- CLASS_PROPERTY_LIST: Tuple[GCProp, ...] = (prop:idtag, prop:name, prop:code, prop:rdfid, prop:action, prop:selected_to_merge, prop:comment, prop:diff_changes, prop:modelling_authority, prop:commissioned_date, prop:decommissioned_date, prop:build_status, prop:owners, prop:bus0, prop:active, prop:winding_count, prop:Pfe, prop:I0, prop:x, prop:y, prop:internal_impedances)ο
- CLASS_REGISTERED_PROPERTIES: Dict[str, GCProp] = {'I0': prop:I0, 'Pfe': prop:Pfe, 'action': prop:action, 'active': prop:active, 'build_status': prop:build_status, 'bus0': prop:bus0, 'code': prop:code, 'comment': prop:comment, 'commissioned_date': prop:commissioned_date, 'decommissioned_date': prop:decommissioned_date, 'diff_changes': prop:diff_changes, 'idtag': prop:idtag, 'internal_impedances': prop:internal_impedances, 'modelling_authority': prop:modelling_authority, 'name': prop:name, 'owners': prop:owners, 'rdfid': prop:rdfid, 'selected_to_merge': prop:selected_to_merge, 'winding_count': prop:winding_count, 'x': prop:x, 'y': prop:y}ο
- property I0: floatο
Shared no-load current in %.
- LOCAL_PROPERTY_DECLARATIONS: Tuple[GCProp, ...] = (prop:bus0, prop:active, prop:winding_count, prop:Pfe, prop:I0, prop:x, prop:y, prop:internal_impedances)ο
- property Pfe: floatο
Shared iron loss in kW.
- property active: boolο
Get
active.
- property active_prof: ProfileBoolο
Cost profile :return: Profile
- add_winding(bus: Bus | None = None, winding: Winding | None = None, w_idtag: str | None = None, nominal_voltage: float | None = None, nominal_power: float = 0.0) Winding[source]ο
Add a winding to the transformer.
- bus0ο
- cn0ο
- fill_from_design_values(Pfe: float, I0: float, Sbase: float) None[source]ο
Fill winding per-unit values from each windingβs design data and the shared transformer core-loss data.
- initialize_windings(winding_count: int | None = None, buses: Sequence[Bus | None] | None = None) None[source]ο
Initialize the transformer winding set from a winding count and optional buses.
- property internal_impedances: ImpedanceTripletListο
Internal impedances of transformer model
- recalculate_windings_from_definition(Sbase: float = 100.0) None[source]ο
Recompute the winding per-unit values from the design data stored in each winding plus the shared core-loss values stored at the transformer level.
- set_bus(i: int, bus: Bus | None) None[source]ο
Set terminal bus and keep the associated winding in sync.
- set_winding(i: int, winding: Winding, bus: Bus | None = None) None[source]ο
Replace a winding at position
i.
- set_winding_count(count: int) None[source]ο
Resize the winding list preserving existing winding objects when possible.
- property winding_count: intο
Number of windings in the transformer.
- property x: floatο
Get
x.
- property y: floatο
Get
y.
VeraGridEngine.Devices.Branches.transformer_type moduleο
- class VeraGridEngine.Devices.Branches.transformer_type.TransformerType(hv_nominal_voltage: float = 0.0, lv_nominal_voltage: float = 0.0, nominal_power: float = 0.001, copper_losses: float = 0.0, iron_losses: float = 0.0, no_load_current: float = 0.0, short_circuit_voltage: float = 0.0, gr_hv1: float = 0.5, gx_hv1: float = 0.5, total_positions: int = 5, neutral_position: int = 2, dV: float = 0.01, asymmetry_angle: float = 90.0, tc_type: TapChangerTypes = NoRegulation, name: str = 'TransformerType', idtag: None | str = None, capex: float = 0.0, opex: float = 0.0, vector_group_number: int = 0)[source]ο
Bases:
DynamicDevice- CLASS_NON_EDITABLE_PROPERTIES: Tuple[str, ...] = ('idtag', 'selected_to_merge', 'diff_changes', 'tap_module_min', 'tap_module_max', 'tap_phase_min', 'tap_phase_max')ο
- CLASS_PROPERTIES_WITH_PROFILE: Dict[str, str] = {}ο
- CLASS_PROPERTY_DECLARATIONS: Tuple[GCProp, ...] = (prop:idtag, prop:name, prop:code, prop:rdfid, prop:action, prop:selected_to_merge, prop:comment, prop:diff_changes, prop:modelling_authority, prop:commissioned_date, prop:decommissioned_date, prop:build_status, prop:owners, prop:rms_model, prop:emt_model, prop:rms_template, prop:emt_template, prop:rms_fmu_template, prop:emt_fmu_template, prop:rms_fmu_import_config, prop:emt_fmu_import_config, prop:rms_fmu_me_import_config, prop:emt_fmu_me_import_config, prop:HV, prop:LV, prop:Sn, prop:Pcu, prop:Pfe, prop:I0, prop:Vsc, prop:capex, prop:opex, prop:tc_type, prop:total_positions, prop:dV, prop:neutral_position, prop:asymmetry_angle, prop:conn_hv, prop:conn_lv, prop:vector_group_number, prop:tap_module_min, prop:tap_module_max, prop:tap_phase_min, prop:tap_phase_max)ο
- CLASS_PROPERTY_LIST: Tuple[GCProp, ...] = (prop:idtag, prop:name, prop:code, prop:rdfid, prop:action, prop:selected_to_merge, prop:comment, prop:diff_changes, prop:modelling_authority, prop:commissioned_date, prop:decommissioned_date, prop:build_status, prop:owners, prop:rms_model, prop:emt_model, prop:rms_template, prop:emt_template, prop:rms_fmu_template, prop:emt_fmu_template, prop:rms_fmu_import_config, prop:emt_fmu_import_config, prop:rms_fmu_me_import_config, prop:emt_fmu_me_import_config, prop:HV, prop:LV, prop:Sn, prop:Pcu, prop:Pfe, prop:I0, prop:Vsc, prop:capex, prop:opex, prop:tc_type, prop:total_positions, prop:dV, prop:neutral_position, prop:asymmetry_angle, prop:conn_hv, prop:conn_lv, prop:vector_group_number, prop:tap_module_min, prop:tap_module_max, prop:tap_phase_min, prop:tap_phase_max)ο
- CLASS_REGISTERED_PROPERTIES: Dict[str, GCProp] = {'HV': prop:HV, 'I0': prop:I0, 'LV': prop:LV, 'Pcu': prop:Pcu, 'Pfe': prop:Pfe, 'Sn': prop:Sn, 'Vsc': prop:Vsc, 'action': prop:action, 'asymmetry_angle': prop:asymmetry_angle, 'build_status': prop:build_status, 'capex': prop:capex, 'code': prop:code, 'comment': prop:comment, 'commissioned_date': prop:commissioned_date, 'conn_hv': prop:conn_hv, 'conn_lv': prop:conn_lv, 'dV': prop:dV, 'decommissioned_date': prop:decommissioned_date, 'diff_changes': prop:diff_changes, 'emt_fmu_import_config': prop:emt_fmu_import_config, 'emt_fmu_me_import_config': prop:emt_fmu_me_import_config, 'emt_fmu_template': prop:emt_fmu_template, 'emt_model': prop:emt_model, 'emt_template': prop:emt_template, 'idtag': prop:idtag, 'modelling_authority': prop:modelling_authority, 'name': prop:name, 'neutral_position': prop:neutral_position, 'opex': prop:opex, 'owners': prop:owners, 'rdfid': prop:rdfid, 'rms_fmu_import_config': prop:rms_fmu_import_config, 'rms_fmu_me_import_config': prop:rms_fmu_me_import_config, 'rms_fmu_template': prop:rms_fmu_template, 'rms_model': prop:rms_model, 'rms_template': prop:rms_template, 'selected_to_merge': prop:selected_to_merge, 'tap_module_max': prop:tap_module_max, 'tap_module_min': prop:tap_module_min, 'tap_phase_max': prop:tap_phase_max, 'tap_phase_min': prop:tap_phase_min, 'tc_type': prop:tc_type, 'total_positions': prop:total_positions, 'vector_group_number': prop:vector_group_number}ο
- GR_hv1ο
- GX_hv1ο
- property HV: floatο
Get
HV.- Returns:
float
- property I0: floatο
Get
I0.- Returns:
float
- LOCAL_PROPERTY_DECLARATIONS: Tuple[GCProp, ...] = (prop:HV, prop:LV, prop:Sn, prop:Pcu, prop:Pfe, prop:I0, prop:Vsc, prop:capex, prop:opex, prop:tc_type, prop:total_positions, prop:dV, prop:neutral_position, prop:asymmetry_angle, prop:conn_hv, prop:conn_lv, prop:vector_group_number, prop:tap_module_min, prop:tap_module_max, prop:tap_phase_min, prop:tap_phase_max)ο
- property LV: floatο
Get
LV.- Returns:
float
- property Pcu: floatο
Get
Pcu.- Returns:
float
- property Pfe: floatο
Get
Pfe.- Returns:
float
- property Sn: floatο
Get
Sn.- Returns:
float
- property Vsc: floatο
Get
Vsc.- Returns:
float
- property asymmetry_angle: floatο
Tap changer assymetry angle (deg) :return: float
- property capex: floatο
Get
capex.- Returns:
float
- conn_hv: WindingTypeο
- conn_lv: WindingTypeο
- property dV: floatο
Tap changer Voltage increment per step (p.u.) :return: float
- get_impedances(VH: float, VL: float, Sbase: float)[source]ο
Compute the branch parameters of a transformer from the short circuit test values. :param VH: High voltage bus nominal voltage in kV :param VL: Low voltage bus nominal voltage in kV :param Sbase: Base power in MVA (normally 100 MVA) :return: Zseries and Yshunt in system per unit
- get_tap_changer() TapChanger[source]ο
Get tap changer object :return: TapChanger
- property neutral_position: intο
Tap changer neutral position :return: int
- property opex: floatο
Get
opex.- Returns:
float
- property tap_module_max: floatο
Max tap module, computed on the fly :return: float
- property tap_module_min: floatο
Min tap module, computed on the fly :return: float
- property tap_phase_max: floatο
Maximum tap phase (calculated) :return: float
- property tap_phase_min: floatο
Min tap phase, cputed on the fly :return: float
- property tc_type: TapChangerTypesο
Get the tap changer type :return: TapChangerTypes
- property total_positions: intο
Tap changer total number of positions :return: int
- property vector_group_number: intο
Get
vector_group_number.- Returns:
int
- VeraGridEngine.Devices.Branches.transformer_type.get_impedances(VH_bus: float, VL_bus: float, Sn: float, HV: float, LV: float, Pcu: float, Pfe: float, I0: float, Vsc: float, Sbase: float, GR_hv1: float) Tuple[complex, complex][source]ο
Compute the branch parameters of a transformer from the short circuit test values. :param VH_bus: High voltage bus nominal voltage in kV :param VL_bus: Low voltage bus nominal voltage in kV :param Sn: Nominal power (MVA) :param HV: Transformer high voltage nominal voltage in kV :param LV: Transformer low voltage nominal voltage in kV :param Pcu: Copper losses, AKA resistive losses (kW) :param Pfe: Iron losses, AKA magnetic losses (kW) :param I0: No-load current (%) :param Vsc: Short-circuit voltage (%) :param Sbase: Base power in MVA (normally 100 MVA) :param GR_hv1: Share of impedance of towards the high voltage side (0 to 1) :return: Zseries and Yshunt in system per unit
- VeraGridEngine.Devices.Branches.transformer_type.reverse_transformer_short_circuit_study(R: float, X: float, G: float, B: float, rate: float, Sbase: float) Tuple[float, float, float, float, float][source]ο
Get the short circuit study values from the impedance values :param R: :param X: :param G: :param B: :param rate: :param Sbase: base power in MVA (100 MVA) :return:
VeraGridEngine.Devices.Branches.underground_line_type moduleο
- class VeraGridEngine.Devices.Branches.underground_line_type.UndergroundLineType(name: str = 'UndergroundLine', idtag: None | str = None, Imax: float = 1.0, Vnom: float = 1.0, R: float = 0.0, X: float = 0.0, B: float = 0.0, C: float = 0.0, R0: float = 0.0, X0: float = 0.0, B0: float = 0.0, C0: float = 0.0, freq: float = 50.0, capex: float = 0.0, opex: float = 0.0)[source]ο
Bases:
DynamicDevice- property B: floatο
Get
B.- Returns:
float
- property B0: floatο
Get
B0.- Returns:
float
- property C: floatο
- property C0: floatο
- CLASS_NON_EDITABLE_PROPERTIES: Tuple[str, ...] = ('idtag', 'selected_to_merge', 'diff_changes')ο
- CLASS_PROPERTIES_WITH_PROFILE: Dict[str, str] = {}ο
- CLASS_PROPERTY_DECLARATIONS: Tuple[GCProp, ...] = (prop:idtag, prop:name, prop:code, prop:rdfid, prop:action, prop:selected_to_merge, prop:comment, prop:diff_changes, prop:modelling_authority, prop:commissioned_date, prop:decommissioned_date, prop:build_status, prop:owners, prop:rms_model, prop:emt_model, prop:rms_template, prop:emt_template, prop:rms_fmu_template, prop:emt_fmu_template, prop:rms_fmu_import_config, prop:emt_fmu_import_config, prop:rms_fmu_me_import_config, prop:emt_fmu_me_import_config, prop:Imax, prop:Vnom, prop:freq, prop:R, prop:X, prop:B, prop:C, prop:R0, prop:X0, prop:B0, prop:C0, prop:n_circuits, prop:capex, prop:opex)ο
- CLASS_PROPERTY_LIST: Tuple[GCProp, ...] = (prop:idtag, prop:name, prop:code, prop:rdfid, prop:action, prop:selected_to_merge, prop:comment, prop:diff_changes, prop:modelling_authority, prop:commissioned_date, prop:decommissioned_date, prop:build_status, prop:owners, prop:rms_model, prop:emt_model, prop:rms_template, prop:emt_template, prop:rms_fmu_template, prop:emt_fmu_template, prop:rms_fmu_import_config, prop:emt_fmu_import_config, prop:rms_fmu_me_import_config, prop:emt_fmu_me_import_config, prop:Imax, prop:Vnom, prop:freq, prop:R, prop:X, prop:B, prop:C, prop:R0, prop:X0, prop:B0, prop:C0, prop:n_circuits, prop:capex, prop:opex)ο
- CLASS_REGISTERED_PROPERTIES: Dict[str, GCProp] = {'B': prop:B, 'B0': prop:B0, 'C': prop:C, 'C0': prop:C0, 'Imax': prop:Imax, 'R': prop:R, 'R0': prop:R0, 'Vnom': prop:Vnom, 'X': prop:X, 'X0': prop:X0, 'action': prop:action, 'build_status': prop:build_status, 'capex': prop:capex, 'code': prop:code, 'comment': prop:comment, 'commissioned_date': prop:commissioned_date, 'decommissioned_date': prop:decommissioned_date, 'diff_changes': prop:diff_changes, 'emt_fmu_import_config': prop:emt_fmu_import_config, 'emt_fmu_me_import_config': prop:emt_fmu_me_import_config, 'emt_fmu_template': prop:emt_fmu_template, 'emt_model': prop:emt_model, 'emt_template': prop:emt_template, 'freq': prop:freq, 'idtag': prop:idtag, 'modelling_authority': prop:modelling_authority, 'n_circuits': prop:n_circuits, 'name': prop:name, 'opex': prop:opex, 'owners': prop:owners, 'rdfid': prop:rdfid, 'rms_fmu_import_config': prop:rms_fmu_import_config, 'rms_fmu_me_import_config': prop:rms_fmu_me_import_config, 'rms_fmu_template': prop:rms_fmu_template, 'rms_model': prop:rms_model, 'rms_template': prop:rms_template, 'selected_to_merge': prop:selected_to_merge}ο
- property Imax: floatο
Get
Imax.- Returns:
float
- LOCAL_PROPERTY_DECLARATIONS: Tuple[GCProp, ...] = (prop:Imax, prop:Vnom, prop:freq, prop:R, prop:X, prop:B, prop:C, prop:R0, prop:X0, prop:B0, prop:C0, prop:n_circuits, prop:capex, prop:opex)ο
- property R: floatο
Get
R.- Returns:
float
- property R0: floatο
Get
R0.- Returns:
float
- property Vnom: floatο
Get
Vnom.- Returns:
float
- property X: floatο
Get
X.- Returns:
float
- property X0: floatο
Get
X0.- Returns:
float
- property capex: floatο
Get
capex.- Returns:
float
- property freq: floatο
- get_values(Sbase: float, length: float)[source]ο
Get the per-unit values :param Sbase: Base power (MVA, always use 100MVA) :param length: length in km :return: R (p.u.), x(p.u.), B(p.u.), Rate (MVA)
- property n_circuits: intο
Get
n_circuits.- Returns:
int
- property opex: floatο
Get
opex.- Returns:
float
VeraGridEngine.Devices.Branches.upfc moduleο
- class VeraGridEngine.Devices.Branches.upfc.UPFC(bus_from: Bus = None, bus_to: Bus = None, name='UPFC', code='', idtag=None, active=True, rs=0.0, xs=1e-05, rp=0.0, xp=0.0, vp=1.0, Pset=0.0, Qset=0.0, design_rate: float = 9999, rate=9999, mttf=0, mttr=0, cost=100, contingency_factor=1.0, protection_rating_factor: float = 1.4, contingency_enabled=True, monitor_loading=True, rs0=0.0, xs0=1e-05, rp0=0.0, xp0=0.0, rs2=0.0, xs2=1e-05, rp2=0.0, xp2=0.0, capex=0, opex=0, build_status: BuildStatus = Commissioned)[source]ο
Bases:
BranchParent- CLASS_NON_EDITABLE_PROPERTIES: Tuple[str, ...] = ('idtag', 'selected_to_merge', 'diff_changes', 'bus_from', 'bus_to')ο
- CLASS_PROPERTIES_WITH_PROFILE: Dict[str, str] = {'Cost': 'Cost_prof', 'active': 'active_prof', 'contingency_factor': 'contingency_factor_prof', 'protection_rating_factor': 'protection_rating_factor_prof', 'rate': 'rate_prof', 'temp_oper': 'temp_oper_prof'}ο
- CLASS_PROPERTY_DECLARATIONS: Tuple[GCProp, ...] = (prop:idtag, prop:name, prop:code, prop:rdfid, prop:action, prop:selected_to_merge, prop:comment, prop:diff_changes, prop:modelling_authority, prop:commissioned_date, prop:decommissioned_date, prop:build_status, prop:owners, prop:rms_model, prop:emt_model, prop:rms_template, prop:emt_template, prop:rms_fmu_template, prop:emt_fmu_template, prop:rms_fmu_import_config, prop:emt_fmu_import_config, prop:rms_fmu_me_import_config, prop:emt_fmu_me_import_config, prop:bus_from, prop:bus_to, prop:active, prop:reducible, prop:design_rate, prop:rate, prop:contingency_factor, prop:protection_rating_factor, prop:monitor_loading, prop:mttf, prop:mttr, prop:Cost, prop:capex, prop:opex, prop:group, prop:color, prop:bus_from_pos, prop:bus_to_pos, prop:temp_base, prop:temp_oper, prop:alpha, prop:R, prop:X, prop:Rsh, prop:Xsh, prop:R0, prop:X0, prop:Rsh0, prop:Xsh0, prop:R2, prop:X2, prop:Rsh2, prop:Xsh2, prop:Vsh, prop:Pfset, prop:Qfset)ο
- CLASS_PROPERTY_LIST: Tuple[GCProp, ...] = (prop:idtag, prop:name, prop:code, prop:rdfid, prop:action, prop:selected_to_merge, prop:comment, prop:diff_changes, prop:modelling_authority, prop:commissioned_date, prop:decommissioned_date, prop:build_status, prop:owners, prop:rms_model, prop:emt_model, prop:rms_template, prop:emt_template, prop:rms_fmu_template, prop:emt_fmu_template, prop:rms_fmu_import_config, prop:emt_fmu_import_config, prop:rms_fmu_me_import_config, prop:emt_fmu_me_import_config, prop:bus_from, prop:bus_to, prop:active, prop:reducible, prop:design_rate, prop:rate, prop:contingency_factor, prop:protection_rating_factor, prop:monitor_loading, prop:mttf, prop:mttr, prop:Cost, prop:capex, prop:opex, prop:group, prop:color, prop:bus_from_pos, prop:bus_to_pos, prop:temp_base, prop:temp_oper, prop:alpha, prop:R, prop:X, prop:Rsh, prop:Xsh, prop:R0, prop:X0, prop:Rsh0, prop:Xsh0, prop:R2, prop:X2, prop:Rsh2, prop:Xsh2, prop:Vsh, prop:Pfset, prop:Qfset)ο
- CLASS_REGISTERED_PROPERTIES: Dict[str, GCProp] = {'Cost': prop:Cost, 'Pfset': prop:Pfset, 'Qfset': prop:Qfset, 'R': prop:R, 'R0': prop:R0, 'R2': prop:R2, 'Rsh': prop:Rsh, 'Rsh0': prop:Rsh0, 'Rsh2': prop:Rsh2, 'Vsh': prop:Vsh, 'X': prop:X, 'X0': prop:X0, 'X2': prop:X2, 'Xsh': prop:Xsh, 'Xsh0': prop:Xsh0, 'Xsh2': prop:Xsh2, 'action': prop:action, 'active': prop:active, 'alpha': prop:alpha, 'build_status': prop:build_status, 'bus_from': prop:bus_from, 'bus_from_pos': prop:bus_from_pos, 'bus_to': prop:bus_to, 'bus_to_pos': prop:bus_to_pos, 'capex': prop:capex, 'code': prop:code, 'color': prop:color, 'comment': prop:comment, 'commissioned_date': prop:commissioned_date, 'contingency_factor': prop:contingency_factor, 'decommissioned_date': prop:decommissioned_date, 'design_rate': prop:design_rate, 'diff_changes': prop:diff_changes, 'emt_fmu_import_config': prop:emt_fmu_import_config, 'emt_fmu_me_import_config': prop:emt_fmu_me_import_config, 'emt_fmu_template': prop:emt_fmu_template, 'emt_model': prop:emt_model, 'emt_template': prop:emt_template, 'group': prop:group, 'idtag': prop:idtag, 'modelling_authority': prop:modelling_authority, 'monitor_loading': prop:monitor_loading, 'mttf': prop:mttf, 'mttr': prop:mttr, 'name': prop:name, 'opex': prop:opex, 'owners': prop:owners, 'protection_rating_factor': prop:protection_rating_factor, 'rate': prop:rate, 'rdfid': prop:rdfid, 'reducible': prop:reducible, 'rms_fmu_import_config': prop:rms_fmu_import_config, 'rms_fmu_me_import_config': prop:rms_fmu_me_import_config, 'rms_fmu_template': prop:rms_fmu_template, 'rms_model': prop:rms_model, 'rms_template': prop:rms_template, 'selected_to_merge': prop:selected_to_merge, 'temp_base': prop:temp_base, 'temp_oper': prop:temp_oper}ο
- LOCAL_PROPERTY_DECLARATIONS: Tuple[GCProp, ...] = (prop:R, prop:X, prop:Rsh, prop:Xsh, prop:R0, prop:X0, prop:Rsh0, prop:Xsh0, prop:R2, prop:X2, prop:Rsh2, prop:Xsh2, prop:Vsh, prop:Pfset, prop:Qfset)ο
- property Pfset: floatο
Get
Pfset.- Returns:
float
- property Qfset: floatο
Get
Qfset.- Returns:
float
- property R: floatο
Get
R.- Returns:
float
- property R0: floatο
Get
R0.- Returns:
float
- property R2: floatο
Get
R2.- Returns:
float
- property Rsh: floatο
Get
Rsh.- Returns:
float
- property Rsh0: floatο
Get
Rsh0.- Returns:
float
- property Rsh2: floatο
Get
Rsh2.- Returns:
float
- property Vsh: floatο
Get
Vsh.- Returns:
float
- property X: floatο
Get
X.- Returns:
float
- property X0: floatο
Get
X0.- Returns:
float
- property X2: floatο
Get
X2.- Returns:
float
- property Xsh: floatο
Get
Xsh.- Returns:
float
- property Xsh0: floatο
Get
Xsh0.- Returns:
float
- property Xsh2: floatο
Get
Xsh2.- Returns:
float
VeraGridEngine.Devices.Branches.vsc moduleο
- class VeraGridEngine.Devices.Branches.vsc.VSC(bus_from: Bus | None = None, bus_to: Bus | None = None, bus_dc_n: Bus | None = None, name='VSC', idtag: str | None = None, code='', active=True, design_rate: float = 9999.0, rate: float = 9999.0, alpha1=0.0001, alpha2=0.015, alpha3=0.2, mttf=0.0, mttr=0.0, cost=100, contingency_factor=1.0, protection_rating_factor: float = 1.4, contingency_enabled=True, monitor_loading=True, capex=0.0, opex=0.0, build_status: BuildStatus = Commissioned, control1: ConverterControlType = Q_droop, control1_dev: Bus | BRANCH_TYPES | None = None, control1_val: float = 1.0, control1_val_min: float = -9999.0, control1_val_max: float = 9999.0, control1_droop: float = 0.1, control1_droop_val: float = 1.0, control1_droop_val_min: float = 0.9, control1_droop_val_max: float = 1.1, control2: ConverterControlType = Vm_dc, control2_dev: Bus | BRANCH_TYPES | None = None, control2_val: float = 0.0, control2_val_min: float = -9999.0, control2_val_max: float = 9999.0, control2_droop: float = 0.1, control2_droop_val: float = 1.0, control2_droop_val_min: float = 0.9, control2_droop_val_max: float = 1.1, fault_control: ConverterFaultControlType = Standard, min_ac_voltage: float = 0.1, ysvs: float = 0.0, x: float = 0.0, y: float = 0.0)[source]ο
Bases:
BranchParent- CLASS_NON_EDITABLE_PROPERTIES = ('idtag', 'selected_to_merge', 'diff_changes', 'bus_from', 'bus_to', 'bus_dc_n', 'control1_dev', 'control2_dev')ο
- CLASS_PROPERTIES_WITH_PROFILE = {'Cost': 'Cost_prof', 'active': 'active_prof', 'contingency_factor': 'contingency_factor_prof', 'control1': 'control1_prof', 'control1_dev': 'control1_dev_prof', 'control1_droop_val': 'control1_droop_val_prof', 'control1_val': 'control1_val_prof', 'control1_val_droop': 'control1_val_droop_prof', 'control2': 'control2_prof', 'control2_dev': 'control2_dev_prof', 'control2_droop_val': 'control2_droop_val_prof', 'control2_val': 'control2_val_prof', 'control2_val_droop': 'control2_val_droop_prof', 'fault_control': 'fault_control_prof', 'protection_rating_factor': 'protection_rating_factor_prof', 'rate': 'rate_prof', 'temp_oper': 'temp_oper_prof'}ο
- CLASS_PROPERTY_DECLARATIONS = (prop:idtag, prop:name, prop:code, prop:rdfid, prop:action, prop:selected_to_merge, prop:comment, prop:diff_changes, prop:modelling_authority, prop:commissioned_date, prop:decommissioned_date, prop:build_status, prop:owners, prop:rms_model, prop:emt_model, prop:rms_template, prop:emt_template, prop:rms_fmu_template, prop:emt_fmu_template, prop:rms_fmu_import_config, prop:emt_fmu_import_config, prop:rms_fmu_me_import_config, prop:emt_fmu_me_import_config, prop:bus_from, prop:bus_to, prop:active, prop:reducible, prop:design_rate, prop:rate, prop:contingency_factor, prop:protection_rating_factor, prop:monitor_loading, prop:mttf, prop:mttr, prop:Cost, prop:capex, prop:opex, prop:group, prop:color, prop:bus_from_pos, prop:bus_to_pos, prop:temp_base, prop:temp_oper, prop:alpha, prop:bus_dc_n, prop:alpha1, prop:alpha2, prop:alpha3, prop:control1, prop:control1_dev, prop:control1_val, prop:control1_val_min, prop:control1_val_max, prop:control1_val_droop, prop:control1_droop_val, prop:control1_droop_val_min, prop:control1_droop_val_max, prop:control2, prop:control2_dev, prop:control2_val, prop:control2_val_min, prop:control2_val_max, prop:control2_val_droop, prop:control2_droop_val, prop:control2_droop_val_min, prop:control2_droop_val_max, prop:fault_control, prop:min_ac_voltage, prop:ysvs, prop:x, prop:y)ο
- CLASS_PROPERTY_LIST = (prop:idtag, prop:name, prop:code, prop:rdfid, prop:action, prop:selected_to_merge, prop:comment, prop:diff_changes, prop:modelling_authority, prop:commissioned_date, prop:decommissioned_date, prop:build_status, prop:owners, prop:rms_model, prop:emt_model, prop:rms_template, prop:emt_template, prop:rms_fmu_template, prop:emt_fmu_template, prop:rms_fmu_import_config, prop:emt_fmu_import_config, prop:rms_fmu_me_import_config, prop:emt_fmu_me_import_config, prop:bus_from, prop:bus_to, prop:active, prop:reducible, prop:design_rate, prop:rate, prop:contingency_factor, prop:protection_rating_factor, prop:monitor_loading, prop:mttf, prop:mttr, prop:Cost, prop:capex, prop:opex, prop:group, prop:color, prop:bus_from_pos, prop:bus_to_pos, prop:temp_base, prop:temp_oper, prop:alpha, prop:bus_dc_n, prop:alpha1, prop:alpha2, prop:alpha3, prop:control1, prop:control1_dev, prop:control1_val, prop:control1_val_min, prop:control1_val_max, prop:control1_val_droop, prop:control1_droop_val, prop:control1_droop_val_min, prop:control1_droop_val_max, prop:control2, prop:control2_dev, prop:control2_val, prop:control2_val_min, prop:control2_val_max, prop:control2_val_droop, prop:control2_droop_val, prop:control2_droop_val_min, prop:control2_droop_val_max, prop:fault_control, prop:min_ac_voltage, prop:ysvs, prop:x, prop:y)ο
- CLASS_REGISTERED_PROPERTIES = {'Cost': prop:Cost, 'action': prop:action, 'active': prop:active, 'alpha': prop:alpha, 'alpha1': prop:alpha1, 'alpha2': prop:alpha2, 'alpha3': prop:alpha3, 'build_status': prop:build_status, 'bus_dc_n': prop:bus_dc_n, 'bus_from': prop:bus_from, 'bus_from_pos': prop:bus_from_pos, 'bus_to': prop:bus_to, 'bus_to_pos': prop:bus_to_pos, 'capex': prop:capex, 'code': prop:code, 'color': prop:color, 'comment': prop:comment, 'commissioned_date': prop:commissioned_date, 'contingency_factor': prop:contingency_factor, 'control1': prop:control1, 'control1_dev': prop:control1_dev, 'control1_droop_val': prop:control1_droop_val, 'control1_droop_val_max': prop:control1_droop_val_max, 'control1_droop_val_min': prop:control1_droop_val_min, 'control1_val': prop:control1_val, 'control1_val_droop': prop:control1_val_droop, 'control1_val_max': prop:control1_val_max, 'control1_val_min': prop:control1_val_min, 'control2': prop:control2, 'control2_dev': prop:control2_dev, 'control2_droop_val': prop:control2_droop_val, 'control2_droop_val_max': prop:control2_droop_val_max, 'control2_droop_val_min': prop:control2_droop_val_min, 'control2_val': prop:control2_val, 'control2_val_droop': prop:control2_val_droop, 'control2_val_max': prop:control2_val_max, 'control2_val_min': prop:control2_val_min, 'decommissioned_date': prop:decommissioned_date, 'design_rate': prop:design_rate, 'diff_changes': prop:diff_changes, 'emt_fmu_import_config': prop:emt_fmu_import_config, 'emt_fmu_me_import_config': prop:emt_fmu_me_import_config, 'emt_fmu_template': prop:emt_fmu_template, 'emt_model': prop:emt_model, 'emt_template': prop:emt_template, 'fault_control': prop:fault_control, 'group': prop:group, 'idtag': prop:idtag, 'min_ac_voltage': prop:min_ac_voltage, 'modelling_authority': prop:modelling_authority, 'monitor_loading': prop:monitor_loading, 'mttf': prop:mttf, 'mttr': prop:mttr, 'name': prop:name, 'opex': prop:opex, 'owners': prop:owners, 'protection_rating_factor': prop:protection_rating_factor, 'rate': prop:rate, 'rdfid': prop:rdfid, 'reducible': prop:reducible, 'rms_fmu_import_config': prop:rms_fmu_import_config, 'rms_fmu_me_import_config': prop:rms_fmu_me_import_config, 'rms_fmu_template': prop:rms_fmu_template, 'rms_model': prop:rms_model, 'rms_template': prop:rms_template, 'selected_to_merge': prop:selected_to_merge, 'temp_base': prop:temp_base, 'temp_oper': prop:temp_oper, 'x': prop:x, 'y': prop:y, 'ysvs': prop:ysvs}ο
- LOCAL_PROPERTY_DECLARATIONS: Tuple[GCProp, ...] = (prop:bus_dc_n, prop:alpha1, prop:alpha2, prop:alpha3, prop:control1, prop:control1_dev, prop:control1_val, prop:control1_val_min, prop:control1_val_max, prop:control1_val_droop, prop:control1_droop_val, prop:control1_droop_val_min, prop:control1_droop_val_max, prop:control2, prop:control2_dev, prop:control2_val, prop:control2_val_min, prop:control2_val_max, prop:control2_val_droop, prop:control2_droop_val, prop:control2_droop_val_min, prop:control2_droop_val_max, prop:fault_control, prop:min_ac_voltage, prop:ysvs, prop:x, prop:y)ο
- property alpha1: floatο
Get
alpha1.- Returns:
float
- property alpha2: floatο
Get
alpha2.- Returns:
float
- property alpha3: floatο
Get
alpha3.- Returns:
float
- property control1ο
- Returns:
- property control1_devο
- Returns:
- property control1_dev_prof: ProfileDeviceο
Cost profile :return: Profile
- property control1_droop_val: floatο
Get
control1_droop_val.- Returns:
float
- property control1_droop_val_max: floatο
Get
control1_droop_val_max.- Returns:
float
- property control1_droop_val_min: floatο
Get
control1_droop_val_min.- Returns:
float
- property control1_droop_val_prof: ProfileFloatο
Cost profile :return: Profile
- property control1_prof: ProfileEnumο
Cost profile :return: Profile
- property control1_valο
- Returns:
- property control1_val_droop: floatο
Get
control1_val_droop.- Returns:
float
- property control1_val_droop_prof: ProfileFloatο
Cost profile :return: Profile
- property control1_val_max: floatο
Get
control1_val_max.- Returns:
float
- property control1_val_min: floatο
Get
control1_val_min.- Returns:
float
- property control1_val_prof: ProfileFloatο
Cost profile :return: Profile
- property control2ο
- Returns:
- property control2_devο
- Returns:
- property control2_dev_prof: ProfileDeviceο
Cost profile :return: Profile
- property control2_droop_val: floatο
Get
control2_droop_val.- Returns:
float
- property control2_droop_val_max: floatο
Get
control2_droop_val_max.- Returns:
float
- property control2_droop_val_min: floatο
Get
control2_droop_val_min.- Returns:
float
- property control2_droop_val_prof: ProfileFloatο
Cost profile :return: Profile
- property control2_prof: ProfileEnumο
Cost profile :return: Profile
- property control2_valο
- Returns:
- property control2_val_droop: floatο
Get
control2_val_droop.- Returns:
float
- property control2_val_droop_prof: ProfileFloatο
Cost profile :return: Profile
- property control2_val_max: floatο
Get
control2_val_max.- Returns:
float
- property control2_val_min: floatο
Get
control2_val_min.- Returns:
float
- property control2_val_prof: ProfileFloatο
Cost profile :return: Profile
- property fault_controlο
- Returns:
- property fault_control_prof: ProfileEnumο
Cost profile :return: Profile
- get_control1_at(t: int | None) ConverterControlType[source]ο
- Parameters:
t
- Returns:
- get_control1_dev_at(t: int | None) Bus | BranchParent | None[source]ο
- Parameters:
t
- Returns:
- get_control2_at(t: int | None) ConverterControlType[source]ο
- Parameters:
t
- Returns:
- get_control2_dev_at(t: int | None) Bus | BranchParent | None[source]ο
- Parameters:
t
- Returns:
- get_fault_control_at(t: int | None) ConverterControlType[source]ο
- Parameters:
t
- Returns:
- property min_ac_voltage: floatο
Get
min_ac_voltage.- Returns:
float
- plot_profiles(time_series=None, my_index=0, show_fig=True)[source]ο
Plot the time series results of this object :param time_series: TimeSeries Instance :param my_index: index of this object in the simulation :param show_fig: Show the figure?
- property x: floatο
Get
x.- Returns:
float
- property y: floatο
Get
y.- Returns:
float
- property ysvs: floatο
Get
ysvs.- Returns:
float
VeraGridEngine.Devices.Branches.winding moduleο
- class VeraGridEngine.Devices.Branches.winding.Winding(bus_from: Bus = None, bus_to: Bus = None, name='Winding', idtag: None | str = None, code: str = '', HV: None | float = None, LV: None | float = None, nominal_power: float = 0.001, copper_losses: float = 0.0, iron_losses: float = 0.0, no_load_current: float = 0.0, short_circuit_voltage: float = 0.0, r: float = 1e-20, x: float = 1e-05, g: float = 1e-20, b: float = 1e-20, design_rate: float = 9999.0, rate: float = 9999.0, tap_module: float = 1.0, tap_module_max: float = 1.2, tap_module_min: float = 0.5, tap_phase: float = 0.0, tap_phase_max: float = 6.28, tap_phase_min: float = -6.28, active: bool = True, tolerance: float = 0.0, cost: float = 100.0, mttf: float = 0.0, mttr: float = 0.0, vset: float = 1.0, Pset: float = 0.0, Qset: float = 0.0, temp_base: float = 20.0, temp_oper: float = 20.0, alpha: float = 0.0033, tap_module_control_mode: TapModuleControl = Fixed, tap_phase_control_mode: TapPhaseControl = Fixed, contingency_factor: float = 1.0, protection_rating_factor: float = 1.4, contingency_enabled: bool = True, monitor_loading: bool = True, r0: float = 1e-20, x0: float = 1e-20, g0: float = 1e-20, b0: float = 1e-20, r2: float = 1e-20, x2: float = 1e-20, g2: float = 1e-20, b2: float = 1e-20, conn: WindingsConnection = GG, capex: float = 0.0, opex: float = 0.0, build_status: BuildStatus = Commissioned)[source]ο
Bases:
Transformer2W- CLASS_NON_EDITABLE_PROPERTIES: Tuple[str, ...] = ('idtag', 'selected_to_merge', 'diff_changes', 'bus_from', 'bus_to', 'tap_changer', 'template')ο
- CLASS_PROPERTIES_WITH_PROFILE: Dict[str, str] = {'Cost': 'Cost_prof', 'Pset': 'Pset_prof', 'Qset': 'Qset_prof', 'active': 'active_prof', 'contingency_factor': 'contingency_factor_prof', 'protection_rating_factor': 'protection_rating_factor_prof', 'rate': 'rate_prof', 'tap_module': 'tap_module_prof', 'tap_module_control_mode': 'tap_module_control_mode_prof', 'tap_phase': 'tap_phase_prof', 'tap_phase_control_mode': 'tap_phase_control_mode_prof', 'temp_oper': 'temp_oper_prof', 'vset': 'vset_prof'}ο
- CLASS_PROPERTY_DECLARATIONS: Tuple[GCProp, ...] = (prop:idtag, prop:name, prop:code, prop:rdfid, prop:action, prop:selected_to_merge, prop:comment, prop:diff_changes, prop:modelling_authority, prop:commissioned_date, prop:decommissioned_date, prop:build_status, prop:owners, prop:rms_model, prop:emt_model, prop:rms_template, prop:emt_template, prop:rms_fmu_template, prop:emt_fmu_template, prop:rms_fmu_import_config, prop:emt_fmu_import_config, prop:rms_fmu_me_import_config, prop:emt_fmu_me_import_config, prop:bus_from, prop:bus_to, prop:active, prop:reducible, prop:design_rate, prop:rate, prop:contingency_factor, prop:protection_rating_factor, prop:monitor_loading, prop:mttf, prop:mttr, prop:Cost, prop:capex, prop:opex, prop:group, prop:color, prop:bus_from_pos, prop:bus_to_pos, prop:temp_base, prop:temp_oper, prop:alpha, prop:R, prop:X, prop:G, prop:B, prop:R0, prop:X0, prop:G0, prop:B0, prop:R2, prop:X2, prop:G2, prop:B2, prop:tolerance, prop:tap_changer, prop:tap_module, prop:tap_module_max, prop:tap_module_min, prop:tap_module_control_mode, prop:vset, prop:Qset, prop:regulation_bus, prop:tap_phase, prop:tap_phase_max, prop:tap_phase_min, prop:tap_phase_control_mode, prop:Pset, prop:HV, prop:LV, prop:Sn, prop:Pcu, prop:Pfe, prop:I0, prop:Vsc, prop:conn, prop:conn_f, prop:conn_t, prop:vector_group_number, prop:template)ο
- CLASS_PROPERTY_LIST: Tuple[GCProp, ...] = (prop:idtag, prop:name, prop:code, prop:rdfid, prop:action, prop:selected_to_merge, prop:comment, prop:diff_changes, prop:modelling_authority, prop:commissioned_date, prop:decommissioned_date, prop:build_status, prop:owners, prop:rms_model, prop:emt_model, prop:rms_template, prop:emt_template, prop:rms_fmu_template, prop:emt_fmu_template, prop:rms_fmu_import_config, prop:emt_fmu_import_config, prop:rms_fmu_me_import_config, prop:emt_fmu_me_import_config, prop:bus_from, prop:bus_to, prop:active, prop:reducible, prop:design_rate, prop:rate, prop:contingency_factor, prop:protection_rating_factor, prop:monitor_loading, prop:mttf, prop:mttr, prop:Cost, prop:capex, prop:opex, prop:group, prop:color, prop:bus_from_pos, prop:bus_to_pos, prop:temp_base, prop:temp_oper, prop:alpha, prop:R, prop:X, prop:G, prop:B, prop:R0, prop:X0, prop:G0, prop:B0, prop:R2, prop:X2, prop:G2, prop:B2, prop:tolerance, prop:tap_changer, prop:tap_module, prop:tap_module_max, prop:tap_module_min, prop:tap_module_control_mode, prop:vset, prop:Qset, prop:regulation_bus, prop:tap_phase, prop:tap_phase_max, prop:tap_phase_min, prop:tap_phase_control_mode, prop:Pset, prop:HV, prop:LV, prop:Sn, prop:Pcu, prop:Pfe, prop:I0, prop:Vsc, prop:conn, prop:conn_f, prop:conn_t, prop:vector_group_number, prop:template)ο
- CLASS_REGISTERED_PROPERTIES: Dict[str, GCProp] = {'B': prop:B, 'B0': prop:B0, 'B2': prop:B2, 'Cost': prop:Cost, 'G': prop:G, 'G0': prop:G0, 'G2': prop:G2, 'HV': prop:HV, 'I0': prop:I0, 'LV': prop:LV, 'Pcu': prop:Pcu, 'Pfe': prop:Pfe, 'Pset': prop:Pset, 'Qset': prop:Qset, 'R': prop:R, 'R0': prop:R0, 'R2': prop:R2, 'Sn': prop:Sn, 'Vsc': prop:Vsc, 'X': prop:X, 'X0': prop:X0, 'X2': prop:X2, 'action': prop:action, 'active': prop:active, 'alpha': prop:alpha, 'build_status': prop:build_status, 'bus_from': prop:bus_from, 'bus_from_pos': prop:bus_from_pos, 'bus_to': prop:bus_to, 'bus_to_pos': prop:bus_to_pos, 'capex': prop:capex, 'code': prop:code, 'color': prop:color, 'comment': prop:comment, 'commissioned_date': prop:commissioned_date, 'conn': prop:conn, 'conn_f': prop:conn_f, 'conn_t': prop:conn_t, 'contingency_factor': prop:contingency_factor, 'decommissioned_date': prop:decommissioned_date, 'design_rate': prop:design_rate, 'diff_changes': prop:diff_changes, 'emt_fmu_import_config': prop:emt_fmu_import_config, 'emt_fmu_me_import_config': prop:emt_fmu_me_import_config, 'emt_fmu_template': prop:emt_fmu_template, 'emt_model': prop:emt_model, 'emt_template': prop:emt_template, 'group': prop:group, 'idtag': prop:idtag, 'modelling_authority': prop:modelling_authority, 'monitor_loading': prop:monitor_loading, 'mttf': prop:mttf, 'mttr': prop:mttr, 'name': prop:name, 'opex': prop:opex, 'owners': prop:owners, 'protection_rating_factor': prop:protection_rating_factor, 'rate': prop:rate, 'rdfid': prop:rdfid, 'reducible': prop:reducible, 'regulation_bus': prop:regulation_bus, 'rms_fmu_import_config': prop:rms_fmu_import_config, 'rms_fmu_me_import_config': prop:rms_fmu_me_import_config, 'rms_fmu_template': prop:rms_fmu_template, 'rms_model': prop:rms_model, 'rms_template': prop:rms_template, 'selected_to_merge': prop:selected_to_merge, 'tap_changer': prop:tap_changer, 'tap_module': prop:tap_module, 'tap_module_control_mode': prop:tap_module_control_mode, 'tap_module_max': prop:tap_module_max, 'tap_module_min': prop:tap_module_min, 'tap_phase': prop:tap_phase, 'tap_phase_control_mode': prop:tap_phase_control_mode, 'tap_phase_max': prop:tap_phase_max, 'tap_phase_min': prop:tap_phase_min, 'temp_base': prop:temp_base, 'temp_oper': prop:temp_oper, 'template': prop:template, 'tolerance': prop:tolerance, 'vector_group_number': prop:vector_group_number, 'vset': prop:vset}ο
- conn: WindingsConnectionο
- possible_transformer_typesο
- template: TransformerType | Noneο
VeraGridEngine.Devices.Branches.wire moduleο
- class VeraGridEngine.Devices.Branches.wire.Wire(name='', idtag: str | None = None, r: float = 0.01, max_current: float = 1.0, stranding: str = '', material: str = '', diameter: float = 0.0, diameter_internal: float = 0.0, is_tube: bool = False, code: str = '')[source]ο
Bases:
EditableDeviceThis class represents a wire (an actual wire) to compose towers
- CLASS_NON_EDITABLE_PROPERTIES: Tuple[str, ...] = ('idtag', 'selected_to_merge', 'diff_changes')ο
- CLASS_PROPERTIES_WITH_PROFILE: Dict[str, str] = {}ο
- CLASS_PROPERTY_DECLARATIONS: Tuple[GCProp, ...] = (prop:idtag, prop:name, prop:code, prop:rdfid, prop:action, prop:selected_to_merge, prop:comment, prop:diff_changes, prop:R, prop:diameter, prop:diameter_internal, prop:is_tube, prop:max_current, prop:stranding, prop:material)ο
- CLASS_PROPERTY_LIST: Tuple[GCProp, ...] = (prop:idtag, prop:name, prop:code, prop:rdfid, prop:action, prop:selected_to_merge, prop:comment, prop:diff_changes, prop:R, prop:diameter, prop:diameter_internal, prop:is_tube, prop:max_current, prop:stranding, prop:material)ο
- CLASS_REGISTERED_PROPERTIES: Dict[str, GCProp] = {'R': prop:R, 'action': prop:action, 'code': prop:code, 'comment': prop:comment, 'diameter': prop:diameter, 'diameter_internal': prop:diameter_internal, 'diff_changes': prop:diff_changes, 'idtag': prop:idtag, 'is_tube': prop:is_tube, 'material': prop:material, 'max_current': prop:max_current, 'name': prop:name, 'rdfid': prop:rdfid, 'selected_to_merge': prop:selected_to_merge, 'stranding': prop:stranding}ο
- LOCAL_PROPERTY_DECLARATIONS: Tuple[GCProp, ...] = (prop:R, prop:diameter, prop:diameter_internal, prop:is_tube, prop:max_current, prop:stranding, prop:material)ο
- property R: floatο
- property diameter: floatο
- property diameter_internal: floatο
- property is_tube: boolο
- property material: strο
Material of wire :return:
- property max_current: floatο
- property stranding: strο
Stranding of wire :return: