Method and device for calculating frequency domain amplitude and phase angle in memristor array

By calculating the cosine and sinusoidal mixed signals in the memristor array, and calculating the current data using a discrete Fourier transform matrix, and finally reading the frequency point information through the phase detector and the peak detector, the problem of being unable to directly calculate the amplitude and phase in the prior art is solved, and efficient frequency domain amplitude phase angle calculation is achieved.

CN119673247AActive Publication Date: 2025-03-21TSINGHUA UNIVERSITY

Patent Information

Application Number
CN202411494874.7
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-10-24
Publication Date
2025-03-21
Estimated Expiration
2044-10-24

AI Technical Summary

Technical Problem

The prior art cannot directly calculate the amplitude and phase of the signal without adding additional hardware overhead and computing delay, affecting the efficiency of the calculation of the amplitude phase angle of the frequency domain.

Method used

By obtaining the time domain input signal of the target memristor array, and computing the cosine mixing signal and the sinusoidal mixing signal based on the time domain input signal, the preset cosine signal and the sinusoidal signal. These signals are then applied to the corresponding row lines of the memristor array, the current data is calculated using a discrete Fourier transform matrix, and finally the phase information and amplitude information of each frequency point are read through the phase detector and the peak detector.

Benefits of technology

It realizes the direct obtaining of the amplitude and phase of each frequency point of the signal in the analog domain, greatly reducing energy efficiency and operation delay, and improving the efficiency of the amplitude phase angle calculation in the frequency domain.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119673247A_ABST
    Figure CN119673247A_ABST
Patent Text Reader

Abstract

The invention relates to a calculation method and device for an intermediate frequency domain amplitude phase angle in a memristor array, and the method comprises the steps: obtaining a time domain input signal corresponding to a target memristor array, and calculating a cosine frequency mixing signal and a sine frequency mixing signal based on the time domain input signal, a preset cosine signal and a preset sine signal; respectively applying the cosine frequency mixing signal and the sine frequency mixing signal to corresponding row lines of the target memristor array so as to calculate cosine current data and sine current data based on discrete Fourier transform matrixes of the corresponding row lines; and obtaining current information of each frequency point in the target memristor array based on the cosine current data and the sine current data, and reading phase information and amplitude information corresponding to each frequency point in the current information through a preset phase discriminator and a peak detector. Therefore, the problems that in the prior art, the amplitude and the phase cannot be directly calculated under the condition that extra hardware overhead and operation delay are not increased, and the frequency domain amplitude phase angle calculation efficiency is greatly affected are solved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the technical field of memristor arrays, and in particular to a method and device for calculating frequency domain amplitude phase angle in a memristor array. Background Art

[0002] Time-frequency transform is the most commonly used signal analysis method in the field of signal processing. Researchers can obtain richer information by observing the amplitude and phase of each frequency point of the signal.

[0003] At present, the time-frequency transformation of discrete signals can be completed by using memristor arrays. The basic principle is as follows: Figure 1 As shown, the discrete Fourier transform matrix is ​​stored in the form of conductance values ​​on the memristor array (the real matrix and the imaginary matrix need to be split when mapping). The real part Re(x) and the imaginary part Im(x) of the input signal x are simultaneously input to the row lines of the memristor array, and the real part Re(y) and the imaginary part Im(y) of the result y after time-frequency transformation are output on the column lines, where the real part is calculated as Re(y)=Re(x)Re(W)-Im(x)Im(W), and the imaginary part is calculated as Im(y)=Re(x)Im(W)+Im(x)Re(W) (for simplicity, the positive and negative elements in the parameter matrix are not considered); in fact, in order to map a parameter matrix containing both positive and negative numbers, a memristor array of twice the size needs to be used to represent the parameter matrix in differential form. Generally, one memristor array is used to represent one parameter matrix (the elements can be positive or negative), as shown in FIG. Figure 2 shown.

[0004] However, current work can only calculate the real and imaginary values ​​of each frequency point, and cannot directly calculate the amplitude and phase, making it difficult to intuitively obtain spectrum information; existing technologies can also introduce digital circuits to obtain amplitude and phase, but they need to complete complex square sum, square root, and trigonometric function calculations in the digital domain, which incurs additional hardware overhead and computational delays.

[0005] In summary, the existing technology cannot directly calculate the amplitude and phase without adding additional hardware overhead and computing delay, which greatly affects the efficiency of frequency domain amplitude and phase angle calculation and needs to be solved urgently. Summary of the invention

[0006] The present application provides a method and device for calculating the frequency domain amplitude and phase angle in a memristor array to solve the problem that the prior art cannot directly calculate the amplitude and phase without adding additional hardware overhead and calculation delay, which greatly affects the efficiency of frequency domain amplitude and phase angle calculation.

[0007] The first aspect of the present application provides a method for calculating the frequency domain amplitude phase angle in a memristor array, comprising the following steps: obtaining a time domain input signal corresponding to a target memristor array, and calculating a cosine mixing signal and a sine mixing signal based on the time domain input signal, a preset cosine signal and a sine signal; applying the cosine mixing signal and the sine mixing signal to the corresponding row lines of the target memristor array, respectively, to calculate cosine current data corresponding to the cosine mixing signal and sine current data corresponding to the sine mixing signal based on a discrete Fourier transform matrix of the corresponding row lines; obtaining current information of each frequency point in the target memristor array based on the cosine current data and the sine current data, and reading the phase information and amplitude information corresponding to each frequency point in the current information through a preset phase detector and a peak detector, respectively.

[0008] Optionally, in one embodiment of the present application, the time domain input signal corresponding to the target memristor array is obtained, and based on the time domain input signal, a preset cosine signal and a sine signal, a cosine mixing signal and a sine mixing signal are calculated, including: inputting the real part and the imaginary part of the time domain input signal of the target memristor array into a preset digital-to-analog converter to generate an analog voltage signal corresponding to the time domain input signal; inputting the analog voltage signal into a preset mixer to generate a mixing signal corresponding to the time domain input signal; generating the cosine signal and the sine signal by a preset cosine wave generator and a sine wave generator, and multiplying the mixing signal with the cosine signal and the sine signal, respectively, to obtain the cosine mixing signal and the sine mixing signal.

[0009] Optionally, in one embodiment of the present application, the cosine mixing signal and the sine mixing signal are applied to the corresponding row lines of the target memristor array respectively to calculate the cosine current data corresponding to the cosine mixing signal and the sine current data corresponding to the sine mixing signal based on the discrete Fourier transform matrix of the corresponding row lines, including: applying the cosine mixing signal to the upper half of the row lines of the target memristor array through a preset multiplexer, and obtaining the discrete Fourier transform matrix of the upper half of the row lines. conversion matrix; multiplying the cosine mixing signal with the negative of the real matrix and the imaginary matrix of the discrete Fourier transform matrix of the upper half of the row lines respectively to obtain the cosine current data; applying the sine mixing signal to the lower half of the row lines of the target memristor array through the multiplexer, and obtaining the discrete Fourier transform matrix of the lower half of the row lines; multiplying the sine mixing signal with the real matrix and the imaginary matrix of the discrete Fourier transform matrix of the lower half of the row lines respectively to obtain the sine current data.

[0010] Optionally, in one embodiment of the present application, the current information of each frequency point in the target memristor array is obtained based on the cosine current data and the sinusoidal current data, and the phase information and amplitude information corresponding to each frequency point in the current information are read through a preset phase detector and a peak detector respectively, including: obtaining the current information of each frequency point based on the cosine current data, the sinusoidal current data and a preset Kirchhoff's current law; extracting the target coefficient through the current information, and transmitting the current information to a preset transimpedance amplifier to generate a voltage signal corresponding to the current information; inputting the voltage signal into the phase detector and the peak detector to read the phase information and the amplitude information corresponding to each frequency point in the target coefficient.

[0011] The second aspect of the present application provides a device for calculating the frequency domain amplitude phase angle in a memristor array, including: an acquisition module, used to acquire a time domain input signal corresponding to a target memristor array, and calculate a cosine mixing signal and a sine mixing signal based on the time domain input signal, a preset cosine signal and a sine signal; an application module, used to apply the cosine mixing signal and the sine mixing signal to the corresponding row lines of the target memristor array, respectively, so as to calculate the cosine current data corresponding to the cosine mixing signal and the sine current data corresponding to the sine mixing signal based on the discrete Fourier transform matrix of the corresponding row lines; a reading module, used to obtain the current information of each frequency point in the target memristor array based on the cosine current data and the sine current data, and read the phase information and amplitude information corresponding to each frequency point in the current information through a preset phase detector and a peak detector, respectively.

[0012] Optionally, in one embodiment of the present application, the acquisition module includes: a first generating unit, used to input the real part and the imaginary part of the time domain input signal of the target memristor array into a preset digital-to-analog converter to generate an analog voltage signal corresponding to the time domain input signal; a second generating unit, used to input the analog voltage signal into a preset mixer to generate a mixed signal corresponding to the time domain input signal; and a third generating unit, used to generate the cosine signal and the sine signal through a preset cosine wave generator and a sine wave generator, and multiply the mixed signal with the cosine signal and the sine signal respectively to obtain the cosine mixed signal and the sine mixed signal.

[0013] Optionally, in one embodiment of the present application, the application module includes: a first allocation unit, used to apply the cosine mixing signal to the upper half of the row lines of the target memristor array through a preset multiplexer, and obtain the discrete Fourier transform matrix of the upper half of the row lines; a first calculation unit, used to multiply the cosine mixing signal with the negative of the real matrix and the imaginary matrix of the discrete Fourier transform matrix of the upper half of the row lines, respectively, to obtain the cosine current data; a second allocation unit, used to apply the sine mixing signal to the lower half of the row lines of the target memristor array through the multiplexer, and obtain the discrete Fourier transform matrix of the lower half of the row lines; a second calculation unit, used to multiply the sine mixing signal with the real matrix and the imaginary matrix of the discrete Fourier transform matrix of the lower half of the row lines, respectively, to obtain the sine current data.

[0014] Optionally, in one embodiment of the present application, the reading module includes: a third calculation unit, used to obtain the current information of each frequency point based on the cosine current data, the sinusoidal current data and a preset Kirchhoff's current law; an extraction unit, used to extract the target coefficient through the current information, and transmit the current information to a preset transimpedance amplifier to generate a voltage signal corresponding to the current information; an input unit, used to input the voltage signal into the phase detector and the peak detector to read the phase information and the amplitude information corresponding to each frequency point in the target coefficient.

[0015] The third aspect of the present application provides an electronic device, comprising: a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the program to implement the method for calculating the frequency domain amplitude phase angle of a memristor array as described in the above embodiment.

[0016] The fourth aspect of the present application provides a computer-readable storage medium, which stores a computer program. When the program is executed by a processor, it implements the method for calculating the frequency domain amplitude phase angle of the memristor array as described above.

[0017] The fifth aspect of the present application provides a computer program product, including a computer program, which is executed to implement the above-mentioned method for calculating the frequency domain amplitude phase angle in the memristor array.

[0018] Therefore, the embodiments of the present application have the following beneficial effects:

[0019] The embodiment of the present application can obtain the time domain input signal corresponding to the target memristor array, and calculate the cosine mixing signal and the sine mixing signal based on the time domain input signal, the preset cosine signal and the sine signal; respectively apply the cosine mixing signal and the sine mixing signal to the corresponding row line of the target memristor array, and calculate the cosine current data corresponding to the cosine mixing signal and the sine current data corresponding to the sine mixing signal based on the discrete Fourier transform matrix of the corresponding row line; based on the cosine current data and the sine current data, obtain the current information of each frequency point in the target memristor array, and read the phase information and amplitude information corresponding to each frequency point in the current information through the preset phase detector and the peak detector. The present application only needs to introduce a small number of hardware units to directly obtain the amplitude and phase of each frequency point of the signal in the analog domain, which greatly reduces energy efficiency and operation delay. Thus, the problem that the prior art cannot directly calculate the amplitude and phase without adding additional hardware overhead and operation delay, which greatly affects the efficiency of frequency domain amplitude phase angle calculation, etc.

[0020] Additional aspects and advantages of the present application will be given in part in the description below, and in part will become apparent from the description below, or will be learned through the practice of the present application. BRIEF DESCRIPTION OF THE DRAWINGS

[0021] The above and / or additional aspects and advantages of the present application will become apparent and easily understood from the following description of the embodiments in conjunction with the accompanying drawings, in which:

[0022] Figure 1 A schematic diagram of a discrete Fourier transform based on a memristor array when the positive and negative elements of the parameter matrix are not considered, provided in one embodiment of the present application;

[0023] Figure 2 A schematic diagram of a discrete Fourier transform based on a memristor array when considering positive and negative elements of a parameter matrix is ​​provided for one embodiment of the present application;

[0024] Figure 3 A flow chart of a method for calculating frequency domain amplitude phase angle in a memristor array provided according to an embodiment of the present application;

[0025] Figure 4 A schematic diagram of the logic architecture of a method for calculating frequency domain amplitude phase angle in a memristor array provided in one embodiment of the present application;

[0026] Figure 5 A hardware circuit diagram of a method for calculating frequency domain amplitude phase angle in a memristor array provided in one embodiment of the present application;

[0027] Figure 6 A schematic diagram of a phase detector circuit provided for one embodiment of the present application;

[0028] Figure 7 A schematic diagram of a peak detection circuit provided for one embodiment of the present application;

[0029] Figure 8 is an exemplary diagram of a device for calculating frequency domain amplitude and phase angle in a memristor array according to an embodiment of the present application;

[0030] Fig. 9 A schematic diagram of the structure of an electronic device provided in an embodiment of the present application.

[0031] Among them, 10 is a device for calculating the frequency domain amplitude and phase angle in the memristor array, 100 is an acquisition module, 200 is an application module, 300 is a reading module, 901 is a memory, 902 is a processor, and 903 is a communication interface. DETAILED DESCRIPTION

[0032] Embodiments of the present application are described in detail below, and examples of the embodiments are shown in the accompanying drawings, wherein the same or similar reference numerals throughout represent the same or similar elements or elements having the same or similar functions. The embodiments described below with reference to the accompanying drawings are exemplary and are intended to be used to explain the present application, and should not be construed as limiting the present application.

[0033] The following describes the method and device for calculating the frequency domain amplitude phase angle in the memristor array of the embodiment of the present application with reference to the accompanying drawings. In view of the problems mentioned in the above background technology, the present application provides a method for calculating the frequency domain amplitude phase angle in the memristor array, in which the time domain input signal corresponding to the target memristor array is obtained, and the cosine mixing signal and the sine mixing signal are calculated based on the time domain input signal, the preset cosine signal and the sine signal; the cosine mixing signal and the sine mixing signal are applied to the corresponding row lines of the target memristor array respectively, and the cosine current data corresponding to the cosine mixing signal and the sine current data corresponding to the sine mixing signal are calculated based on the discrete Fourier transform matrix of the corresponding row line; based on the cosine current data and the sine current data, the current information of each frequency point in the target memristor array is obtained, and the phase information and amplitude information corresponding to each frequency point in the current information are read respectively by the preset phase detector and the peak detector. The present application only needs to introduce a small number of hardware units to directly obtain the amplitude and phase of each frequency point of the signal in the analog domain, which greatly reduces energy efficiency and operation delay. This solves the problem that the existing technology cannot directly calculate the amplitude and phase without adding additional hardware overhead and calculation delay, which greatly affects the efficiency of frequency domain amplitude and phase angle calculation.

[0034] Specifically, Figure 3 A flow chart of a method for calculating frequency domain amplitude phase angle in a memristor array provided in an embodiment of the present application.

[0035] like Figure 3As shown, the method for calculating the frequency domain amplitude phase angle in the memristor array includes the following steps:

[0036] In step S301, a time domain input signal corresponding to the target memristor array is obtained, and a cosine mixing signal and a sine mixing signal are calculated based on the time domain input signal, a preset cosine signal and a sine signal.

[0037] The embodiment of the present application can first obtain the time domain input signal x corresponding to the memristor array, and combine the cosine signal and the sine signal generated by the cosine wave generator and the sine wave generator to calculate the cosine mixing signal and the sine mixing signal.

[0038] The memristor array of the embodiment of the present application includes but is not limited to the following structure:

[0039] 1. Use different types of memristors (such as resistive random access memory, phase change memory, magnetic random access memory, etc.);

[0040] 2. Use in-memory computing crossbar arrays of other memory types (such as SRAM arrays, DRAM arrays, FLASH arrays, etc.);

[0041] 3. Use storage and computing integrated architectures or units with different structures (such as 1T1R, 2T2R, 2T1R, etc.).

[0042] Optionally, in one embodiment of the present application, a time domain input signal corresponding to the target memristor array is obtained, and based on the time domain input signal, a preset cosine signal and a sine signal, a cosine mixing signal and a sine mixing signal are calculated, including: inputting the real part and the imaginary part of the time domain input signal of the target memristor array into a preset digital-to-analog converter to generate an analog voltage signal corresponding to the time domain input signal; inputting the analog voltage signal into a preset mixer to generate a mixing signal corresponding to the time domain input signal; generating a cosine signal and a sine signal by a preset cosine wave generator and a sine wave generator, and multiplying the mixing signal with the cosine signal and the sine signal respectively to obtain a cosine mixing signal and a sine mixing signal.

[0043] During the actual implementation process, the embodiments of the present application can input the real part Re(x) and the imaginary part Im(x) of the input time domain input signal x into a digital-to-analog converter (DAC) to convert them into corresponding analog voltage signals, and pass the analog voltage signals to a mixer to generate a mixed signal.

[0044] Afterwards, if Figure 4As shown, the embodiments of the present application can multiply the mixing signal with the cosine signal cos wt generated by the cosine wave generator and the sine signal sin wt generated by the sine wave generator, respectively, to obtain cosine mixing signals Re(x)cos wt and Im(x)cos wt corresponding to the cosine signal, and sine mixing signals Re(x)sin wt and Im(x)sin wt corresponding to the sine signal.

[0045] Therefore, the embodiment of the present application calculates the cosine mixing signal and the sine mixing signal corresponding to the time domain input signal, thereby providing a reliable data basis for the subsequent calculation of the frequency domain amplitude and phase angle.

[0046] In step S302, the cosine mixing signal and the sine mixing signal are respectively applied to the corresponding row lines of the target memristor array to calculate the cosine current data corresponding to the cosine mixing signal and the sine current data corresponding to the sine mixing signal based on the discrete Fourier transform matrix of the corresponding row lines.

[0047] Furthermore, the embodiments of the present application also need to apply the cosine mixing signal and the sine mixing signal to the corresponding row lines of the target memristor array, and combine the discrete Fourier transform strategy to calculate the cosine current data corresponding to the cosine mixing signal and the sine current data corresponding to the sine mixing signal.

[0048] Optionally, in one embodiment of the present application, a cosine mixing signal and a sine mixing signal are respectively applied to corresponding rows of a target memristor array to calculate cosine current data corresponding to the cosine mixing signal and sine current data corresponding to the sine mixing signal based on a discrete Fourier transform matrix of the corresponding row lines, including: applying the cosine mixing signal to the upper half of the row lines of the target memristor array through a preset multiplexer, and obtaining the discrete Fourier transform matrix of the upper half of the row lines; multiplying the cosine mixing signal by the negative of the real matrix and the imaginary matrix of the discrete Fourier transform matrix of the upper half of the row lines to obtain cosine current data; applying the sine mixing signal to the lower half of the row lines of the target memristor array through a multiplexer, and obtaining the discrete Fourier transform matrix of the lower half of the row lines; multiplying the sine mixing signal by the real matrix and the imaginary matrix of the discrete Fourier transform matrix of the lower half of the row lines to obtain sine current data.

[0049] It should be noted that, under the control of the signal BL_sw[1:N], the embodiment of the present application can apply the above-obtained cosine mixing data to the row lines of the upper half of the memristor array through the MUX at the BL end; then, the embodiment of the present application can combine the cosine mixing data with the real part matrix G of the discrete Fourier transform matrix stored on the array based on Ohm's law and Kirchhoff's current law. real , the negative of the imaginary matrix - G img Multiply, such as Figure 5 As shown, the corresponding SL current calculation result, ie, the cosine current data Re(y)cos wt, can be obtained at this time.

[0050] Similarly, under the control of the signal BL_sw[1:N], the embodiment of the present application can also apply the above-obtained sinusoidal mixing data to the row lines of the lower half of the memristor array through the multiplexer (MUX) at the BL end; then, the embodiment of the present application can combine the sinusoidal mixing data with the imaginary matrix G of the discrete Fourier transform matrix stored in the array based on Ohm's law and Kirchhoff's current law. img , real matrix G real Multiply, such as Figure 5 As shown, the corresponding SL current calculation result, that is, the sinusoidal current data Im(y)sin wt, can be obtained at this time.

[0051] In step S303, the current information of each frequency point in the target memristor array is obtained based on the cosine current data and the sine current data, and the phase information and amplitude information corresponding to each frequency point in the current information are read through a preset phase detector and a peak detector respectively.

[0052] Afterwards, the embodiment of the present application can calculate the current information of each frequency point in the memristor array according to the cosine current data and the sine current data, and read the phase information and amplitude information corresponding to each frequency point in the current information through the phase detector and the peak detector respectively.

[0053] Optionally, in one embodiment of the present application, based on cosine current data and sine current data, current information of each frequency point in the target memristor array is obtained, and the phase information and amplitude information corresponding to each frequency point in the current information are read through a preset phase detector and a peak detector, respectively, including: obtaining the current information of each frequency point based on the cosine current data, the sine current data and the preset Kirchhoff's current law; extracting the target coefficient through the current information, and transmitting the current information to a preset transimpedance amplifier to generate a voltage signal corresponding to the current information; inputting the voltage signal into the phase detector and the peak detector to read the phase information and amplitude information corresponding to each frequency point in the target coefficient.

[0054] Specifically, the embodiment of the present application can calculate the final full array complete output result based on the cosine current data and the sine current data, combined with Kirchhoff's current law:

[0055] Re(y)cos wt+Im(y)sin wt (1)

[0056] For a single frequency point y, the above formula can be written as:

[0057] Re(y)cos wt+Im(y)sin wt (2)

[0058] Here, y represents a single frequency point, not the entire output vector y.

[0059] Furthermore, the embodiment of the present application can derive the target coefficient based on the trigonometric formula: Then formula (2) can be rewritten as:

[0060]

[0061] Furthermore, formula (2) can also be written as:

[0062]

[0063] in,

[0064]

[0065]

[0066] Therefore, the final formula (2) can be written as:

[0067]

[0068] Based on formula (7), it can be seen that each frequency point calculated by the memristor array contains amplitude information Therefore, the embodiment of the present application can directly read the amplitude information of each frequency point through the peak detector. This is consistent with the definition of phase. Therefore, each frequency point calculated by the memristor array also contains phase information θ. Therefore, the embodiment of the present application can also directly read out the phase information of each frequency point by the phase detector (ie, phase detector).

[0069] In the actual operation process, Figure 5 As shown, the MUX at the WL end is controlled by the signal WL_sw[1:M], which transmits all the signals V_WL[1:M] to the array, controlling all WLs to be turned on. At this time, the MUX at the SL end is controlled by the signal SL_sw[1:M], which transmits the current signal on the SL to the transimpedance amplifier (TIA), where the current signal is converted into a voltage signal, and then sent to the phase detector and peak detector to obtain the amplitude spectrum (amplitude) and phase spectrum (phase) of the signal directly in the analog domain.

[0070] A typical phase detector circuit and a peak detection circuit are introduced below in conjunction with the accompanying drawings to help those skilled in the art understand the execution process of the method for calculating the frequency domain amplitude phase angle in the memristor array of the present application.

[0071] Figure 6 Figure 1 is a schematic diagram of the phase detector circuit. Figure 6 As shown, under the control of the clock CLK, the phase detector counts the proportion of high level and low level in half a cycle to obtain a phase value.

[0072] Figure 7 Figure 1 is a schematic diagram of a peak detection circuit. Figure 7 As shown in the figure, the peak detection circuit is controlled by a diode, and the upper plate of the capacitor can only charge but cannot discharge the charge; therefore, after one cycle, the voltage U across the capacitor is out That means input U in The peak value of the frequency point is obtained.

[0073] It should be noted that, in the specific implementation process, those skilled in the art can design or select a suitable phase detector circuit and peak detection circuit according to actual conditions, and no specific limitation is made here.

[0074] According to the method for calculating the frequency domain amplitude phase angle in the memristor array proposed in the embodiment of the present application, by obtaining the time domain input signal corresponding to the target memristor array, and based on the time domain input signal, the preset cosine signal and the sine signal, the cosine mixing signal and the sine mixing signal are calculated; the cosine mixing signal and the sine mixing signal are respectively applied to the corresponding row lines of the target memristor array, and the cosine current data corresponding to the cosine mixing signal and the sine current data corresponding to the sine mixing signal are calculated based on the discrete Fourier transform matrix of the corresponding row lines; based on the cosine current data and the sine current data, the current information of each frequency point in the target memristor array is obtained, and the phase information and amplitude information corresponding to each frequency point in the current information are read respectively by the preset phase detector and the peak detector. The present application only needs to introduce a small number of hardware units to directly obtain the amplitude and phase of each frequency point of the signal in the analog domain, which greatly reduces energy efficiency and operation delay.

[0075] Next, a device for calculating frequency domain amplitude and phase angle in a memristor array according to an embodiment of the present application is described with reference to the accompanying drawings.

[0076] Figure 8 It is a block diagram of a device for calculating frequency domain amplitude and phase angle in a memristor array according to an embodiment of the present application.

[0077] like Figure 8 As shown, the device 10 for calculating the frequency domain amplitude and phase angle in the memristor array includes: an acquisition module 100 , an application module 200 and a reading module 300 .

[0078] The acquisition module 100 is used to acquire a time domain input signal corresponding to the target memristor array, and calculate a cosine mixing signal and a sine mixing signal based on the time domain input signal, a preset cosine signal and a sine signal.

[0079] The application module 200 is used to apply the cosine mixing signal and the sine mixing signal to the corresponding row lines of the target memristor array respectively, so as to calculate the cosine current data corresponding to the cosine mixing signal and the sine current data corresponding to the sine mixing signal based on the discrete Fourier transform matrix of the corresponding row lines.

[0080] The reading module 300 is used to obtain the current information of each frequency point in the target memristor array based on the cosine current data and the sine current data, and read the phase information and amplitude information corresponding to each frequency point in the current information through a preset phase detector and a peak detector respectively.

[0081] Optionally, in one embodiment of the present application, the acquisition module 100 includes: a first generation unit, a second generation unit and a third generation unit.

[0082] The first generating unit is used to input the real part and the imaginary part of the time domain input signal of the target memristor array into a preset digital-to-analog converter to generate an analog voltage signal corresponding to the time domain input signal.

[0083] The second generating unit is used to input the analog voltage signal into a preset mixer to generate a mixed signal corresponding to the time domain input signal.

[0084] The third generating unit is used to generate a cosine signal and a sine signal by a preset cosine wave generator and a sine wave generator, and multiply the mixing signal by the cosine signal and the sine signal respectively to obtain a cosine mixing signal and a sine mixing signal.

[0085] Optionally, in one embodiment of the present application, the applying module 200 includes: a first distributing unit, a first calculating unit, a second distributing unit and a second calculating unit.

[0086] The first allocation unit is used to apply the cosine mixing signal to the upper half of the rows of the target memristor array through a preset multiplexer, and obtain the discrete Fourier transform matrix of the upper half of the rows.

[0087] The first calculation unit is used for multiplying the cosine mixing signal with the real matrix and the negative number of the imaginary matrix of the discrete Fourier transform matrix of the upper half of the row lines to obtain cosine current data.

[0088] The second allocation unit is used to apply the sinusoidal mixing signal to the lower half of the row lines of the target memristor array through the multiplexer, and obtain the discrete Fourier transform matrix of the lower half of the row lines.

[0089] The second calculation unit is used to multiply the sinusoidal mixing signal with the real matrix and the imaginary matrix of the discrete Fourier transform matrix of the lower half of the row lines to obtain sinusoidal current data.

[0090] Optionally, in one embodiment of the present application, the reading module 300 includes: a third calculation unit, an extraction unit and an input unit.

[0091] The third calculation unit is used to obtain the current information of each frequency point based on the cosine current data, the sine current data and the preset Kirchhoff's current law.

[0092] The extraction unit is used to extract the target coefficient through the current information and transmit the current information to a preset transimpedance amplifier to generate a voltage signal corresponding to the current information.

[0093] The input unit is used to input the voltage signal to the phase detector and the peak detector to read the phase information and amplitude information corresponding to each frequency point in the target coefficient.

[0094] It should be noted that the above explanation of the embodiment of the method for calculating the frequency domain amplitude phase angle in the memristor array is also applicable to the device for calculating the frequency domain amplitude phase angle in the memristor array of this embodiment, and will not be repeated here.

[0095] According to the calculation device of the frequency domain amplitude phase angle in the memristor array proposed in the embodiment of the present application, it includes an acquisition module for acquiring the time domain input signal corresponding to the target memristor array, and calculating the cosine mixing signal and the sine mixing signal based on the time domain input signal, the preset cosine signal and the sine signal; an application module for respectively applying the cosine mixing signal and the sine mixing signal to the corresponding row lines of the target memristor array, so as to calculate the cosine current data corresponding to the cosine mixing signal and the sine current data corresponding to the sine mixing signal based on the discrete Fourier transform matrix of the corresponding row lines; a reading module for obtaining the current information of each frequency point in the target memristor array based on the cosine current data and the sine current data, and reading the phase information and amplitude information corresponding to each frequency point in the current information through the preset phase detector and the peak detector. The present application only needs to introduce a small number of hardware units to directly obtain the amplitude and phase of each frequency point of the signal in the analog domain, which greatly reduces energy efficiency and operation delay.

[0096] Fig. 9 A schematic diagram of the structure of an electronic device provided in an embodiment of the present application. The electronic device may include:

[0097] A memory 901 , a processor 902 , and a computer program stored in the memory 901 and executable on the processor 902 .

[0098] When the processor 902 executes the program, the method for calculating the frequency domain amplitude phase angle in the memristor array provided in the above embodiment is implemented.

[0099] Furthermore, the electronic device further comprises:

[0100] The communication interface 903 is used for communication between the memory 901 and the processor 902 .

[0101] The memory 901 is used to store computer programs that can be executed on the processor 902 .

[0102] The memory 901 may include a high-speed RAM memory, and may also include a non-volatile memory (non-volatile memory), such as at least one disk memory.

[0103] If the memory 901, the processor 902 and the communication interface 903 are implemented independently, the communication interface 903, the memory 901 and the processor 902 can be connected to each other through a bus and communicate with each other. The bus can be an Industry Standard Architecture (ISA) bus, a Peripheral Component Interconnect (PCI) bus or an Extended Industry Standard Architecture (EISA) bus. The bus can be divided into an address bus, a data bus, a control bus, etc. For ease of representation, Fig. 9 Only one thick line is used in the diagram, but this does not mean that there is only one bus or only one type of bus.

[0104] Optionally, in a specific implementation, if the memory 901, the processor 902 and the communication interface 903 are integrated on a chip, the memory 901, the processor 902 and the communication interface 903 can communicate with each other through an internal interface.

[0105] The processor 902 may be a central processing unit (CPU), or an application specific integrated circuit (ASIC), or one or more integrated circuits configured to implement the embodiments of the present application.

[0106] An embodiment of the present application further provides a computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the method for calculating the frequency domain amplitude phase angle of a memristor array as described above.

[0107] An embodiment of the present application further provides a computer program product, including a computer program, which, when executed, is used to implement the above-mentioned method for calculating the frequency domain amplitude phase angle in the memristor array.

[0108] In the description of this specification, the description with reference to the terms "one embodiment", "some embodiments", "example", "specific example", or "some examples" etc. means that the specific features, structures, materials or characteristics described in conjunction with the embodiment or example are included in at least one embodiment or example of the present application. In this specification, the schematic representations of the above terms do not necessarily refer to the same embodiment or example. Moreover, the specific features, structures, materials or characteristics described may be combined in any one or N embodiments or examples in a suitable manner. In addition, those skilled in the art may combine and combine the different embodiments or examples described in this specification and the features of the different embodiments or examples, without contradiction.

[0109] In addition, the terms "first" and "second" are used for descriptive purposes only and should not be understood as indicating or implying relative importance or implicitly indicating the number of technical features indicated. Therefore, a feature defined as "first" or "second" may explicitly or implicitly include at least one of the features. In the description of this application, "N" means at least two, such as two, three, etc., unless otherwise clearly and specifically defined.

[0110] Any process or method description in a flowchart or otherwise described herein may be understood to represent a module, fragment or portion of code comprising one or N executable instructions for implementing the steps of a custom logical function or process, and the scope of the preferred embodiments of the present application includes alternative implementations in which functions may not be performed in the order shown or discussed, including performing functions in a substantially simultaneous manner or in reverse order depending on the functions involved, which should be understood by technicians in the technical field to which the embodiments of the present application belong.

[0111] The logic and / or steps represented in the flowchart or otherwise described herein, for example, can be considered as an ordered list of executable instructions for implementing logical functions, and can be embodied in any computer-readable medium for use by an instruction execution system, device or apparatus (such as a computer-based system, a system including a processor, or other system that can fetch instructions from an instruction execution system, device or apparatus and execute instructions), or in combination with these instruction execution systems, devices or apparatuses. For the purpose of this specification, "computer-readable medium" can be any device that can contain, store, communicate, propagate or transmit a program for use by an instruction execution system, device or apparatus, or in combination with these instruction execution systems, devices or apparatuses. More specific examples of computer-readable media (a non-exhaustive list) include the following: an electrical connection with one or N wirings (electronic devices), a portable computer disk box (magnetic device), a random access memory (RAM), a read-only memory (ROM), an erasable and programmable read-only memory (EPROM or flash memory), a fiber optic device, and a portable compact disk read-only memory (CDROM). In addition, the computer-readable medium may even be paper or other suitable medium on which the program is printed, since the program may be obtained electronically by optically scanning the paper or other medium and then editing, interpreting or processing in other suitable ways as necessary and then storing it in a computer memory.

[0112] It should be understood that the various parts of the present application can be implemented by hardware, software, firmware or a combination thereof. In the above embodiment, the N steps or methods can be implemented by software or firmware stored in a memory and executed by a suitable instruction execution system. If implemented by hardware, as in another embodiment, it can be implemented by any one of the following technologies known in the art or their combination: a discrete logic circuit having a logic gate circuit for implementing a logic function for a data signal, a dedicated integrated circuit having a suitable combination of logic gate circuits, a programmable gate array (PGA), a field programmable gate array (FPGA), etc.

[0113] A person skilled in the art may understand that all or part of the steps in the method for implementing the above-mentioned embodiment may be completed by instructing related hardware through a program, and the program may be stored in a computer-readable storage medium, which, when executed, includes one or a combination of the steps of the method embodiment.

[0114] In addition, each functional unit in each embodiment of the present application may be integrated into a processing module, or each unit may exist physically separately, or two or more units may be integrated into one module. The above-mentioned integrated module may be implemented in the form of hardware or in the form of a software functional module. If the integrated module is implemented in the form of a software functional module and sold or used as an independent product, it may also be stored in a computer-readable storage medium.

[0115] The storage medium mentioned above may be a read-only memory, a magnetic disk or an optical disk, etc. Although the embodiments of the present application have been shown and described above, it can be understood that the above embodiments are exemplary and cannot be understood as limiting the present application. A person of ordinary skill in the art may change, modify, replace and modify the above embodiments within the scope of the present application.

Claims

1. A method for calculating frequency domain amplitude phase angle in a memristor array, characterized in that: The following steps are involved: Acquire a time domain input signal corresponding to the target memristor array, and calculate a cosine mixing signal and a sine mixing signal based on the time domain input signal, a preset cosine signal and a preset sine signal; Applying the cosine mixing signal and the sine mixing signal to corresponding row lines of the target memristor array respectively, so as to calculate cosine current data corresponding to the cosine mixing signal and sine current data corresponding to the sine mixing signal based on a discrete Fourier transform matrix of the corresponding row lines; Based on the cosine current data and the sine current data, the current information of each frequency point in the target memristor array is obtained, and the phase information and amplitude information corresponding to each frequency point in the current information are read through a preset phase detector and a peak detector respectively.

2. The method according to claim 1, characterized in that: The step of obtaining a time domain input signal corresponding to the target memristor array and calculating a cosine mixing signal and a sine mixing signal based on the time domain input signal, a preset cosine signal and a sine signal comprises: Inputting the real part and the imaginary part of the time domain input signal of the target memristor array into a preset digital-to-analog converter to generate an analog voltage signal corresponding to the time domain input signal; Inputting the analog voltage signal into a preset mixer to generate a mixed signal corresponding to the time domain input signal; The cosine signal and the sine signal are generated by a preset cosine wave generator and a preset sine wave generator, and the mixing signal is multiplied by the cosine signal and the sine signal respectively to obtain the cosine mixing signal and the sine mixing signal.

3. The method according to claim 2, characterized in that The step of respectively applying the cosine mixing signal and the sine mixing signal to corresponding row lines of the target memristor array to calculate cosine current data corresponding to the cosine mixing signal and sine current data corresponding to the sine mixing signal based on a discrete Fourier transform matrix of the corresponding row lines comprises: Applying the cosine mixing signal to the upper half of the rows of the target memristor array through a preset multiplexer, and obtaining a discrete Fourier transform matrix of the upper half of the rows; Multiplying the cosine mixing signal with the real matrix and the negative imaginary matrix of the discrete Fourier transform matrix of the upper half of the row lines respectively to obtain the cosine current data; Applying the sinusoidal mixing signal to the lower half of the rows of the target memristor array through the multiplexer, and acquiring a discrete Fourier transform matrix of the lower half of the rows; The sinusoidal mixing signal is multiplied with the real matrix and the imaginary matrix of the discrete Fourier transform matrix of the lower half of the row lines respectively to obtain the sinusoidal current data.

4. The method according to claim 3, characterized in that The method of obtaining the current information of each frequency point in the target memristor array based on the cosine current data and the sine current data, and reading the phase information and amplitude information corresponding to each frequency point in the current information through a preset phase detector and a peak detector respectively, includes: Based on the cosine current data, the sinusoidal current data and a preset Kirchhoff's current law, obtaining the current information of each frequency point; Extracting a target coefficient through the current information, and transmitting the current information to a preset transimpedance amplifier to generate a voltage signal corresponding to the current information; The voltage signal is input into the phase detector and the peak detector to read the phase information and the amplitude information corresponding to each frequency point in the target coefficient.

5. A device for calculating frequency domain amplitude and phase angle in a memristor array, characterized in that: include: An acquisition module, used for acquiring a time domain input signal corresponding to a target memristor array, and calculating a cosine mixing signal and a sine mixing signal based on the time domain input signal, a preset cosine signal and a sine signal; An applying module, used for applying the cosine mixing signal and the sine mixing signal to the corresponding row lines of the target memristor array respectively, so as to calculate the cosine current data corresponding to the cosine mixing signal and the sine current data corresponding to the sine mixing signal based on the discrete Fourier transform matrix of the corresponding row lines; A reading module is used to obtain the current information of each frequency point in the target memristor array based on the cosine current data and the sine current data, and read the phase information and amplitude information corresponding to each frequency point in the current information through a preset phase detector and a peak detector respectively.

6. The device according to claim 5, characterized in that The acquisition module comprises: A first generating unit, configured to input the real part and the imaginary part of the time domain input signal of the target memristor array into a preset digital-to-analog converter to generate an analog voltage signal corresponding to the time domain input signal; A second generating unit, configured to input the analog voltage signal into a preset mixer to generate a mixed signal corresponding to the time domain input signal; The third generating unit is used to generate the cosine signal and the sine signal by a preset cosine wave generator and a preset sine wave generator, and multiply the mixing signal by the cosine signal and the sine signal respectively to obtain the cosine mixing signal and the sine mixing signal.

7. The device according to claim 6, characterized in that The application module comprises: A first allocation unit is used to apply the cosine mixing signal to the upper half of the row lines of the target memristor array through a preset multiplexer, and obtain a discrete Fourier transform matrix of the upper half of the row lines; A first calculation unit, used for multiplying the cosine mixing signal with the real matrix and the negative imaginary matrix of the discrete Fourier transform matrix of the upper half of the row lines respectively, so as to obtain the cosine current data; A second allocation unit is used to apply the sinusoidal mixing signal to the lower half of the row lines of the target memristor array through the multiplexer, and obtain a discrete Fourier transform matrix of the lower half of the row lines; The second calculation unit is used to multiply the sinusoidal mixing signal with the real matrix and the imaginary matrix of the discrete Fourier transform matrix of the lower half of the row lines respectively to obtain the sinusoidal current data.

8. An electronic device, characterized in that: include: A memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the program to implement the method for calculating the frequency domain amplitude phase angle in a memristor array as described in any one of claims 1 to 4.

9. A computer-readable storage medium having a computer program stored thereon, characterized in that: The program is executed by a processor to implement the method for calculating the frequency domain amplitude phase angle in a memristor array as described in any one of claims 1 to 4.

10. A computer program product, comprising a computer program, characterized in that The computer program is executed to implement the method for calculating the frequency domain amplitude phase angle in the memristor array according to any one of claims 1 to 4.

Citation Information

Patent Citations

  • Inter-harmonic detection method based on triangular-rectangular hybrid convolution window and accelerated PSO algorithm

    CN108957128A

  • Dynamic power analysis method based on frequency domain interpolation

    CN109946512A

  • Two-dimensional discrete Fourier transform operation circuit and operation method

    CN111125616A

  • Memristor array-based PageRank algorithm hardware circuit implementation method

    CN114664350A

  • Full weight mapping method and device based on memristor array

    CN115099396A

Cited By

  • AC voltage peak value measurement method and device, storage medium and electronic equipment

    CN121276132A