Simulating a variable resistance input with LTSpice?

Apr 13, 2010 60 Replies

Surprise! Three point subcircuit fit, R0 (nominal at 25°C) and at the end points of the data (same as above)... generates a Steinhart-Hart equation accurate to ±0.3%....

*************************************************** .SUBCKT ThermistorSH3PT THERMP THERMN
  • PARAMS: R0=470 T0=25 R1=26618 T1=-55 R2=23.24 T2=125 .PARAM TK0={T0+273.15} .PARAM TK1={T1+273.15} .PARAM TK2={T2+273.15} .PARAM K01={TK0*TK1/(TK0-TK1)} .PARAM K02={TK0*TK2/(TK2-TK0)} .PARAM Q01={(TK0**3-TK1**3)/(TK0**3)/(TK1**3)} .PARAM Q02={(TK2**3-TK0**3)/(TK0**3)/(TK2**3)} .PARAM C={(K02*LOG(R0/R2)-K01*LOG(R1/R0))/((Q02*K02)-(Q01*K01))} .PARAM B={K01*LOG(R1/R0)-C*K01*Q01} .PARAM A={(-1)*(B/TK0+C/(TK0**3))} .PARAM TK={TEMP+273.15} .PARAM RT={R0*EXP(A+B/TK+C/(TK**3))} G_G1 THERMP THERMN VALUE {V(THERMP,THERMN)/RT} .ENDS ThermistorSH3PT
***************************************************

(Math all solved by PSpice within the subcircuit declaration :-) ...Jim Thompson

| James E.Thompson, CTO | mens | | Analog Innovations, Inc. | et | | Analog/Mixed-Signal ASIC's and Discrete Systems | manus | | Phoenix, Arizona 85048 Skype: Contacts Only | | | Voice:(480)460-2350 Fax: Available upon request | Brass Rat | | E-mail Icon at http://www.analog-innovations.com | 1962 | The only thing bipartisan in this country is hypocrisy

Join the Discussion

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

Didn't find your answer?

Ask the community — no account required