InsertFrequencySweep

Adds a frequency sweep to a Driven solution-type setup.

UI Access Right-click an analysis setup, then select Add Frequency Sweep....
Parameters
Name Type Description
<SetupName> String Name of the solution setup into which the sweep will be inserted.
<Attributes> Array Structured array.

Array("NAME:<string name of sweep>",

"IsEnabled:=", <boolean>

"RangeType:=", <"LinearStep" | "LinearCount" | "LogScale">,

<LinearStepArray>

"RangeStart:=", "<real>GHz",

"RangeEnd:=", "<real>GHz",

"RangeStep:=", "<real>GHz",

<LinearCountArray>

"RangeStart:=", "<real>GHz",

"RangeEnd:=", "<real>GHz",

"RangeCount:=", <int>,

<LogScaleArray>

RangeStart:=", "<real>GHz",

"RangeEnd:=", "<real>GHz",

"RangeCount:=", <int>,

"RangeSamples:=", <int>,

<SweepTypeArray>

"Type:=", <"Interpolating" |"Fast" | "Discrete">,

<InterpolatingParametersArray>

"SaveFields:=", <boolean>,

"SaveRadFields:=", <boolean>,

"InterpTolerance:=", <real>,

"InterpMaxSolns:=", <int>,

"InterpMinSolns:=", <int>,

"InterpMinSubranges:=", <int>,

"ExtrapToDC:=", <boolean>,

"InterpUseS:=", <boolean>,

"InterpUsePortImped:=", <boolean>,

"InterpUsePropConst:=", <boolean>,

"UseDerivativeConvergence:=", true,

"InterpDerivTolerance:=", <real>,

"UseFullBasis:=", <boolean>,

"EnforcePassivity:=", <boolean>,

"PassivityErrorTolerance:=", <real>)

"EnforceCausality:=", <boolean>,

"UseQ3DForDCSolve:=" , <boolean>,

"SMatrixOnlySolveMode:=", <"Manual">|"Auto">,

"SMatrixOnlySolveAbove:=", "<real><units>"

<FastParametersArray>

"SaveFields:=", <boolean>,

"SaveRadFields:=", <boolean>,

"GenerateFieldsForAllFreqs:=", <boolean>,

"ExtrapToDC:=", <boolean>)

<DiscreteParametersArray>

"SaveFields:=", <boolean>,

SaveRadFields:=", <boolean>,

"ExtrapToDC:=", <boolean>)

Return Value None.

 

Python Syntax InsertFrequencySweep(<SetupName>, <Attributes>)
Python Example

oModule.InsertFrequencySweep("Setup1",

[

"NAME:Sweep1",

"IsEnabled:=" , True,

"RangeType:=" , "LinearCount",

"RangeStart:=" , "2.5GHz",

"RangeEnd:=" , "7.5GHz",

"RangeCount:=" , 401,

"Type:=" , "Interpolating",

"SaveFields:=" , False,

"SaveRadFields:=" , False,

"InterpTolerance:=" , 0.5,

"InterpMaxSolns:=" , 250,

"InterpMinSolns:=" , 0,

"InterpMinSubranges:=" , 1,

"InterpUseS:=" , True,

"InterpUsePortImped:=" , False,

"InterpUsePropConst:=" , True,

"UseDerivativeConvergence:=", False,

"InterpDerivTolerance:=", 0.2,

"UseFullBasis:=" , True,

"EnforcePassivity:=" , True,

"PassivityErrorTolerance:=", 0.0001,

"SMatrixOnlySolveMode:=", "Manual",

"SMatrixOnlySolveAbove:=", "1MHz"

])

 

VB Syntax InsertFrequencySweep <SetupName>, <Attributes>
VB Example

Discrete Sweep:

oModule.InsertFrequencySweep "Setup1", Array("NAME:Sweep", "IsEnabled:=", true,
"RangeType:=", "LinearStep",
"RangeStart:=", "1GHz",
"RangeEnd:=", "10GHz",
"RangeStep:=", "0.1GHz",
"Type:=", "Discrete",
"SaveFields:=", false,
"SaveRadFields:=", false,
"ExtrapToDC:=", false)

Fast Sweep:

oModule.InsertFrequencySweep "Setup1",
Array("NAME:Sweep2", "IsEnabled:=", false,
"RangeType:=", "LinearStep",
"RangeStart:=", "1GHz",
"RangeEnd:=", "10GHz",
"RangeStep:=", "0.1GHz",
"Type:=", "Fast",
"SaveFields:=", true,
"SaveRadFields:=", false,
"GenerateFieldsForAllFreqs:=", false,
"ExtrapToDC:=", false)

Interpolating Sweep with additional setups:

oModule.InsertFrequencySweep "Setup1", Array("NAME:Sweep3", _

"IsEnabled:=", true, "SetupType:=", _

"LinearStep", "StartValue:=", "0GHz", _

"StopValue:=", "2.5GHz", "StepSize:=", "0.005GHz", _

"Type:=", "Interpolating", _

"SaveFields:=", false, _

"InterpTolerance:=", 0.5, _

"InterpMaxSolns:=", 50, "InterpMinSolns:=", 0, _

"InterpMinSubranges:=", 1, _

"ExtrapToDC:=", true, "MinSolvedFreq:=", "0.005GHz", _

"InterpUseS:=", true, _

"InterpUseT:=", false, "InterpUsePortImped:=", false, _

"InterpUsePropConst:=", true, "UseFullBasis:=", true) _

Array( "SetupType:=", "LogScale", "StartValue:=", "11GHz", "StopValue:=", _

"12GHz", "Count:=", 91, _

"SetupType:=", "LinearCount", "StartValue:=", "13GHz", _

"StopValue:=", "100GHz", "Count:=", 91)

Discrete sweeps with linear step and log scale:

oModule.InsertFrequencySweep "Setup1", Array("NAME:Sweep2", _

"IsEnabled:=", true, "SetupType:=", "LinearStep", _

"StartValue:=", "0.005GHz", >"StopValue:=", "2.5GHz", _

"StepSize:=", "0.005GHz", "Type:=", "Discrete", _

"SaveFields:=", false, "ExtrapToDC:=", false)

 

oModule.InsertFrequencySweep "Setup1", Array("NAME:Sweep3", _

"IsEnabled:=", true, "SetupType:=", "LogScale", _

"StartValue:=", "1GHz", "StopValue:=", "10GHz", _

"SamplesPerDecade:=", 4, "Type:=", "Discrete", _

"SaveFields:=", false, "ExtrapToDC:=", false)

A Fast sweep, specified using the starting and stopping frequencies and the step count:

oModule.InsertFrequencySweep "Setup1", Array("NAME:Sweep4", _

"IsEnabled:=", true, "SetupType:=", "LinearCount", _

"StartValue:=", "1GHz", "StopValue:=", "10GHz", _

"Count:=", 3, "Type:=", "Fast", _

"SaveFields:=", true, "ExtrapToDC:=", false)