Class DC
Class that implements a DC sweep analysis.
Implements
Inherited Members
Namespace: SpiceSharp.Simulations
Assembly: SpiceSharp.dll
Syntax
public class DC : BiasingSimulation, IBiasingSimulation, ISimulation<IVariable<double>>, ITemperatureSimulation, ISimulation, IParameterSetCollection, IParameterSet, IStateful<ITemperatureSimulationState>, IBehavioral<ITemperatureBehavior>, IBehavioral<IBiasingBehavior>, IBehavioral<IConvergenceBehavior>, IStateful<IBiasingSimulationState>, IStateful<TemperatureSimulationState>, IStateful<IIterationSimulationState>, IStateful, IBehavioral<IBiasingUpdateBehavior>, IBehavioral, IParameterized<BiasingParameters>, IParameterized<DCParameters>
Constructors
DC(string)
Initializes a new instance of the DC class.
Declaration
public DC(string name)
Parameters
Type | Name | Description |
---|---|---|
string | name | The name of the simulation. |
Exceptions
Type | Condition |
---|---|
ArgumentNullException | Thrown if |
DC(string, IEnumerable<ISweep>)
Initializes a new instance of the DC class.
Declaration
public DC(string name, IEnumerable<ISweep> sweeps)
Parameters
Type | Name | Description |
---|---|---|
string | name | The name of the simulation. |
IEnumerable<ISweep> | sweeps | The sweeps. |
Exceptions
Type | Condition |
---|---|
ArgumentNullException | Thrown if |
DC(string, string, double, double, double)
Initializes a new instance of the DC class.
Declaration
public DC(string name, string source, double start, double stop, double step)
Parameters
Type | Name | Description |
---|---|---|
string | name | The name of the simulation. |
string | source | The source name. |
double | start | The starting value. |
double | stop | The stop value. |
double | step | The step value. |
Exceptions
Type | Condition |
---|---|
ArgumentNullException | Thrown if |
Fields
ExportSweep
The constant returned when exporting a sweep point.
Declaration
public const int ExportSweep = 1
Field Value
Type | Description |
---|---|
int |
Properties
DCParameters
Gets the dc parameters.
Declaration
public DCParameters DCParameters { get; }
Property Value
Type | Description |
---|---|
DCParameters | The dc parameters. |
Methods
Execute(int)
Executes the simulation.
Declaration
protected override IEnumerable<int> Execute(int mask = 65535)
Parameters
Type | Name | Description |
---|---|---|
int | mask | A bit mask for simulation export identifiers. |
Returns
Type | Description |
---|---|
IEnumerable<int> |
Overrides
Exceptions
Type | Condition |
---|---|
SpiceSharpException | Thrown if the simulation can't continue. |
GetCurrentSweepValue()
Gets the current sweep values. The last element indicates the inner-most sweep value.
Declaration
public double[] GetCurrentSweepValue()
Returns
Type | Description |
---|---|
double[] | The sweep values, or |
Events
IterationFailed
Occurs when iterating to a solution has failed.
Declaration
public event EventHandler<EventArgs> IterationFailed
Event Type
Type | Description |
---|---|
EventHandler<EventArgs> |