Abstract:
In a wave shape generator of the memory reading type, a waveshape memory stores sample values of a wave each value being represented by an integral address. A coefficient memory stores coefficients for nth order interpolation. Unknown intermediate sample values not stored in the wave shape memory represented by non-integral addresses and are approximated by multiplication of stored sample values of the waveshape and corresponding coefficient values on the basis of nth order interpolation. Use of the interpolation method assures smoothness of the wave shape with respect to time and thereby minimizes quantization noise while permitting use of relatively small memories.

Description:
BACKGROUND OF THE INVENTION 
     The present invention relates to a wave shape generator for electronic musical instruments, and more particularly relates to improvement in a wave shape memory in which a certain wave shape stored in a wave shape memory is read out by periodical address signals in order to produce a wave shape signal to be used for generation of a corresponding musical tone. 
     In an electronic musical instrument, a wave shape generator having one or more wave shape memories is used for generation of musical tone wave shapes and envelope wave shapes. The wave shape generator outputs musical tone wave shapes upon receipt of frequency information from the associated frequency information memory. 
     In the case of the conventional wave shape generator of the above-described type, only the integer part of the accumulated value of the frequency information is utilized as the read-out address signal for the wave shape memory. This partial utilization of the given information naturally leads to low accuracy of read-out address signals with respect to the time axis and a large amount of quantization noise in the obtained musical tone wave. 
     In order to avoid the above-described disadvantages, it is necessary to increase the address shifting speed and to enlarge the data storing capacity of the memories. 
     SUMMARY OF THE INVENTION 
     It is one object of the present invention to provide a wave shape generator having a compact memory yet assuring high accuracy of read-out wave shape with respect to the time axis. 
     It is the other object of the present invention to provide a wave shape generator of a compact size yet able to produce musical tone wave shapes with minimum quantization noise. 
     In accordance with the present invention, both the integer part and the fractional part are used as read-out address signals, the former being for wave shape memory addressing and the latter being for the coefficient memory. Sample values from the wave shape memory are multiplied by corresponding coefficient values from the coefficient memory for production of unknown intermediate sample values on the basis of an interpolation method. 
    
    
     DESCRIPTION OF THE DRAWINGS 
     FIG. 1 is a block diagram showing the construction of a conventional wave shape generator for electronic musical instruments, 
     FIG. 2 is a graph for showing an example of a musical tone wave shape to be stored in the wave shape memory, 
     FIG. 3 is a graph for showing an example of an envelope wave shape to be outputted from an envelope wave shape generator, 
     FIG. 4 is a graph for showing another example of the musical tone wave shape to be stored in the wave shape memory, 
     FIG. 5 is a block diagram showing the construction of one embodiment of the wave shape generator in accordance with the present invention, and 
     FIG. 6 is a timing chart for clock pulse signals used in the wave shape generator shown in FIG. 5. 
    
    
     DESCRIPTION OF THE PREFERRED EMBODIMENT 
     One typical example of the conventional electronic musical instructment of a wave memory reading type is shown in FIG. 1, in which a keyboard circuit 1 outputs a logic value &#34;1&#34; to one of its output lines when a corresponding key is operated on the associated keyboard. For the sake of simplicity of explanation, a monophonic instrument is herein disclosed. The keyboard circuit 1 is provided with a single tone selecting circuit (not shown) which has the function of singling out one tone when two or more keys are operated simultaneously on the keyboard. One typical example of such a single tone selecting circuit is disclosed in the U.S. Pat. No. 3,981,217 to Oya issued on Sep. 21, 1976. The keyboard circuit 1 is generative of a key-on signal which designates key operation on one of the keys in the keyboard. 
     The output lines of the keyboard circuit 1 are coupled to corresponding input terminals of a frequency information memory 2 which stores frequency information F, each of which corresponds to the tonal pitch of a corresponding key. Consequently, when a key is operated, frequency datum F corresponding to the tonal pitch of that key is read out from the frequency information memory 2. The output terminal of the frequency information memory 2 is coupled to an input terminal of an accumulator 3. 
     Upon receipt of a series of clock pulse signals φ, the accumulator 3 accumulates frequency data F sequentially outputted from the frequency information memory 2 and outputs sequentially the integer part I of the accumulated values qF (q=1, 2, 3,---) as read-out address signals. The output terminal of the accumulator 3 is coupled to the input side of a musical tone wave shape generator including a wave shape memory 4. 
     The wave shape memory 4 is provided with a number of addresses each of which stores a sample value fi(i=0, 1, 2, 3,---) of a desired musical tone wave shape such as the one shown in FIG. 2. Consequently, upon receipt of address signals I from the accumulator 3, the wave shape memory 4 reads out sample values fi stored in addresses corresponding to the given address signals I in order to output a musical tone wave shape MV constructed by the read-out sample values fi. This musical tone wave shape MV is passed to a multiplier 5. 
     Concurrently with the above-described process, an envelope wave shape generator 6 outputs to multiplier 5 an envelope wave shape signal EV upon receipt of a key-on signal KON from the keyboard circuit 1. 
     Thus the musical tone wave shape MV from the wave shape memory 4 and the envelope wave shape EV from the generator 6 are multiplied to each other by the multiplier 5, whereby a proper tone volume envelope is given to the musical tone wave. After this multiplication, the resultant complete wave is passed to a sound system 7 for generation of a desired musical tone. The sound system 7 comprises a tone volume controller, amplifiers and loud speakers. 
     One example of an envelope wave shape that might be outputted by the envelope wave shape generator 6 is shown in FIG. 3. Selection of the envelope wave shape to be multiplied to the musical tone wave shape is carried out by player&#39;s operation of tone color selection switches provided on the operation panel of the musical instrument. 
     As is clear from the foregoing description, the read-out address signal to be outputted from the accumulator 3 is representative only of the integer part I of the corresponding accumulated value qF, while disregarding the fractional part of the same at all. In other words, the musical tone wave shapes MW outputted from the wave shape memory 4 are more or less quantized with respect to time, and such quantization seriously degrades the smoothness of the musical tone wave shapes with respect to the time axis. 
     In addition, the sample values fi stored in the addresses of the wave shape memory 4 are not continuous with each other but discontinuous from each other as shown in FIG. 2. Therefore, the musical tone wave shapes MW to be read out from the wave shape memory 4 by the corresponding address signals I in general include a large amount of quantization noise. 
     In order to avoid the above-described disadvantages, it is required to increase the address shifting speed of the wave shape memory 4 and to increase the number of addresses in the wave shape memory 4. In this way, the musical tone wave shapes can be divided very finely and the large number of sample values so obtained can be distributed into the increased number of addresses in the wave shape memory 4. However, this solution inevitably requires enlarging the wave shape memory. 
     As described already, the present invention contemplates the provision of a wave shape generator with a very compact wave shape memory yet assuring good smoothness in the generated musical tone wave shape and minimizing the quantization noises. 
     The present invention is based on a principle in which an unknown sample value between two neighboring given sample values is estimated (calculated) and thus generated via the interpolation method on the basis of the sequential sample values actually stored in the addresses (0, 1, 2, ---, I, ---, m) of the wave shape memory. 
     The above-described interpolation method will hereinafter be explained in more detail, taking a third order interpolation using a third order polynomial as an example. 
     The following third order interpolation method contemplates theoretical estimation of an unknown sample value f(I+e) (where 0&lt;e&lt;1) which should be located between the address I and the address (I+1) in FIG. 4 but is not stored in the wave shape memory 4. The interpolation method starts with determining a third order curve F(x) which passes through the four sample values f(I), f(I+1), f(I+2) and f(I+3) stored in the addresses I, (I+1), (I+2) and (I+3), respectively. On the assumption that the sample values between the given sample values f(I) and f(I+1) can be given by this third order curve F(x), the value f(I+e) of the third order curve F(x) at x=I+e is regarded as an approximate sample value f(I+e). The above-described third order curve F(x) is determined in the following manner. 
     The third order equation F(x) is provisionally formularized as follows: 
     
         F(x)=A.sub.0 X.sup.3 +A.sub.1 X.sup.2 +A.sub.2 X+A.sub.3   (1) 
    
     As the curve represented by the above-described third order equation F(x) passes through the four sample values f(I) through f(I+3), the following four equations are obtained. Here, the address I of the third order equation F(x) is taken (for simplicity) as the origin, at which x=0. ##EQU1## 
     The above-described four equations are represented by the following matrix equation: 
     
         f=Xa                                                       (3) 
    
     where ##EQU2## 
     The above-described matrix equation (3) is represented by the following equation when an inverted matrix X -1  is employed. 
     
         A=X.sup.-1 f                                               (4) 
    
     By substituting x=(x 3  x 2  ×1) into equation (1), the following equation (5) is obtained: 
     
         F(x)=xa                                                    (5) 
    
     By substituting the equation (4) into the equation (5), the following equation (6) is obtained: 
     
         F(x)=xX.sup.-1 f                                           (6) 
    
     The inverted matrix X -1  is given by the following equation (7): ##EQU3## 
     By substituting the equation (7) into the equation (6), the latter is rearranged as follows: 
     
         F(x)=A.sub.0 (x)·f(I)+A.sub.1 (x)·f(I+1)+A.sub.2 (x)·f(I+2)+A.sub.3 (x)·f(I+3)           (8) 
    
     where ##EQU4## 
     By making x=e in the equation (8), the sample value f(e), which is not stored in the wave shape memory 4, can be approximately given by the following equation (10); 
     
         f(e)=F(e)=A.sub.0 (e)·f(I)+A.sub.1 (e)·f(I+1)+A.sub.2 (e)·f(I+2)+A.sub.3 (e)·f(I+3)           (10) 
    
     In practice, the unknown sample value f(I+e) as shown in FIG. 4 can be obtained by the following process which is designed on the basis of the above-described equation (10). 
     As a first step, the four sample values f(I), f(I+1), f(I+2) and f(I+3) shown in FIG. 4 and stored in the successive four addresses are sequentially read out from the wave shape memory 4. 
     As a second step, an additional memory is provided which stores coefficient values A 0  (e) to A 3  (e) for various values of &#34;e&#34; and the coefficient values A 0  (e) to A 3  (e) are read out from the additional memory. 
     As the third step, calculation is carried out in accordance with the above-described equation (10), using the sample values f(I) to f(I+3) and the coefficient values A 0  (e) to A 3  (e) in order to estimate the unknown sample value f(I+e) located between the given values f(I) and f(I+1). 
     When estimation of unknown sample values is to be carried out via an n-th order interpolation method, the process is substantially similar to that of the above-described third order interpolation method, in which process the equation (10) is defined as the basis for the n-th order interpolation. 
     In the case of n-th order interpolation method, n+1 successive sample values f(I),f(I+1), - - -,f(I+n) are read out from the wave shape memory by time division method. Concurrently with this process, n+1 coefficient values A 0  (e), A 1  (e) - - - An(e) (where 0&lt;e&lt;1) are read out from the coefficient memory in accordance with the value of &#34;e&#34; by time division method. In a multiplier, the sample values f(I+p) (where p=0, 1, 2, - - -, n) from the wave shape memory and the coefficient values A k  (e) (where k=0, 1, 2, - - -, n) from the coefficient memory are multiplied by each other by time division method, and the multiplied values A k  (e)·f(I+p) are sequentially accumulated in order to estimate the sample values not stored in the wave shape memory as follows: ##EQU5## 
     An embodiment of the wave shape generator in accordance with the present invention is shown in FIG. 5, in which parts and signals substantially similar to those used in the construction shown in FIG. 1 are designated with similar reference numerals and symbols. Operation of this wave shape generator will be described with reference to the case in which estimation of unknown sample values is carried out via the third order interpolation method. 
     In the construction shown in FIG. 5, the output terminal of the frequency information memory 2 is coupled to the input terminal of an accumulator 10. The accumulation command terminal T of the accumulator 10 receives a series of clock pulse signals φ 1 , and causes the count of qF (where q=1, 2, 3, . . . in accumulator 10 to increase by F each time a new clock pulse signal φ 1  is applied thereto. The accumulator 10 generates a signal I=0, 1, 2 . . . on its output A indicating the number of times its stored count qF has reached its maximum storage capability. This may be referred to as the integer part I. Accumulator 10 further generates a signal on its fractional part output B indicative of the instantaneous count qF in accumulator 10. 
     The above-described integer part output terminal A of the accumulator 10 is coupled to input terminal C1 counter 11 whose command terminal T receives a series of clock pulse signals φ 2  and whose count input terminal C2 received clock pulse signals φ 4 . The output terminal of the counter 11 is coupled, via a wave shape memory 12, to the first input terminal of a multiplier 13. 
     The above-described fractional part output terminal B of the accumulator 10 is coupled to the first input terminal A&#39; of a coefficient memory 22 whose second input terminal B&#39; is coupled to the output terminal of a counter 21. The clock pulse signals φ 2  are applied to the reset terminal R of the counter 21 while the clock pulse signals φ 4  are applied to the count input terminal C. The output terminal of the coefficient memory 22 is coupled to the second input terminal of the above-described multiplier 13. 
     The wave shape memory 12 stores a number of sample values fi (where i=1, 2, 3, . . . , m) of a musical tone wave shape such as the one shown in FIG. 4. In the case of this sample value storage by the wave shape memory, there is no need for fine division of the musical tone wave shape, and therefore the wave shape memory 12 can be very compact in construction. 
     The coefficient memory 22 stores four coefficient values A 0  (e), A 1  (e), A 2  (e) and A 3  (e) in accordance with the value of e. The coefficient memory 22 receives as address signals the signal e which is indicative of the instantaneous fractional count in the accumulator 10 and also receives as an address signal a count value k from the counter 21. As noted above, the values A 0  (e), A 1  (e), A 2  (e) and A 3  (e) are to be read out of coefficient memory 22. The address e defines the particular intermediate value e which is to be read out of the memory while the count value determines which coefficient value (i.e., A 0 , A 1 , A 2  or A 3 ) from the above coefficient value from the above-described coefficient values is to be used out of memory. Then, in accordance with the address e generated by accumulator 10 and the address generated by counter 21, coefficient memory 22 outputs a coefficient value A k  (e) to the multiplier 13. For example, when a count value k=0 is applied to the second input terminal B&#39;, a coefficient value A 0  (e) is nominated in the coefficient memory 22, and when the fractional part e=0.5 is applied to the first input terminal A&#39;, a coefficient value A 0  (0.5) is outputted from the coefficient memory 22. Here, since no high accuracy is required for operation of the coefficient memory 22, it can be very compact in construction. 
     The output side of the multiplier 13 is coupled to an accumulator 14. The clear terminal CL of the accumulator 14 receives of the clock pulse signals φ 2  whereas the accumulation command terminal T of the accumulator 14 receives a series of clock pulse signals φ 3 . The output terminal of the accumulator 14 is coupled to the input terminal of the multiplier 5 via a latching circuit 15. The latch command terminal L of the latching circuit 15 receives of the clock pulse signals φ 1 . 
     The clock pulse signals φ 1  through φ 4  are generated in the sequence shown in FIG. 6. 
     Operation of the above-described wave shape generator is as follows. 
     When a certain key is operated, a frequency datum F corresponding to the tonal pitch of the operated key is read out from the frequency information memory 2, which is accumulated by the accumulator 10 at the input timings of the clock pulse signals φ 1 . 
     At a time t 1  (see FIG. 6), a clock pulse signal φ 1  is applied to the accumulation command terminal T of the accumulator 10, which thereupon accumulates the frequency datum F and produces an accumulated value qF (q=1). The integer part I of the accumulated value qF(q=1) is outputted from the first output terminal A and the fractional part e thereof is outputted from the second output terminal B. 
     At time t 2 , a clock pulse signal φ 2  is applied to input terminal T of the counter 11, which thereupon takes in the integer part I of the accumulated value qF(q=1) from the accumulator 10 and outputs this value as a count value I which is used as a read-out address signal for the wave shape memory 12. Upon receipt of this count value I, the wave shape memory 12 outputs a sample value f I  stored at the address I. 
     Concurrently with the above-described process, the clock pulse signal φ 2  is also applied to the reset terminal R of the counter 21, thereby resetting the counter 21. The counter 21 reads out a count value k=0. Thus, the coefficient memory 22 receives the fractional part e of the accumulated value qF (q=1) from the accumulator 10 and the count value k=0 as an address signal from the counter 21. This combination of input causes the first coefficient value A 0  (e) to be singled out from the four coefficient values A 0  (e) through A 3  (e) stored in the coefficient memory 22 and passed to the multiplier 13. The multiplier 13 multiplies the sample value f I  from the wave shape memory 12 by the coefficient value A 0  (e) from the coefficient memory 22 in order to output a wave shape signal A 0  (e).f I . Simultaneously with this, the clock pulse signal φ 2  is applied to the clear terminal CL of the accumulator 14 in order to clear the latter. 
     At a timing t 3 , a clock pulse signal φ 3  is inputted to the accumulator command terminal T of the accumulator 14, which thereupon accumulates the above-described wave shape signal A 0  (e).f I . Since the accumulator 14 has already been cleared by the clock pulse signal φ 2  at the timing t 2 , the accumulated value thereof is A 0  (e)·f I . 
     At time t 4 , a clock pulse signal φ 4  is applied to the count input terminal C2 of the counter 11, which thereupon shifts the count value from I to (I+1). In FIG. 5, the count value by the clock pulse signal φ 4  is designated by &#34;p&#34;. This count value (I+1) is applied to the wave shape memory 12 as a new address signal, whereupon the wave shape memory 12 reads out a sample value f(I+1) stored in the address (I+1). 
     Concurrently with this process, the clock pulse signal φ 4  is applied to the count input terminal C of the counter 21, in which the count value k shifts from 0 to 1. Upon receipt of the fractional part e of the accumulated value qF, (q=1) from the accumulator 10 and the count value k=1 from the counter 21, the coefficient memory 22 outputs the second coefficient value A 1  (e) which is singled out from the four coefficient values A 0  (e) through A 3  (e) corresponding to the value of the fractional part e. The multiplier 13 multiplies the sample value f.sub.(I+1) from the wave shape memory 12 by the coefficient value A 1  (e) from the coefficient memory 22 to output a wave shape signal A 1  (e)·f.sub.(I+1). 
     Further at time t 4 , a clock pulse signal φ 3  is applied to the accumulation command terminal T of the accumulator 14, whereupon the latter accumulates the above-described wave shape signal A 1  (e)·f.sub.(I+1), producing an accumulated value {A 0  (e)·f.sub.(I) +A 1  (e)·f.sub.(I+1) }. 
     Similarly, at time t 5 , the counter 11 shifts its count value from (I+1) to (I+2) upon receipt of a clock pulse signal φ 4  and outputs the shifted count value (I+2) as a new read-out address signal for the wave shape memory 12. Upon receipt of this address signal (I+2), the wave shape memory 12 outputs the sample value f.sub.(I+2) stored at its address (I+2). Concurrently, the counter 21 shifts the count value k from 1 to 2 upon receipt of the clock pulse signal φ 4  and outputs the shifted count value k=2 as new read-out address signal for the coefficient memory 22. Upon receipt of this address signal k=2, the coefficient memory 22 outputs the third coefficient value A 2  (e). The multiplier 13 multiplies the sample value f.sub.(I+2) from the wave shape memory 12 by the coefficient value A 2  (e) from the coefficient memory 22 to output a wave shape signal A 2  (e)·f.sub.(I+2). Upon receipt of a clock pulse signal φ 3  at the timing t 5 , the accumulator 14 accumulates the above-described wave shape signal A 2  (e)·f.sub.(I+2) to produce an accumulated value {A 0  (e)·f.sub.(I) +A 1  (e)·f.sub.(I+1) +A 2  (e)·f.sub.(I+2) }. 
     At time t 6 , the counter 11 shifts its count value from (I+2) to (I+3) upon receipt of a clock pulse signal φ 4  and outputs the shifted count value (I+3) as a new readout address signal for the wave shape memory 12. Upon receipt of this address signal (I+3), the wave shape memory 12 outputs the sample value f.sub.(I+3) stored in the address (I+3). Concurrently, the counter 21 shifts its count value k from 2 to 3 upon receipt of the clock pulse signal φ 4  and outputs the shifted count value k=3 as a new readout address signal for the coefficient memory 22. Upon receipt of this address signal k=3, the coefficient memory 22 outputs the fourth coefficient value A 3  (e). The multiplier 13 multiplies the sample value f.sub.(I+3) from the wave shape memory 12 and the coefficient value A 3  (e) from the coefficient memory 22 to output a wave shape signal A 3  (e)·f.sub.(I+3). Upon receipt of a clock pulse signal φ 3  at time t 6 , the accumulator 14 accumulates the above-described wave shape signal A 3  (e)·f.sub.(I+3) to produce an accumulated value {A 0  (e)·f.sub.(I) +A 1  (e)·f.sub.(I+1) +A 2  (e)·f.sub.(I+2) +A 3  (e)·f.sub.(I+3) }. 
     At the next time t 1 , a clock pulse signal φ 1  is produced and applied to the latch command terminal L of the latching circuit 15, which thereupon latches the above-described wave shape signal {A 0  (e)·f.sub.(I) +A 1  (e)·f.sub.(I+1) +A 2  (e)·f.sub.(I+2) +A 3  (e)·f.sub.(I+3) } from the accumulator 15. The resultant wave shape signal is multiplied by a proper envelope wave shape EV at the multiplier 5 and passed to the sound system 7, which uses it to generate a corresponding musical tone. 
     Concurrently with the above-described process, the clock pulse signal φ 1  is applied to the accumulation command terminal T of the accumulator 10, which thereupon restarts accumulation of the frequency information F outputted by the frequency information memory 2. The integer part I of the new accumulated value of qF (where q=2) is passed to the counter 11 and the fractional part e of the same is passed to the coefficient memory 22. The above-described sequence of operations at times t 1  through t 6  ensues. 
     In the case of the above-described embodiment, the third order interpolation method is used for obtaining the unknown intermediate sample values. However, it should be noted that the above-described embodiment is applicable to estimation of unknown intermediate sample values via the n-th order interpolation also. In such a case, (n+1) sets of coefficient values are stored in the coefficient memory 22 and (n+1) sets of sample values are read out from the wave shape memory 12. 
     Although the foregoing explanation refers to generation of musical tones only, the present invention can advantageously be applied to generation of envelope wave shapes also. 
     As the present invention is based on the principle of the mathematical interpolation method, use of a wave shape memory of a compact construction also assures smoothness of the read-out wave shape with respect to and assures generation of wave shapes with greatly reduced quantization noise.