⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 spice.txt

📁 spice中支持多层次元件模型仿真的可单独运行的插件源码
💻 TXT
📖 第 1 页 / 共 5 页
字号:
TEXT: HTEXT: H CAP = CJ (LENGTH - NARROW) (WIDTH - NARROW) + 2 CJSW (LENGTH + WIDTH - 2 NARROW)TEXT: HTEXT: HSUBJECT: InductorsTITLE: InductorsTEXT: HTEXT: H _3._1._7.  _I_n_d_u_c_t_o_r_sTEXT: HTEXT: H _G_e_n_e_r_a_l _f_o_r_m:TEXT: HTEXT: H     LYYYYYYY N+ N- VALUE <IC=INCOND>TEXT: HTEXT: HTEXT: H _E_x_a_m_p_l_e_s:TEXT: HTEXT: H     LLINK 42 69 1UHTEXT: H     LSHUNT 23 51 10U IC=15.7MATEXT: HTEXT: HTEXT: H      N+ and N- are the  positive  and  negative  elementTEXT: H nodes,  respectively.   VALUE  is the inductance in Hen-TEXT: H ries.TEXT: HTEXT: HTEXT: H      The (optional) initial condition is the initial  (time-TEXT: H zero)  value  of  inductor current (in Amps) that flows fromTEXT: H N+, through the inductor, to N-.  Note that the initial con-TEXT: H ditions  (if  any) apply only if the UIC option is specifiedTEXT: H on the .TRAN analysis line.TEXT: HTEXT: HSUBJECT: Coupled InductorsTITLE: Coupled (Mutual) InductorsTEXT: HTEXT: H _3._1._8.  _C_o_u_p_l_e_d (_M_u_t_u_a_l) _I_n_d_u_c_t_o_r_sTEXT: HTEXT: H _G_e_n_e_r_a_l _f_o_r_m:TEXT: HTEXT: H     KXXXXXXX LYYYYYYY LZZZZZZZ VALUETEXT: HTEXT: HTEXT: H _E_x_a_m_p_l_e_s:TEXT: HTEXT: H     K43 LAA LBB 0.999TEXT: H     KXFRMR L1 L2 0.87TEXT: HTEXT: HTEXT: H      LYYYYYYY and LZZZZZZZ are the names of the two cou-TEXT: H pled  inductors,  and  VALUE  is the coefficient of cou-TEXT: H pling, K, which must be greater than 0 and less than  orTEXT: H equal  to  1.  Using the 'dot' convention, place a 'dot'TEXT: H on the first node of each inductor.TEXT: HTEXT: HTEXT: HSUBJECT: SwitchesTITLE: SwitchesTEXT: HTEXT: H _3._1._9.  _S_w_i_t_c_h_e_sTEXT: HTEXT: H _G_e_n_e_r_a_l _f_o_r_m:TEXT: HTEXT: H     SXXXXXXX N+ N- NC+ NC- MODEL <ON><OFF>TEXT: H     WYYYYYYY N+ N- VNAM MODEL <ON><OFF>TEXT: HTEXT: HTEXT: H _E_x_a_m_p_l_e_s:TEXT: HTEXT: H     s1 1 2 3 4 switch1 ONTEXT: H     s2 5 6 3 0 sm2 offTEXT: H     Switch1 1 2 10 0 smodel1TEXT: H     w1 1 2 vclock switchmod1TEXT: H     W2 3 0 vramp sm1 ONTEXT: H     wreset 5 6 vclck lossyswitch OFFTEXT: HTEXT: HTEXT: H      Nodes 1 and 2  are  the  nodes  between  which  theTEXT: H switch  terminals are connected.  The model name is man-TEXT: H datory while the initial conditions are  optional.   ForTEXT: H the voltage controlled switch, nodes 3 and 4 are the po-TEXT: H sitive and negative controlling nodes respectively.  ForTEXT: H the  current  controlled switch, the controlling currentTEXT: H is that  through  the  specified  voltage  source.   TheTEXT: H direction  of  positive controlling current flow is fromTEXT: H the positive node, through the source, to  the  negativeTEXT: H node.TEXT: HTEXT: HTEXT: HSUBJECT: Switch Model TITLE: Switch Model (SW/CSW)TEXT: HTEXT: H _3._1._1_0.  _S_w_i_t_c_h _M_o_d_e_l (_S_W/_C_S_W)TEXT: HTEXT: HTEXT: H      The switch model allows an almost ideal  switch  to  beTEXT: H described  in SPICE.  The switch is not quite ideal, in thatTEXT: H the resistance can not change from 0 to infinity,  but  mustTEXT: H always have a finite positive value.  By proper selection ofTEXT: H the on and off resistances, they can be effectively zero andTEXT: H infinity  in  comparison  to  other  circuit  elements.  TheTEXT: H parameters available are:TEXT: HTEXT: H     name   parameter            units   default   switchTEXT: HTEXT: H     VT     threshold voltage    Volts   0.0       STEXT: H     IT     threshold current    Amps    0.0       WTEXT: H     VH     hysteresis voltage   Volts   0.0       STEXT: H     IH     hysteresis current   Amps    0.0       WTEXT: H     RON    on resistance        Z       1.0       bothTEXT: H     ROFF   off resistance       Z       1/GMIN*   bothTEXT: HTEXT: HTEXT: HTEXT: HTEXT: H      *(See the .OPTIONS control line for  a  description  ofTEXT: H GMIN,  its  default  value  results  in an off-resistance ofTEXT: H 1.0e+12 ohms.)TEXT: HTEXT: HTEXT: H      The use of an ideal element that  is  highly  nonlinearTEXT: H such as a switch can cause large discontinuities to occur inTEXT: H the circuit node voltages.  A  rapid  change  such  as  thatTEXT: H associated  with a switch changing state can cause numericalTEXT: H roundoff or tolerance problems leading to erroneous  resultsTEXT: H or  timestep difficulties.  The user of switches can improveTEXT: H the situation by taking the following steps:TEXT: HTEXT: H      First, it is wise to set ideal switch  impedances  justTEXT: H high  or  low  enough to be negligible with respect to otherTEXT: H circuit elements.  Using switch impedances that are close toTEXT: H "ideal"  in all cases aggravates the problem of discontinui-TEXT: H ties mentioned above.  Of course, when modeling real devicesTEXT: H such  as  MOSFETS, the on resistance should be adjusted to aTEXT: H realistic level depending on the size of  the  device  beingTEXT: H modeled.TEXT: HTEXT: H      If a wide range of ON to OFF resistance must be used inTEXT: H the switches (ROFF/RON >1e+12), then the tolerance on errorsTEXT: H allowed during transient analysis  should  be  decreased  byTEXT: H using  the  .OPTIONS control line and specifying TRTOL to beTEXT: H less than the default  value  of  7.0.   When  switches  areTEXT: H placed around capacitors, then the option CHGTOL should alsoTEXT: H be reduced.  Suggested values for these two options are  1.0TEXT: H and  1e-16  respectively.  These changes inform SPICE3 to beTEXT: H more careful around the switch points so that no errors  areTEXT: H made due to the rapid change in the circuit.TEXT: HSUBJECT: VOLTAGE AND CURRENT SOURCESTITLE: VOLTAGE AND CURRENT SOURCESTEXT: HTEXT: H _3._2.  _V_O_L_T_A_G_E _A_N_D _C_U_R_R_E_N_T _S_O_U_R_C_E_STEXT: HSUBTOPIC: SPICE:Independent SourcesSUBTOPIC: SPICE:Linear Dependent SourcesSUBTOPIC: SPICE:Nonlinear Dependent SourcesSUBJECT: Independent SourcesTITLE: Independent SourcesTEXT: HTEXT: H _3._2._1.  _I_n_d_e_p_e_n_d_e_n_t _S_o_u_r_c_e_sTEXT: HTEXT: H _G_e_n_e_r_a_l _f_o_r_m:TEXT: HTEXT: H     VXXXXXXX N+ N- <<DC> DC/TRAN VALUE> <AC <ACMAG <ACPHASE>>>TEXT: H     +       <DISTOF1 <F1MAG <F1PHASE>>> <DISTOF2 <F2MAG <F2PHASE>>>TEXT: H     IYYYYYYY N+ N- <<DC> DC/TRAN VALUE> <AC <ACMAG <ACPHASE>>>TEXT: H     +       <DISTOF1 <F1MAG <F1PHASE>>> <DISTOF2 <F2MAG <F2PHASE>>>TEXT: HTEXT: HTEXT: H _E_x_a_m_p_l_e_s:TEXT: HTEXT: H     VCC 10 0 DC 6TEXT: H     VIN 13 2 0.001 AC 1 SIN(0 1 1MEG)TEXT: H     ISRC 23 21 AC 0.333 45.0 SFFM(0 1 10K 5 1K)TEXT: H     VMEAS 12 9TEXT: H     VCARRIER 1 0 DISTOF1 0.1 -90.0TEXT: H     VMODULATOR 2 0 DISTOF2 0.01TEXT: H     IIN1 1 5 AC 1 DISTOF1 DISTOF2 0.001TEXT: HTEXT: HTEXT: H      N+ and N- are the positive and negative nodes,  respec-TEXT: H tively.   Note  that  voltage  sources need not be grounded.TEXT: H Positive current is assumed to flow from the positive  node,TEXT: H through  the source, to the negative node.  A current sourceTEXT: H of positive value forces current to flow out of the N+ node,TEXT: H through  the source, and into the N- node.  Voltage sources,TEXT: H in addition to being used for circuit  excitation,  are  theTEXT: H 'ammeters'  for  SPICE, that is, zero valued voltage sourcesTEXT: H may be inserted into the circuit for the purpose of  measur-TEXT: H ing  current.   They  of  course  have  no effect on circuitTEXT: H operation since they represent short-circuits.TEXT: HTEXT: HTEXT: H      DC/TRAN is the dc and transient analysis value  of  theTEXT: H source.   If  the source value is zero both for dc and tran-TEXT: H sient analyses, this value may be omitted.   If  the  sourceTEXT: H value  is  time-invariant  (e.g.,  a power supply), then theTEXT: H value may optionally be preceded by the letters DC.TEXT: HTEXT: HTEXT: H      ACMAG is the ac magnitude and ACPHASE is the ac  phase.TEXT: H The  source  is  set  to  this value in the ac analysis.  IfTEXT: H ACMAG is omitted following the keyword AC, a value of  unityTEXT: H is  assumed.   If  ACPHASE  is  omitted,  a value of zero isTEXT: H assumed.  If the source is not an ac small-signal input, theTEXT: H keyword AC and the ac values are omitted.TEXT: HTEXT: HTEXT: H      DISTOF1 and DISTOF2 are the keywords that specify  thatTEXT: H the independent source has distortion inputs at the frequen-TEXT: H cies F1 and F2 respectively  (see  the  description  of  theTEXT: H .DISTO  control  line).   The keywords may be followed by anTEXT: H optional magnitude and phase.  The  default  values  of  theTEXT: H magnitude and phase are 1.0 and 0.0 respectively.TEXT: HTEXT: HTEXT: H      Any independent source can be assigned a time-dependentTEXT: H value  for  transient  analysis.   If a source is assigned aTEXT: H time-dependent value, the time-zero value  is  used  for  dcTEXT: H analysis.   There  are  five  independent  source functions:TEXT: H pulse,  exponential,  sinusoidal,  piece-wise  linear,   andTEXT: H single-frequency FM.  If parameters other than source valuesTEXT: H are omitted or set to zero, the  default  values  shown  areTEXT: H assumed.   (TSTEP is the printing increment and TSTOP is theTEXT: H final time (see the .TRAN control line for explanation)).TEXT: HTEXT: HSUBTOPIC: SPICE:PulseSUBTOPIC: SPICE:SinusoidalSUBTOPIC: SPICE:ExponentialSUBTOPIC: SPICE:PieceWise LinearSUBTOPIC: SPICE:SingleFrequency FMSUBJECT: PulseTITLE: PulseTEXT: HTEXT: H _3._2._1._1.  _P_u_l_s_eTEXT: HTEXT: H _G_e_n_e_r_a_l _f_o_r_m:TEXT: HTEXT: H     PULSE(V1 V2 TD TR TF PW PER)TEXT: HTEXT: HTEXT: H _E_x_a_m_p_l_e_s:TEXT: HTEXT: H     VIN 3 0 PULSE(-1 1 2NS 2NS 2NS 50NS 100NS)TEXT: HTEXT: HTEXT: HTEXT: H      parameter               default value         unitsTEXT: H      -----------------------------------------------------TEXT: H      V1 (initial value)                      Volts or AmpsTEXT: H      V2 (pulsed value)                       Volts or AmpsTEXT: H      TD (delay time)         0.0             secondsTEXT: H      TR (rise time)          TSTEP           secondsTEXT: H      TF (fall time)          TSTEP           secondsTEXT: H      PW (pulse width)        TSTOP           secondsTEXT: H      PER(period)             TSTOP           secondsTEXT: HTEXT: HTEXT: HTEXT: HTEXT: HTEXT: H      A single pulse so specified is described by the follow-TEXT: H ing table:TEXT: HTEXT: HTEXT: HTEXT: H      time          valueTEXT: H      -------------------TEXT: H      0             V1TEXT: H      TD            V1TEXT: H      TD+TR         V2TEXT: H      TD+TR+PW      V2TEXT: H      TD+TR+PW+TF   V1TEXT: H      TSTOP         V1TEXT: HTEXT: HTEXT: HTEXT: HTEXT: H      Intermediate points are determined by linear interpola-TEXT: H tion.TEXT: HTEXT: HSUBJECT: SinusoidalTITLE: SinusoidalTEXT: HTEXT: H _3._2._1._2.  _S_i_n_u_s_o_i_d_a_lTEXT: HTEXT: H _G_e_n_e_r_a_l _f_o_r_m:TEXT: HTEXT: H     SIN(VO VA FREQ TD THETA)TEXT: HTEXT: HTEXT: H _E_x_a_m_p_l_e_s:TEXT: HTEXT: H     VIN 3 0 SIN(0 1 100MEG 1NS 1E10)TEXT: HTEXT: HTEXT: HTEXT: HTEXT: HTEXT: HTEXT: H      parameters                default value   unitsTEXT: H      -------------------------------------------------------TEXT: H      VO     (offset)                           Volts or AmpsTEXT: H      VA     (amplitude)                        Volts or AmpsTEXT: H      FREQ   (frequency)        1/TSTOP         HzTEXT: H      TD     (delay)            0.0             secondsTEXT: H      THETA  (damping factor)   0.0             1/secondsTEXT: HTEXT: HTEXT: HTEXT: HTEXT: HTEXT: H      The shape of the waveform is described by the followingTEXT: H table:TEXT: HTEXT: HTEXT: H      time          valueTEXT: H      ------------------------------------------------------------TEXT: H      0 to TD       VOTEXT: H                             -(t - TD)THETATEXT: H      TD to TSTOP   VO + VA e               sin(2 J FREQ (t + TD))

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -