1 / 39

ECE 530 – Analysis Techniques for Large-Scale Electrical Systems

ECE 530 – Analysis Techniques for Large-Scale Electrical Systems. Lecture 23: Numeric Solution of Differential Equations. Prof. Hao Zhu Dept. of Electrical and Computer Engineering University of Illinois at Urbana-Champaign haozhu@illinois.edu 11/18/2014. Announcements.

afrodite
Download Presentation

ECE 530 – Analysis Techniques for Large-Scale Electrical Systems

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. ECE 530 – Analysis Techniques for Large-Scale Electrical Systems Lecture 23: Numeric Solution of Differential Equations Prof. Hao Zhu Dept. of Electrical and Computer Engineering University of Illinois at Urbana-Champaign haozhu@illinois.edu 11/18/2014

  2. Announcements • HW 7 is due Thursday, November 20 • Final exam on Monday Dec 15 from 1:30 to 4:30pm in this room (ECEB-4026) • Closed book, closed notes; you can bring in two note sheets (one new note sheet and exam 1 note sheet), along with simple calculators

  3. Forward Euler’s Method • A simplest technique for numerically integrating is the Euler's Method (sometimes the Forward Euler's Method) • Key idea is to approximate • In general, the smaller the Dt, the more accurate and stable the solution, but it also takes more time steps

  4. Second Order Runge-Kutta Method • Runge-Kutta methods improve on Euler's method by evaluating f(x) at selected points over the time step • Simplest method is the second order method in which • That is, k1 is what we get from Euler's; k2 improves on this by reevaluating at the estimated end of the time step

  5. Second Order Runge-Kutta (RK2) t = 0, x(0) = x0, Dt = step size While t tendDo k1 =Dt f(x(t)) k2 =Dt f(x(t) + k1) x(t+Dt) = x(t) + ( k1 + k2)/2 t = t + Dt End While

  6. RK2 Oscillating Cart • Consider the same example from before the position of a cart attached to a lossless spring. Again, with initial conditions of x1(0) =1 and x2(0) = 0, the analytic solution is x1(t) = cos(t)

  7. RK2 Oscillating Cart • With Dt=0.25 at t = 0

  8. Comparison • The below table compares the numeric and exact solutions for x1(t) using the RK2 algorithm

  9. Comparison of x1(10) for varying Dt • The below table compares the x1(10) values for different values of Dt; recall with Euler's with Dt=0.1 was -1.41 and with 0.01 was -0.8823

  10. RK2 Versus Euler's • RK2 requires twice the function evaluations per iteration, but gives much better results • With RK2 the error tends to vary with the cube of the step size, compared with the square of the step size for Euler's • The smaller error allows for larger step sizes compared to Euler’s

  11. Fourth Order Runge-Kutta • Other Runge-Kutta algorithms are possible, including the fourth order

  12. RK4 Oscillating Cart Example • RK4 gives much better results, with error varying with the time step to the fifth power

  13. Multistep Methods • Euler's and Runge-Kutta methods are single step approaches, in that they only use information at x(t) to determine its value at the next time step • Multistep methods take advantage of the fact that using we have information about previous time steps x(t-Dt), x(t-2Dt), etc • These methods can be explicit or implicit (dependent on x(t+Dt) values); we'll just consider the explicit Adams-Bashforth approach

  14. Multistep Motivation • In determining x(t+Dt) we could use a Taylor series expansion about x(t) (note Euler's is just the first two terms on the right-hand side)

  15. Adams-Bashforth • What we derived is the second-order Adams-Bashforth approach. Higher-order methods are also possible, by approximating subsequent derivatives. Here we also present the second- and third-order Adams-Bashforth

  16. Adams-Bashforth Versus Runge-Kutta • The key Adams-Bashforth advantage is the approach only requires one function evaluation per time step while the RK methods require multiple evaluations • A key disadvantage is when discontinuities are encountered, such as with limit violations; • Another method needs to be used until there are sufficient past solutions • They also have difficulties if variable time steps are used

  17. Numerical Instability • All explicit methods can suffer from numerical instability if the time step is not correctly chosen for the problem eigenvalues Values are scaled by thetime step; the shapefor RK2 has similar dimensions but is closerto a square. Key pointis to make sure the timestep is small enoughrelative to the eigenvalues Image source: http://www.staff.science.uu.nl/~frank011/Classes/numwisk/ch10.pdf

  18. Stiff Differential Equations • Stiff differential equations are ones in which the desired solution has components the vary quite rapidly relative to the solution • Stiffness is associated with solution efficiency: in order to account for these fast dynamics we need to take quite small time steps

  19. Multi-Rate Methods • Multi-rate methods can be used with sets of differential equations in which different parts of the system have different speeds • Use small time steps for the fast parts of the system • Use larger time steps for the slower parts of the system • Subsystems need to be sufficiently decoupled • A good power system reference: J. Chen and M. L. Crow, "A Variable Partitioning Strategy for the Multirate Method in Power Systems," Power Systems, IEEE Transactions on, vol. 23, pp. 259-266, 2008

  20. Multi-Rate Methods • At each macro step the slow variables are integrated, at each micro step the fast variables are integrated • Macro variables can be interpolated during the micro steps Figure from Jingjia Chen and M. L. Crow, "A Variable Partitioning Strategy for the Multirate Method in Power Systems," Power Systems, IEEE Transactions on, vol. 23, pp. 259-266, 2008

  21. Multi-Rate Example: Transient Stability • The power system transient stability problem is usually solved with a time step of ¼ or ½ cycle • Some subsystems can have much faster time constants • When starting induction machines can exhibit very fast (relative to the time step) transients • Some types of exciters can have very fast time constants, in which the dynamics only come into play during close by faults

  22. Implicit Methods • Implicit solution methods have the advantage of being numerically stable over the entire left half plane • Only methods considered here are the is the Backward Euler and Trapezoidal

  23. Implicit Methods • The obvious difficulty associated with these methods is x(t) appears on both sides of the equation • Easiest to show the solution for the linear case:

  24. Backward Euler Cart Example • Returning to the cart example

  25. Backward Euler Cart Example • Results with Dt = 0.25 and 0.05 Note: Just because the method is numerically stabledoesn't mean it is doesn't have errors! RK2 is moreaccurate than backward Euler for this case.

  26. Trapezoidal Linear Case • For the trapezoidal with a linear system we have

  27. Trapezoidal Cart Example • Results with Dt = 0.25, comparing between backward Euler and trapezoidal

  28. Overview of Commercial Transient Stability Algorithm • Most commercial packages use an explicit approach, such as a second order Runge-Kutta because of 1) the large number of nonlinear models and 2) the number of limit violations that are encountered • Power flow solution provides the initial starting point • Initial state variables are determined by back solving from the power flow conditions • Example: TGOV1 governorinitialization

  29. Overview of Commercial Transient Stability Algorithm • For simplicity showing Euler's, which is not used • While (t <= tend) Do Begin • Any events? If so, apply event and solve algebraic equations, g(x,y) = 0 • Solve differential equations: • Solve algebraic equations, g(x,y) = 0 • Output results • End while • Many complications to consider, including events that occur in the middle of a time step

  30. Power System Equivalents • For many power system applications it is not necessary to study the entire interconnected network • Usually we are only concerned with a portion of the network • For real-time operations, real-time information is only available for a portion of the network • System is partitioned into study system, for which a detailed model is desired, and an external system, for which an equivalent model is used • Boundary buses (within the study system) connect the two

  31. Power System Equivalents • For decades power system network models have been equivalenced using the approach originally presented by J.B. Ward in 1949 AIEE paper “Equivalent Circuits for Power-Flow Studies” • Paper’s single reference is to 1939 book by Gabriel Kron, so this also known as Kron’sreduction • Additional classical techniques are discussed in S. Deckmann, A. Pizzolante, A. Monticelli, B. Stott, and O. Alsac,“Studies on power system load flow equivalencing,” IEEE Trans. Power App. Syst., vol. PAS-99, no. 6, pp. 2301–2310, Nov./Dec. 1980.

  32. Ward Equivalents (Kron Reduction) • Equivalent is performed by doing a reduction of the bus admittance matrix • Done by doing a partial factorization of the Ybus • Computationally efficient • Yee matrix is never explicitly inverted! • Similar to what is done when fills are added, with new equivalent lines eventually joining the boundary buses

  33. Ward Equivalents (Kron Reduction) • Prior to equivalencing constant power injections are converted to equivalent current injections, the system equivalenced, then they are converted back to constant power injections • Tends to place large shunts at the boundary buses • This equivalencing process has no impact on the non-boundary study buses • Various versions of the approach are used, primarily differing on the handling of reactive power injections • The equivalent embeds information about the operating state when the equivalent was created

  34. PowerWorld Example • Ward type equivalents can be created in PowerWorld by going into the Edit Mode and selecting Tools, Equivalencing • Use Select the Buses to determine buses in the equivalent • Use Create the Equivalent to actually create the equivalent • When making equivalents for large networks the boundary buses tend to be joined by many high impedance lines; these lines can be eliminated by setting the Max Per Unit for Equivalent Line field to a relatively low value (say 2.0 per unit) • Loads and gens are converted to shunts, equivalenced, then converted back

  35. PowerWorld B7Flat_Eqv Example • In this example the B7Flat_Eqv case is reduced, eliminating buses 1, 3 and 4. The study system is then 2, 5, 6, 7, with buses 2 and 5 the boundary buses For ease ofcomparisonsystem is modeled unloaded

  36. PowerWorld B7Flat_Eqv Example • Original Ybus

  37. PowerWorld B7Flat_Eqv Example Note Yes=Yse'if no phaseshifters

  38. PowerWorld B7Flat_Eqv Example • Comparing original and equivalent Only modification was a change in the impedancebetween buses 2 and 5, modeled by adding anequivalent line

  39. Contingency Analysis Application of Equivalencing • One common application of equivalencing is contingency analysis • Most contingencies have a rather limited affect • Much smaller equivalents can be created for each contingent case, giving rapid contingency screening • Contingencies that appear to have violations in contingency screening can be processed by more time consuming but also more accurate methods • W.F. Tinney, J.M. Bright, "Adaptive Reductions for Power System Equivalents," IEEE. Trans Power, May 1987, pp. 351-359

More Related