Numerical discretization of tangent vectors of hyperbolic conservation laws. Michael Herty IGPM, RWTH Aachen www.sites.google.com/michaelherty joint work with Benedetto Piccoli MNCFF 2014, Bejing, 22.5.2014
Contents Originally on multi-phase fluid flow on networks (extension of coupling conditions - NumHyp 2013 ) Recent results on tangent vectors in collaboration with B. Piccoli (Rutgers) Tangent vectors are used for optimization problems where the dynamics is governed by 1 d hyperbolic systems Tangent vectors are a first order sensitivity calculus for solutions u 0 u(t, x) Examples are control of compressor stations in gas networks, control of gates in open canals, parameter identification problems subject to transport problems,...
This presentation References and theoretical problem Example of tangent vectors for Burgers Numerical challenges Approximation of evolution of tangent vectors Numerical examples
References Concept of tangent vectors present one possibility to compute and analyze sensitivity of systems on 1-d hyperbolic balance laws Existing calculus for spatially one dimensional systems of conservation laws Introduced by Bressan/Marson (1995), extended by Bressan and co workers (1997,2007), Bianchini (2000), Piccoli and co workers (2000 ) Lipschitz continuous dependence for 1 d system Crasta/Bressan/Piccoli (2001) Related for scalar convex case: Ulbrich (2001), Giles (1996), Ulbrich/Giles (2010), Zuazua/Castro et al (2008 ). Application of sensitivity equations for general inverse problems, optimal control problems, and control / controllability questions,...
Theoretical challenge t u + x f (u) = 0, u(t = 0, x) = u 0 (x) Solution operator for nonlinear conservation laws u(t, ) = S t u 0 generically non differentiable on L 1 No classical calculus for first order variations of S t u 0 with respect to u 0 No characterizing conditions for parameter identification problems or optimal control problems min J(u(T, x))dx subject to t u+ x f (u) = 0, u(t = 0, x) = u 0 (x) u 0
Example for Burger s equation t u + x u 2 2 = 0, u(t = 0, x) = uɛ 0 = ɛ x χ [0.1] variations of initial data and interest in the behavior of the solution S t u0 ɛ with respect to h at e.g. ɛ u ɛ 0 S t u ɛ+h 0 S t u ɛ 0 + hv + O(h) Exact solution u ɛ (t, x) = (1+ɛ)x wrt ɛ Shock position is 1 + ɛt 1+ɛt χ [0, 1+ɛt] is Lipschitz in L1 t = 0: a first order approximation in L 1 exists and is v(t, x) = lim ɛ+h u0 (x) u0 ɛ(x) h 0 ɛ = ɛ x χ [0,1] But for any t > 0 the jump depends on ɛ + h and the previous limit does not define any function in L 1
Idea of tangent vectors for Burger s equation lim h 0 u ɛ+h (t, x) u ɛ (t, x) dx = O(1)+ 1 1+(ɛ+h)t h h = O( 1 h ) 1+ɛt Use weak formulation to compute the limit h 0 for arbitrary value of ɛ lim h 0 lim h 0 lim h 0 u ɛ+h (t, x) u ɛ (t, x) φ(x)dx = h x (1 + (ɛ + h)t)(1 + ɛt) χ [0, 1+ɛt] (x)φ(x)dx+ (ɛ + h)x 1 + (ɛ + h)t dx t 2 1 + (ɛ + h)t φ(y) (ɛ + h)y 1 + (ɛ + h)t, y [ 1 + ɛt, 1 + (ɛ + h)t]
Idea of tangent vectors (cont d) lim h 0 lim h 0 x (1 + (ɛ + h)t)(1 + ɛt) χ [0, 1+ɛt] (x)φ(x)dx+ t 2 1 + (ɛ + h)t φ(y) (ɛ + h)y 1 + (ɛ + h)t, y [ 1 + ɛt, 1 + (ɛ + h)t] A suitable differential of u ɛ (t, x) at ɛ may therefore consist of two components: an L 1 part and a measure located at the jump of u ɛ S t u ɛ+h 0 = u ɛ+h (t, ) = S t u ɛ 0 + h ( v(t, ) + δ s ɛ (t)( )[u ɛ ]ξ(t) )
Idea of tangent vectors for Burger s equation (2/2) lim h 0 lim h 0 x (1 + (ɛ + h)t)(1 + ɛt) χ [0, 1+ɛt] (x)φ(x)dx+ t 2 1 + (ɛ + h)t φ(y) (ɛ + h)y 1 + (ɛ + h)t, y [ 1 + ɛt, 1 + (ɛ + h)t] v(t, x) is the L 1 part consists of the a.e. pointwise limit u ɛ+h (t, x) u ɛ (t, x) v(t, x) = lim = h 0 h x (1 + ɛt) 2 ξ(t) is a real number and is the variation in the shift of the shock position s ɛ s ɛ+h (t) s ɛ (t) t ξ(t) = lim = h 0 h 2 1 + ɛt, u ɛ+h (t, ) = u ɛ (t, ) + h ( v(t, ) + δ s ɛ (t)( )[u ɛ ]ξ(t) ) (v, ξ) is called generalized tangent vector
Generalized tangent vectors (v, ξ) v(t, x) is the L 1 part consists of the a.e. pointwise limit u v(t, x) = lim ɛ+h (t,x) u ɛ (t,x) h 0 h ξ(t) is a real number and is the variation in the shift of the shock position s ɛ s ξ(t) = lim ɛ+h (t) s ɛ (t) h 0 h u ɛ+h (t, ) = u ɛ (t, ) + h ( v(t, ) + δ s ɛ (t)( )[u ɛ ]ξ(t) ) Question Which variations ɛ u0 ɛ lead to well defined tangent vectors? Different settings possible. Here, we follow B/M with u0 ɛ piecewise Lipschitz with a finite number of isolated discontinuities A tangent vector a t = 0 may lead to a tangent vector at time t by solving suitable evolution equations (first order variations of hyperbolic system). For hyperbolic balance laws and suitable variations this is proven up to shock interaction (B/M) and extended in case of conservation laws (C/B/P).
Suitable variations of initial data leading to well defined tangent vectors (v, ξ) A suitable variation u h of u 0 (x) is within an L 1 equivalence class to u h (x) = u 0 (x)+hv(x)+ ξ i <0 [u 0 ]χ [xi +hξ,x i ](x) ξ i >0[u 0 ]χ [xi,x i +hξ](x) for some v L 1 and ξ R N where N is the number of isolated discontinuities located at x i in u 0 (x).
Theoretical results (Theorem 2.2 (B/M) For previous variations the evolution equation for the tangent vector is well defined up to any point in time when two shocks coincide Result holds for system of balance laws u t + f (u) x = h(t, x, u), A(u) = Df (u).
Numerical implementation of tangent vectors Requires knowledge on exact shock positions for evaluation of the evolution of ξ(t) Requires solution of compatibility condition between waves of different families Evolution of the L 1 part v influences evolution of shift ξ(t) Non conservative system for v
Approximation to the problem for numerical implementation Presentation on the simplest case of a 1 d scalar conservation law y (1) t + f (y (1) ) x = 0, y (1) (t = 0, x) = u 0 (x) Replace equation by Jin Xin relaxation approximation for 0 < µ << 1 ( ) 0 1 y t + a 2 y 0 x = 1 ( ) 0 µ f (y (1) ) y (2) y (1) (0, x) = u 0 (x), y (2) (0, x) = f (u 0 (x)) Relaxation is a viscous approximation (( y (1) t + f (y (1) ) x = µ a 2 f (y (1) ) 2) ) y x (1) System is linear hyperbolic with stiff source term x.
Tangent vectors for relaxation system y t + ( ) 0 1 a 2 y 0 x = 1 ( ) 0 µ f (y (1) ) y (2) L 1 part of tangent vector does not depend on y (1) and is linear system ( ) 0 1 v(0, ) = v( ), v t + a 2 v 0 x = 1 ( ) 0 µ f (y (1) )v (1) v (2), v = (v (1), v (2) ) outside the discontinuities of y N discontinuities and l j jth eigenvector and i v = v(x i (t)+, t) v(x i (t), t) jump across ithe discontinuities ξ i (t) = ξ i and l j ( i v + i y x ξ i ) = 0 j k.
Variation of general cost functional wrt initial data Given y d L 1 (R), T > 0 given and y = y (1) solution to relaxation system J(y(, ), y d ( )) = χ I (x) (y(t, x) y d (x)) 2 dx Variation of J with respect to variations in u 0 generating the tangent vectors (v, ξ) and a fixed number N of discontinuities u0 J(y, y d ) = 2 ( ) χ I (x) y (1) (T, x) y d (x) v (1) (T, x)dx+ ( ( ) y (1) (T, x i +) y d (x i +) + N(u 0 ) i=1 ( )) y (1) (T, x i ) y d (x i ) i y (1) (T, )ξ i (T )
Variation of cost and tangent vectors used for maximal descent ( u0 J(y, y d ) = 2 χ I (x) y (1) ) (T, x) y d (x) v (1) (T, x)dx+ N(u 0 ) ( ( y (1) ) ( (T, x i +) y d (x i +) + y (1) )) (T, x i ) y d (x i ) i y (1) (T, )ξ i (T ) i=1 Update of control u 0 using gradient based information with stepsize ρ > 0 ũ 0 (x) = u 0 (x) ρv(0, x) N(u 0 ) i=1 χ [xi +ρξ i (0),x i+1 +ρξ i+1 (0)](x)u 0 (x i +) Choice of v for maximal descent in J ( ) v (1) (T, x) = y (1) (T, x) y d (x), v (2) (T, x) = 0 Choice of ξ for maximal descent in J ξ i (T ) = (( y (1) ) (T, x i +) y d (x i +) + ( y (1) )) (T, x i ) y d (x i ) i y (1) (T )
Numerical implementation of tangent vectors i=1 ( ) 0 1 v t + a 2 v 0 x = 1 ( µ ( u0 J(y, y d ) = 2 χ I (x) y (1) ) (T, x) y d (x) v (1) (T, x)dx+ N(u 0 ) ( ( y (1) ) ( (T, x i +) y d (x i +) + y (1) )) (T, x i ) y d (x i ) i y (1) (T, )ξ i (T ) 0 f (y (1) )v (1) v (2) ), ξ i (t) = ξ i and l j ( i v + i y x ξ i ) = 0 j k. Introduce a spatial grid (x i ) n i=1 and intervals I i = [x i 1, x 2 i+ 1 ] 2 Choose a control u 0 a piecewise constant on I i leading to ξ R 2n possible shock variations ( ) 0 1 Diagonalise matrix a 2 and derive tangent vectors for 0 system in diagonal form Splitting of transport and source term integration
Advantage of relaxation system over nonlinear system v t + ( ) 0 1 a 2 v 0 x = 1 ( µ 0 f (y (1) )v (1) v (2) ), ξ i (t) = ξ i and l j ( i v + i y x ξ i ) = 0 j k. Due to the linearity of system the equations for L 1 and real part ξ decouple Nonlinear source term does not influence evolution of t ξ(t) Variations of initial data on each grid cell I i leading to shock variations ξ i at each grid cell and an L 1 variation piecewise constant v i on each grid cell Evaluation of source term may lead to additional discontinuities and therefore additional shock variations Apply a splitting technique and use piecewise constant control in each component (v (1) 0, v (2) 0 ) spanning two consecutive intervals
Diagonalise the system in variables η with source term S and discretization according to the splitting above using a transformation T Choose control η 0 in first component constant on even and in the second on odd gridpoints Choose x and t according to the CFL condition with constant one Exact evaluation of first order Upwind scheme for the transport part Admissible controls and discretization of tangent vectors (v, ξ) v t + ( ) 0 1 a 2 v 0 x = 1 ( µ 0 f (y (1) )v (1) v (2) ), t η (1) + a x η (1) = 0, t η (2) = 0, t η (1) = S(η (1), η (2) ), t η (2) = S(η (1), η (2) ), t η (2) a x η (2) = 0, t η (1) = 0, (η (1) 0 ) 2i = (η (1) 0 ) 2i+1, (η (2) 0 ) 2i 1 = (η (2) 0 ) 2i, i = 0,..., n 2
Admissible controls and discretization of tangent vectors (v, ξ) (cont d) t η (1) + a x η (1) = 0, t η (2) = 0, t η (1) = S(η (1), η (2) ), t η (2) = S(η (1), η (2) ), t η (2) a x η (2) = 0, t η (1) = 0, x 2i 1 (t n ) = x 2i 1 (0) + a t n, x 2i (t n ) = x 2i (0) a t n, i = 0,..., n, Splitting does not need introduce additional shocks since exact Upwind leads to piecewise constant functions on even and odd grid cells Shock position at time t n is given x i (t n ) = xi 0 ± at n depending if discontinuity at even or odd cell boundary Condition l j ( i v + i y x ξ i ) = 0 j k, automatically satisfied since there is only one discontinuity at each cell boundary at even grid points in the first and odd in the second component
Tests and algorithm for control problems with cost J min y 0 =(y (1) 0,y (2) 0 ) J sbj to relaxation system Unregularized cost J(y(, ), y d ( )) = χ I (x) (y(t, x) y d (x)) 2 dx Update of control u 0 using gradient based information with stepsize ρ > 0 ũ 0 (x) = u 0 (x) ρv(0, x) N(u 0) i=1 Choice of v for maximal descent in J v (1) (T, x) = Choice of ξ for maximal descent in J ξ i (T ) = χ [xi +ρξ i (0),x i+1 +ρξ i+1 (0)](x)u 0 (x i +) ( ) y (1) (T, x) y d (x), v (2) (T, x) = 0 (( ) ( )) y (1) (T, x i +) y d (x i +) + y (1) (T, x i ) y d (x i ) i y (1) (T
Algorithm for computing a gradient 1. Set terminal time T > 0, a 2 max(f (y (1) ) 2 and choose an y (1) equidistant spatial discretization( with N x gridpoints. ) Choose t = x a and k = 0. Let η0,i k = (η (1) 0,i )k, (η (2) 0,i )k for i = 0,..., N x, be an arbitrary initial control such that η0 k is admissible Let (y d ) i be a discretization of the given function y d ( ). 2. Solve forward relaxation equations with (y 0 ) i := T η0,i k to obtain η Nt i = T 1 y Nt i. 3. Set initial data ϕ 0 i and shock variations ξ i where x i (t Nt ) are given by equation shock positions 4. Solve sensitivity equations backwards in time for initial data ṽi 0 := T ϕ 0 i to obtain ϕ Nt i = T 1 ṽ Nt i. 5. Update the current iterate η0,i k by setting η k+1 0,i := η i 0 by ηi 0 := η0,i k. 6. Provided that J(T η, y d ) is sufficiently small we terminate. Otherwise set k k + 1 and continue with step (2).
Numerical results: Grid convergence for splitting
Numerical results: Convergence for a linear system without source term
Numerical results: Convergence table using (v, ξ) components
Numerical results: Convergence table using only v components
Numerical results: Relaxation for Burger s equation
Numerical results: Convergence
Thank you for your attention.