Analog to digital converter system
BACKGROUND OF THE INVENTION 
     Analog signals are generally translated into their digital form by applying them to analog-to-digital converters, hereinafter referred to as A/D&#39;s, before any computation or signal processing is performed. The A/D&#39;s sample the amplitude of the analog signal at intervals of t 0  seconds and produce digital words that represent the closest amplitude to the actual amplitude of each sample that can be attained with the number of bits used by the converter. Any difference between the actual amplitude of the sample of the analog wave and the amplitude represented by digital words derived from it is known as &#34;digitization noise&#34;. 
     The highest frequency of the analog signal that can be accurately represented by such a sampling process is known as the &#34;Nyquist frequency&#34; and is equal to one-half the sampling frequency. If the analog signal is permitted to include higher frequencies, they can heterodyne with the sampling frequency and its harmonics to produce signals lying below the Nyquist frequency and therefore within the signal frequencies of interest. This is known as &#34;aliasing&#34;. In order to prevent this from occurring, it has been customary to pass the analog signal through a low pass filter having a cut-off at or below the Nyquist frequency, but the sharper the cut-off, the greater the phase distortion. For this reason, it would be desirable to avoid the use of an analog filter. 
     In many applications, interference from power lines, at 50 Hz or 60 Hz, as the case may be, can introduce severe aliasing effects. Notch filters can be used to attenuate these frequencies in the analog signal prior to its application to an A/D converter, but they also introduce troublesome errors in phase. 
     BRIEF DISCUSSION OF THE INVENTION 
     In accordance with this invention, digitization noise and aliasing can be reduced and high attenuation of the effects of power line frequencies can be attained by utilizing an integrating A/D followed by a digital filter. For reasons that will be explained, significantly better results can be attained by use of an integrating A/D, even though it is inherently more noisy than a sample-and-hold A/D. 
    
    
     THE DRAWINGS 
     FIG. 1 is a block diagram of an A/D system of the prior art; 
     FIG. 2 is a block diagram of an A/D system incorporating the invention; 
     FIG. 3 is a simplified diagram of an integrating A/D; 
     FIG. 3A illustrates the operation of the integrating A/D of FIG. 3; 
     FIG. 4 is comprised of graphs illustrating the operation of the invention; and 
     FIG. 5 is used to illustrate the operation of a two-point boxcar filter. 
    
    
     PRIOR ART 
     Reference is made to the block diagram of FIG. 1 for an understanding of prior art systems for making the A/D conversion. A source 2 provides an analog signal that may include signal frequencies above the maximum frequency of interest, 1/2t 0 , as well as interference at fifty or sixty cycles, as the case may be, from the power lines. The effects of the latter interference may be reduced by a notch filter 4 that is coupled to the source 2, and the analog signal may be cut off at the Nyquist frequency of 1/2t 0  by a low pass or anti-alias filter 6. The output of the filter 6 is applied to a sample-and-hold A/D converter 8 which samples the analog signal at intervals of t 0  seconds and produces digital words respectively representing the amplitudes of the analog signal at these sampling instants. As previously pointed out, an analog filter such as the filter 6 will introduce undesirable phase shifts in the analog signal that is applied to the A/D converter 8 and cause errors in the digital signal it provides. 
     EMBODIMENT OF THE INVENTION 
     FIG. 2 illustrates an analog-to-digital conversion system embodying this invention. Signals that may include signal components that are higher than the highest signal frequency of interest as well as interference from power lines that may be at 50 Hz or 60 Hz, as the case may be, are supplied from a source of analog signals 10 to an integrating A/D converter 12. The output of the converter 12 is applied to a digital filter 14. Although the particular details of the manner in which the filter 14 carries out the functions required by this invention is not important to this invention, the filter is illustrated as being comprised of a shift register having sections r 1 , r 2 , r 3 , r 4 , r 5 , r 6 , r 7 , r 8 , r 9 , r 10 , r 11 , and r n  with their outputs respectively connected to multipliers 16, 18, 20, 22, 24, 26, 28, 30, 32, 34, 36, and X n . The outputs of the multipliers are coupled via separate leads in a harness 54 to the input of an adder 56. The multiplying factors for each of the multipliers 16-36 are for one particular digital filter that is useful in carrying out this invention, but as will be explained, other digital filters having different numbers of multipliers and respectively different multiplying factors may be used. 
     INTEGRATING A/D 
     The integrating A/D of FIG. 3 is simplified and impractical values of certain components are assumed in order to facilitate the explanation of the functional characteristics that relate to this invention. An analog signal V IN  to be digitized, that is assumed to be +1 volt, is applied via a one-ohm resistor 40 to the inverting input of an operational amplifier U 1 . Clock #1 supplies pulses that are precisely one second apart to the &#34;set&#34; input of a relay control device 42 which immediately provides a voltage at its &#34;out&#34; terminal so as to energize a relay coil 44 and close a normally open switch s. This applies -10 volts via a one-ohm resistor 46 to the inverting input of U 1 . Its non-inverting input is connected to ground, and a one-farad capacitor C is connected between the inverting input of U 1  and its output, so that U 1  supplies an integrated voltage V INT  to the non-inverting input of a comparator U 2 . The inverting input of U 2  is connected to a voltage -E 0  /2,E 0  being the voltage of one conversion step, as will be explained. 
     Each tick of the clock #1 starts a faster clock #2, e.g., having a frequency of 1000 Hz, that outputs pulses to the &#34;in&#34; terminal of a counter 48. When the integrated voltage V INT  from U 1  reaches -E 0  /2, the output of the comparator U 2  shifts to a high state. This is applied to one input of an AND gate U 3  but it cannot change until the next pulse from clock #2 reaches its other input via lead 50. When this occurs, the output of U 3  changes state. The output of U 3  is applied to the &#34;reset&#34; input of the relay control device 42, causing it to deenergize the relay coil 44 and permitting the switch s to open. The output of U 3  is also applied to a &#34;data ready&#34; output that is connected to a process controller 52. Although the connections are not shown, the process controller 52 causes the digital words in the stages r 1  ---r 11  of the shift register to advance to the next stage and the digital word at the output of the counter 48 to be stored in the stage r 1 . The multipliers 16 through X n  then multiply the outputs of the respective sections of the shift register to which they are connected. The outputs of the multipliers 16 through X n  are applied by conductors in the harness 54 to the adder 56. When the addition is complete, a signal indicating that the data has been fetched is applied to the &#34;reset&#34; terminal of the counter 48. 
     OPERATION OF THE INTEGRATING A/D 
     Reference is now made to the graph of FIG. 3A wherein the horizontal line G represents ground potential and the sawtooth line V INT  represents the voltage at the output of U 1 . If V IN  is +1 volt and the switch s is open, the capacitor C charges in a negative direction at the rate of one volt per second, and V INT  does likewise. When the clock #1 ticks,the switch s closes, the capacitor C starts charging in a positive direction at a rate of 9 volts per second, the clock #2 starts ticking, and the counter 48 starts counting the ticks. E 0  is the voltage by which V INT  increases in a positive direction between ticks. When V INT  reaches -E 0  /2, the output of U 2  changes state so as to increase the voltage in one of the inputs of U 3 . However, as previously stated, U 3  cannot change state until the next tick of the clock #2 is applied to its other input via the lead 50. This could occur anywhere between the dotted lines -E 0  /2 and +E 0  /2. When it does occur, clock #2 is stopped and the count then in the counter 48 is used by the counter to output a digital word representing the size of the count and therefore the amplitude of V IN . Until U 3  fires, V INT  keeps increasing so that it can have a value anywhere between -E 0  /2 and +E 0  /2. When U 3  fires, the capacitor C is charged in a negative direction until the one-second clock #1 ticks. It can thus be seen that both ends of the +9-volt/second portion of V INT  can vary so that the number of pulses from clock #2 that are counted by the counter 48 can change. These variations are independent variables but they are related owing to the fact that an increase in the voltage at the upper end of one 9-volt/second portion of V INT  causes an increase in the voltage of V INT  at the lower end of the next 9-volt/second portion of V INT . These variations are the source of the digitization noise. 
     DIGITAL NOISE 
     It can be shown that the RMS value of the digitization noise in the system shown in FIG. 2 is ##EQU1## wherein h(L) is the impulse response of the digital filter 14 and L is digital time. 
     Thus, if the signal from the integrating A/D 12 is applied to a digital filter having one section that multiplies by one and which is described as a filter (1), there is, in effect, no filtering at all. The resulting noise is calculated as follows. The impulse response of such a filter may be described as having the following values at successive digital or sample times--00100. The expression within the brackets represents the slope at any digital time L because the digital times are uniformly separated. The slopes for such a filter can be expressed as the difference in response at one digital time and the response at the previous time, so that slopes for the filter just described are 0, 0, 1, -1, 0, 0 and the sum of the squares of these slopes is 1 2  +(-1) 2  =2, so that expression (1) becomes ##EQU2## 
     It can also be shown that the RMS noise of a sample-and-hold A/D followed by a digital filter may be expressed as ##EQU3## If this filter (1), which is no filter at all, is connected to the output of a sample-and-hold A/D , the RMS noise is ##EQU4## Accordingly, a sample-and-hold A/D is inherently less noisy than an integrating A/D, but if we apply the same calculations to each of the A/D&#39;s followed by the digital filters described in the chart below, the results will be as tabulated. 
     
         ______________________________________                                    
                 SAMPLE                                                   
FILTER           &amp; HOLD    INTEGRATING                                    
______________________________________                                    
(1)              .29 E.sub.O                                              
                           .41 E.sub.O                                    
(1,1)            .41 E.sub.O                                              
                           .41 E.sub.O                                    
(1,1,1,1,1,1,1,1)                                                         
                 .82 E.sub.O                                              
                           .41 E.sub.O                                    
(1,3,7,13,16,13,7,3,1)                                                    
                 7.7 E.sub.O                                              
                           3.3 E.sub.O                                    
(1,2,4,7,11,14,16,18,16,14,11                                             
7,4,2,1)         11.6 E.sub.O                                             
                           2.8 E.sub.O                                    
(1,3,5,8,10,10,10,8,5,3,1)                                                
                 6.4 E.sub.O                                              
                           1.9 E.sub.O                                    
______________________________________                                    
 
    
     By way of example, the slopes for the last filter are 1,2,2,3,2,0,0,-2,-3,-2,-2,-1, the sum of the individual squares is 44, and the value of expression (1) for an integrating A/D becomes ##EQU5## The value of expression (3) for the sample-and-hold A/D when coupled to this same filter becomes ##EQU6## This noise is 3.4 times greater. 
     The following table indicates the ratio of filter gain to digitization noise, the filter gain being the sum of the multiplications of the separate sections. 
     
         ______________________________________                                    
                SAMPLE                                                    
   FILTER       &amp; HOLD     INTEGRATING                                    
______________________________________                                    
(1)                                                                       
                 ##STR1##                                                 
                            ##STR2##                                      
(1,1)                                                                     
                 ##STR3##                                                 
                            ##STR4##                                      
(1,1,1,1,1,1,1,1)                                                         
                 ##STR5##                                                 
                            ##STR6##                                      
(1,3,7,13,16,13,7,3,1)                                                    
                 ##STR7##                                                 
                            ##STR8##                                      
(1,2,4,7,11,14,16,18,16,14,11 7,4,2,1)                                    
                 ##STR9##                                                 
                            ##STR10##                                     
(1,3,5,8,10,10,10,8,5,3,1)                                                
                 ##STR11##                                                
                            ##STR12##                                     
______________________________________                                    
 
    
     Thus, if digitization noise is a problem and if no filtering is to be done, the sample-and-hold A/D should be used, but if digitization noise is a problem or filtering is to be used, the integrating A/D should be used. 
     ANTI-ALIASING 
     The frequency response of a sample-and-hold A/D is the same for all frequencies as indicated by the horizontal line 58 of FIG. 4, i.e., whatever the sampling frequency, the beat with any other frequency has the same amplitude. Therefore, alias frequencies produced by heterodyning between some undesired input frequencies and the sampling frequency of the A/D would lie in the bandwidth of the desired signals. It is for this reason that the low pass filter 6 is used in the prior art system of FIG. 1. 
     The frequency response for an integrating A/D can be derived as follows. If an analog circuit has an impulse response of μ -1  (t)μ -1  (-t+t 0 ) wherein μ -1  (t) is a step function having zero value up to 0 and unity value thereafter, and wherein μ -1  (-t+t 0 ) is a step function having unity value from -∞ until t 0  and zero thereafter, the frequency response is ##EQU7## If we apply a signal i(t) to this circuit and integrate over a period of t 0 , we see that the result is the same as for a continuously integrating A/D such as shown in FIG. 3. Accordingly, we can say that such an A/D has a frequency response H.sub.ω as given in equation (6). This is illustrated by the line H.sub.ω of FIG. 4. Examination of equation (6) shows that H.sub.ω =0 when ω=2π/t 0 , so that the line H.sub.ω  goes to zero at this frequency. Another way of realizing that this occurs with an integrating A/D converter such as shown in FIG. 3 is to observe that t 0  is the sampling interval of one second and the sampling frequency is 2π/t 0 . If in that particular circuit, V IN  has a frequency of one cycle per second, the output will be zero as integration over a complete cycle is zero. The line H.sub.ω will also pass through zero at all harmonics of the sampling frequency 2π/t 0 . There will not be a great reduction in aliasing because most of the frequencies between π/t 0  and 2π/t 0  have significant amplitude. 
     The impulse ω -1  (t)ω -1  (-t+t 0 ) describes each of the samples S 1  ---S 7  of FIG. 5. Now, however, if we couple the output of an integrating A/D to a two-point boxcar filter, the output will be impulses S 1  +S 2 , S 2  +S 3 , S 3  +S 4 , etc. The frequency of sampling is the same, but the samples now have a duration of 2t 0  and have an impulse response u -1  (t)u -1  (-t+2t 0 ). The frequency response H&#39;.sub.(ω) of the integrating A/D followed by a two-point boxcar filter is given by the expression ##EQU8## and is illustrated by the line H&#39;.sub.(ω) of FIG. 4. Such a response will reduce the aliasing because the response to frequencies above π/t 0  is quite low. 
     DIGITAL NOISE AND ALIASING 
     It can be seen from the tables of noise figures for the sample-and-hold A/D and the integrating A/D that a two-point boxcar filter does not reduce the noise, although it does improve the gain-to-noise ratio of the filter. If filters other than boxcar filters are used, however, the noise figures are better for the integrating A/D. A good noise figure and anti-aliasing can be attained by using a filter such as the last one in the charts. This is the filter illustrated in FIG. 2. Its frequency response is indicated by the dotted line 60. The more stages there are in a filter, the greater is the duration of a sample, and the lower is the frequency of the first zero response. 
     Furthermore, if the dotted line 60 were accurately plotted on a large scale, the response at line frequencies of 50 and 60 Hz would be very low for some distance on either side, so that these frequencies would produce very little interference, even if they varied. 
     It will be understood that FIG. 2 could have the number of sections and the required multipliers for any filter, e.g., fifteen sections would be required to form the filter having the best gain-to-noise ratio of 45.71/E 0 .