Main Page   Class Hierarchy   Alphabetical List   Compound List   File List   Compound Members   File Members  

current_sink Class Reference

A 1-port resistor (terminator) that can be a power source. More...

#include <sources.h>

Inheritance diagram for current_sink::

nport device List of all members.

Public Methods

 current_sink ()
 Constructor. More...

int size ()
 Generators are 1-port devices. More...

const nport::data_infoget_data_info ()
void recalc ()
 The function for calculating sdata. More...

void recalc_S ()
 If the following function is implemented, it should only calculate the S matrix and B vector parts of data, leaving the C matrix part stale. More...


Public Attributes

parameter Y
 Admittance in standard units (1/Ohm). More...

parameter Temp
 Temperature in standard units. More...

parameter source_f
 Source frequency in standard units. More...

parameter source_width
 Source frequency width in standard units. More...

parameter sink_current
 Sink current in standard units. More...

parameter sink_phase
 Source phase in standard units (Radians). More...


Detailed Description

A 1-port resistor (terminator) that can be a power source.

Note that unlike generator, this device is a SINK of current; for a SOURCE, the phase must be adjusted by 180 Degrees.

For this device, the sink current is specified in sink_current and sink_phase.

The default is to create an ideal current sink, with Y = 0. Only a real admittance Y can be specified for this device; if a complex admittance is required, use an ideal sink and couple it to the circuit through a 2-port with the desired parallel admittance.

The source frequency is held in source_f, and the frequency width of the source is held in source_width.

If the global frequency differs from source_f by more than source_width/2, then the source vector sdata::B will be set to 0.

See also:
voltage_source , generator

Definition at line 224 of file sources.h.


Constructor & Destructor Documentation

current_sink::current_sink ( )
 

Constructor.

Definition at line 136 of file sources.cc.


Member Function Documentation

const nport::data_info & current_sink::get_data_info ( ) [virtual]
 

Returns:
info about the sdata of the device

Reimplemented from nport.

Definition at line 146 of file sources.cc.

void current_sink::recalc ( ) [virtual]
 

The function for calculating sdata.

recalc() should do the following:

  • (1) Read device::f, device::Z0, and, by default, device::T to get the operating conditions for the response calculation.
  • (2) Calculate the S, C, and B matrix values and store them to nport::data, with all values normalized using device::Z0.
  • (3) Store the normalizing impedance to nport::data by calling data.set_znorm().

Reimplemented from nport.

Definition at line 171 of file sources.cc.

void current_sink::recalc_S ( ) [virtual]
 

If the following function is implemented, it should only calculate the S matrix and B vector parts of data, leaving the C matrix part stale.

Reimplemented from nport.

Definition at line 153 of file sources.cc.

Referenced by recalc().

int current_sink::size ( ) [inline, virtual]
 

Generators are 1-port devices.

Returns:
the number of ports

Reimplemented from nport.

Definition at line 256 of file sources.h.


Member Data Documentation

parameter current_sink::Temp
 

Temperature in standard units.

Shadows global temperature T by default.

Definition at line 234 of file sources.h.

parameter current_sink::Y
 

Admittance in standard units (1/Ohm).

Default is 0.

Definition at line 228 of file sources.h.

parameter current_sink::sink_current
 

Sink current in standard units.

Default is 0.

Definition at line 243 of file sources.h.

parameter current_sink::sink_phase
 

Source phase in standard units (Radians).

Default is 0.

Definition at line 246 of file sources.h.

parameter current_sink::source_f
 

Source frequency in standard units.

Default is 0.

Definition at line 237 of file sources.h.

parameter current_sink::source_width
 

Source frequency width in standard units.

Default is 0.

Definition at line 240 of file sources.h.


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

Please direct comments and corrections to supermix@submm.caltech.edu
Go to the supermix home page
Generated by doxygen1.2.7