Abstract:
A method and apparatus are provided for mixing a plurality of signals within a predetermined dynamic range without clipping. In the method and apparatus, first and second signal samples are added together to obtain a first intermediate result. Then the first signal sample is multiplied with the second signal sample to obtain a second intermediate result. In one embodiment, the second intermediate result is subtracted from the first intermediate result to obtain a third intermediate result, and the third intermediate result is discarded if the third intermediate result is less than zero. In another embodiment, the second intermediate result is added to the first intermediate result to obtain the third intermediate result, and the third intermediate result is discarded if the third intermediate result is greater than zero. An output signal sample is provided based on the third intermediate result.

Description:
FIELD OF THE INVENTION 
     This invention relates to mixers, and more particularly to mixers that provide a bounded signal. 
     BACKGROUND OF THE INVENTION 
     Many communications systems have a limited dynamic range so that bounded signals are preferably provided. Such signals are bounded to be within the dynamic range. In practice this has been difficult to achieve because of the variations in factors that can result in the need for various signal strengths. In some applications two or more signals are combined and then transmitted. Each of the signals may be within the dynamic range but the combination is not. Another application arises when there is a need to amplify a source signal to achieve a target signal to noise ratio. After providing the requisite amplification, the result amplified signal may be outside the dynamic range. Most approaches result in some clipping of the signal upon actual transmission. The transmission channel itself forces the clipping and results in distortion at the receiving end. In the case of voice transmission, clipping generally results in a very unpleasant sound and often a significant reduction in intelligibility. In the case of image or video transmission, clipping results in loss of fidelity and overexposure. Other approaches require an extra supporting circuitry and can still result in the loss of information. For example, two signals can be combined to result in a 16 bit digital signal but be transmitted at a reduced number of bits as a bounded signal due to the limited dynamic range of the transmission channel. This requires additional circuitry for the combining and results in the loss of data after being bounded to the dynamic range of the transmission channel. 
     Thus there is a need for a circuit technique that provides for a bounded signal that avoids one or more of the problems described above. 
    
    
     
       BRIEF DESCRIPTION OF THE DRAWINGS 
       The foregoing and further and more specific objects and advantages of the invention will become readily apparent to those skilled in the art from the following detailed description of a preferred embodiment thereof taken in conjunction with the following drawings: 
         FIG. 1  is a circuit diagram of a mixing kernel according to one embodiment; 
         FIG. 2  is a circuit diagram of a mixing kernel according to another embodiment; 
         FIG. 3  is a circuit diagram of a mixer using the mixing kernel of either  FIG. 1  or  FIG. 2 ; and 
         FIG. 4  is a circuit diagram of a mixer using the mixing kernel of  FIG. 1  or  FIG. 2 . 
     
    
    
     DETAILED DESCRIPTION OF THE INVENTION 
     In one aspect a mixer kernel combines two signals, which are themselves bounded, in a way that the resulting combined signal is bounded as well. The resulting combined signal is ensured of being no greater magnitude than the largest of the incoming signals that are to be combined. This approach normalizes the incoming signals to plus and minus one for the full dynamic range so that the signal magnitudes that are mixed each have an absolute value that is less than or equal to one. The result is that the character of the combined signal is compressed into the dynamic range. The resulting sound of the combined signal is more pleasant to the listener as well as being of higher intelligibility. This is better understood by reference to the drawings and the following description. 
     Shown in  FIG. 1  is a mixing kernel  10  comprising an adder  12 , a multiplier  14 , an adder  16 , an adder  18 , a discard negative values circuit  20 , a discard negative values circuit  22 , and an adder  24 . Adders  12 ,  16 ,  18 , and  24  and multiplier  14  are shown as separate elements and may be implemented in that fashion or as a part of processing system that uses various circuit elements for a desired function under the control of software. Adder  12  has an adding input for receiving signal X 1 , an adding input for receiving signal X 2 , and an output. Multiplier  14  has an input for receiving signal X 1 , an input for receiving signal X 2 , and an output. Adder  16  has an adding input coupled to the output of adder  12 , a negating input coupled to the output of multiplier  14 , and an output. Adder  18  has a negating input coupled to the output of adder  12 , a negating input coupled to the output of multiplier  14 , and an output. Discard negative values circuit  20  has an input coupled to the output of adder  16  and has an output. Discard negative values circuit  22  has an input coupled to the output of adder  18  and has an output. Adder  24  has an adding input coupled to the output discard negative values circuit  20 , a negating input coupled to the output of discard negative values circuit  22 , and an output that provides a mixed signal M. At any given point in time, signals X 1  and X 2  are a sample of a time varying signal such as voice signal and are digital signals that have been normalized so that their maximum absolute value is one. Any absolute value less than one is represented as a fractional value between plus and minus one. Plus and minus one also represents the dynamic range available for transmission of mixed signal M. 
     In operation, adder  12  provides an intermediate result on its output of X 1  plus X 2 ; 
     X 1 +X 2 . 
     Multiplier  14  provides an intermediate result on its output of X 1  times X 2 ; 
     X 1 X 2 . 
     Adder  16  thus provides an intermediate result on its output of X 1  plus X 2  minus X 1  times X 2 ; 
     X 1 +X 2 −X 1 X 2 . 
     Adder  18  provides an intermediate result on its output of minus X 1  minus X 2  minus X 1  times X 2 ; 
     −X 1 −X 2 −X 1 X 2 . 
     Discard negative values circuit  20  couples the output of adder  16  to the adding input  24  if it is positive and otherwise couples zero to adder  24 . Similarly, discard negative values circuit  22  couples the output of adder  18  to the negating input of adder  24  if the value of its output is positive and otherwise couples a zero value to adder  24 . This can be viewed as multiplying the input by a step function of the input. Accordingly, discard negative values circuits  20  and  22  each include a step function circuit. For example, if X 1  is 1 and X 2  is minus one, then the output of adder  16  is 1−1−(−1)1=1, which is positive, and is coupled to the adding input of adder  24 , and the output of adder  18  is −(−1)−1−(−1)1=1, which is positive, and is coupled to the negating input of adder  44 . With the adding input and negating input of adder  24  both at plus 1, adder  44  provides a zero as the output. This is consistent with the inputs X 1  and X 2 , which are minus 1 and plus 1, respectively, adding to zero. 
     For a different example, assume X 1  is −0.5 and X 2  is 0.8, the output of adder  16  is −0.5+0.8−(−0.4)=0.3+0.4=0.7, and the output of adder  18  is −(−0.5)−0.8−(−0.4)=−0.3+0.4=0.1 Adder  24  then provides an output of 0.7−0.1 which equals 0.6. 
     For an example where the summation of X 1  and X 2  exceeds one, X 1  is minus 0.8 and X 2  is minus 0.5. This is a simple summation of minus 1.3. Using mixing kernel  10 , the output of adder  16  is −0.8−0.5−(−0.5)(−0.8)=−1.7, and the output of adder  18  is −(−0.8)−(−0.5)−(−0.8)(−0.5)=0.9. Because the value provided by adder  16  is negative, it is discarded. Adder  24  then receives zero on its adding input and 0.9 on its negating input so provides −0.9 as the value of signal M. As can be seen then, even though the straight sum of X 1  and X 2  has an absolute value greater than one, the value produced as signal M for transmission is within the dynamic range for transmission. The primary effect is that the signal is compressed near the clipping range. 
     Shown in  FIG. 2  is a mixing kernel  30  comprising an adder  32 , a multiplier  34 , an adder  36 , an adder  38 , a discard positive values circuit  40 , a discard positive values circuit  42 , and an adder  44 . Mixing kernel  30  is an alternative to mixing kernel  10  for mixing signals X 1  and X 2  and providing signal M. Adder  32  has an adding input for receiving signal X 1 , an adding input for receiving signal X 2 , and an output. Multiplier  34  has an input for receiving signal X 1 , an input for receiving signal X 2 , and an output. Adder  36  has an adding input coupled to the output of adder  32 , an adding input coupled to the output of multiplier  34 , and an output. Adder  38  has a negating input coupled to the output of adder  32 , an adding input coupled to the output of multiplier  34 , and an output. Discard positive values circuit  40  has an input coupled to the output of adder  36  and has an output. Discard positive values circuit  42  has an input coupled to the output of adder  38  and has an output. Adder  44  has an adding input coupled to the output discard positive values circuit  40 , a negating input coupled to the output of discard positive values circuit  42 , and an output that provides a mixed signal M. 
     In operation, adder  32  provides an intermediate result on its output of X 1  plus X 2 ; 
     X 1 +X 2 . 
     Multiplier  34  provides an intermediate result on its output of X 1  times X 2 ; 
     X 1 X 2 . 
     Adder  36  thus provides an intermediate result on its output of X 1  plus X 2  plus X 1  times X 2 ; 
     X 1 +X 2 +X 1 X 2 . 
     Adder  38  provides an intermediate result on its output of minus X 1  minus X 2  plus X 1  times X 2 ; 
     −X 1 −X 2 +X 1 X 2 . 
     Discard positive values circuits  40  and  42  operate similarly to discard negative values circuits  20  and  22 . Discard positive values circuit  40  couples the output of adder  36  to the adding input  44  if it is negative and otherwise couples zero to adder  44 . Similarly, discard positive values circuit  42  couples the output of adder  38  to the negating input of adder  44  if its output is negative and otherwise couples a zero to adder  44 . This can be viewed as multiplying the input by a step function of the negating input. Accordingly, discard positive values circuits  40  and  42  each include a step function circuit. For example, if X 1  is plus 1 and X 2  is minus one, then the output of adder  36  is 1−1+(−1)1=−1, which is negative, and is coupled to the adding input of adder  44 , and the output of adder  38  is −(−1)−1+(−1)1=−1, which is negative, and is coupled to the negating input of adder  44 . With the adding input and negating input of adder  24  both at negative  1 , adder  44  provides a zero as the output. This is consistent with the inputs X 1  and X 2 , which are minus 1 and plus 1, respectively, adding to zero. 
     For an example where the summation of X 1  and X 2  exceeds one, X 1  is minus 0.8 and X 2  is minus 0.5. This is a simple summation of minus 1.3. Using mixing kernel  30 , the output of adder  36  is −0.8−0.5+(−0.5)(−0.8)=−0.9, and the output of adder  38  is −(−0.8)−(−0.5)+(−0.8)(−0.5)=1.7. Because the value provided by adder  38  is positive, it is discarded. Adder  44  then receives zero on its negating input and −0.9 on its positive input so provides −0.9 as the value of signal M. As can also be seen then for mixing kernel  30 , even though the straight sum of X 1  and X 2  has an absolute value greater than one, the value produced as signal M for transmission is within the dynamic range for transmission. 
     Shown in  FIG. 3  is a signal mixer  50  comprising three mixing kernels such as mixing kernel  30  from  FIG. 2  and additional mixing kernels as needed. This shows that the output of a mixing kernel  30  or mixing kernel  10  can be mixed with another signal to produce another mixed signal that is bounded according to the dynamic range of the channel over which the output signal MN will be transmitted. There are situations where it is desirable to mix more than two signals. This shows there is actually no limit to the number of signals that can be mixed. Of course there may be other practical limitations as to how many can actually beneficially be combined. For example in a telephone conference involving many different remote locations, only so many can talk at once and there be benefit in doing so. Another alternative (not shown) is to have signals X 1 -XN each input to a kernel mixer and then have the kernel mixer outputs go to other kernel mixer inputs. In such case, kernel mixer outputs would be mixed together rather than a kernel mixer output mixed with one of signals X 1 -XN. In addition, the various inputs can be the same signal. 
     This is particularly relevant in the situation in which a particular signal to noise ratio is to be obtained by amplifying the signal. The noise level can vary and in some situations become quite high. In such cases, the calculated gain for the desired signal to noise ratio can be so high that it would result in transmitting a signal that would exceed the dynamic range of the channel. For example a gain factor of three may exceed the dynamic range of the channel to be transmitted on. If the signal X 1  is to be amplified by a factor of three, both inputs of a first kernel mixer such as kernel mixer  10  or  30  would receive signal X 1 , the first kernel mixer would provide an output that would be mixed with X 1  in second kernel mixer, and the second kernel mixer would then provide the amplified output for transmission. This would ensure that the transmitted signal was bounded to avoid exceeding the dynamic range of the channel and the consequent clipping. If the number to be amplified is not a simple integer such as 3.5, the extra 0.5 would be achieved by mixing once with a signal that is 0.5X 1  in addition to what is required to achieve the integer mixes. 
     Shown in  FIG. 4  is an alternative to signal mixer  50  comprising a mixing kernel  30 , a register  62 , and a multiplexer  64 . Multiplexer  64  has a first signal input for receiving signal X 1 , a second signal input, a control input for receiving a control signal C 1 , and an output. Mixing kernel  30  has an input coupled to the output of multiplexer  64 , an input for receiving one of signals X( 2 -N), and an output for providing an output signal MN. Register  62  has a signal input coupled to the output of mixing kernel  30 , a control input for receiving signal C 2 , and an output coupled to the second signal input of multiplexer  64 . In operation multiplexer first couples signal X 1  to mixing kernel  30  and receives signal X 2  to generate a mixed output that is stored in register  62 . Multiplexer  64  then couples the output of register  62  to mixing kernel  30  so that mixing kernel  30  then mixes signal X 3  with the output of register  62 . At this point register  62  is storing the result of mixing signals X 1 , X 2 , and X 3 . Signal X 4  is then mixed by mixing kernel  30  with the output of register  62  to produce a mixed signal as a mix of signals X( 1 - 4 ). This continues until signal XN, N being the number of signals to be mixed, has been mixed with the output of register  62  to produce signal MN. The number of signals is not limited mixing kernel  30 . The limit would be based on other considerations such as was described relative to signal mixer  50  of  FIG. 3 . 
     Also signal mixer  60  can be used for the case of mixing in response to a desired gain factor, which as stated previously as an example, may occur when a desired signal to noise ratio is being attempted but in which the channel may not have sufficient dynamic range for the desired gain factor. In such case signal X 1  would be placed on the input kernel mixer  30  that is shown as receiving signals X( 2 -N). The number of mixes would be controlled by signals C 1  and C 2  and others to obtain signal MN. For gains that have a fraction in addition to an integer such as 3.5, one of the inputs is 0.5X 1 . 
     Various changes and modifications to the embodiments herein chosen for purposes of illustration will readily occur to those skilled in the art. For example, other functional circuits may used to implement various features than those disclosed. Additionally other uses of a mixing kernel may be implemented as well as other benefits than those disclosed may arise. To the extent that such modifications and variations do not depart from the spirit of the invention, they are intended to be included within the scope thereof which is assessed only by a fair interpretation of the following claims.