Method for detecting approaching steady state of radio frequency circuit

By detecting the approach of the RF circuit close to steady state, the transient analysis is automatically stopped and Newton iteration is solved, and the simulation time is too long in the RF circuit steady state search process is improved, and iterative convergence performance and simulation efficiency are improved.

CN119886020AActive Publication Date: 2025-04-25SHENZHEN HUADA EMPYREAN TECH CO LTD
View PDF 5 Cites 0 Cited by

Patent Information

Application Number
CN202510070113.7
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-01-16
Publication Date
2025-04-25
Estimated Expiration
2045-01-16

AI Technical Summary

Technical Problem

When the prior art is looking for the steady state of RF circuits, long transient analysis is required, which leads to too long simulation time and is unbearable, and it is impossible to select a fixed tstab length to determine the iteration initial value, resulting in convergence problems.

Method used

A method for detecting the close-stable state of the radio frequency circuit is proposed. By automatically stopping the transient analysis and turning to Newton's iteration, it uses the transient simulation of the fixed-time interval and the calculation of amplitude and average values ​​to determine whether the circuit reaches steady state, thereby selecting the appropriate initial value.

Benefits of technology

It improves iterative convergence performance, avoids excessive transient analysis, reduces simulation time consumption, and improves simulation efficiency.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119886020A_ABST
    Figure CN119886020A_ABST
Patent Text Reader

Abstract

The invention relates to a method for detecting whether a radio frequency circuit is close to a steady state, which belongs to the technical field of integrated circuit computer aided design, and can automatically detect whether the radio frequency circuit is close to the steady state, firstly, the state of the circuit is close to the steady state when the time duration of transient analysis is ended; according to the method, a good initial value is selected for subsequent Newton iteration, iteration is helped to converge better, transient analysis can be stopped immediately when it is detected that a circuit is close to a steady state, Newton iteration is entered, overlong transient analysis is avoided, and time consumption of simulation is reduced.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention belongs to the technical field of integrated circuit computer-aided design, and in particular, the present invention relates to a method for detecting when a radio frequency circuit is close to a steady state. Background Art

[0002] RF circuits are a special type of analog circuits that are widely used in wireless signal transmission and communication fields, such as Bluetooth, WiFi, radar, navigation, etc. The operating frequency of RF circuits is higher than that of ordinary analog circuits, and their design indicators are calculated based on the periodic invariant results of the steady state after the circuit reaches a steady state, that is, a periodic state. Therefore, the primary task of RF simulation is to find the steady state of the circuit, that is, to find the periodic waveform of all circuit signals.

[0003] like Figure 1 As shown, the operating frequency of RF circuits is generally high, and the time to reach steady-state operation is difficult to predict, usually requiring tens of thousands or even millions of cycles. If the transient analysis of a general SPICE simulator is used to find the circuit steady state, the simulation time will reach weeks or even months, which is unbearable for circuit design.

[0004] Shooting Newton and Harmonic Balance are commonly used methods for calculating the steady state of RF circuits. Both methods are essentially Newton iterations. Solving the circuit steady state as an unknown can avoid long transient simulations. Newton iteration is a local convergence algorithm. Its convergence is greatly affected by the initial value of the iteration. If zero voltage is used as the initial value, the iteration process will encounter great convergence difficulties because the initial value is too far from the true solution and the circuit is nonlinear. In order to improve convergence, before entering the steady-state solution iteration, a short transient analysis is usually performed on the circuit. Then, the voltage value of the last cycle of the transient analysis is used as the initial value to start the iteration of the shooting Newton or harmonic balance. The process of selecting the initial value of the iteration through transient analysis is called the steady-state process (stab), and the time length of the transient analysis is called tstab. For example Figure 1 As shown in the figure, when 200ns is selected as tstab, the transient waveform is closer to the steady state. Using it as the initial value to start the iteration, the convergence is definitely better than the transient waveform with tstab of 20ns.

[0005] Due to the wide variety of RF circuits, their functions and indicators are also different, so it is impossible to select a fixed tstab length for transient analysis to determine the initial value of the iteration. If the tstab time is too short, the circuit working state is still far from the steady state, and using it as an initial value is likely to cause convergence problems; if the tstab time is too long, it can ensure that the circuit state is close to the steady state, but the overly long tstab does not improve the iterative convergence much, but it takes extra time to do transient analysis, so a method is needed to detect whether the circuit is close to the steady state. Summary of the invention

[0006] To solve the above problems, the present invention proposes a method for detecting when a radio frequency circuit is close to a steady state. When an approximate steady state is detected, the transient analysis in the steady state stage is automatically stopped and Newton iteration is entered instead. On the one hand, the iterative convergence performance can be improved, and on the other hand, the extra simulation workload caused by excessively long transient analysis can be avoided, thereby improving the simulation efficiency.

[0007] A first aspect of the present invention provides a method for detecting that a radio frequency circuit is close to a steady state, comprising:

[0008] Step S1, obtaining the period T of the circuit according to the circuit excitation frequency, and initializing the parameters;

[0009] Step S2, if the number n>10, go to step S10, otherwise go to step S3;

[0010] Step S3, performing transient simulation of a length of [(n-1)MT, nMT];

[0011] Step S4, extracting voltage data V(t) of the kth circuit node;

[0012] Step S5, based on the voltage data V(t) of the kth circuit node, respectively calculating the amplitude a1 and the average value d1 in the interval [nMT-2T, nMT-T], and the amplitude a2 and the average value d2 in the interval [nMT-T, nMT];

[0013] Step S6, determine whether the first standard condition is met, if yes, set f1 = false; determine whether the second standard condition is met, if yes, set f2 = false;

[0014] Step S7, determine whether all circuit nodes have been traversed. If not, set k=k+1 and execute step S4. If all circuit nodes have been traversed, execute step S8.

[0015] Step S8, determine whether the steady-state condition is reached, if yes, retain the result state of [nMT-T, nMT] and execute S10, if no, execute step S9;

[0016] Step S9, set n=n+1, k=1, and go to step S2 for execution;

[0017] Step S10, terminate, and obtain the waveform of [nMT-T, nMT] as the iteration initial value;

[0018] The parameter initialization includes setting: number n=1, node counter k=1, number of cycles M, number of nodes K, Boolean variables f1=true, f2=true, amplitude determination threshold P and average value determination threshold Q as initial values.

[0019] Furthermore, in step S3, performing a transient simulation of a length of [(n-1)MT, nMT] is to call a general SPICE simulation software to perform a transient simulation on the current circuit.

[0020] Furthermore, in step S5:

[0021]

[0022]

[0023] Where t is time.

[0024] Furthermore, in step S6:

[0025] The first condition is |a1-a2|>P. If the result is yes, f1=false. If not, f1=true.

[0026] The second condition is |d1-d2|>Q. If the result is yes, f2=false. If not, f2=true.

[0027] Furthermore, in step S7, judging whether all circuit nodes have been traversed specifically includes: when k=K, judging that all circuit nodes have been traversed.

[0028] Furthermore, in step S8, the steady-state condition is: f1 = true and f2 = true; if the steady-state condition is true, the steady state is reached.

[0029] A second aspect of the present invention provides an electronic device, comprising:

[0030] at least one processor; and a memory in communication with the at least one processor; wherein,

[0031] The memory stores instructions executable by the at least one processor, and the instructions are executed by the at least one processor so that the at least one processor can execute the method for detecting that a radio frequency circuit is approaching a steady state as described in the first aspect of the present invention.

[0032] According to a third aspect of the present invention, a computer-readable storage medium is provided, on which a computer program is stored. The computer program can be loaded and executed by a processor according to a method for detecting when a radio frequency circuit is approaching a steady state according to the first aspect of the present invention.

[0033] The advantages of the present invention compared to the prior art are:

[0034] The present invention can automatically detect whether a radio frequency circuit is close to a steady state. Firstly, it can ensure that the state of the circuit is close to a steady state when the time length tstab of the transient analysis ends, and a better initial value is selected for the subsequent Newton iteration to help the iteration converge better. Secondly, when it is detected that the circuit is close to a steady state, the transient analysis can be stopped immediately and the Newton iteration can be entered, thus avoiding excessively long transient analysis and reducing the time consumption of simulation. BRIEF DESCRIPTION OF THE DRAWINGS

[0035] Figure 1 It is a schematic diagram of the time when the operating frequency of the radio frequency circuit in the prior art reaches steady-state operation.

[0036] Figure 2 It is a method flow chart of a method for detecting when a radio frequency circuit is close to a steady state provided by an embodiment of the present invention.

[0037] Figure 3 It is a structural schematic diagram of an electronic device provided by an embodiment of the present invention. DETAILED DESCRIPTION

[0038] The following will be combined with the drawings in the embodiments of the present application to clearly describe the technical solutions in the embodiments of the present application. Obviously, the described embodiments are part of the embodiments of the present application, rather than all the embodiments. All other embodiments obtained by ordinary technicians in this field based on the embodiments in the present application belong to the scope of protection of this application.

[0039] Method Embodiment

[0040] The purpose of the present invention is to provide a method for detecting that a radio frequency circuit is close to a steady state, so as to avoid the problem that the simulation results may be inaccurate or the simulation efficiency is low due to manually setting the maximum harmonic number, and to improve the usability of the simulation software. To solve the above problems, the first aspect of the present invention provides a method based on detecting that a radio frequency circuit is close to a steady state, such as Figure 2 shown.

[0041] A method based on detecting that a radio frequency circuit is close to a steady state, comprising:

[0042] S1, obtaining the period T of the circuit according to the circuit excitation frequency, and initializing the parameters.

[0043] Among them, parameter initialization is performed, including: setting the number of times n=1, the node counter k=1, the number of cycles M, the number of nodes K, the Boolean variables f1=true, f2=true, the amplitude judgment threshold P and the average value judgment threshold Q as initial values.

[0044] SPICE simulation software is circuit simulation software. Parameter initialization refers to initializing the parameters of general SPICE simulation software.

[0045] Preferably, the number of cycles M is 100, and the initial values ​​of the amplitude determination threshold P and the average value determination threshold Q are between 1e-2 and 1e-3.

[0046] S2: If the number n>10, go to step S10; otherwise, go to step S3.

[0047] S3, execute transient simulation of length [(n-1)MT, nMT].

[0048] In this step, a transient simulation of a length of [(n-1)MT, nMT] is performed by calling a general SPICE simulation software to perform a transient simulation on the current circuit.

[0049] In this embodiment, transient simulation is performed in segments with fixed time intervals, and the steady state is determined after the transient simulation of each interval is completed.

[0050] Transient simulation is a common function of SPICE simulation software. Through transient simulation, the waveform of the voltage change of each node in the circuit with respect to time, that is, the voltage data V(t), can be obtained.

[0051] S4, extracting the voltage data V(t) of the kth circuit node.

[0052] S5 , based on the voltage data V(t) of the kth circuit node, calculate the amplitude a1 and the average value d1 in the interval [nMT-2T, nMT-T], and the amplitude a2 and the average value d2 in the interval [nMT-T, nMT].

[0053] in,

[0054]

[0055] Where t is time.

[0056] S6, determine whether the first compliance condition is met, if yes, set f1 = false; determine whether the second compliance condition is met, if yes, set f2 = false.

[0057] In this step, the first condition is |a1-a2|>P. If it is true, f1=false. If it is false, f1=true.

[0058] The second condition for reaching the target is |d1-d2|>Q. If it is true, f2=false. If it is false, f2=true.

[0059] S7, determine whether all circuit nodes have been traversed. If not, set k=k+1 and execute step S4. If all circuit nodes have been traversed, execute step S8.

[0060] The step of judging whether all circuit nodes have been traversed specifically includes: when k=K, judging that all circuit nodes have been traversed.

[0061] S8, determine whether the steady-state condition is reached, if yes, retain the result state of [nMT-T, nMT] and execute S10, if no, execute step S9.

[0062] The steady state condition is: f1 = true and f2 = true. If the steady state condition is true, the steady state is reached.

[0063] S9, set n=n+1, k=1, and go to step S2 to execute.

[0064] S10, termination, obtaining the waveform of [nMT-T,nMT] as the iteration initial value.

[0065] The present invention divides the transient simulation into intervals with a fixed duration, and determines the steady state after each interval transient simulation is completed. This solves the technical problem that due to the wide variety of RF circuits, the functions and indicators are also different, and therefore a fixed tstab length cannot be selected for transient analysis to determine the initial value of the iteration. After the transient analysis of the interval segment is completed, the present invention calculates the amplitude a1, a2 and the average value d1, d2 of each node in the last two cycles as indicators for judging the steady state, which solves the convergence problem caused by the poor selection of the tstab duration, saves analysis time, and improves design efficiency.

[0066] by Figure 1 The implementation manner of the present invention is described by taking the signal as an example.

[0067] Assume that the circuit excitation frequency is 500 MHz, so the period T is 2 ns, set the number of periods M=100, set P=1e-9, and Q=1e-6.

[0068] The first step is to perform transient analysis at [0,200ns] and calculate the voltage data V(t) of the first circuit node.

[0069] The amplitudes and average values at [196 ns, 198 ns] and [198 ns, 200 ns] are respectively obtained as a1 = 1.96 V, a2 = 1.98 V, d1 = 1.2e-5 V, and d2 = 1.3e-5 V. It can be determined that |a1 - a2| > P and |d1 - d2| > Q. Therefore, the circuit has not reached a near-steady state at this time.

[0070] Perform a transient analysis again on [200 ns, 400 ns], and calculate the voltage data V(t) of the second circuit node at

[0071] The amplitudes and average values at [396 ns, 398 ns] and [398 ns, 400 ns] are respectively obtained as a1 = 1.99 V, a2 = 1.99 V, d1 = 1.2e-6 V, and d2 = 1.3e-6 V.

[0072] Judge the threshold again. Since |a1 - a2| < P and |d1 - d2| < Q, the circuit meets the standard of being near the steady state, save

[0073] the waveform at [398 ns, 400 ns] as the initial value of the iteration, and terminate.

[0074] Embodiment of the electronic device

[0075] In a second aspect of the present invention, an electronic device is provided, including:

[0076] at least one processor; and a memory communicatively connected to the at least one processor; wherein,

[0077] the memory stores instructions executable by the at least one processor, and the instructions are executed by the at least one processor so that the at least one processor can execute a method for detecting that a radio frequency circuit is near a steady state according to the first aspect of the present invention.

[0078] Figure 3 is a schematic structural diagram of an electronic device according to an embodiment of the present invention. As Figure 3 shown, the electronic device may include one or more ( Figure 3 only one is shown in ) processors 102 (the processor 102 may include, but is not limited to, a microprocessor (abbreviated as MPU) or a programmable logic device (abbreviated as PLD)) and a memory 104 for storing data. In an exemplary embodiment, the above electronic device may further include a transmission device 106 for communication functions and an input / output device 108. Those of ordinary skill in the art can understand that Figure 3The structure shown is only for illustration and does not limit the structure of the above terminal device. Figure 3 More or fewer components as shown, or with Figure 3 Equivalent functions or comparisons shown Figure 3 A different configuration with more features is shown.

[0079] The memory 104 can be used to store computer programs, for example, software programs and modules of application software, such as computer programs corresponding to the methods in the embodiments of the present invention. The processor 102 executes various functional applications and data processing by running the computer programs stored in the memory 104, that is, to implement the above-mentioned methods. The memory 104 may include a high-speed random access memory, and may also include a non-volatile memory, such as one or more magnetic storage devices, flash memory, or other non-volatile solid-state memory. In some examples, the memory 104 may further include a memory remotely arranged relative to the processor 102, and these remote memories may be connected to the terminal device via a network. Examples of the above-mentioned network include, but are not limited to, the Internet, an intranet, a local area network, a mobile communication network, and combinations thereof.

[0080] The transmission device 106 is used to receive or send data via a network. The specific example of the above network may include a wireless network provided by a communication provider of the switching device. In one example, the transmission device 106 includes a network adapter (Network Interface Controller, referred to as NIC), which can be connected to other network devices through a base station so as to communicate with the Internet. In one example, the transmission device 106 can be a radio frequency (RF) module, which is used to communicate with the Internet wirelessly.

[0081] Computer Readable Storage Medium Embodiments

[0082] A third aspect of the present invention provides a computer-readable storage medium having a computer program stored thereon, wherein the computer program can be loaded and executed by a processor to implement the method for detecting that a radio frequency circuit is approaching a steady state as described in the first aspect.

[0083] The embodiments of the present application are described above in conjunction with the accompanying drawings, but the present application is not limited to the above-mentioned specific implementation methods. The above-mentioned specific implementation methods are merely illustrative and not restrictive. Under the guidance of the present application, ordinary technicians in this field can also make many forms without departing from the purpose of the present application and the scope of protection of the claims, all of which are within the protection of the present application.

Claims

1. A method for detecting that a radio frequency circuit is close to a steady state, characterized in that: include: Step S1, obtaining the period T of the circuit according to the circuit excitation frequency, and initializing the parameters; Step S2, if the number n>10, execute step S10, otherwise execute step S3; Step S3, performing transient simulation of length [(n-1)MT, nMT]; Step S4, extracting voltage data V(t) of the kth circuit node; Step S5, based on the voltage data V(t) of the kth circuit node, respectively calculating the amplitude a1 and the average value d1 in the interval [nMT-2T, nMT-T], and the amplitude a2 and the average value d2 in the interval [nMT-T, nMT]; Step S6, determine whether the first standard condition is met, if yes, set f1 = false; determine whether the second standard condition is met, if yes, set f2 = false; Step S7, determine whether all circuit nodes have been traversed. If not, set k=k+1 and execute step S4. If all circuit nodes have been traversed, execute step S8. Step S8, determine whether the steady-state condition is reached, if yes, retain the result state of [nMT-T, nMT] and execute S10, if no, execute step S9; Step S9, set n=n+1, k=1, and go to step S2 for execution; Step S10, terminate, and obtain the waveform of [nMT-T, nMT] as the iteration initial value; The parameter initialization includes setting: number n=1, node counter k=1, number of cycles M, number of nodes K, Boolean variables f1=true, f2=true, amplitude determination threshold P and average value determination threshold Q as initial values.

2. The method for detecting when a radio frequency circuit is close to a steady state according to claim 1, characterized in that: In the step S3, performing a transient simulation of a length of [(n-1)MT, nMT] is to call a general SPICE simulation software to perform a transient simulation on the current circuit.

3. The method for detecting when a radio frequency circuit is close to a steady state according to claim 2, characterized in that: In step S5: Where t is time.

4. The method for detecting that a radio frequency circuit is close to a steady state according to claim 3, characterized in that: In step S6: The first condition is |a1-a2|>P. If the result is yes, f1=false. If not, f1=true. The second condition is |d1-d2|>Q. If the result is yes, f2=false. If not, f2=true.

5. The method for detecting when a radio frequency circuit is close to a steady state according to claim 4, characterized in that: In the step S7, it is determined whether all circuit nodes have been traversed, specifically including: when k=K, it is determined that all circuit nodes have been traversed.

6. The method for detecting when a radio frequency circuit is close to a steady state according to claim 5, characterized in that: In the step S8, the steady state condition is: f1 = true and f2 = true; if the steady state condition is true, the steady state is reached.

7. An electronic device, characterized in that: include: at least one processor; and a memory communicatively connected to the at least one processor; wherein, The memory stores instructions executable by the at least one processor, and the instructions are executed by the at least one processor so that the at least one processor can execute the method for detecting that a radio frequency circuit is approaching a steady state as described in any one of claims 1 to 6.

8. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores a computer program thereon, and the computer program can be loaded and executed by a processor according to a method for detecting a radio frequency circuit approaching a steady state as claimed in any one of claims 1 to 6.

Citation Information

Patent Citations

  • Chip steady-state temperature calculation method and device and electronic equipment

    CN112329218A

  • Circuit simulation device

    JP1995110825A

  • Method for debugging of analog and mixed-signal behavioral models during simulation

    US20030018459A1

  • Method for determining the steady state behavior of a circuit using an iterative technique

    US6493849B1

  • Automatic harmonic number identification for harmonic balance analysis

    US9507894B1