Discrete cosine transformation circuit

Abstract: The present invention has an object to provide a high-speed discrete cosine transformation circuit. In this structure, the one-dimensional input signals x(0) to x(7) are input in parallel to the positive input terminals "+" or the negative input terminals "-" of eight neural operation units (NOU) 11 to 18 through capacitors d0 to d6. In each NOU 11 to 18, input signals x(0) to x(7) are added and subtracted: x(0) to x(7) are multiplied beforehand by the coefficient in proportion to the capacities of capacitors d0 to d6 which are connected to NOU 11 to 18. Thereafter, discrete cosine transforming coefficients y(0) to y(7) are output. A two-dimensional descrete cosine transformation circuit is realized by using the one-dimensional descrete cosine transforming circuit.

Description: FIELD OF THE INVENTION The present invention relates to a discrete cosine transformation circuit (DCT circuit). BACKGROUND OF THE INVENTION Discrete cosine transformation (DCT) is one kind of orthogonal transformation. It is a signal processing method used more widely now that multimedia processing has developed recently. Especially in the field of image processing discrete cosine transformations based standards like JPEG and MPEG are used with increasing importance. DCT is usually implemented by digital circuits or software. Document WO-A-9016039 discloses a neural network to carry out vector-matrix multiplication by using two sets of weighting capacitors in each neuron model and differential input non linear amplifiers. Document US-A-4156284 discloses an apparatus to carry out vector-matrix multiplication by using a plurality of switched capacitors. SUMMARY OF THE INVENTION When DCT is executed by software, high-speed processing is difficult, although proprietary hardware is not requisite. When proprietary hardware is used, high-speed processing is possible, but only with extra hardware requiring many multiplication circuits and address and the quantity of hardware is large. In many cases the analog input signal must be converted to a digital one. The present invention has an object to provide a discrete cosine transformation circuit for high-speed discrete cosine transformation with less hardware requisite and with an analog input signal. To achieve the foregoing object, the linear discrete cosine transformation circuit of the present invention includes: I) a number N of signal input means for receiving N points of analog input signals, and II) a number N of operation units comprising: i) a first and second inverting amplifier; ii) a first, second and third capacitor, each having a capacity corresponding to the coefficients for a discrete cosine transformation, two positive and negative input terminals and an output terminal, with the first capacitor provided between an input and output of the first inverting amplifier, the second capacitor provided between an output of the first inverting amplifier and an input of the second inverting amplifier, and the third capacitor provided between an input and an output of the second inverting amplifier; iii) two positive and negative input terminals connected to an input of the first and second inverting amplifier in the operation unit, respectively; and iv) an output terminal. A two dimensional discrete cosine transformation circuit of the present invention includes a number N of linear discrete cosine transformation circuits to each of which is input one of the number N of rows or columns of input signals in parallel, as mentioned above, and the N output signals of each of said number N of linear discrete cosine transformation circuits is input in parallel to one of a number N of linear discrete cosine transformation circuits in such a way to input in parallel the outputs corresponding to the identical rows or columns of the inputs of said number N of linear discrete cosine transformation circuits. Another two dimensional discrete cosine transformation circuit of the present invention includes the above-mentioned first discrete cosine transformation circuit for receiving a number N of rows or columns of signals in parallel, a secondary memory device for storing outputs of the above first discrete cosine transformation circuit row by row, and a second linear discrete cosine transformation circuit for receiving the signals read out column by column from the secondary memory device. Another two dimensional discrete cosine transformation circuit of the present invention besides the two mentioned above includes: i) a first switching circuit having first and second input terminals, each receiving a number N of input signals, and a first switching circuit having an output terminal for outputting a number N of output signals; ii) a one-dimensional discrete cosine transformation circuit as above mentioned with an input connected to an output terminal of the first switching circuit; iii) a second switching circuit having an input terminal to connect with an output of the one-dimensional discrete cosine transformation circuit as well as first and second output terminals, each able to output a number N of signals; and iv) a two-dimensional memory means for storing signals input from the first output terminal of the second switching circuit to each row, wherein a number N of rows or columns of signal sources are connected to the first input terminal of the first switching circuit, and signals read out by column from the two-dimensional memory means are connected to the second input terminal of the first switching circuit. The invention will be carried out according to appended claim 1. BRIEF DESCRIPTION OF THE DRAWINGS Fig. 1 (a) and (b) show diagrams of the neural operation units used in the present invention. Fig. 2 shows a diagram of the one-dimensional discrete cosine transformation circuit of the first embodiment of the present invention. Fig. 3 shows a diagram of the two-dimensional discrete cosine transformation circuit of the second embodiment of the present invention. Fig. 4 shows a diagram of a variation of the two-dimensional discrete cosine transformation circuit of the present invention. Fig. 5 shows a diagram of another variation of the two-dimensional discrete cosine transformation circuit of the present invention. PREFERRED EMBODIMENT OF THE PRESENT INVENTION Fig. 1 (a) shows the structure of neural operation unit (NOU) 10 used in the discrete cosine transformation circuit of the present invention. In this figure, 1 and 2 are input terminals for inputting analog voltage signals, 3 is an output terminal, 4 and 5 are inverting amplifiers, and 7 and 8 are capacitors having identical capacities, with the capacity of each assumed to be C0. The input of inverting amplifier 4 is connected to input terminal 1, and the output of inverting amplifier 4 is connected to an input of inverting amplifier 5 through capacitor 7. Input terminal 2 is connected to the input of inverting amplifier 5, its output being connected to output terminal 3. Capacitor 6 is provided between the input and output of inverting amplifier 4, and capacitor 8 is provided between the input and output of inverting amplifier 5. Inverting amplifiers 4 and 5 include CMOS inverters connected in serial by an odd number of stages and other components. The working mechanism of neural operation unit 10 having the above structure is described with reference to Fig. 1 (b), which shows neural operation unit 10 with three input voltages applied. As shown, voltages V1 and V2 are applied to input terminal 1 through capacitors C1 and C2, respectively, and voltage V3 is applied to input terminal 2 through capacitor C3. Point A on the input of inverting amplifier 4 is connected to the capacitors C0, C1 and C2, and to an n-type MOSFET and a p-type MOSFET gate electrodes which are included in the first-stage CMOS inverter of inverting amplifier 4. Point A is floating, as is point B. If all the electric charges stored in capacitors 6, 7, 8, C1, C2 and C3 are 0, the total quantity stored in the capacitors is 0 based on the principle of conservation of charge with reference to points A and B, even when input voltages V1, V2 and V3 are applied. Consequently, formulas of conservation of charge (1) and (2) at points A and B, respectively, pertain. C1(V1-Vb)+C2(V2-Vb)+C0(Va-Vb)=0 C0(Va-Vb)+C3(V3-Vb)+C0(Vout-Vb)=0 Here, Vb is the electric potential on points A and B, and Va is the electric potential of the output of inverting amplifier 4. The electric potential Vb of points A and B is usually set to be 1/2 of the supply voltage applied to inverting amplifiers 4 and 5. When inverting amplifiers 4 and 5 are driven by +Vdd and the grounded potential, the Vb is +(1/2)Vdd, and when inverting amplifiers 4 and 5 are driven by positive and negative supply voltages, respectively, it is 0 volts. Formula (3) can be derived from formulas (1) and (2): C1(V1-Vb)+C2(V2-Vb)-C3(V3-Vb)-C0(Vout-Vb)=0 When the electric potentials in formula (3) correspond to the potentials on reference Vb as V(1) =V1-Vb , V(2)=V2-Vb , V(3)=V3-Vb , Vo=Vout-Vb , formula (3) can be expressed by formula (4): Vo = C 1 C 0 V (1) + C 2 C 0 V (2) - C 3 C 0 V (3) Formula (4) means that V(1) and V(2) for inputting to input terminal 1 are added, and V(3) for inputting to input terminal 2 is subtracted. Input voltages V(1), V(2) and V(3) are output after being multiplied by the values corresponding to the ratios of C0 provided in neural operation unit 10 and the respective connected capacitors C1, C2 and C3. The operations above are performed at an extremely high speed in a time span approximately equal to the delay time from input to output of inverting amplifiers 4 and 5. The circuit of NOU is realized as an integrated circuit of a semiconductor. Determining the capacities of the capacitances according to conductor areas makes them remarkably accurate, enabling accurate operation results. Since its voltage alone drives the neural operation unit, electric power consumption is quite low. The discrete cosine transformation circuit of the present invention uses the above neural operation unit as its operation unit. Next, the one-dimensional discrete cosine transformation circuit of the first embodiment of the present invention is described. The one-dimensional discrete cosine transformation on point N of the first dimensional signal x(k) is defined by formula (5): When it is assumed that C(m,k)=cos(kπ/m) through one cycle of operation, formula (5) can be simplified into formula (6). This is the example when N=8. y (1)= 1 2 {x(0)C(16,1)+x(1)C(16,3)+x(2)C(16,5)+x(3)C(16,7) -x(4)C(16,7)-x(5)C(16,5)-x(6)C(16,3)-x(7)C(16,1)} y (2) = 1 2 {x(0)C(8,1)+x(1)C(8,3)-x(2)C(8,3)-x(3)C(8,1) -x(4)C(8,1)-x(5)C(8,3)+x(6)C(8,3)+x(7)C(8,1)} y (3) = 1 2 {x(0)C(16,3)-x(1)C(16,7)-x(2)C(16,1)-x(3)C(16,5) +x(4)C(16,5)+x(5)C(16,1)+x(6)C(16,7)-x(7)C(16,3)} y (4) = 1 2 2 {x(0)-x(1)-x(2)+x(3)+x(4)-x(5)-x(6)+x(7) y (5) = 1 2 {x(0)C(16,5)-x(1)C(16,1)+x(2)C(16,7)+x(3)C(16,3) -x(4)C(16,3)-x(5)C(16,7)+x(6)C(16,1)-x(7)C(16,5)} y (6) = 1 2 {x(0)C(8,3)-x(1)C(8,1)+x(2)C(8,1)-x(3)C(8,3) -x(4)C(8,3)+x(5)C(8,1)-x(6)C(8,1)+x(7)C(8,3)} y (7) = 1 2 {x(0)C(16,7)-x(1)C(16,5)+x(2)C(16,3)-x(3)C(16,1) +x(4)C(16,1)-x(5)C(16,3)+x(6)C(16,5)-x(7)C(16,7)} Using the neural operation unit described above, the one-dimensional discrete cosine transformation circuit of the first embodiment performs the operations in formulas (6) to (13) in parallel. Fig. 2 shows the structure of the one-dimensional discrete cosine transformation circuit on eight points of N. In Fig. 2, 11 to 18 are the neural operation units mentioned above, d0 to d6 are capacitors, and x(0) to x(7) are one-dimensional input signals. As shown, matrices are formed by the wiring connected to the one-dimensional input signals x(0) to x(7), and to positive input terminals "+" and negative input terminals "-" of neural operation units 11 to 18. Capacitors d0 to d6 are connected to the cross points of the wiring. The "+" and "-" correspond to input terminals 1 and 2 in Fig. 1. Capacitors d0 to d6 are formed so as to possess the capacities in formulas (14) to (20) when the capacity of the capacitors in neural operation units 11 to 18 is C0: d 0 = 1 2 2 C 0 d 1 = C (16,1) 2 C 0 = cos(π/16) 2 C 0 d 2 = C (16,3) 2 C 0 = cos(3π/16) 2 C 0 d 3 = C (16,5) 2 C 0 = cos(5π/16) 2 C 0 d 4 = C (16,7) 2 C 0 = cos(7π/16) 2 C 0 d 5 = C (8,1) 2 C 0 = cos(π/8) 2 C 0 d 6 = C (8,3) 2 C 0 = cos(3π/8) 2 C 0 In this structure, the one-dimensional input signals x(0) to x(7) are input in parallel to the positive input terminals "+" and the negative input terminals "-" of eight neural operation units (NOU) 11 to 18 through capacitors d0 to d6 connected to the cross points of the matrices. In each NOU 11 to 18, input signals x(0) to x(7) are added and subtracted: x(0) to x(7) are multiplied beforehand by the coefficient determined by capacities of capacitors d0 to d6 which are connected to NOU 11 to 18. Thereafter, discrete cosine transforming coefficients y(0) to y(7) are output. All input signals x(0) to x(7) are input to the positive input terminal of NOU 11 through capacitor d0. The operation in formula (6) above is performed in NOU 11. Similarly, the operations in formulas (7) to (13) are performed in NOU 12 to 18, respectively, and then discrete cosine transforming coefficients y(1) to y(7) are output from NOU 12 to 18, respectively. The discrete cosine transformation on eight points is performed by the structure in Fig. 2. Any number of points on the first dimensional discrete cosine transformation circuit can be defined; it is not limited to eight. N number of points of discrete cosine transformation can be performed in parallel in N number of neural operation circuits by the one-dimensional discrete cosine transformation circuit of the present invention. Each neural operation circuit has an operation time approximately identical to the propagation delay time of the inverting amplifier mentioned above. This enables high-speed operation of the one-dimensional discrete cosine transformation. As each neural operation unit includes two inverting amplifiers as mentioned, of which usually includes three steps of CMOS inverters, the one-dimensional discrete cosine transformation circuit can be realized with only 48 CMOS inverters and 88 capacitors. Consequently, the quantity of hardware is small. The two-dimensional discrete cosine transformation circuit of the second embodiment of the present invention is as follows. The two-dimensional discrete cosine transformation is defined by formula (21): The two-dimensional discrete cosine transformation can be decomposed into two one-dimensional discrete cosine transformations independent of the variables i and j respectively. First, the one-dimensional discrete cosine transformation is performed with respect to i(j) as shown in formula (22) and then with respect to j(i) as shown in formula (23): These two operations reduce the number of operations Fig. 3 shows the structure of the two-dimensional discrete cosine transformation circuit of the second embodiment. The circuit performs two dimensional discrete cosine transformations on 8 rows x 8 columns of data. In Fig. 3, 20 to 35 represent the one-dimensional discrete transformation circuits shown in Fig. 2. High-speed two-dimensional discrete cosine transformations can be performed by eight first discrete cosine transformation circuits 20 to 27 doing one-dimensional cosine transformations in column direction, and by the other eight first discrete cosine transformation circuits 28 to 35 doing such transformations in row-direction. Eight inputs from x(0,0) to x(7,0), x(0,1) to x(7,1), ..., x(0,7) to x(7,7) are input to one-dimensional discrete cosine transformation circuits 20 to 27, respectively, and one-dimensional discrete cosine transformation is performed in each circuit. Then, first dimensional discrete cosine transforming coefficients t(0,0) to t(7,0), t(0,1) to t(7,1), ..., t(0,7) to t(7,7) are output from circuits 20 to 27, respectively. Thereafter, coefficients belonging to the identical row of one-dimensional discrete cosine transforming coefficients t(0,0) to t(7,7) are input to one-dimensional discrete cosine transformation circuits 28 to 35 in such manner that coefficients t(7,0) to t(7,7) are input to first discrete cosine transformation circuit 28, and coefficients t(6,0) to t(6,7) are input to circuit 29. With reference to fig. 4 Number 42 shows a buffer and D/A converting circuit for inputting one row of image data in sequence in such manner as to read data from x(0,0) to x(0,7) first, x(1,0) to x(1,7) second, and successively on to x(7,0) to x(7,7), converting the data from digital to analog and outputting it to one-dimensional cosine transformation circuit 43. Number 43 shows a one-dimensional discrete cosine transformation circuit for performing discrete cosine transformation on the one-row image data converted into analog data input from the buffer and D/A converting circuit 42. Its structure is similar to that in Fig. 2. Number 44 shows an analog memory for storing output from one-dimensional discrete cosine transformation circuit 43, including a two-dimensional analog shift register, for example. Number 45 shows a one-dimensional discrete cosine transformation circuit for reading in column direction the one-dimensional discrete cosine coefficients stored in analog memory 44 and performing one-dimensional discrete cosine transformation. It has the same structure as that in Fig. 2. In the two-dimensional DCT circuit having the above structure, data x(0,0) to x(0,7) on the 0-order row in the 8x8 8-bit digital image data stored in digital memory 41 is read out into the buffer and D/A converting circuit 42, and each is the, converted into an analog voltage signal. The image data signal of one row converted into the analog voltage signal in the buffer and D/A converting circuit 42 is supplied in parallel to one-dimensional DCT circuit 43, which then performs in parallel the one-dimensional discrete cosine transformation. Conversion result outputs t(0,0) to t(0,7) are written in analog memory 44. Digital image data of the first row x(1,0) to x(1,7) stored in digital memory 41 is input to the buffer and D/A converting circuit 42, the one-dimensional discrete cosine conversion is performed in DCT circuit 43, and results t(1,0) to t(1,7) are stored in analog memory 44. Similarly, digital image data in digital memory 41 are successively input to the buffer and D/A converting circuit 42 row by row, and the one-dimensional discrete cosine conversion is performed in one-dimensional DCT circuit 43. The results are successively stored in analog memory 44, and the results after performing the row by row one-dimensional discrete cosine conversions are stored in analog memory 44, as shown in Fig. 4. Data stored in analog memory 44 is read out by column by column in column direction and supplied to one-dimensional DCT circuit 45. That is, 0-order column data t(0,0) to t(0,7) among the data in analog memory 44 is read out and supplied to one-dimensional DCT circuit 45 and the first degree discrete cosine transformation performed. This DCT circuit 45 performs the first discrete cosine transformation in column direction, and two-dimensional discrete cosine conversion coefficients from y(0,0) to y(0,7) are output from first degree DCT circuit 45. First column data from t(1,0) to t(1,7) is read out from analog memory 44 and the one-dimension cosine conversion performed in one-dimension DCT circuit 45. The two-dimensional discrete cosine conversion coefficients from y(1,0) to y(1,7) are next output from the outputs of one-dimensional DCT circuit 45. Similarly, data in column direction is read out and processed successively in one-dimensional DCT circuit 45. Results of the two-dimensional discrete cosine conversions are then successively output from the outputs of one-dimensional DCT circuit 45. Though the time requisite for the two-dimensional discrete cosine conversion increases, the quantity of hardware in this embodiment is small. Fig. 5 shows the embodiment with legs hardware than that of the embodiment in Fig. 4. The quantity of the hardware of the embodiment is smaller by switch-using a single one-dimensional DCT circuit from input to output and from output to input. The structure is formed because one-dimensional DCT circuits 43 and 45 do not work at the same time in Fig. 4. In Fig. 5, 41, 42 and 44, respectively, are the digital memory buffer and D/A converting circuit and analog memory identical to those in Fig. 4. Number 50 is the one-dimensional DCT circuit exactly like that in Fig. 2, and 46 and 47 are switching circuits for switching the input and the output, respectively, for this DCT circuit 50. In the two-dimensional DCT circuit with the above structure, switching circuit 46 is initially set so that data from side A is output and switching circuit 47 so that the supplied data is output to side D. In this configuration, similar to that in Fig. 4, image data stored in digital memory 41 is sequentially read out by one row into the buffer and D/A converting circuit 42, and the signal, now converted into analog, is applied to one-dimensional circuit 50 through switching circuit 46. The output signal, having had the one-dimensional discrete cosine conversion performed in row direction in one-dimensional DCT circuit 50, is output from side D of switching circuit 47 and sequentially stored in analog memory 44. After completing the one-dimensional discrete cosine conversion with respect to the 8x8 image data in digital memory 41, the resulting data undergoes the one-dimensional discrete cosine conversion in analog memory 44 and is stored there in row direction. Then, the signal read out from analog memory 44 is switched so as to be input to one-dimensional DCT circuit 50 by switching circuit 46 to side B, and simultaneously, the output of one-dimensional DCT circuit 50 is switched so as to be output to the outside by switching circuit 47 to side C. As above, after setting switching circuits 46 and 47, data is read out column by column from analog memory 44, input to one-dimensional DCT circuit 50 through switching circuit 46 and the one-dimensional discrete cosine conversion performed in column direction. The resulting signal of the two-dimensional discrete cosine conversion is output in sequence from one-dimensional DCT circuit 50 through an output terminal of switching circuit 47. This embodiment decreases the amount of needed hardware. The discrete cosine transformation circuit of the present invention enables high-speed one- and two-dimensional discrete cosine conversions with minimal hardware.

Claims: A one-dimensional discrete cosine transformation circuit for generating an output of discrete cosine transformation (y(0) to y(7)) from a number N of input voltages wherein N is a positive integer and wherein said one-dimensional discrete transformation circuit comprises: N signal input means for receiving N analog input signals (x(0) to x(7)); a number N of operational units (NOU) each of which comprising: i) a positive input terminal (1); ii) a negative input terminal (2); iii) an output terminal (3); iv) a first inverting amplifier (4) having an input and an output, said input being connected to said positive input terminal (1); v) a first feedback capacitance (6) connected between said input and said output of said first inverting amplifier; vi) an intermediate capacitance (7) having an input and an output; vii) said input being connected to said output of said first inverting amplifier (4); viii) a second inverting amplifier (5) having an input and an output, said input being connected to said output of said intermediate capacitance (7), said output being connected to said output terminal (3); and ix) a second feedback capacitance (8) connected between said input and said output of said second inverting amplifier; and a plurality of capacitances (d0 to d6) corresponding to said input voltages each of which is connected between one of said input voltages and one of said positive and negative terminals, and wherein said capacitances (d0 to d6) having capacities according to coefficients of said discrete cosine transformation. A two-dimensional discrete cosine transformation circuit for performing NxN points two-dimensional discrete cosine transformation of N x N points input signal, comprising: i) a number N of said one-dimensional descrete cosine transformation circuits (20 to 27) as claimed in claim 1, each receiving N input signals in parallel corresponding to one row or one column of said N x N points input signal and performing a one-dimensional discrete cosine transform on said N input signals and outputting N one dimensional discrete cosine transformed signals (t(0,0) to t(7,7)), and ii) a number N of said one-dimensional cosine transformation circuits (28, 35) as claimed in claim 1, each receiving the output from said number N of one-dimensional discrete cosine transformation circuits (20, 27), said one dimensional discrete cosine transformed signals ((0,0) to t(7,7)) corresponding to the identical row or column. A two-dimensional discrete cosine transformation circuit for performing NxN points two-dimensional discrete cosine transformation of a N x N points input signal, comprising: i) a first one-dimensional cosine transformation circuit as claimed in claim 1 (43), for receiving N input signals in parallel corresponding to one row or one column of said N x N points input signal and performing a one-dimensional discrete cosine transform on said N input signals and outputting N one dimensional discrete cosine transformed signals (t(0,0) to t(7,7)); ii) a two-dimensional memory means (44) for storing in each row the N output (t(0,0) to t(7,7)) of said one-dimensional discrete cosine transformation circuit as claimed in claim 1; and iii) a second one-dimensional discrete cosine transformation circuit (45) as claimed in claim 1 for receiving signals read out by column from said two-dimensional memory means (44) and for carrying out a second one dimensional discrete cosine transform. A two-dimensional cosine transformation circuit for performing NxN points two-dimensional discrete cosine transformation of N x N points input signal comprising: i) a first switching circuit (46) having a first (A) and second (B) input terminal, each receiving a number N of input signals, and also having an output terminal for outputting a number N of output signals; ii) a one-dimensional discrete cosine transforming circuit (50) as claimed in claim 1 having input connected to said output terminal of said first switching circuit (46); iii) a second switching circuit (47) having input terminal connected with said output of said one-dimensional discrete cosine transformation circuit (50), and having a first (C) and second (D) output terminal each with the ability to output a number N of signals; and iv) a two-dimensional memory means (44) for storing signals input from said first output terminal (D) of said second switching circuit (47) by column, wherein N input signals of said N x N points input signal are input row by row to said first input terminal (A) of said first switching circuit (46), and signals read out by column from said two-dimensional memory means (44) are input to said second input terminal (B) of said first switching circuit (46).

Inventors: CHEN JIE, SHOU GUOLIANG, TAKATORI SUNAO, ZHOU CHANGMING
Applicants: SHARP KK, YOZAN INC, SHARP KABUSHIKI KAISHA, YOZAN INC.
Application year: 1997
Main classification: G06F17
IPC codes: G06G7, G06F17