Frequency Dependance in AC and TRAN Analysis

Jul 17, 2007 3 Replies

I am trying to model a current clamp in Spice based on a mathematical model which uses frequency dependent inductances.



I have seen various articles on using Laplace code blocks for frequency dependent expressions, but these don't seem to behave properly when in circuit for AC sweeps, and I have tried passing parameters to the inductor value but these only seem to work in AC or Transient not both.



What I am hoping to achieve is an inductor whose inductance is selected from a look up table based on the instantaneous frequency of the stimulating waveform.



I have included an example netlist below to show the solution I am trying to get working. NB I am using ICAP4 which insists on Laplace functions being denominator loaded hence the use of "1/s" rather than just "s" to extract the frequency.



V1 1 0 AC=1 L1 1 2 (v(5)) R1 2 0 1k



B1 103 0 V=v(1) A1 103 104 LAPLACEA1 .MODEL LAPLACEA1 s_xfer( in_offset=0 gain=1 num_coeff=[0 1] den_coeff=[1 0] denorm_freq=1) A2 104 105 TABLEA2 .MODEL TABLEA2 Pwl( xy_array=[>] input_domain=.01 fraction=true) R2 105 0 1 .END



When I run the above sort of circuit in AC mode it seems to calculate L at the start of the run and keep it constant. I need a model that will work in both AC and TRAN as the intention is to replicate results from a network analyser to validate the circuit model against an actual device and then perform TRAN runs to examine the time domain response under varying conditions.



...Jim Thompson

| James E.Thompson, P.E. | mens | | Analog Innovations, Inc. | et | | Analog/Mixed-Signal ASIC\'s and Discrete Systems | manus | | Phoenix, Arizona Voice:(480)460-2350 | | | E-mail Address at Website Fax:(480)460-2142 | Brass Rat | | http://www.analog-innovations.com | 1962 | America: Land of the Free, Because of the Brave

The general technique to make a controllable/variable impedance is to use a VCCS connected to itself. So, try a VCCS fed from the laplace transfer function output with the laplace input connected to the VCCS output.

Kevin Aylward ka@kevinaylward.co.uk

Shame on you Jim. Its xspice, well maybe a bit modified, the inductor line don't make sense in xspice, but the other stuff looks basically ok.

Kevin Aylward snipped-for-privacy@kevinaylward.co.uk

Join the Discussion

Have something to add? Share your thoughts — no account required.

Didn't find your answer?

Ask the community — no account required