2009 Fifth International Conference on Intelligent Information Hiding and Multimedia Signal Processing
Implementation of Thermistor Linearization Using LabVIEW
Chin-Fu Tsai 1, Lung-Tsai Li 2, Chin-Hao Li 1 , Ming-Shing••Young 2
1 2
National Chin-Yi University of Technology National Cheng-Kung University
E-mail : tsaicf@ncut.edu.tw, , lee306@ncut.edu.tw, k281172@yahoo.com.tw, msyoung@mail.ncku.edu.tw
Abstract can be simulated on MathCAD [8]. In regard to the
types of errors already noted, it is recognized that in
Thermistor nonlinearity is an important problem in the practical applications some degree of linearity error
applications of temperature measurement. Much may be acceptable—a typical thermistor has about 1%
research has been devoted to accurate linearization tolerance. Therefore, we will focus on a flexible, user-
but typical methods still involve complicated circuits friendly workbench for designing a linear temperature-
or require algorithms for training neural networks. In dependence circuit.
this report, we demonstrate how programs for Laboratory Virtual Instrument Engineering
thermistor linearization involving a series or parallel Workbench (LabVIEW) is a graphical programming
resistor can be easily implement in the LabVIEW language developed by National Instruments. It has
environment. The goal of this study is to define and been widely used in a variety of industries for
demonstrate a technique for determining the optimal measurement, data analysis, data presentation, and
resistor value. control [9][10]. Because LabVIEW provides icons to
represent and manage the user interface, it allows us to
1. Introduction develop a human-friendly program for the analysis and
design of the thermistor linearization circuit. This
Thermistors are temperature sensors often used in research may provide a useful base for designers who
the field of automobile industries and consumer are attempting to reduce the cost and shorten
electronics. They have merits of low cost, high development time for thermistor-related circuits.
sensitivity, and a variety of physical sizes and shapes
suited to assembly in many applications. However, the 2. Theories of thermistor linearization
device nonlinearity is the limiting factor in achieving
accurate temperature measurement. Studies performed For an NTC thermistor, the temperature dependence
on thermistor linearization have used various of the resistance RT is almost exponential, as shown in
configurations in combined circuits. For example, Eq. (1)
early on, Khan [1] and Natarajan [2] successively RT R0 exp[ B(1 / T 1 / T0 )] (1)
proposed a linearization method that was based on an where R0 is the zero-power resistance at a specific
analog multiplier. These methods do not eliminate all temperature T0 in Kelvins, and B is the characteristic
linearity errors and still require several circuit temperature of the material.
components. To resolve those problems, much To make the thermistor behave linearly, there are two
attention has been focused on techniques for basic and well-known methods. One is to build a
combining circuits and software [3-7]. These circuit that we can expect to product a linearized
techniques use numerical methods or artificial neural output, using a resistor in series as shown in Fig.1 (a).
networks to reduce the linearity errors by performing Another is to create linearized resistance behavior
computations on a personal computer (PC). using a parallel combination as shown in Fig.1 (b).
The rapid growth in the capability of PCs means that Either way, the central problem is how to determine
complicated mathematical calculations have become the optimal resistance value, one that will achieve the
much easier to execute. Nenova has proposed a expected linear range.
method of linearizing an NTC thermistor that is based
on a 7555 timer with frequency and analog outputs that
978-0-7695-3762-7/09 $26.00 © 2009 IEEE 530
DOI 10.1109/IIH-MSP.2009.98
( B 2T ) (4)
S
1 1
( B 2T ) exp[ B ( )]
T T0
The parallel combination of both resistors shown in
Fig. 1(b) can be expressed as follows:
RRT
Rp (5)
R RT
Continuing with Fig. 1(b), the temperature-coefficient
ratio (TCR) D can be calculated as (dRp/dT)/Rp. Taking
Fig.1 Basic methods of thermistor linearization
the derivative of Eq. (5) yields the following:
B 1
In Figure 1(a), for example, the relationship between D (6)
the output and the input shall be T (1 RT / R )
2
vo 1 From Eq. (7), the optimal value of R for the expected
{ f (T ) (2). temperature region can be found. To obtain the
vi 1 Sr (T ) necessary value for R, we take the second derivative of
where S is defined the ratio of R0 to R, and r(T) is the Eq. (5) and equate the result to zero; that is:
ratio of RT to R0. d 2 Rp R 2 BRT B 2 BRT
The function f(T) is S-shaped curve as shown in Fig. [ 2 ] 0 (7)
2 and, hence, the linear region is limited only to a dT 2 ( RT R) T T
2 3
( RT R)T
narrow range of temperatures. To achieve the Solving for R, we obtain
temperature range that we expect, we need first to B 2Tc
determine the appropriate value for S. Using the R RTc (8)
second derivative of the function f(T), the solution can
B 2Tc
be expressed as follows: where Tc is the center temperature of the linearized
range. From Eq. (7) the optimal value of R will be
found out for the expected temperature region.
3. Implementation
The method just described was implemented and
integrated into a virtual instrument developed in
LabVIEW.
Fig.2 S-shaped curves for different S values in Eq. (2)
d 2 f (T ) SBr (T ) 2 SBr (T )
[ B 2T ] (3), Fig.3. Block diagram: Software design and implementation
dT 2
[1 Sr (T )]2 1 Sr (T ) for thermistor linearization
Note that the result must be zero for a straight-line
response. The second term in Eq. (3) equals zero, Fig. 3 shows a block diagram of the total software
yielding the following result: implementation. First, we specify and define the
character of a thermistor. Then, according to the other
conditions specified, we obtain an optimal resistance
531
for R, using Eq. (4) and Eq. (8). The simulation results can easily determine a value of 29.6 k˖ for R and
can be visualized using the “waveform graph” object
achieve a straight-line response from 10 to 50 °C.
displayed on the front panel.
Figure 4 is a program example that follows the
model shown in Fig.1(b). In the program, three
subprograms (subVIs) are used, respectively, to 1)
define the character of the thermistor; 2) find the
optimal value of R, using Eq. (8); and 3) perform the
parallel function. At the subVI level, we use the
formula node function to perform the required
calculations.
Fig. 6. Operations example: 50 kȍ thermistor using the
Fig. 1(a) circuits
Fig. 4. Block diagram: Parallel method for linearization
4. Discussion
Thermistor linearization has been developed and
implemented in LabVIEW, using the basic series-
parallel resistor method. A two-parameter model is
presented in this paper to simulate the NTC thermistor
characteristics in order to present and analyze a model
for linearization. In a temperature span of 50 °C for a
thermistor, this model might yield a deviation of r0.3
°C. In practical applications such as room temperature
monitoring and thermal compensation, this deviation is
acceptable. LabVIEW has been found to be an
effective tool for analyzing an NTC thermistor to
determine an optimal value for a resistor used in
thermistor linearization.
Fig. 5. Operations example: 50 kȍ thermistor linearization 5. References
.
Figure 5 shows the interactive user interface of the [1] A.A. Khan, M.A. Al-Turaigi, A.R.M Alamoud,
VI, which is the front panel of the system. The user “Linearized thermistor thermometer using an analog
multiplier,” IEEE trans on Instrumentation and
interface shows that the optimal value of R is 34.3 k˖ Measurement, Vol 37, Issue 2, pp 322-323, June 1988.
for linearizing a 50 kȍ NTC thermistor over the range [2] S. Natarajan, “A modified linearized thermistor
5–60 °C. Fig. 5 shows that we can get a straight-line thermometer using an analog multiplier,” IEEE trans on
curve of Rp. Obviously, this linearity is good relative to Instrumentation and Measurement, Vol 39, Issue 2, pp
the cure of the essential characteristic RT of the 440-441, April 1990.
thermistor. [3] D. Ghosh, D. Patranabis, “Software based linearisation
Following from Eq. (2) and Eq. (4), Fig. 6 shows of thermistor type nonlinearity,” Circuits, Devices and
another example for a 50 kȍ thermistor, using the Systems, IEE Proceedings G, Vol 139, Issue 3, pp 339-
circuits illustrated in Fig. 1(a). In the user interface, we 342, June 1992.
532
[4] M. Attari, F. Boudjema, M. Heniche, “Linearizing a 2007. 18th European Conf. on 27-30 Aug. 2007
Thermistor Characteristic in the Range of Zero to 100 Page(s):910 - 913
Degree C With Two Layers Artificial Neural Networks,” [8] Nenova, Z.P.; Nenov, T.G.,” Linearization Circuit of the
Instrumentation and Measurement Technology Thermistor Connection”, Instrumentation and
Conference, pp119-122, 24-26 April 1995. Measurement, IEEE Transactions on Vol. 58, Issue
[5] M.B. Lucks, N.Oki, “An analog implementation of radial 2, Feb. 2009 Page(s):441 – 449
basis function network appropriate for transducer [9] Falcon, J.S. “LabVIEW State Diagram Toolkit for the
linearizer,” 42nd Midwest Symposium on Vol 2, pp 1109 Design and Implementation of Discrete-Event Systems”,
- 1112, Aug 1999. 2006 8th International Workshop on 10-12 July 2006
[6] Hosny, Amal N., Moaty, Iman A.E., “Development of a Page(s):469 - 470
linear temperature measuring circuit using a thermistor”, [10] Akram, G.; Jasmy, Y.; “Numerical Simulation of the
Modelling, Measurement & Control A, v 63, n 1-3, 1995, FDTD Method in LabVIEW”, Microwave Magazine,
p 25-30 IEEE Vol. 8, Issue 6, Dec. 2007 Page(s):90 – 99
[7] Renneberg, C.; Lehmann, T.; “Analog circuits for
thermistor linearization with Chebyshev-optimal
linearity error”, Circuit Theory and Design, ECCTD
533