DSS C-API and dss.hpp
DSS C-API and dss.hpp expose a customized and extended implementation of OpenDSS to C and C++.
dss::obj::CapacitorBatch Class Reference
Inheritance diagram for dss::obj::CapacitorBatch:
[legend]
Collaboration diagram for dss::obj::CapacitorBatch:
[legend]

Public Types

typedef Capacitor::Properties Properties
 
typedef Capacitor BatchElementClass
 

Public Member Functions

 CapacitorBatch (APIUtil *util)
 Create a batch of all Capacitor elements.
 
 CapacitorBatch (APIUtil *util, int32_t prop_idx, int32_t prop_value)
 Create a batch of all Capacitor elements that match an integer property value.
 
 CapacitorBatch (APIUtil *util, const char *regexp)
 Create a batch of all Capacitor elements that match a regular expression.
 
CapacitorBatchbegin_edit ()
 
CapacitorBatchend_edit (int32_t num_edits=1)
 
strings bus1 ()
 Name of first bus of 2-terminal capacitor. More...
 
CapacitorBatchbus1 (const string &value)
 
CapacitorBatchbus1 (strings &value)
 
strings bus2 ()
 Name of 2nd bus. More...
 
CapacitorBatchbus2 (const string &value)
 
CapacitorBatchbus2 (strings &value)
 
BatchInt32ArrayProxy phases ()
 Number of phases. More...
 
CapacitorBatchphases (int32_t value)
 
template<typename T >
CapacitorBatchphases (T &value)
 
template<typename T >
CapacitorBatchphases (typename T::iterator it_begin, typename T::iterator it_end)
 
std::vector< VectorXd > kvar ()
 Total kvar, if one step, or ARRAY of kvar ratings for each step. More...
 
CapacitorBatchkvar (VectorXd &value)
 
BatchFloat64ArrayProxy kv ()
 For 2, 3-phase, kV phase-phase. More...
 
CapacitorBatchkv (double value)
 
template<typename T >
CapacitorBatchkv (T &value)
 
template<typename T >
CapacitorBatchkv (typename T::iterator it_begin, typename T::iterator it_end)
 
BatchInt32ArrayProxy conn ()
 ={wye | delta |LN |LL} Default is wye, which is equivalent to LN More...
 
CapacitorBatchconn (string &value)
 
CapacitorBatchconn (int32_t value)
 
CapacitorBatchconn (Connection value)
 
CapacitorBatchconn (strings &value)
 
CapacitorBatchconn (std::vector< int32_t > &value)
 
CapacitorBatchconn (std::vector< Connection > &value)
 
strings conn_str ()
 ={wye | delta |LN |LL} Default is wye, which is equivalent to LN More...
 
CapacitorBatchconn_str (string &value)
 
CapacitorBatchconn_str (strings &value)
 
std::vector< VectorXd > cmatrix ()
 Nodal cap. More...
 
CapacitorBatchcmatrix (VectorXd &value)
 
std::vector< VectorXd > cuf ()
 ARRAY of Capacitance, each phase, for each step, microfarads. More...
 
CapacitorBatchcuf (VectorXd &value)
 
std::vector< VectorXd > R ()
 ARRAY of series resistance in each phase (line), ohms. More...
 
CapacitorBatchR (VectorXd &value)
 
std::vector< VectorXd > XL ()
 ARRAY of series inductive reactance(s) in each phase (line) for filter, ohms at base frequency. More...
 
CapacitorBatchXL (VectorXd &value)
 
std::vector< VectorXd > Harm ()
 ARRAY of harmonics to which each step is tuned. More...
 
CapacitorBatchHarm (VectorXd &value)
 
BatchInt32ArrayProxy Numsteps ()
 Number of steps in this capacitor bank. More...
 
CapacitorBatchNumsteps (int32_t value)
 
template<typename T >
CapacitorBatchNumsteps (T &value)
 
template<typename T >
CapacitorBatchNumsteps (typename T::iterator it_begin, typename T::iterator it_end)
 
std::vector< VectorXi > states ()
 ARRAY of integers {1|0} states representing the state of each step (on|off). More...
 
CapacitorBatchstates (VectorXi &value)
 
CapacitorBatchstates (std::vector< VectorXi > &value)
 
BatchFloat64ArrayProxy normamps ()
 Normal rated current. More...
 
CapacitorBatchnormamps (double value)
 
template<typename T >
CapacitorBatchnormamps (T &value)
 
template<typename T >
CapacitorBatchnormamps (typename T::iterator it_begin, typename T::iterator it_end)
 
BatchFloat64ArrayProxy emergamps ()
 Maximum or emerg current. More...
 
CapacitorBatchemergamps (double value)
 
template<typename T >
CapacitorBatchemergamps (T &value)
 
template<typename T >
CapacitorBatchemergamps (typename T::iterator it_begin, typename T::iterator it_end)
 
BatchFloat64ArrayProxy faultrate ()
 Failure rate per year. More...
 
CapacitorBatchfaultrate (double value)
 
template<typename T >
CapacitorBatchfaultrate (T &value)
 
template<typename T >
CapacitorBatchfaultrate (typename T::iterator it_begin, typename T::iterator it_end)
 
BatchFloat64ArrayProxy pctperm ()
 Percent of failures that become permanent. More...
 
CapacitorBatchpctperm (double value)
 
template<typename T >
CapacitorBatchpctperm (T &value)
 
template<typename T >
CapacitorBatchpctperm (typename T::iterator it_begin, typename T::iterator it_end)
 
BatchFloat64ArrayProxy repair ()
 Hours to repair. More...
 
CapacitorBatchrepair (double value)
 
template<typename T >
CapacitorBatchrepair (T &value)
 
template<typename T >
CapacitorBatchrepair (typename T::iterator it_begin, typename T::iterator it_end)
 
BatchFloat64ArrayProxy basefreq ()
 Base Frequency for ratings. More...
 
CapacitorBatchbasefreq (double value)
 
template<typename T >
CapacitorBatchbasefreq (T &value)
 
template<typename T >
CapacitorBatchbasefreq (typename T::iterator it_begin, typename T::iterator it_end)
 
bools enabled ()
 {Yes|No or True|False} Indicates whether this element is enabled. More...
 
CapacitorBatchenabled (bool value)
 
CapacitorBatchenabled (bools &value)
 
CapacitorBatchlike (const string &value)
 Make like another object, e.g. More...
 
CapacitorBatchlike (const char *value)
 Make like another object, e.g. More...
 
- Public Member Functions inherited from dss::obj::DSSBatch
 DSSBatch (APIUtil *util, int32_t cls_idx)
 Create a batch of all elements in the DSS class.
 
 DSSBatch (APIUtil *util, int32_t cls_idx, int32_t prop_idx, int32_t prop_value)
 Create a batch of all elements that match an integer property value.
 
 DSSBatch (APIUtil *util, int32_t cls_idx, const char *regexp)
 Create a batch of all elements that match a regular expression.
 
 DSSBatch (APIUtil *util)
 Create an uninitialized batch instance.
 
strings name ()
 

Additional Inherited Members

- Public Attributes inherited from dss::obj::DSSBatch
APIUtilapi_util
 
void ** pointer
 
int32_t count [2]
 
- Protected Member Functions inherited from dss::obj::DSSBatch
void check_for_error ()
 
bools get_batch_bool (int32_t index)
 
std::vector< complex > get_batch_complex (int32_t index)
 
template<typename T = VectorXd>
std::vector< T > get_batch_valarray (int32_t index)
 
void set_batch_complex_for_each (int32_t index, std::vector< complex > &values)
 
template<typename T >
void set_batch_val (int32_t index, const T &value)
 
template<typename T = VectorXd>
get_batch_val (int32_t index)
 
template<typename T >
void set_batch_val_for_each (int32_t index, typename T::iterator v, typename T::iterator v_end)
 
- Static Protected Member Functions inherited from dss::obj::DSSBatch
template<typename T = VectorXd>
static T get_batch_val (int32_t index, DSSBatch &batch)
 

Member Function Documentation

◆ basefreq()

BatchFloat64ArrayProxy dss::obj::CapacitorBatch::basefreq ( )
inline

Base Frequency for ratings.

DSS property name: basefreq, DSS property index: 19

◆ bus1()

strings dss::obj::CapacitorBatch::bus1 ( )
inline

Name of first bus of 2-terminal capacitor.

Examples: bus1=busname bus1=busname.1.2.3

If only one bus specified, Bus2 will default to this bus, Node 0, and the capacitor will be a Yg shunt bank.

DSS property name: bus1, DSS property index: 1

◆ bus2()

strings dss::obj::CapacitorBatch::bus2 ( )
inline

Name of 2nd bus.

Defaults to all phases connected to first bus, node 0, (Shunt Wye Connection) except when Bus2 explicitly specified.

Not necessary to specify for delta (LL) connection.

DSS property name: bus2, DSS property index: 2

◆ cmatrix()

std::vector< VectorXd > dss::obj::CapacitorBatch::cmatrix ( )
inline

Nodal cap.

matrix, lower triangle, microfarads, of the following form:

cmatrix="c11 | -c21 c22 | -c31 -c32 c33"

All steps are assumed the same if this property is used.

DSS property name: cmatrix, DSS property index: 7

◆ conn()

BatchInt32ArrayProxy dss::obj::CapacitorBatch::conn ( )
inline

={wye | delta |LN |LL} Default is wye, which is equivalent to LN

DSS property name: conn, DSS property index: 6

◆ conn_str()

strings dss::obj::CapacitorBatch::conn_str ( )
inline

={wye | delta |LN |LL} Default is wye, which is equivalent to LN

DSS property name: conn, DSS property index: 6

◆ cuf()

std::vector< VectorXd > dss::obj::CapacitorBatch::cuf ( )
inline

ARRAY of Capacitance, each phase, for each step, microfarads.

See Rules for NumSteps.

DSS property name: cuf, DSS property index: 8

◆ emergamps()

BatchFloat64ArrayProxy dss::obj::CapacitorBatch::emergamps ( )
inline

Maximum or emerg current.

DSS property name: emergamps, DSS property index: 15

◆ enabled()

bools dss::obj::CapacitorBatch::enabled ( )
inline

{Yes|No or True|False} Indicates whether this element is enabled.

DSS property name: enabled, DSS property index: 20

◆ faultrate()

BatchFloat64ArrayProxy dss::obj::CapacitorBatch::faultrate ( )
inline

Failure rate per year.

DSS property name: faultrate, DSS property index: 16

◆ Harm()

std::vector< VectorXd > dss::obj::CapacitorBatch::Harm ( )
inline

ARRAY of harmonics to which each step is tuned.

Zero is interpreted as meaning zero reactance (no filter). Default is zero.

DSS property name: Harm, DSS property index: 11

◆ kv()

BatchFloat64ArrayProxy dss::obj::CapacitorBatch::kv ( )
inline

For 2, 3-phase, kV phase-phase.

Otherwise specify actual can rating.

DSS property name: kv, DSS property index: 5

◆ kvar()

std::vector< VectorXd > dss::obj::CapacitorBatch::kvar ( )
inline

Total kvar, if one step, or ARRAY of kvar ratings for each step.

Evenly divided among phases. See rules for NUMSTEPS.

DSS property name: kvar, DSS property index: 4

◆ like() [1/2]

CapacitorBatch & dss::obj::CapacitorBatch::like ( const char *  value)
inline

Make like another object, e.g.

:

New Capacitor.C2 like=c1 ...

DSS property name: like, DSS property index: 21

◆ like() [2/2]

CapacitorBatch & dss::obj::CapacitorBatch::like ( const string &  value)
inline

Make like another object, e.g.

:

New Capacitor.C2 like=c1 ...

DSS property name: like, DSS property index: 21

◆ normamps()

BatchFloat64ArrayProxy dss::obj::CapacitorBatch::normamps ( )
inline

Normal rated current.

DSS property name: normamps, DSS property index: 14

◆ Numsteps()

BatchInt32ArrayProxy dss::obj::CapacitorBatch::Numsteps ( )
inline

Number of steps in this capacitor bank.

Default = 1. Forces reallocation of the capacitance, reactor, and states array. Rules: If this property was previously =1, the value in the kvar property is divided equally among the steps. The kvar property does not need to be reset if that is accurate. If the Cuf or Cmatrix property was used previously, all steps are set to the value of the first step. The states property is set to all steps on. All filter steps are set to the same harmonic. If this property was previously >1, the arrays are reallocated, but no values are altered. You must SUBSEQUENTLY assign all array properties.

DSS property name: Numsteps, DSS property index: 12

◆ pctperm()

BatchFloat64ArrayProxy dss::obj::CapacitorBatch::pctperm ( )
inline

Percent of failures that become permanent.

DSS property name: pctperm, DSS property index: 17

◆ phases()

BatchInt32ArrayProxy dss::obj::CapacitorBatch::phases ( )
inline

Number of phases.

DSS property name: phases, DSS property index: 3

◆ R()

std::vector< VectorXd > dss::obj::CapacitorBatch::R ( )
inline

ARRAY of series resistance in each phase (line), ohms.

Default is 0.0

DSS property name: R, DSS property index: 9

◆ repair()

BatchFloat64ArrayProxy dss::obj::CapacitorBatch::repair ( )
inline

Hours to repair.

DSS property name: repair, DSS property index: 18

◆ states()

std::vector< VectorXi > dss::obj::CapacitorBatch::states ( )
inline

ARRAY of integers {1|0} states representing the state of each step (on|off).

Defaults to 1 when reallocated (on). Capcontrol will modify this array as it turns steps on or off.

DSS property name: states, DSS property index: 13

◆ XL()

std::vector< VectorXd > dss::obj::CapacitorBatch::XL ( )
inline

ARRAY of series inductive reactance(s) in each phase (line) for filter, ohms at base frequency.

Use this OR "h" property to define filter. Default is 0.0.

DSS property name: XL, DSS property index: 10


The documentation for this class was generated from the following file: