Time domain modeling analysis method and device for circuit transient response and medium
By constructing a system of equations based on Kirchoff's current law and component characteristic equations, and selecting the highest derivative variable as the unknown quantity to be found, the problems of redundant information and intermediate variables in the existing circuit analysis methods are solved, and efficient time-domain modeling analysis of circuit transient responses is realized.
Patent Information
- Application Number
- CN202510302755.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-03-14
- Publication Date
- 2025-06-27
AI Technical Summary
The existing circuit analysis methods have problems such as redundant information, requiring intermediate variables, requiring conversion of independent voltage sources/independent current sources, and requiring development of complex software programs.
By denoting all branch currents and node voltages in the circuit as their 0th order derivatives, based on Kirchoff's current law and component characteristic equations, a system of equations is constructed and the highest derivative variable is selected as the unknown quantity to be found, and numerical solution is performed.
The constrained modeling of redundant systems of equations is realized, which avoids the setting of intermediate variables and the development of independent loop search algorithms, simplifies the development of software programs, and improves the solution efficiency.
Smart Images

Figure CN120218007A_ABST
Abstract
Description
Technical Field
[0001] The present invention belongs to the technical field of circuit analysis, and particularly relates to a time-domain modeling and analysis method for circuit transient response, a computer device, and a computer-readable storage medium. Background Art
[0002] The analysis and calculation methods of circuit characteristics generally include two types of methods. One is the analytical method based on Laplace transform and inverse Laplace transform. This method can convert the time-domain differential and integral equations describing circuit characteristics into algebraic equations in the Laplace domain to simplify the calculation process. After obtaining the analytical solution in the Laplace domain, the inverse Laplace transform is performed on the analytical solution to obtain the time-domain solution. The advantage of this method is that when the circuit is not too complex, the theoretical analytical formula can be obtained, thereby obtaining an accurate solution in the mathematical sense. However, for the analysis of complex high-order circuits, there are great implementation difficulties. Because when the circuit order is high, the inverse Laplace transform is very difficult. If manual calculation is used, a solid mathematical foundation and a large number of basic Laplace transform pairs need to be memorized; if computer solution is used, a special symbolic operation program needs to be developed. Even the symbolic operation software toolkits provided by well-known scientific computing software such as MATLAB, MATHEMATICA, MAPLE, etc. may not give results that meet user expectations for complex high-order circuits.
[0003] The other type of method is the numerical analysis method. Although this method cannot obtain the analytical solution, it does not require the development of a symbolic operation program. Usually, numerical calculation algorithms are easy to implement in computer software. When key parameters such as the step size and error of the algorithm are set reasonably, a highly accurate numerical solution can be obtained, and the engineering applicability is much stronger than the analytical method. Its typical steps are as follows: First, a mathematical model of the circuit is established, that is, the circuit schematic diagram drawn by the user is converted into a system of differential-algebraic equations (DAE). Some variables in the system of equations are selected as the unknowns to be solved, and then explicit expressions of these unknowns are obtained, and finally, the numerical solution is completed through numerical calculation methods. Obviously, the establishment of the system of differential-algebraic equations describing the circuit topology and composition is the starting point of this method. The currently used modeling methods basically all originate from several types of methods introduced in circuit theory: including the 2b method, branch current method, loop current method, node voltage method, etc. Taking a circuit with b branches and n nodes as an example, a simple analysis of these methods is as follows:
[0004] (1) 2b method
[0005] The 2b method requires that for n nodes, n-1 linearly independent current equations be established based on Kirchhoff's Current Law (KCL); then, b-(n-1) linearly independent voltage equations be established based on Kirchhoff's Voltage Law (KVL); finally, b component characteristic equations are established based on the voltage-current relationship (VCR) of the components on each branch, so the total number of equations is 2b. This method is the basic method for circuit modeling. Its advantage is that it can solve the voltages of all n nodes and the currents of b branches of the circuit at one time, but its disadvantage is obvious. Since the 2b equations are linearly related, this means that there are redundant equations. Especially when the number of circuit branches is large, the number of equations is large, the scale of the equations is large, and the solution efficiency is very low.
[0006] (2) Branch current method
[0007] The branch current method is an improvement of the 2b method, also called the 1b method. Its essence is to combine b component characteristic equations with b-(n-1) independent voltage equations, eliminate the b-(n-1) voltage variables, and then combine the n-1 independent current equations to obtain (n-1)+(b-n+1)=b equations containing only current variables. This method lists only b equations, which is half less than the 2b method. However, its disadvantage is that it can only calculate b branch currents. If the user requires voltage, it is also necessary to use the component characteristic equations to solve it. Another disadvantage is that if the branch voltage cannot be expressed by current, for example, when the circuit contains an independent current source, this method cannot be used directly to solve it.
[0008] (3) Loop current method
[0009] The loop current method is for the current flowing in b-(n-1) independent loops as an unknown quantity. According to the KVL law, b-(n-1) equations with loop current as the unknown quantity are listed. Compared with the branch current method, the number of equations is further reduced, but the disadvantage is that the identification of independent loops is relatively difficult for computer software implementation and needs to be completed with the help of path search algorithms or machine vision. On the other hand, the loop current as the solution result is a "virtual" intermediate quantity. If the user needs to obtain the current of a branch shared by two independent loops, it is also necessary to determine the direction of the two independent loop currents and perform superposition operations to obtain the actual current. If the user needs to calculate the voltage, it is necessary to further write the component characteristic equations to solve it.
[0010] (4) Node voltage method
[0011] The idea of the node voltage method is similar to that of the branch current method. Its essence is to combine b component characteristic equations with n-1 independent current equations, eliminate the n-1 current variables, and then combine b-(n-1) independent voltage equations to obtain a total of n-1 equations containing only voltage variables. This method lists n-1 equations, and its disadvantage is that it can only calculate n-1 node voltages. If the user needs to calculate the current, it is also necessary to use the component characteristic equation to solve it. Another disadvantage is that if the branch current cannot be expressed as voltage, for example, when the circuit contains an independent voltage source, this method cannot be used directly to solve it.
[0012] The above four general methods all have obvious defects, mainly including the large scale of the equation group, the inability to directly obtain the variables that the user is concerned about in some cases, and the need to develop a search algorithm for finding independent loops. It should also be pointed out that the above four methods have also evolved into other improved methods, but these methods are mainly aimed at specific problems or reduce the difficulty of manual modeling. For example, the mesh current method is a special case of the loop current method. It selects the natural mesh in the planar circuit to write the KVL equation. For humans, this process is very simple, that is, to find all the "holes" surrounded by branches in the circuit. However, for computers, to achieve this goal, path traversal is usually required, so the development of efficient and accurate mesh scanning algorithms is technically difficult, and when the circuit scale is large and the number of meshes is large, finding meshes will be very time-consuming. Summary of the invention
[0013] In view of the above-mentioned defects existing in the prior art, the present invention provides a time-domain modeling and analysis method, device and medium for circuit transient response, which solves the problems that the current general method is prone to generate redundant information, requires any intermediate variables, requires transformation processing of independent voltage sources / independent current sources, and requires the development of relatively complex software programs such as independent loop search / Laplace transform and inverse transform.
[0014] According to a first aspect of the present invention, a time domain modeling and analysis method for transient response of a circuit is provided, the method comprising:
[0015] Let all b branch currents in the circuit be The superscript 0 represents the 0th-order derivative of each branch current with respect to time t;
[0016] The voltages of all n nodes in the circuit are recorded as The superscript 0 represents the 0th order derivative of the voltage at each node with respect to time t, and one of the nodes m is selected as the ground node, which is set as the known condition
[0017] For n-1 nodes other than the ground node, based on KCL, write the node current equations in sequence and get n - 1 node current equations for variables;
[0018] For all b branches, based on the VCR, write the component characteristic equations in sequence to obtain and b component characteristic equations for variables, where the superscript numerical values of each variable represent the derivative order of each variable with respect to time t;
[0019] n - 1 node current equations, b component characteristic equations, and the ground node equation constitute b + n equations, denoted as the system of equations EQNS. Find the set of variables with the highest - order derivative that appear in the system of equations EQNS for each branch current and each node voltage, and use it as the set of unknowns to be solved for the system of equations EQNS, denoted as the variable set VARS;
[0020] Solve the variable set VARS based on the system of equations EQNS; if it cannot be directly solved, perform a structural singularity analysis on the system of equations EQNS and the variable set VARS, find the smallest structural singular subset and process it to generate a new system of equations NEW_EQNS and a new variable set NEW_VARS;
[0021] Based on the new system of equations NEW_EQNS and the new variable set NEW_VARS, solve for the expressions of the new variable set NEW_VARS, substitute the component parameter values and power supply parameter values, and obtain the time - domain calculation results of each variable through numerical calculation methods.
[0022] In some of these embodiments, arbitrarily specify the preset direction of each branch current.
[0023] In some of these embodiments, select the node where the negative pole of the power supply is located as the ground node.
[0024] In some of these embodiments, the writing method of the component characteristic equations of typical circuit elements is as follows:
[0025] 1) For a resistor element with a resistance value of R, if the node numbers at both ends are p and q, the current passing through it is i, and the preset direction is from p to q, then the component characteristic equation is:
[0026]
[0027] 2) For a capacitor element with a capacitance value of C, if the node numbers at both ends are p and q, the current passing through it is i, and the preset direction is from p to q, then the component characteristic equation is:
[0028]
[0029] 3) For an inductor element with an inductance value of L, if the node numbers at its two ends are p and q, the current passing through it is i, and the preset direction is from p to q, the component characteristic equation is:
[0030]
[0031] 4) For an independent voltage source, if the generated voltage is known as E, if the node numbers at its two ends are p and q, the current passing through it is i, and the preset direction is from p to q, the component characteristic equation is:
[0032]
[0033] 5) For an independent current source, if the generated current is known as A, if the node numbers at its two ends are p and q, the current passing through it is i, and the preset direction is from p to q, the component characteristic equation is:
[0034] i (0) = A (0)
[0035] where E is a function of time t and A is a function of time t.
[0036] In some of these embodiments, for each branch current and node voltage, traverse the highest-order derivative that appears in the system of equations EQNS, select this order of derivative as the unknown to be solved, and obtain a set VARS of b + n unknown variables to be solved composed of the highest-order derivative variables.
[0037] In some of these embodiments, the structural singularity analysis method includes the GEAR method or the bipartite graph method.
[0038] In some of these embodiments, the solution method includes the Gaussian elimination method or the column pivoting elimination method.
[0039] In some of these embodiments, the numerical calculation method includes the Runge-Kutta method or the Euler approximation method.
[0040] According to a second aspect of the present invention, there is provided a computer device, including: a processor and a memory, the memory stores a program or instruction that can run on the processor, and when the program or instruction is executed by the processor, the steps of the time-domain modeling analysis method for the circuit transient response described in any one of the first aspects are implemented.
[0041] According to a third aspect of the present invention, there is provided a computer-readable storage medium, on which a program or instruction is stored, and when the program or instruction is executed by the processor, the steps of the time-domain modeling analysis method for the circuit transient response described in any one of the first aspects are implemented.
[0042] Generally speaking, compared with the prior art by the above technical solutions conceived by the present invention, the following beneficial effects can be achieved:
[0043] (1) Write equations for all n node voltages and b branch currents in the circuit in a sequential and procedural manner. Use the highest-order derivatives of the n node voltages and b branch currents in the system of equations as unknowns. Therefore, the total number of unknowns is b + n, and the number of equations in the system of equations listed is also b + n. So there are no redundant equations, and the number of equations in the system is equal to the number of unknowns, which is exactly constrained. This is beneficial for the computer to quickly generate a complete system of equations describing the circuit model according to the numbers and component types of the node voltages and branch currents. It is also beneficial for users to check whether important constraint conditions are missed during the modeling process, reducing the probability of errors.
[0044] (2) Compared with the existing node voltage method / branch current method, there is no need to process independent voltage sources / independent current sources in the circuit through equivalent transformation or other means. Instead, equations for their voltages and currents can be directly written according to their physical characteristics. Compared with the existing loop current method / mesh current method, it avoids setting intermediate quantities such as loop currents / mesh currents and also avoids the development of independent loop search algorithms, reducing the difficulty of program development and making the solution more convenient. Compared with analytical methods such as the Laplace transform method, it is easy to implement in computer software and avoids extremely difficult development work such as developing computer programs for inverse Laplace transforms.
[0045] (3) When this method is used to model any high-order circuit (i.e., a circuit containing more than two capacitive or inductive energy storage elements), the highest differential index of the system of equations is 1, and there are no second-order or higher-order differential variables. In subsequent numerical calculation steps, there is no need to set intermediate variables to substitute for high-order differential variables, which can effectively reduce the number of unknowns and the scale of the equations, improving the solution efficiency. Description of the Drawings
[0046] Figure 1 It is a schematic flow chart of a time-domain modeling and analysis method for the transient response of a circuit provided by an embodiment of the present application;
[0047] Figure 2 It is a circuit diagram of a 6th-order passive band-pass filter provided by an embodiment of the present application;
[0048] Figure 3 It is a waveform diagram of the time-domain transient response of a circuit under the excitation of a voltage impulse function provided by an embodiment of the present application;
[0049] Figure 4 It is a comparison diagram of transient responses provided by an embodiment of the present application;
[0050] Figure 5 It is a schematic diagram of the hardware structure of a computer device provided by an embodiment of the present application. Detailed Embodiments
[0051] In order to make the objectives, technical solutions and advantages of the present invention clearer and more understandable, the present invention will be further described in detail below in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present invention and are not used to limit the present invention. Based on the embodiments provided in this application, all other embodiments obtained by those of ordinary skill in the art without making creative efforts fall within the scope of protection of the present invention.
[0052] Obviously, the accompanying drawings in the following description are only some examples or embodiments of this application. For those of ordinary skill in the art, without making creative efforts, this application can also be applied to other similar scenarios based on these drawings. In addition, it can also be understood that although the efforts made in this development process may be complex and lengthy, for those of ordinary skill in the art related to the content disclosed in this application, some design, manufacturing or production changes made on the basis of the technical content disclosed in this application are only conventional technical means and should not be understood as the content disclosed in this application being insufficient.
[0053] Referring to "embodiment" in this application means that the specific features, structures or characteristics described in conjunction with the embodiment can be included in at least one embodiment of this application. The appearance of this phrase in various positions in the specification does not necessarily refer to the same embodiment, nor is it an independent or alternative embodiment mutually exclusive with other embodiments. Those of ordinary skill in the art explicitly and implicitly understand that the embodiments described in this application can be combined with other embodiments without conflict.
[0054] Unless otherwise defined, the technical terms or scientific terms involved in this application shall have the ordinary meanings understood by those with ordinary skills in the technical field to which this application belongs. The words such as "a", "an", "one kind", "the" and the like involved in this application do not indicate a quantity limitation and may represent singular or plural. The terms "include", "comprise", "have" and any variations thereof involved in this application are intended to cover non-exclusive inclusion; for example, a process, method, system, product or device that includes a series of steps or modules (units) is not limited to the listed steps or units, but may further include steps or units not listed, or may further include other steps or units inherent to these processes, methods, products or devices. The similar words such as "connect", "be connected", "couple" and the like involved in this application are not limited to physical or mechanical connections, but may include electrical connections, whether direct or indirect. The "plurality" involved in this application means two or more. "And / or" describes the association relationship of associated objects and indicates that three relationships may exist. For example, "A and / or B" may represent: A exists alone, A and B exist simultaneously, and B exists alone. The character " / " generally represents an "or" relationship between the front and rear associated objects. The terms "first", "second", "third" and the like involved in this application are only used to distinguish similar objects and do not represent a specific order for the objects.
[0055] This application proposes a time-domain modeling analysis method for the circuit transient response that is easy to be implemented by computer software, and solves the problems of the current general methods, such as being prone to generate redundant information, requiring any intermediate variables, requiring transformation processing of independent voltage sources / independent current sources, and requiring the development of relatively complex software programs such as independent loop search / Laplace transform and inverse transform.
[0056] As Figure 1 shown, the time-domain modeling analysis method for the circuit transient response of this application includes the following steps:
[0057] (1) Denote all b branch currents in the circuit as where the superscript 0 represents the 0th derivative of each branch current with respect to time t, that is, the branch current variable itself; according to circuit theory, the preset directions of each branch current can be arbitrarily specified.
[0058] (2) Denote all n node voltages in the circuit as where the superscript 0 represents the 0th derivative of each node voltage with respect to time t, that is, the node voltage variable itself, and select one node m as the ground node and set it as a known condition where the selection of the ground node is arbitrary, but generally the node where the negative pole of the power supply is located is selected as the ground node to simplify the operation.
[0059] (3) For the n - 1 nodes other than the ground node, based on KCL, write the node current equations successively to obtain n - 1 node current equations with as variables.
[0060] For example, branches x, y, and z are connected at a certain node, and the preset current directions are and flowing into this node, and
[0061]
[0062] flowing out of this node. Then, according to KCL, one form of the node current equation is:
[0063] In the formula, the subscripts x, y, and z represent the corresponding branches. and as variables, where the superscript values of each variable represent the order of the derivative of each variable with respect to time t.
[0064] The writing methods of the component characteristic equations of typical circuit elements are as follows:
[0065] 1) For a resistor element with a resistance value of R, if the node numbers at both ends are p and q, the current passing through it is i, and the preset direction is from p to q, then the component characteristic equation is:
[0066]
[0067] 2) For a capacitor element with a capacitance value of C, if the node numbers at both ends are p and q, the current passing through it is i, and the preset direction is from p to q, then the component characteristic equation is:
[0068]
[0069] 3) For an inductor element with an inductance value of L, if the node numbers at both ends are p and q, the current passing through it is i, and the preset direction is from p to q, then the component characteristic equation is:
[0070]
[0071] 4) For an independent voltage source, if the generated voltage is known as E (E is a function of time t), if the node numbers at both ends are p and q, the current passing through it is i, and the preset direction is from p to q, then the component characteristic equation is:
[0072]
[0073] 5) For an independent current source, if the current it generates is known to be A (A is a function of time t), if the nodes at its two ends are numbered p and q, the current passing through it is i, and the preset direction is from p to q, then the component characteristic equation is:
[0074] i (0) =A (0)
[0075] From 4) and 5), it can be seen that this method does not require any other transformation processing for the independent voltage source and the independent current source, and the equations can be directly written according to their own physical characteristics. That is, the independent voltage source equation does not require the current variable passing through it to appear, and the independent current source equation does not require the voltage variable at its two ends to appear.
[0076] (5) For all n-1+b equations generated in steps (3) and (4), the simultaneous ground node equations Construct b+n equations, denoted as the equation group EQNS, find the highest-order derivative variable set of each branch current and each node voltage that has appeared in EQNS, and use it as the unknown quantity to be solved in the equation group EQNS, denoted as VARS. For example, in the equation group EQNS, for the branch current i1, one of the equations appears And another equation appears Then choose As the unknown quantity to be determined, Treated as known quantities, after traversing all b branch currents and n node voltages, we finally get a set of b+n unknown variables VARS consisting of the highest-order derivative variables. Therefore, the number of equations is equal to the number of quantities to be solved, which satisfies the necessary condition that the system of equations has a unique solution.
[0077] (6) For the system of equations EQNS generated in step (5), when the variable set VARS is selected as the unknowns, it may be directly solvable or may have no solution. In the case of no solution, EQNS is structurally singular with respect to VARS. Therefore, a specific algorithm needs to be used to perform a structural singularity analysis on EQNS and VARS, find the smallest structurally singular subset among them and process it to generate a new system of equations NEW_EQNS and a new variable set NEW_VARS. For the methods of finding and processing the structurally singular subset, a large number of literatures have disclosed various algorithms, such as the GEAR method, the bipartite graph method, etc., which will not be elaborated here. Although the algorithm itself is not within the scope of protection of this patent, it should be noted that the system of equations EQNS and the variables VARS generated by the method of steps (1) to (5) cover all the constraint conditions in the circuit, and the system of equations is just-constrained with respect to the variables. Therefore, it must be able to be processed by the algorithm for finding and processing the structurally singular subset, and finally a solvable new system of equations NEW_EQNS and new variables NEW_VARS can be obtained. Another advantage of the system of equations EQNS and the variables VARS generated by the method of steps (1) to (5) is that even for any high-order circuit (i.e., a circuit containing more than two capacitive or inductive energy storage elements) for modeling, the differential index of the EQNS system of equations is at most 1, and there are no second-order or higher-order differential variables. Therefore, before applying the algorithm for finding and processing the structurally singular subset, there is no need to add intermediate variables. However, when using other modeling methods, it is very easy to generate a system of equations with a differential index greater than or equal to 2, and additional intermediate variables need to be added, increasing the scale and difficulty of the solution.
[0078] (7) Based on NEW_EQNS and NEW_VARS, solve for the expressions of NEW_VARS. The solution methods include Gaussian elimination method, column pivoting elimination method, etc. These algorithms are very mature and the implementation processes are described in the open literature, which will not be elaborated here.
[0079] (8) Substitute the component parameter values and power supply parameter values into the expressions of NEW_VARS, and use numerical calculation methods to perform numerical solution on NEW_VARS to obtain the time-domain calculation results of each variable. The typical numerical calculation methods include the Runge-Kutta method, the Euler approximation method, etc. A large number of literatures have disclosed the implementation processes of these algorithms, which will not be elaborated here.
[0080] The time-domain modeling analysis method applicable to the transient response of the circuit proposed in this application has the following advantages:
[0081] (1) Write equations for all n node voltages and b branch currents in the circuit in a sequential and procedural manner. Using the highest-order derivatives of the n node voltages and b branch currents in the system of equations as unknowns, the total number of unknowns is b + n, and the number of equations in the listed system of equations is also b + n. Therefore, there are no redundant equations, and the number of equations in the system is equal to the number of unknowns, which is exactly constrained. This is beneficial for the computer to quickly generate a complete system of equations describing the circuit model according to the node voltage and branch current numbers and component types. It is also beneficial for users to check whether important constraint conditions are missed during the modeling process, reducing the probability of errors.
[0082] (2) Compared with the existing node voltage method / branch current method, there is no need to process independent voltage sources / independent current sources in the circuit through equivalent transformation or other means. Instead, equations for their voltages and currents can be directly written according to their physical characteristics. Compared with the existing loop current method / mesh current method, it avoids setting intermediate quantities such as loop currents / mesh currents and also avoids the development of independent loop search algorithms, reducing the difficulty of program development and making the solution more straightforward. Compared with analytical methods such as the Laplace transform method, it is easy to be implemented by computer software, avoiding extremely difficult development work such as developing a computer program for the inverse Laplace transform.
[0083] (3) When this method is used to model any high-order circuit (i.e., a circuit containing more than two capacitive or inductive energy storage elements), the highest differential index of the system of equations is 1, and there are no second-order or higher-order differential variables. In subsequent numerical calculation steps, there is no need to set intermediate variables to substitute for high-order differential variables, which can effectively reduce the number of unknowns and the scale of the equations, improving the solution efficiency.
[0084] Specifically, take Figure 2 the solution of the transient time-domain response of the 6th-order passive band-pass filter circuit shown under the excitation of a voltage impulse function as an example to illustrate the implementation process of this application. According to circuit theory, this circuit includes a total of 7 nodes, and the node voltages of its nodes 1 to 7 are u1 to u7 in sequence; this circuit includes 9 branches, and the branch currents are i1 to i9 in sequence. Among them, the voltage impulse excitation is generated by the power supply E, and the transient time-domain voltage response across the load R2 is calculated. According to the method and steps provided in this application, the specific implementation process is as follows:
[0085] (1) Denote all 9 branch currents in the circuit as where the superscript 0 represents the 0th derivative of each branch current with respect to time t, that is, the branch currents i1, i2,..., i9 themselves, and their preset current directions are as shown by the dashed arrows in Figure 2 .
[0086] (2) Denote all 7 node voltages in the circuit as Where the superscript 0 represents the 0th derivative of each node voltage with respect to time t, that is, the node voltages u1, u2,..., u7 themselves. According to the Figure 2 ground symbol position in the appendix, it can be seen that node 7 is the ground node, so set
[0087] (3) For the 6 nodes other than the ground node, based on KCL, write the node current equations in sequence, and obtain 6 node current equations with
[0088] 1) For node 1, based on KCL, obtain equation ①:
[0089]
[0090] 2) For node 2, based on KCL, obtain equation ②:
[0091]
[0092] 3) For node 3, based on KCL, obtain equation ③:
[0093]
[0094] 4) For node 4, based on KCL, obtain equation ④:
[0095]
[0096] 5) For node 5, based on KCL, obtain equation ⑤:
[0097]
[0098] 6) For node 6, based on KCL, obtain equation ⑥:
[0099]
[0100] 7) For node 7, the ground node voltage equation ⑦ can be directly obtained:
[0101]
[0102] (4) For all 9 branches, based on VCR, write the component characteristic equations in sequence:
[0103] 1) For branch 1 composed of R1, based on VCR, obtain equation ⑧:
[0104]
[0105] 2) For branch 2 composed of C1, based on VCR, obtain equation ⑨:
[0106]
[0107] 3) For the branch 3 formed by L1, based on the VCR, the equation ⑩ is obtained:
[0108]
[0109] 4) For the branch 4 formed by L2, based on the VCR, the equation
[0110]
[0111] 5) For the branch 5 formed by C2, based on the VCR, the equation
[0112]
[0113] 6) For the branch 6 formed by C3, based on the VCR, the equation
[0114]
[0115] 7) For the branch 7 formed by L3, based on the VCR, the equation
[0116]
[0117] 8) For the branch 8 formed by R2, based on the VCR, the equation
[0118]
[0119] 9) For the branch 9 formed by the voltage source E, based on the VCR, the equation
[0120] where E (0) is the 0th derivative of the voltage of the voltage source with respect to time t and is the known voltage excitation condition.
[0121] (5) A total of 16 equations including the ground node equation are generated in the above two steps Denote them as the system of equations EQNS, find the set of variables of the highest order derivative that appear in EQNS for each branch current and each node voltage, and use it as the set of unknowns to be solved for the system of equations EQNS:
[0122] 1) For the branch current i1, it can be seen that it appears in equations ①, ②, and ⑧ So its highest differential order is 0, and select as the unknown to be solved for EQNS;
[0123] 2) For the branch current i2, it can be seen that it appears in equations ②, ③, and ⑨ So its highest order of differentiation is 0, and select as the unknown quantity to be solved in EQNS;
[0124] 3) For the branch current i3, it can be seen that it appears in equations ③ and ④ and appears in equation ⑩ So its highest order of differentiation is 1, and select as the unknown quantity to be solved in EQNS;
[0125] 4) For the branch current i4, it can be seen that it appears in equation ④ and appears in equation and appears in So its highest order of differentiation is 1, and select as the unknown quantity to be solved in EQNS;
[0126] 5) For the branch current i5, it can be seen that it appears in equations ④ and and appears in So its highest order of differentiation is 0, and select as the unknown quantity to be solved in EQNS;
[0127] 6) For the branch current i6, it can be seen that it appears in equations ④, ⑤, and and appears in So its highest order of differentiation is 0, and select as the unknown quantity to be solved in EQNS;
[0128] 7) For the branch current i7, it can be seen that it appears in equations ⑤ and ⑥ and appears in equation and appears in So its highest order of differentiation is 1, and select as the unknown quantity to be solved in EQNS;
[0129] 8) For the branch current i8, it can be seen that it appears in equations ⑥ and and appears in So its highest order of differentiation is 0, and select as the unknown quantity to be solved in EQNS;
[0130] 9) For the branch current i9, it can be seen that it appears in equation ① So its highest order of differentiation is 0, and select as the unknown quantity to be solved in EQNS;
[0131] 10) For the node voltage u1, it can be seen that it appears in equations ⑧ and and appears in Therefore, its highest order of differentiation is 0, and select as the unknowns to be solved in EQNS;
[0132] 11) For the node voltage u2, it can be seen that appears in Equation ⑧ and appears in Equation ⑨
[0133] Therefore, its highest order of differentiation is 1, and select as the unknowns to be solved in EQNS; 12) For the node voltage u3, it can be seen that appears in Equation ⑩
[0134] and appears in Equation ⑨ Therefore, its highest order of differentiation is 1, and select as the unknowns to be solved in EQNS; 13) For the node voltage u4, it can be seen that appears in Equation ⑩,
[0135] and appears in Equation Therefore, its highest order of differentiation is 1, and select as the unknowns to be solved in EQNS;
[0136] 14) For the node voltage u5, it can be seen that appears in Equation and appears in Equation Therefore, its highest order of differentiation is 1, and select
[0137] as the unknowns to be solved in EQNS; 15) For the node voltage u6, it can be seen that appears in Equation Therefore, its highest order of differentiation is 0, and select as the unknowns to be solved in EQNS;
[0138]
[0139] In summary, the unknowns VARS to be solved in the obtained system of equations EQNS are:
[0140] The visible circuit is modeled by 16 equations and 16 unknowns to be solved. Therefore, the system of equations satisfies the exact constraint condition for the unknowns to be solved, that is, it satisfies the necessary condition for the system of equations to have one and only one solution.
[0141] (6) Try to solve the unknowns VARS with the system of equations EQNS. In this example, it is found that no solution can be obtained, and the method of finding and processing the structurally singular subset needs to be used to transform EQNS and VARS. In this embodiment, the mature bipartite graph method is used, with EQNS and VARS as inputs, to process the input equations and variables. According to the bipartite graph method, first take the derivative of some equations with respect to time t to obtain the following supplementary equations:
[0142] 1) Denoted as equation This equation is derived from the derivative of equation ②;
[0143] 2) Denoted as equation This equation is derived from the derivative of equation ③;
[0144] 3) Denoted as equation This equation is derived from the derivative of equation ⑦;
[0145] 4) Denoted as equation This equation is derived from the derivative of equation ⑧;
[0146] 5) Denoted as equation This equation is derived from the derivative of equation ;
[0147] Then take the derivative of the unknown with respect to time t to obtain the new variable
[0148] Use the new equation to replace equations ②, ③, ⑦, ⑧ in EQNS respectively, to obtain the new system of equations NEW_EQNS; use the new variable to replace in VARS respectively to obtain the new unknowns to be solved NEW_VARS.
[0149] (7) Based on NEW_EQNS and NEW_VARS, use the column pivoting elimination method to solve the symbolic expressions of NEW_VARS as follows:
[0150]
[0151] (8) To complete the subsequent numerical calculation process, in this embodiment, first set the component parameter values as follows:
[0152] R1 = 50 Ω
[0153] R2 = 50 Ω
[0154] L1 = 10 mH
[0155] L2 = 200 μH
[0156] L3 = 10 mH
[0157] C1 = 100 nF
[0158] C2 = 5 μF
[0159] C3 = 100 nF
[0160] Through theoretical analysis, it can be known that the above component parameters make the circuit in the embodiment form a Butterworth band-pass filter, whose center frequency is 5.033 kHz and the bandwidth is 1 kHz.
[0161] Set the power supply excitation as a voltage impulse function. Since the impulse function has a value only at the moment of 0 and this value is infinite, in numerical calculations, a rectangular time-domain narrow pulse function with a finite amplitude is used to approximate the impulse function, and we get:
[0162] where ts is the duration of the rectangular narrow pulse.
[0163] For a circuit, what is usually concerned about is its output characteristics. In this example, it is the node voltage at the output port According to what is obtained in step (7) Expression
[0164]
[0165] It can be known that to find it is necessary to find And what is obtained through steps (1) to (7) Its expression is
[0166]
[0167] This form of expression is compatible with the requirements of the numerical integration method (expressing high-order variables in terms of low-order variables), so it can be obtained through a numerical integration algorithm such as the Runge-Kutta method. Therefore, substitute the component parameter values into the expression of NEW_VARS in step (7), and use the Runge-Kutta method to and the associated variables in its expression Simultaneously perform numerical integration operations to obtain and The numerical solutions of. Here, taking the zero-state response as an example, set and Their initial values are all 0, and The time-domain waveform from 0 to 0.006 s is shown in the appendix Figure 3 As shown. Further, to verify the correctness of the calculation results, this waveform is compared with the time-domain response obtained by the Laplace transform method, as shown in the appendix Figure 4 As shown, Figure 4 This is a comparison chart of the transient response obtained by the method proposed in this application and the transient response obtained by the Laplace transform method.
[0168] It can be seen that the method proposed in this application realizes the circuit modeling in a process-oriented manner, models the 6th-order circuit in the embodiment as a differential-algebraic equation set with a differential index not higher than 1, and compares it with the analytical solution of the time-domain response obtained by the Laplace transform method, obtaining a numerical solution of the time-domain waveform of the circuit response with high accuracy.
[0169] It should be noted that the steps shown in the above process or the flowchart of the accompanying drawings can be executed in a computer system such as a set of computer-executable instructions, and although the logical order is shown in the flowchart, in some cases, the steps shown or described can be executed in a different order than here.
[0170] In addition, combined with Figure 1 The time-domain modeling analysis method of the circuit transient response described in the embodiments of this application can be implemented by a computer device. Figure 5 This is a schematic diagram of the hardware structure of the computer device in the embodiments of this application. As Figure 5 shown, the device may include a processor 301 and a memory 302 storing computer program instructions.
[0171] Specifically, the above-mentioned processor 301 may include a central processing unit (CPU), or an application specific integrated circuit (ASIC), or may be configured as one or more integrated circuits implementing the embodiments of this application.
[0172] Among them, the memory 302 may include a mass storage for data or instructions. By way of example and not limitation, the memory 302 may include a hard disk drive (HDD), a floppy disk drive, a solid state drive (SSD), a flash memory, an optical disk, a magneto-optical disk, a magnetic tape, or a universal serial bus (USB) drive, or a combination of two or more of these. Where appropriate, the memory 302 may include removable or non-removable (or fixed) media. Where appropriate, the memory 302 may be internal or external to the data processing device. In a particular embodiment, the memory 302 is non-volatile memory. In a particular embodiment, the memory 302 includes a read-only memory (ROM) and a random access memory (RAM). Where appropriate, the ROM may be a mask-programmed ROM, a programmable ROM (PROM), an erasable PROM (EPROM), an electrically erasable PROM (EEPROM), an electrically alterable ROM (EAROM), or a flash memory, or a combination of two or more of these. Where appropriate, the RAM may be a static random access memory (SRAM) or a dynamic random access memory (DRAM), where the DRAM may be a fast page mode dynamic random access memory (FPMDRAM), an extended date out dynamic random access memory (EDODRAM), a synchronous dynamic random access memory (SDRAM), etc.
[0173] The memory 302 can be used to store or cache various data files required for processing and / or communication, as well as possible computer program instructions executed by the processor 301.
[0174] The processor 301 reads and executes the computer program instructions stored in the memory 302 to implement any one of the time-domain modeling analysis methods for circuit transient response in the above embodiments.
[0175] In some embodiments, the point cloud generation device may further include a communication interface 303 and a bus 300. Among them, as Figure 5 shown, the processor 301, the memory 302, and the communication interface 303 are connected through the bus 300 and complete communication with each other.
[0176] The communication interface 303 is used to implement communication between the modules, devices, units, and / or devices in the embodiments of the present application. The communication interface 303 can also implement data communication with other components, such as external devices, image / data acquisition devices, databases, external storage, and image / data processing workstations, etc.
[0177] The bus 300 includes hardware, software, or both, and couples the components of the point cloud generation device to each other. The bus 300 includes, but is not limited to, at least one of the following: Data Bus, Address Bus, Control Bus, Expansion Bus, Local Bus. By way of example and not limitation, the bus 300 may include an Accelerated Graphics Port (AGP) or other graphics bus, an Extended Industry Standard Architecture (EISA) bus, a Front Side Bus (FSB), a Hyper Transport (HT) interconnect, an Industry Standard Architecture (ISA) bus, an InfiniBand interconnect, a Low Pin Count (LPC) bus, a memory bus, a MicroChannel Architecture (MCA) bus, a Peripheral Component Interconnect (PCI) bus, a PCI-Express (PCI-X) bus, a Serial Advanced Technology Attachment (SATA) bus, a Video Electronics Standards Association Local Bus (VLB) bus, or other suitable bus or a combination of two or more of these. In a suitable case, the bus 300 may include one or more buses. Although the embodiments of the present application describe and illustrate specific buses, the present application contemplates any suitable bus or interconnect.
[0178] The computer device can perform the time-domain modeling analysis method of the circuit transient response in the embodiments of the present application based on computer software, so as to implement the combination with Figure 1 the time-domain modeling analysis method of the circuit transient response described.
[0179] In addition, in combination with the time-domain modeling analysis method of the circuit transient response in the above embodiments, the embodiments of the present application can be implemented by providing a computer-readable storage medium. Computer program instructions are stored on the computer-readable storage medium; when the computer program instructions are executed by a processor, any one of the time-domain modeling analysis methods of the circuit transient response in the above embodiments is implemented.
[0180] The above are the preferred embodiments of the present invention, aiming to illustrate the typical implementation schemes and working processes of the present invention. However, due to the diversity of circuit types and the diversity of the forms of Kirchhoff's current law and component characteristic equations, the implementation methods of the present invention also have great flexibility. Therefore, the present invention should not be limited to the content disclosed in this embodiment and the accompanying drawings. So all equivalent or modified implementations completed without departing from the spirit disclosed by the present invention, for example, merging and splitting some processes in the embodiment, transposing / integrating / differentiating equations to change the equation form, modifying the circuit node sorting and ground potential setting, changing the preset current direction, modifying the power supply excitation and component parameters, modifying variable names and other local modifications, as well as other measures to enhance its functions, all fall within the scope of protection of the present invention.
Claims
1. A time domain modeling and analysis method for circuit transient response, characterized in that: The method includes: Let all b branch currents in the circuit be The superscript 0 represents the 0th-order derivative of each branch current with respect to time t; The voltages of all n nodes in the circuit are recorded as The superscript 0 represents the 0th order derivative of the voltage at each node with respect to time t, and one of the nodes m is selected as the ground node, which is set as the known condition For n-1 nodes other than the ground node, based on KCL, write the node current equations in sequence and get n-1 node current equations with variables; For all b branches, based on VCR, write the component characteristic equations in sequence to obtain as well as are b component characteristic equations of variables, where the superscript values of each variable represent the derivative order of each variable with respect to time t; n-1 node current equations, b component characteristic equations and ground node equation Construct b+n equations, recorded as the equation group EQNS, find out the highest-order derivative variable set of each branch current and each node voltage that has appeared in the equation group EQNS, and use it as the unknown quantity to be solved of the equation group EQNS, recorded as the variable set VARS; Solve the variable set VARS based on the equation group EQNS; if it cannot be solved directly, perform structural singularity analysis on the equation group EQNS and the variable set VARS, find and process the smallest structural singular subset, and generate a new equation group NEW_EQNS and a new variable set NEW_VARS; Based on the new equation group NEW_EQNS and the new variable set NEW_VARS, the expression of the new variable set NEW_VARS is solved, and the component parameter values and power supply parameter values are substituted, and the time domain calculation results of each variable are obtained through numerical calculation methods.
2. The time domain modeling and analysis method of circuit transient response according to claim 1, characterized in that: Arbitrarily specify the preset direction of each branch current.
3. The time domain modeling and analysis method of circuit transient response according to claim 1, characterized in that: Select the node where the negative pole of the power supply is located as the ground node.
4. The time domain modeling and analysis method of circuit transient response according to claim 1, characterized in that: The component characteristic equations of typical circuit elements are written as follows: 1) For a resistor element with a resistance value of R, if its two end nodes are numbered p and q, the current passing through it is i, and the preset direction is from p to q, then the component characteristic equation is: 2) For a capacitor element with a capacitance value of C, if its two end nodes are numbered p and q, the current passing through it is i, and the preset direction is from p to q, then the component characteristic equation is: 3) For an inductor with an inductance value of L, if the nodes at both ends are numbered p and q, the current passing through it is i, and the preset direction is from p to q, then the component characteristic equation is: 4) For an independent voltage source, if the voltage it generates is known to be E, if the nodes at its two ends are numbered p and q, the current passing through it is i, and the preset direction is from p to q, then the component characteristic equation is: 5) For an independent current source, if the current it generates is known to be A, if the nodes at its two ends are numbered p and q, the current passing through it is i, and the preset direction is from p to q, then the component characteristic equation is: i (0) =A (0) Among them, E is a function of time t, and A is a function of time t.
5. The time domain modeling and analysis method of circuit transient response according to claim 1, characterized in that: For each branch current and node voltage, the highest-order derivative appearing in the equation group EQNS is traversed, and this derivative is selected as the unknown quantity to be solved, thereby obtaining a set of b+n unknown variables VARS consisting of the highest-order derivative variables.
6. The time domain modeling and analysis method of circuit transient response according to claim 1, characterized in that: Structural singularity analysis methods include the GEAR method or the bipartite graph method.
7. The time domain modeling and analysis method of circuit transient response according to claim 1, characterized in that: Solving methods include Gaussian elimination or column pivoting elimination.
8. The time domain modeling and analysis method of circuit transient response according to claim 1, characterized in that: Numerical calculation methods include the Runge-Kutta method or the Euler approximation method.
9. A computer device, characterized in that: include: A processor and a memory, wherein the memory stores programs or instructions that can be run on the processor, and when the programs or instructions are executed by the processor, the steps of the time domain modeling and analysis method for circuit transient response described in any one of claims 1 to 8 are implemented.
10. A computer-readable storage medium, characterized in that: A program or instruction is stored thereon, and when the program or instruction is executed by a processor, the steps of the time domain modeling and analysis method of circuit transient response described in any one of claims 1 to 8 are implemented.