校园网页 · 学校官网
Energy-dissipative evolutionary deep operator neural networks
Journal of Computational Physics 498 (2024) 112638 Available online 22 November 2023 0021-9991/© 2023 Elsevier Inc. All rights reserved. Contentslistsavailableat ScienceDirect Journal of Computational Physics journal homepage: www.elsevier.com/locate/jcp Energy-dissipative evolutionary deep operator neural networks JiahaoZhang a,1, ShihengZhang a,1, JieShen b,∗, GuangLin a,c,∗ a Department of Mathematics, Purdue University, 150 N. University Street, West Lafayette, IN 47907-2067, USA b School of Mathematical Science, Eastern Institute of Technology, Ningbo, Zhejiang 315200, PR China c School of Mechanical Engineering, Purdue University, 585 Purdue Mall, West Lafayette, IN 47907-2067, USA A R T I C L E I N F O A B S T R A C T Keywords: Operator learning Evolutionary neural networks Energy dissipative Parametric equation Scalar auxiliary variable Deep learning Energy-Dissipative Evolutionary Deep Operator Neural Network is an operator learning neural network. It is designed to seek numerical solutions for a class of partial differential equations instead of a single partial differential equation, such as partial differential equations with different parameters or different initial conditions. The network consists of two sub-networks, the Branch net and the Trunk net. For an objective operator , the Branch net encodes different input functions 𝑓at a fixed number of sensors 𝑥𝑖, 𝑖 =1 , 2, ⋯ , 𝑚, and the Trunk net evaluates the output function at any location. By minimizing the error between the evaluated output 𝑞and the expected output (𝑓)(𝑦) at the test point 𝑦, DeepONet generates a good approximation of the operator . A key distinction in our methodology is the utilization of DeepONet for the training of the initial state, which operates as a multi-parametric operator. Further, the evolution of parameters in our model is facilitated by the Scalar Auxiliary Variable (SAV) method, leading to a formulated iterative process for the parameter’s progression over time. The SAV approach is adopted to preserve essential physical properties of PDEs, particularly the Energy Dissipation Law. It introduces a kind of modified energy and establishes unconditional energy dissipation law in the discrete level. By treating the parameters of the well-trained DeepONet as a representation of the initial operator and evolving them by a dynamic system, our network can predict the accurate solution at any further time, while the training data is only the initial state. In order to validate the accuracy and efficiency of our neural networks, we provide numerical simulations of several partial differential equations, including heat equations, parametric heat equations, Allen-Cahn equations and a reaction–diffusion equation in three dimensions. 1. Introduction Operator learning is a popular and challenging problem with potential applications across various disciplines. The opportunity to learn an operator over a domain in Euclidean spaces[1]and Banach spaces[2]opens a new class of problems in neural network design with generalized applicability. In application to solve partial differential equations (PDEs), operator learning has the potential to predict accurate solutions for the PDEs by acquiring extensive prior knowledge [3–11]. In a recent paper [12], Lu, Jin, and Karniadakis proposed an operator learning method with some deep operator networks, named as DeepONets. It is based on the universal approximation theorem [13–15]. The goal of this neural network is to learn an operator instead of a single function. By * Corresponding authors. E-mail addresses:jshen@eitech.edu.cn(J.Shen), guanglin@purdue.edu(G.Lin). 1 These two authors contributed equally to this work. https://doi.org/10.1016/j.jcp.2023.112638 Received 2 April 2023; Received in revised form 26 September 2023; Accepted 12 November 2023 Journal of Computational Physics 498 (2024) 112638 2 J.Zhang,S.Zhang,J.Shenetal. denoting Ω = ℝ𝑙×[0, 𝑇]and 𝑓=𝑓(𝑥, 𝑡), we can define an operator by taking 𝑓as the input function, (𝑓)as the output function, such that for any (𝑥, 𝑡)in Ω, (𝑓)(𝑥, 𝑡) ∈ℝ. DeepONet takes the discrete input function and approximates the operator by a network. Before delving into our network, it is pertinent to revisit the architecture of DeepONet. In DeepONet, the term “sensors” refers to specific finite locations within Ω, exemplified as {(𝑥1, 𝑡1), (𝑥2, 𝑡2), ⋯ , (𝑥𝑚, 𝑡𝑚)}. The DeepONet architecture is bifurcated into the Branch net and the Trunk net. The Branch net undertakes the task of encoding the input function 𝑓at these fixed sensors. The resultant output from the Branch net comprises 𝑝neurons, where each neuron is conceptualized as a scalar of the form 𝑏𝑘= 𝑏𝑘(𝑓(𝑥1, 𝑡1), 𝑓(𝑥2, 𝑡2), ⋯ , 𝑓(𝑥𝑚, 𝑡𝑚)) for 𝑘 =1, 2, ⋯ , 𝑝. Conversely, the Trunk net encodes evaluation points denoted as {𝑦𝑗∈Ω|𝑗= 1, ⋯ , 𝑛}. Its output is also structured into 𝑝neurons, with each neuron represented as a scalar: 𝑔𝑘=𝑔𝑘(𝑦1, 𝑦2, ⋯ , 𝑦𝑛)for 𝑘 =1, 2, ⋯ , 𝑝. It’s crucial to note that the neuron count in the final layers of both the Trunk and Branch nets is identical. This permits the DeepONet output to be articulated as an inner product between the vectors (𝑏1, 𝑏2, ⋯ , 𝑏𝑝)𝑇and (𝑔1, 𝑔2, ⋯ , 𝑔𝑝)𝑇. Hence, the relation linking the expected and evaluated outputs is delineated as (𝑓)(𝑦) ≈∑ 𝑝 𝑘=1𝑏𝑘𝑔𝑘. DeepONet essentially stands as an embodiment of the Universal Approximation Theorem for Operators, as expounded by Chen & Chen [16]. For any time-dependent PDE, the training data is the form of (𝑓, 𝑦, (𝑓)(𝑦)), where 𝑓in the discrete form can be represented as (𝑓(𝑥1,𝑡1),𝑓(𝑥2,𝑡2), ⋯,𝑓(𝑥𝑚,𝑡𝑚))𝑇in the neural network. In the original paper, they used the classic FNN [17]a s the baseline model. For dynamic systems, various network architectures are used, including residual networks[18], convolutional NNs(CNNs)[19, 20], recurrent NNs(RNNs) [21], neural jump stochastic differential equations [22]a n d neural ordinary differential equations [23]. DeepONet effectively predicts solutions for a wide array of nonlinear ODEs and PDEs, encompassing systems such as simple dynamics, gravity pendulum, and diffusion-reaction. Nonetheless, a significant challenge arises due to the need for generating training data at each time step, making the network training computationally expensive. In many initial value problems, information about 𝑓(𝑥, 𝑡)is available only at 𝑡 =0. This naturally prompts the question: Is it possible to learn an operator for a time-dependent PDE using solely the initial input functions? Inspired by the Evolutionary Deep Neural Network (EDNN) approach [24], it becomes more streamlined to learn an operator at a fixed time rather than an operator governed by both spatial and time variables. Without loss of generality, in the context of initial value problems, the time variable 𝑡can be set to 0. Upon acquiring the operator corresponding to the initial time, a plethora of traditional numerical methods become available for solution updating. Specifically, once the initial condition operator is proficiently trained, the parameters of both the Branch net and the Trunk net can be interpreted as functions of the time variable, as depicted in Fig.1. Elaborating further for a specified initial value problem, ⎧ ⎪ ⎨ ⎪⎩ 𝜕𝑢 𝜕𝑡=𝑠(𝑢), 𝑢(𝑥,0)= 𝑢0(𝑥).𝑥 ∈𝑋 (1) If we denote an operator input 𝑓which defines the dynamic of the initial condition 𝑢0, our objective is to approximate an operator ∶𝑓↦ (𝑓), where (𝑓)(𝑦) =𝑢0(𝑦)for any 𝑦 ∈𝑋. Given sensors located at {𝑥1, 𝑥2, ⋯ , 𝑥𝑚}, the output from the Branch net can be expressed as: 𝒃= 𝒃(𝑓(𝑥1),𝑓(𝑥2),… ,𝑓(𝑥𝑚))= 𝒃(𝑥1,𝑥2,… ,𝑥𝑚1;𝑊1), where 𝑊1 denotes the parameters within the Branch net. Similarly, the output from the Trunk net can be articulated as: 𝒈= 𝒈(𝑦;𝑊2), with 𝑊2 being the parameters of the Trunk net. Upon satisfactory training, the parameters are interpreted as a function of 𝑡. Here, 𝑊1 and 𝑊2 from the initial DeepONet serve as the initial conditions for 𝑊1(𝑡)and 𝑊2(𝑡)respectively. Leveraging the architecture of the unstacked DeepONet, the solution at the initial time 𝑡0 =0 can be written as: 𝑢(𝑥,𝑡0)≈ 𝑝∑ 𝑘=1 𝑏𝑘𝑔𝑘= 𝒃𝑇𝒈. (2) To approximate 𝑢(𝑥, 𝑡1), no additional data is required. The values of 𝑢(𝑥, 𝑡1) should align with parameters of 𝑊1(𝑡1) and 𝑊2(𝑡1). Drawing inspiration from numerical solvers for PDEs, 𝑊1(𝑡1) and 𝑊2(𝑡1) can be readily obtained provided that 𝜕𝑊1 𝜕𝑡and 𝜕𝑊2 𝜕𝑡are known. Using the chain rule, the time derivative of the solution 𝑢can be expressed as: 𝜕𝑢 𝜕𝑡= 𝜕𝑢 𝜕𝑊 𝜕𝑊 𝜕𝑡, (3) where 𝑊 encompasses both 𝑊1 and 𝑊2. The term 𝜕𝑊 𝜕𝑡can be determined through a least squares problem. Upon obtaining 𝜕𝑊 𝜕𝑡, traditional time discretization schemes can be employed to compute 𝑊𝑛+1 given 𝑊𝑛. The selection of the time discretization scheme varies based on the specific problem at hand. Common choices in evolutionary networks include the Euler or Runge–Kutta methods. In the following, we will present the Energy-Dissipative Evolutionary Deep Operator Neural Network (EDE-DeepONet) as Fig. 1, along with an unconditional energy dissipative approach for gradient flow problems. Many PDEs originate from fundamental physical principles, such as Newton’s Law, the Conservation Law, and the Energy Dis- sipation Law. These principles are pivotal in various scientific and engineering domains, especially within materials science, where Journal of Computational Physics 498 (2024) 112638 3 J.Zhang,S.Zhang,J.Shenetal. Fig. 1. Energy-Dissipative Evolutionary Deep Operator Neural Network. The yellow block represents input at sensors, and the blue block represents subnet- works. The green blocks represent the output of the subnetworks and also the last layer of the DeepONet. The parameters in the well-trained DeepONet are used as the initial state of the parameter evolution. The update formula can be obtained by solving the minimization problem. The solution 𝑢(𝑥, 𝑇) is de- termined by the parameters at time 𝑇. In the right minimization problem, the energy term 𝑟2 can be shown to be dissipative, i.e., (𝑟𝑛+1)2 ≤ (𝑟𝑛)2, where (𝛾1, 𝛾2) = 1 2 ‖‖‖‖ ∑ 𝑝 𝑘=1 𝜕𝑏𝑘(𝑊𝑛 1 ) 𝜕𝑊𝑛 1 𝛾1𝑔𝑘(𝑊𝑛 2 )+ ∑ 𝑝 𝑘=1 𝑏𝑘(𝑊𝑛 1 ) 𝜕𝑔𝑘(𝑊𝑛 2 ) 𝜕𝑊𝑛 2 𝛾2 + 𝑟𝑛+1 √ 𝐸(𝑢𝑛) (𝑢𝑛)‖‖‖‖ 2 2 . gradient flows are frequently incorporated in mathematical modeling[25–32]. When seeking an approximation for the solution of a specific PDE, ensuring adherence to these laws is crucial. We now turn our attention to a gradient flow problem, 𝜕𝑢 𝜕𝑡=−𝛿𝐸 𝛿𝑢, (4) where 𝐸is a specific free energy functional and 𝛿𝐸 𝛿𝑢is the functional derivative of 𝐸. In order to keep the energy dissipative of the above gradient flow problem, we employed the scalar auxiliary variable (SAV) method [33]t o formulate a necessary least squares problem. This method introduces a kind of modified energy, ensuring that the unconditionally dissipative modified energy dissipation law holds at each iteration. The SAV method, recognized for its robustness, ease of implementation, and accuracy, has been effectively used to solve numerous PDEs. Integrating this method with neural networks paves the way for a harmonious fusion of neural network models and foundational physical laws. The objectives of this article are: • Designing an operator learning neural network without data except the given information. • Predicting solutions of parametric PDEs at any further time. • Keeping energy dissipative property of a dynamic system. Our main contributions are: • Constructing an evolutionary operator learning neural network to solve PDEs. •S o l v i n g a kind of PDEs with different parameters in a single neural network. • Introducing the modified energy in the neural network and applying SAV algorithm to keep the unconditionally modified energy dissipation law. • Introducing an adaptive time stepping strategy and restart strategy in order to speed the training process. The organization of this paper is as follows: In Section2, we introduce the Evolutionary Deep Operator Neural Network for a given PDE problem. In Section3, we consider the physics law behind the gradient flow problem and apply the SAV method to obtain the energy dissipation law. We propose the architecture of EDE-DeepONet. In Section4, we present two adaptive time stepping strategies, where the second one is called restart in some cases. In Section 5, we generally review the architecture of the EDE-DeepONet. In Section6, we implement our neural network to predict solutions of heat equations, parametric heat equations, Allen-Cahn equations and a reaction–diffusion equation in three dimensions to show the numerical results. In Section7, we give some concluding remarks. Journal of Computational Physics 498 (2024) 112638 4 J.Zhang,S.Zhang,J.Shenetal. 2. Evolutionary deep operator neural network Consider the general form of a gradient flow problem given by 𝜕𝑢 𝜕𝑡+ (𝑢)=0 , 𝑢(𝑥,0)= 𝑢0(𝑥),𝑥∈𝑋⊆ℝ𝑙, (5) where there is a differentiable function 𝐹, such that (𝑢) =𝐹′(𝑢). By denoting the free energy functional 𝐸[𝑢(𝑥, 𝑡)] = ∫𝑋𝐹(𝑢(𝑥,𝑡))d𝑥, we obtain (𝑢) = 𝛿𝐸 𝛿𝑢. The first step is to represent the initial condition operator using DeepONet. 2.1. Operator learning For the gradient flow (5), we can define the initial condition operator with the input function 𝑓, such that (𝑓)∶𝑦↦𝑢0(𝑦), forany 𝑦∈𝑋. (6) Sensors can be selected at the points {𝑥1, 𝑥2, ⋯ , 𝑥𝑚}. The data input to the DeepONet has the format (𝑓, 𝑦, (𝑓)(𝑦)). The Branch net ac- cepts the vector (𝑓(𝑥1),𝑓(𝑥2), ⋯,𝑓(𝑥𝑚))𝑇as input, which numerically represents 𝑓, and produces the output vector (𝑏1, 𝑏2, ⋯ , 𝑏𝑝)𝑇. Meanwhile, the Trunk net receives 𝑦as input and outputs (𝑔1, 𝑔2, ⋯ , 𝑔𝑝)𝑇. The DeepONet’s output at the test point 𝑦can be articulated as: (𝑓)(𝑦)≈ 𝑝∑ 𝑘=1 𝑏𝑘𝑔𝑘. (7) As previously noted, we operate under the assumption that the initial condition operator is expertly trained. Our next step is to determine the update rule for the parameters to facilitate the evolution of the neural network. 2.2. Parameters evolution within the neural network Let the parameters of the Branch net be represented by 𝑊1 and those of the Trunk net by 𝑊2. Given that these parameters evolve over time, both 𝑊1 and 𝑊2 can be considered functions of 𝑡. Using the chain rule of differentiation, we get 𝜕𝑢 𝜕𝑡= 𝜕𝑢 𝜕𝑊1 𝜕𝑊1 𝜕𝑡+ 𝜕𝑢 𝜕𝑊2 𝜕𝑊2 𝜕𝑡. (8) Considering that 𝑢 = ∑ 𝑝 𝑘=1𝑏𝑘𝑔𝑘= ∑ 𝑝 𝑘=1𝑏𝑘(𝑊1(𝑡))𝑔𝑘(𝑊2(𝑡)), we can differentiate it with respect to 𝑡to obtain: 𝜕𝑢 𝜕𝑡= 𝑝∑ 𝑘=1 (𝜕𝑏𝑘(𝑊1(𝑡)) 𝜕𝑊1(𝑡) 𝜕𝑊1(𝑡) 𝜕𝑡𝑔𝑘(𝑊2(𝑡))+ 𝑏𝑘(𝑊1(𝑡))𝜕𝑔𝑘(𝑊2(𝑡)) 𝜕𝑊2(𝑡) 𝜕𝑊2(𝑡) 𝜕𝑡 ) . Our goal is to determine 𝜕𝑊1(𝑡) 𝜕𝑡 and 𝜕𝑊2(𝑡) 𝜕𝑡, which will guide the evolution of the network parameters. This can be achieved by framing it as a minimization problem: [𝜕𝑊1(𝑡) 𝜕𝑡; 𝜕𝑊2(𝑡) 𝜕𝑡 ] = argmin (𝛾1,𝛾2), (9) where (𝛾1,𝛾2)= 1 2 ‖‖‖‖ ‖ 𝑝∑ 𝑘=1 𝜕𝑏𝑘(𝑊1(𝑡)) 𝜕𝑊1(𝑡) 𝛾1𝑔𝑘(𝑊2(𝑡))+ 𝑝∑ 𝑘=1 𝑏𝑘(𝑊1(𝑡))𝜕𝑔𝑘(𝑊2(𝑡)) 𝜕𝑊2(𝑡) 𝛾2 + (𝑢) ‖‖‖‖ ‖ 2 2 . (10) In this article, the inner product (𝑎, 𝑏) is defined in the integral sense, (𝑎, 𝑏) = ∫𝑋𝑎(𝑥)𝑏(𝑥)d 𝑥and the 𝐿2 norm is defined as ‖𝑎‖2 2 = ∫𝑋|𝑎(𝑥)|2 d𝑥. The minimization problem can be transformed into a linear system by the first-order optimal condition: 𝜕 𝜕𝛾1 = ∫ 𝑋 ( 𝑝∑ 𝑘=1 𝜕𝑏𝑘(𝑊1(𝑡)) 𝜕𝑊1(𝑡) 𝑔𝑘(𝑊2(𝑡)) )𝑇( 𝛾1 𝑝∑ 𝑘=1 𝜕𝑏𝑘(𝑊1(𝑡)) 𝜕𝑊1(𝑡) 𝑔𝑘(𝑊2(𝑡))+ 𝑝∑ 𝑘=1 𝑏𝑘(𝑊1(𝑡))𝜕𝑔𝑘(𝑊2(𝑡)) 𝜕𝑊2(𝑡) 𝛾2+ (𝑢) ) d𝑥=0 𝜕 𝜕𝛾2 = ∫ 𝑋 ( 𝑝∑ 𝑘=1 𝑏𝑘(𝑊1(𝑡))𝜕𝑔𝑘(𝑊2(𝑡)) 𝜕𝑊2(𝑡) )𝑇( 𝛾1 𝑝∑ 𝑘=1 𝜕𝑏𝑘(𝑊1(𝑡)) 𝜕𝑊1(𝑡) 𝑔𝑘(𝑊2(𝑡))+ 𝑝∑ 𝑘=1 𝑏𝑘(𝑊1(𝑡))𝜕𝑔𝑘(𝑊2(𝑡)) 𝜕𝑊2(𝑡) 𝛾2+ (𝑢) ) d𝑥=0 In this framework, the gradients with respect to 𝑊1(𝑡) and 𝑊2(𝑡) can be efficiently determined using automatic differentiation for each time increment. Let’s denote the following: Journal of Computational Physics 498 (2024) 112638 5 J.Zhang,S.Zhang,J.Shenetal. (𝐉𝟏)𝑖𝑗1 = 𝑝∑ 𝑘=1 𝜕𝑏𝑘(𝑊1(𝑡)) 𝜕𝑊𝑗1 1 (𝑡) 𝑔𝑖 𝑘(𝑊2(𝑡)), (𝐉𝟐)𝑖𝑗2 = 𝑝∑ 𝑘=1 𝑏𝑘(𝑊1(𝑡)) 𝜕𝑔𝑖 𝑘(𝑊2(𝑡)) 𝜕𝑊𝑗2 2 (𝑡) , (𝐍)𝑖= (𝑢𝑖), where 𝑖ranges from 1to 𝑙, 𝑗1 from 1to 𝑁𝑏 para, and 𝑗2 from 1to 𝑁𝑡 para. Here, 𝑁𝑏 para denotes the total number of parameters in the Branch net, and 𝑁𝑡 para represents the total number of parameters in the Trunk net. 𝐍 is the output of the DeepONet and is therefore computationally accessible for any spatial location. The integrals mentioned earlier can be numerically approximated: 1 |𝑋|∫ 𝑋 ( 𝑝∑ 𝑘=1 𝜕𝑏𝑘(𝑊1(𝑡)) 𝜕𝑊1(𝑡) 𝑔𝑘(𝑊2(𝑡)) )𝑇( 𝑝∑ 𝑘=1 𝜕𝑏𝑘(𝑊1(𝑡)) 𝜕𝑊1(𝑡) 𝑔𝑘(𝑊2(𝑡)) ) d𝑥= lim 𝑁𝑥→∞ 1 𝑁𝑥 𝐉𝐓 𝟏 𝐉𝟏, 1 |𝑋|∫ 𝑋 ( 𝑝∑ 𝑘=1 𝑏𝑘(𝑊1(𝑡))𝜕𝑔𝑘(𝑊2(𝑡)) 𝜕𝑊2(𝑡) )𝑇( 𝑝∑ 𝑘=1 𝑏𝑘(𝑊1(𝑡))𝜕𝑔𝑘(𝑊2(𝑡)) 𝜕𝑊2(𝑡) ) d𝑥= lim 𝑁𝑥→∞ 1 𝑁𝑥 𝐉𝐓 𝟐 𝐉𝟐, 1 |𝑋|∫ 𝑋 ( 𝑝∑ 𝑘=1 𝜕𝑏𝑘(𝑊1(𝑡)) 𝜕𝑊1(𝑡) 𝑔𝑘(𝑊2(𝑡)) )𝑇 (𝑢)d𝑥= lim 𝑁𝑥→∞ 1 𝑁𝑥 𝐉𝐓 𝟏 𝐍, where 𝑁𝑥is the number of collocation points for numerical integrals. By denoting 𝛾𝑜𝑝𝑡 𝑖 as the optimal values of 𝛾𝑖, 𝑖 =1, 2, the above system can be reduced to 𝐉𝐓 𝟏 ( 𝛾𝑜𝑝𝑡 1 𝐉𝟏 +𝛾𝑜𝑝𝑡 2 𝐉𝟐 + 𝐍 ) =0, 𝐉𝐓 𝟐 ( 𝛾𝑜𝑝𝑡 1 𝐉𝟏 +𝛾𝑜𝑝𝑡 2 𝐉𝟐 + 𝐍 ) =0. The feasible solutions of the above equations are the approximated time derivatives of 𝑊1(𝑡)and 𝑊2(𝑡). 𝑑𝑊1(𝑡) 𝑑𝑡=𝛾𝑜𝑝𝑡 1 , 𝑑𝑊2(𝑡) 𝑑𝑡=𝛾𝑜𝑝𝑡 2 , where the initial conditions 𝑊0 1 and 𝑊0 2 can be determined by DeepONets for initial condition operators. The decoupled ODEs represent the update rules within the neural networks. One straightforward approach to solving these ODEs is to use the explicit Euler method: 𝑊𝑛+1 1 −𝑊𝑛 1 Δ𝑡 =𝛾𝑜𝑝𝑡 1 , 𝑊𝑛+1 2 −𝑊𝑛 2 Δ𝑡 =𝛾𝑜𝑝𝑡 2 . Consequently, the solution at the subsequent time step, 𝑢(𝑥, 𝑡𝑛+1), is given by: 𝑢(𝑥,𝑡𝑛+1)= 𝑝∑ 𝑘=1 𝑏𝑘(𝑊𝑛+1 1 )𝑔𝑘(𝑊𝑛+1 2 ). (11) 3. Energy dissipative evolutionary deep operator neural network Let’s revisit the problem at hand. The gradient flow problem is given by: 𝜕𝑢 𝜕𝑡+ (𝑢)=0 , 𝑢(𝑥,0)= 𝑢0(𝑥), (12) where the energy functional is given by 𝐸[𝑢(𝑥,𝑡)]= ∫ 𝑋 𝐹(𝑢(𝑥,𝑡))d𝑥. This energy functional is assumed to have a positive lower bound. Additionally, (𝑢)can be expressed in terms of the variational derivative of 𝐸(𝑢), that is, (𝑢) = 𝛿𝐸 𝛿𝑢. Journal of Computational Physics 498 (2024) 112638 6 J.Zhang,S.Zhang,J.Shenetal. Taking the inner product of the first equation of (12)with (𝑢), we can derive the energy dissipation property of the system: 𝑑𝐸(𝑢) 𝑑𝑡= (𝛿𝐸 𝛿𝑢, 𝜕𝑢 𝜕𝑡 ) = ( (𝑢), 𝜕𝑢 𝜕𝑡 ) =− ( (𝑢), (𝑢) ) ≤0. (13) However, it is usually hard for a numerical algorithm to be efficient as well as energy dissipative. Recently, the SAV approach [33] was introduced to construct numerical schemes which is energy dissipative (with a modified energy), accurate, robust and easy to implement. More precisely, assuming 𝐸[𝑢(𝑥)] >0, it introduces a 𝑟(𝑡) = √ 𝐸[𝑢(𝑥,𝑡)], and expands the gradient flow problem as 𝜕𝑢 𝜕𝑡=− 𝑟√ 𝐸(𝑢) (𝑢), 𝑑𝑟 𝑑𝑡= 1 2 √ 𝐸(𝑢) ( (𝑢), 𝜕𝑢 𝜕𝑡 ) . (14) With 𝑟(0) = √ 𝐸[𝑢(𝑥,0)], the above system has a solution 𝑟(𝑡) ≡ √ 𝐸[𝑢(𝑥,𝑡)]and 𝑢being the solution of the original problem. By setting 𝑢𝑛= ∑ 𝑝 𝑘=1𝑔𝑘𝑏𝑘, a first order scheme can be constructed as 𝑢𝑛+1 −𝑢𝑛 Δ𝑡 =− 𝑟𝑛+1 √ 𝐸(𝑢𝑛) (𝑢𝑛) 𝑟𝑛+1 −𝑟𝑛 Δ𝑡 = 1 2 √ 𝐸(𝑢𝑛) ∫ 𝑋 (𝑢𝑛)𝑢𝑛+1 −𝑢𝑛 Δ𝑡 𝑑𝑥. (15) This is a coupled system of equations for (𝑟𝑛+1, 𝑢𝑛+1). But it can be easily decoupled as follows. Plugging the first equation into the second one, we obtain: 𝑟𝑛+1 −𝑟𝑛 Δ𝑡 =− 𝑟𝑛+1 2𝐸(𝑢𝑛) ‖‖ (𝑢𝑛)‖‖ 2, (16) which implies 𝑟𝑛+1 = ( 1+ Δ𝑡 2𝐸(𝑢𝑛) ‖‖ (𝑢𝑛)‖‖ 2 )−1 𝑟𝑛 (17) Theorem 3.1 (Discrete Energy Dissipation Law). With the modified energy define above, the scheme is unconditionally energy stable, i.e. (𝑟𝑛+1)2 −(𝑟𝑛)2 ≤0. (18) Proof 3.1. Taking the inner product of the first equation with 𝑟𝑛+1 √ 𝐸(𝑢𝑛) (𝑢𝑛)and the second equation with 2𝑟𝑛+1 (𝑟𝑛+1)2 −(𝑟𝑛)2 =2𝑟𝑛+1(𝑟𝑛+1 −𝑟𝑛)−(𝑟𝑛+1 −𝑟𝑛)2 = Δ𝑡𝑟𝑛+1 √ 𝐸(𝑢𝑛) ∫ 𝑋 (𝑢𝑛)𝑢𝑛+1 −𝑢𝑛 Δ𝑡 𝑑𝑥−(𝑟𝑛+1 −𝑟𝑛)2 =−Δ𝑡 ( 𝑟𝑛+1 √ 𝐸(𝑢𝑛) )2 ∫ 𝑋 (𝑢𝑛) (𝑢𝑛)𝑑𝑥−(𝑟𝑛+1 −𝑟𝑛)2 ≤0 (19) In order to maintain the modified energy dissipation law in the evolution neural network, we only need to replace (𝑢𝑛) by 𝑟𝑛+1 √ 𝐸(𝑢𝑛) (𝑢𝑛)in section2. The update rule of the neural network is [𝜕𝑊1(𝑡) 𝜕𝑡; 𝜕𝑊2(𝑡) 𝜕𝑡 ] =argmin(𝛾1,𝛾2), (20) where (𝛾1,𝛾2)= 1 2 ‖‖ ‖ ‖ ‖‖ 𝑝∑ 𝑘=1 𝜕𝑏𝑘(𝑊𝑛 1 (𝑡)) 𝜕𝑊𝑛 1 (𝑡) 𝛾1𝑔𝑘(𝑊𝑛 2 (𝑡))+ 𝑝∑ 𝑘=1 𝑏𝑘(𝑊𝑛 1 (𝑡)) 𝜕𝑔𝑘(𝑊𝑛 2 (𝑡)) 𝜕𝑊𝑛 2 (𝑡) 𝛾2 + 𝑟𝑛+1 √ 𝐸(𝑢𝑛) (𝑢𝑛) ‖‖ ‖ ‖ ‖‖ 2 2 . (21) The corresponding linear system of the first order optimal condition is Journal of Computational Physics 498 (2024) 112638 7 J.Zhang,S.Zhang,J.Shenetal. 𝐉𝐓 𝟏 ( 𝛾𝑜𝑝𝑡 1 𝐉𝟏 +𝛾𝑜𝑝𝑡 2 𝐉𝟐 + 𝑟𝑛+1 √ 𝐸(𝑢𝑛) 𝐍 ) =0, 𝐉𝐓 𝟐 ( 𝛾𝑜𝑝𝑡 1 𝐉𝟏 +𝛾𝑜𝑝𝑡 2 𝐉𝟐 + 𝑟𝑛+1 √ 𝐸(𝑢𝑛) 𝐍 ) =0. (22) After getting 𝛾𝑜𝑝𝑡 1 and 𝛾𝑜𝑝𝑡 2 , 𝑊𝑛+1 can be obtained by the Forward Euler method: 𝑊𝑛+1 1 =𝑊𝑛 1 +𝛾𝑜𝑝𝑡 1 Δ𝑡, 𝑊𝑛+1 2 =𝑊𝑛 2 +𝛾𝑜𝑝𝑡 2 Δ𝑡. (23) Therefore, the solution for the next time step, 𝑢(𝑥, 𝑡𝑛+1), can be expressed as: 𝑢(𝑥,𝑡𝑛+1)= 𝑝∑ 𝑘=1 𝑏𝑘(𝑊𝑛+1 1 )𝑔𝑘(𝑊𝑛+1 2 ). (24) 4. Adaptive time stepping strategy and restart strategy A key benefit of an unconditionally stable scheme is the flexibility to employ an adaptive time step. Given that the coefficient of 𝑁, represented by 𝑟𝑛+1 √ 𝐸(𝑢𝑛) , should approximate 1, we can define 𝜉𝑛+1 = 𝑟𝑛+1 √ 𝐸(𝑢𝑛) . If 𝜉is near 1, a larger Δ𝑡is permissible, whereas if 𝜉 diverges significantly from 1, a smaller Δ𝑡is more appropriate. This leads us to the following straightforward adaptive time-stepping approach: Algorithm 1 Adaptive time stepping strategy. 1. Set the tolerance for 𝜉as 𝜖0 and 𝜖1, the initial time step Δ𝑡, the maximum time step Δ𝑡𝑚𝑎𝑥and the minimum time step Δ𝑡𝑚𝑖𝑛 2. Compute 𝑢𝑛+1. 3. Compute 𝜉𝑛+1 = 𝑟𝑛+1 √ 𝐸(𝑢𝑛). 4. If |1 −𝜉𝑛+1 | >𝜖0, Then Δ𝑡 =max(Δ𝑡𝑚𝑖𝑛, Δ𝑡∕2); Else if |1 −𝜉𝑛+1 | <𝜖1, Then Δ𝑡 =min(Δ𝑡𝑚𝑎𝑥, 2Δ𝑡). Go to Step 2. 5. Update time step Δ𝑡. Another widely adopted approach to ensure that 𝑟𝑛+1 closely mirrors the original energy 𝐸(𝑢𝑛+1)involves resetting 𝑟𝑛+1 =𝐸(𝑢𝑛+1) under certain conditions. The detailed algorithm is outlined below: Algorithm 2 Restart strategy. 1. Set the tolerance for 𝜉as 𝜖2. 2. Compute 𝑢𝑛+1. 3. Compute 𝜉𝑛+1 = 𝑟𝑛+1 √ 𝐸(𝑢𝑛). 4. If |1 −𝜉𝑛+1 | >𝜖2, Then 𝑟𝑛+1 = √ 𝐸(𝑢𝑛+1)and Go to Step 2. 5. Go to next iteration. The choice for 𝜖0, 𝜖1 should be some small tolerance, usually 10−1and 10−3. The choices for Δ𝑡𝑚𝑎𝑥and Δ𝑡𝑚𝑖𝑛are quite dependent on Δ𝑡, usually Δ𝑡𝑚𝑎𝑥=103 ×Δ𝑡and Δ𝑡𝑚𝑖𝑛=10−3×Δ𝑡. In Algorithm2, we usually take 𝜖2 as 2 ×10−2. 5. Algorithm for EDE-DeepONet A methodical approach to solving time-dependent PDEs with EDE-DeepONet is delineated in Algorithm3. 6. Numerical experiments In this section, we utilize EDE-DeepONet to solve heat equations, parametric heat equations, Allen-Cahn equations, and reaction- diffusion equations, demonstrating its efficacy and accuracy. Journal of Computational Physics 498 (2024) 112638 8 J.Zhang,S.Zhang,J.Shenetal. Algorithm 3 Energy-Dissipative Evolutionary Deep Operator Neural Networks (EDE-DeepONet). 1. Initialization:Prepare input data samples in the form of (𝑓, 𝑦, (𝑓)(𝑦)), where 𝑓is the operator input defining the dynamic of the initial condition. Each input function 𝑓is crafted using the same sensor locations {𝑥1, 𝑥2, ⋯ , 𝑥𝑚}. 2. DeepONet Training: a. Input (𝑓(𝑥1), 𝑓(𝑥2), ⋯ , 𝑓(𝑥𝑚))𝑇into the Branch net and 𝑦into the Trunk net. b. Compute the output of the DeepONet and denote it as 𝑞. c. Adjust the parameters in the DeepONet by minimizing the mean squared error: 1 |𝑌| ∑ 𝑦∈𝑌‖(𝑓)(𝑦)−𝑞‖2. Denote the parameters in the well-trained Branch net and Trunk net as 𝑊0 1 and 𝑊0 2 . 3. Parameter Evolution: a. Using the well-trained DeepONet, solve the system of equations (22)to derive [ 𝜕𝑊1(𝑡) 𝜕𝑡; 𝜕𝑊2(𝑡) 𝜕𝑡 ] . b. Given that the parameters 𝑊0 1 and 𝑊0 2 are known, compute new parameters 𝑊𝑛 1 and 𝑊𝑛 2 using equations (23)iteratively. 4. Output:Compute the solution at time 𝑡𝑛using DeepONet by 𝑢(𝑥, 𝑡𝑛) = ∑ 𝑝 𝑘=1 𝑏𝑘(𝑊𝑛 1 )𝑔𝑘(𝑊𝑛 2 ). Table 1 The mean squared error of the heat equation: The initial input function is 𝑢0(𝑥) =𝑎 sin(𝜋𝑥). Error T=0.025 T=0.05 T=0.075 T=0.1 a=1.0 1.47×10 −5 1.33×10 −5 1.32×10 −5 1.29×10 −5 a=1.5 5.11×10 −6 7.05×10 −6 8.48×10 −6 9.81×10 −6 a=1.8 1.46×10 −5 1.69×10 −5 1.79×10 −5 1.83×10 −5 a=2.5 2.20×10 −4 1.34×10 −4 6.02×10 −5 1.72×10 −5 6.1. Example 1: simple heat equations To demonstrate the accuracy of EDE-DeepONet, we begin by considering the simple heat equation with various initial conditions for which we already possess exact solutions. A one-dimensional heat equation system can be described by the following partial differential equation (PDE): 𝑢𝑡=𝑢𝑥𝑥, 𝑢(𝑥,0)= 𝑢0, 𝑢(0,𝑡)= 𝑢(2,𝑡)=0 . Using the method of separation of variables, we can derive the solution to the heat equation. If we set 𝑢0(𝑥) =𝑎 sin(𝜋𝑥), the solution is given by 𝑢(𝑥, 𝑡) =𝑎 sin(𝜋𝑥)𝑒−𝜋2𝑡, where 𝑎 ∈[1, 2]. The corresponding energy can be calculated as 𝐸(𝑢) = ∫2 0 1 2 |𝑢𝑥|2𝑑𝑥 ≈ Δ𝑥(∑ 𝑛 𝑖=1 1 2 |𝑢𝑥(𝑥𝑖)|2). To generate initial data samples, we choose 51 points uniformly from the interval [0, 2) for 𝑥and 50 random values of 𝑎from [1, 2]. The time step for updating the parameters in the neural network is 2.5 ×104, and the number of iteration steps is 400. We compare the solutions for different values of 𝑎, where 𝑎 =1.0, 1.5, 1.8, and 2.5. Even though 𝑎 =2.5is outside the range of training data, the model performs well. We calculate the mean squared error for different 𝑎as shown in Table 1. In this article, the mean squared error is defined as 𝑒(𝑢, ̂𝑢) = 1 𝑁 ∑ 𝑁 𝑘=1(𝑢(𝑥𝑘)−̂𝑢(𝑥𝑘))2, where 𝑢is the solution obtained by EDE-DeepONet, and ̂𝑢is the reference solution. To illustrate the relationship between the modified energy and the original energy, we compare 𝑟2 and 𝐸at each step (see Fig.2). Both energies are dissipative in EDE-DeepONet, except when the restart strategy is applied. The restart strategy is used to make 𝑟2 approach 𝐸. The modified energy is initialized when the restart strategy is applied. The restart strategy was triggered on the 370th step to realign the modified energy with the real energy. After that, they followed the same trajectory again. It is evident that the modified energy approaches the original energy both before and after the restart strategy being applied. In Fig.3, we provide a comparison between the exact solution and the solution obtained by EDE-DeepONet. From this analysis of the simple heat equation, we conclude that EDE-DeepONet accurately predicts the solution of the PDE. Most importantly, EDE- DeepONet can predict the solution not only within the training subset range but also beyond it. For instance, we tested with 𝑎 =2.5 while 𝑎was in the range [1, 2]during training. EDE-DeepONet demonstrates good accuracy compared to the exact solution, as shown in Fig.3and Table1. 6.2. Example 2: parametric heat equations In Example 1, we considered different initial conditions as our inputs. In Example 2, we will tackle parametric heat equations. A one-dimensional parametric heat equation can be described as: 𝑢𝑡=𝑐𝑢𝑥𝑥, 𝑢(𝑥,0)=sin( 𝜋𝑥), 𝑢(0,𝑡)= 𝑢(2,𝑡)=0 . Journal of Computational Physics 498 (2024) 112638 9 J.Zhang,S.Zhang,J.Shenetal. Fig. 2. Energy comparison for the heat equation: This figure showcases the comparison between the modified and original energies during the training of EDE- DeepONet. Each iteration corresponds to one forward step of the PDE’s numerical solution with a timestep, Δ𝑡 =2.5 ×10−4. Notably, in EDE-DeepONet, both energy forms are dissipative, with the sole exception of the restart strategy implemented. This strategy ensures that 𝑟2 converges towards 𝐸. Specifically, the modified energy is reset at the 370th step. It’s crucial to observe the alignment of the modified and original energies along the same trajectory both before and after this pivotal 370th step. Fig. 3. The heat equation: The solution with 4 different initial input functions 𝑢0(𝑥) =𝑎 sin(𝜋𝑥). The curve represents the solution obtained by the EDE-DeepONet, and xxx represents the reference solution. The training parameter 𝑎is in the range of [1, 2), so we give three examples in this range. We also present the case out of the range. It also shows accuracy in Fig.3d. This PDE is more complex than the one in Example 1 because the parameter 𝑐is embedded within the equation. Traditional numerical schemes require multiple runs to handle cases with different parameters, as they essentially represent distinct equations. In contrast, EDE-DeepONet only needs to be trained once. We choose the training range of 𝑐as [1, 2)and select 51 points for 𝑥and 𝑐in a manner similar to Example 1. To incorporate the parameter 𝑐into the initial state, we can compute the solution after a small time step using traditional methods. This approach allows us to obtain various initial states corresponding to different values of 𝑐. Journal of Computational Physics 498 (2024) 112638 10 J.Zhang,S.Zhang,J.Shenetal. Fig. 4. Energy comparison for the parametric heat equation: We present the modified energy and original energy when training EDE-DeepONet. Each iteration step represents one forward step of the PDE’s numerical solution with Δ𝑡 =2.5 ×10−4. These types of PDEs are inherently complex, necessitating multiple restarts during the training phase. While the original energy consistently diminishes, the modified energy effectively approximates it. Table 2 The mean squared error of the parametric heat equation. Error T=0.025 T=0.05 T=0.075 T=0.1 c=1.2 1.30×10 −5 1.43×10 −5 1.35×10 −5 1.20×10 −5 c=1.5 1.35×10 −5 1.27×10 −5 9.80×10 −6 7.80×10 −6 c=1.8 1.17×10 −5 1.03×10 −5 7.88×10 −5 1.83×10 −5 c=2.5 2.20×10 −4 1.34×10 −4 6.02×10 −5 7.08×10 −6 First, we compare the modified energy with the original energy, as shown in Fig. 4. The energy differs from the first example because it depends on the parameter 𝑐. To represent the energy of the system, we compute the average energy across different values of 𝑐. This case is more complex than the first one, requiring more restarts during training. Although the modified energy oscillates when the restart strategy is used, it consistently decreases after each restart. Second, we present the mean squared error between the solution obtained by EDE-DeepONet and the reference solution in Table2. The reference solution can be obtained explicitly using the variable separation method, and the error is defined in the same way as in Example 1. Third, we provide a comparison between our solution and the reference solution in Fig. 5. Similar to Example 1, we predict the solution for values of 𝑐outside the range of [1, 2], and all results demonstrate excellent accuracy. Therefore, EDE-DeepONet is capable of solving parametric PDEs effectively. 6.3. Example 3: Allen-Cahn equations We will now demonstrate results for a PDE with a more complex energy. The Allen-Cahn equation is developed to describe phase separation processes. Originally formulated for materials science, it has found applications in representing moving interfaces within phase-field models in fluid dynamics. The Allen-Cahn equation can be considered as a gradient flow in 𝐿2 with a specific energy. We will discuss both the one-dimensional case and two-dimensional case as follows: 6.3.1. One-dimensional case (a) Various initial conditions: We will begin with the one-dimensional Allen-Cahn equation, which can be described by the following equations: 𝑢𝑡=𝑢𝑥𝑥−𝑔(𝑢), 𝑢(𝑥,0)= 3∑ 𝑗=1 𝑎𝑗sin(𝑗𝜋𝑥)+ 3∑ 𝑗=1 𝑏𝑗cos(𝑗𝜋𝑥) with periodic boundary conditions. The corresponding Ginzburg–Landau free energy is defined as: Journal of Computational Physics 498 (2024) 112638 11 J.Zhang,S.Zhang,J.Shenetal. Fig. 5.The parametric heat equation: The solution with 4 different parameters 𝑐. The curve represents the solution obtained by the EDE-DeepONet and xxx represents the reference solution. The training parameter 𝑐is in the range of [1, 2), so we give 3 examples in this range. We also present the case out of the range in Fig.5d. Table 3 The mean squared error of the one-dimensional Allen-Cahn equation with the initial input function 𝑢0(𝑥) = ∑ 3 𝑗=1 𝑎𝑗𝑠𝑖𝑛(𝑗𝜋𝑥) + ∑ 3 𝑗=1 𝑏𝑗𝑐𝑜𝑠(𝑗𝜋𝑥). 𝑎1,𝑎2,𝑎3,𝑏1,𝑏2,𝑏3 T=0.02 T=0.04 T=0.06 0.07,0.03,0.06,0.13,0.03,0.09 2.93×10 −4 1.67×10 −3 2.11×10 −3 0.03,0.06,0.08,0.06,0.08,0.08 2.90×10 −4 4.62×10 −4 1.59×10 −4 0.18,0.01,0.01,0.02,0.04,0.14 2.36×10 −4 1.02×10 −3 1.09×10 −3 𝐸[𝑢]= 1 ∫ 0 1 2 |𝑢𝑥|2𝑑𝑥+ 𝑥=1 ∫ 𝑥=0 𝐺(𝑢)𝑑𝑥. Here, we have 𝐺(𝑢) = 1 4𝜖2 (𝑢2 −1)2 and 𝑔(𝑢) =𝐺′(𝑢) = 1 𝜖2 𝑢(𝑢2 −1), with 𝜖=0.1. The parameter 𝜖influences the width of the jump in the steady state. In our EDE-DeepONet configuration, we define Δ𝑡as 5 ×10−4and choose a spatial point count, 𝑁𝑥, of 201. The initial input functions are crafted as linear combinations of sin(𝑗𝜋𝑥)and cos(𝑗𝜋𝑥), where 𝑗=1, 2, 3. The parameters 𝑎𝑗and 𝑏𝑗are drawn from a uniform distribution spanning [0, 1]6. They are then normalized such that ∑ 𝑎𝑖+ ∑ 𝑏𝑖=0.4, a measure to prevent the initial input function’s amplitude from becoming excessively large. A comparison between the modified and original energies can be observed in Fig.6. Notably, the modified energy closely follows the trajectory of the original, even when presented in this intricate form. Subsequently, we compared the solutions derived using EDE-DeepONet, incorporating three distinct sets of randomly generated 𝑎𝑗, 𝑏𝑗parameters, with the benchmark solution ascertained through the traditional numerical SAV method. This comparison is illustrated in Fig. 7. The associated errors are tabulated in Table 3. In this table, the first column showcases the specific 𝑎𝑗values and the second column showcases the 𝑏𝑗values. Both 𝑎𝑗and 𝑏𝑗are rounded to two decimal places for clarity. This example underscores the versatility of EDE-DeepONet in managing PDEs equipped with a plethora of initial input functions anchored to a given basis function. Such flexibility offers the potential to probe into any initial state, granted an ample selection of basis functions is at our disposal. (b) Various thickness of the interface: Heuristically, 𝜖represents the thickness of the interface in the phase separation process. Obtaining a sharp interface as 𝜖→0with time evolution is a key aspect. The theoretical and numerical analysis of this limit plays a crucial role in understanding the equation, as discussed in [34,35]. Journal of Computational Physics 498 (2024) 112638 12 J.Zhang,S.Zhang,J.Shenetal. Fig. 6. The one-dimensional Allen-Cahn Equation: The figure displays both the modified and original energies during network training. Each iteration corresponds to a single forward step in the numerical solution of the PDE, with a time increment of Δ𝑡 =5 ×10−4. Notably, the modified energy closely mirrors the trends observed in the original energy. Fig. 7. One-dimensional Allen-Cahn equation with different initial states 𝑢0(𝑥) = ∑ 3 𝑗=1 𝑎𝑗𝑠𝑖𝑛(𝑗𝜋𝑥) + ∑ 3 𝑗=1 𝑏𝑗𝑐𝑜𝑠(𝑗𝜋𝑥): The coefficients are ran- domly chosen as (𝑎1, 𝑎2, 𝑎3, 𝑏1, 𝑏2, 𝑏3)1 =( 0.07, 0.03, 0.06, 0.13, 0.03, 0.09), (𝑎1, 𝑎2, 𝑎3, 𝑏1, 𝑏2, 𝑏3)2 =( 0.03, 0.06, 0.08, 0.06, 0.08, 0.08), (𝑎1, 𝑎2, 𝑎3, 𝑏1, 𝑏2, 𝑏3)3 = (0.18, 0.01, 0.01, 0.02, 0.04, 0.14). The curve represents the reference solutions obtained by SAV method, and xxx represents the solutions generated by EDE- DeepONet. We compared the solutions at 𝑇=0.02, 𝑇=0.04, 𝑇=0.06. Journal of Computational Physics 498 (2024) 112638 13 J.Zhang,S.Zhang,J.Shenetal. Fig. 8. One dimensional Allen-Cahn equation: Solutions with different thickness of the interface at the same final time. The curve represents the solution obtained by EDE-DeepONet. xxx represents the reference solution. In this scenario, we treat 𝜖as a training parameter, and the problem can be described as follows: 𝑢𝑡=𝑢𝑥𝑥−1 𝜖2 (𝑢3 −𝑢), 𝑢(−1,𝑡)= 𝑢(1,𝑡)=0 . The initial states 𝑢(𝑥, 𝑡0; 𝜖)are obtained by spectral methods for a few steps with the initial input function 𝑢(𝑥, 0) =0.4 sin(𝜋𝑥). The training sample is generated based on the numerical solution of 𝑢(𝑥, 0.02; 𝜖). We randomly select 50 different values of 𝜖from the range [0.1, 0.2]. The learning rate is set to Δ𝑡 =10−4, and an adaptive time-stepping strategy is applied. We obtain the predicted solution after 400 iterations for different 𝜖. The rest of the settings remain the same as in the previous example. The solutions obtained for different 𝜖values are presented in Fig.8. As 𝜖decreases, the interface becomes sharper. Additionally, it’s important to note that the training parameter range is limited to (0.1, 0.2), yet EDE-DeepONet is capable of predicting solutions beyond this range. EDE-DeepONet demonstrates its ability to track the limit of 𝜖in a single training process, a task that traditional numerical methods often struggle with. 6.3.2. Two-dimensional case The two-dimensional case of the Allen-Cahn equation introduces even greater complexity. The problem can be described as follows: 𝑢𝑡=Δ𝑢−𝑔(𝑢), 𝑢(𝑥,𝑦,0)= 𝑎sin(𝜋𝑥)sin(𝜋𝑦), 𝑢(−1,𝑦,𝑡)= 𝑢(1,𝑦,𝑡)= 𝑢(𝑥,−1,𝑡)= 𝑢(𝑥,1,𝑡)=0 . The corresponding Ginzburg–Landau free energy 𝐸[𝑢]can be defined as: 𝐸[𝑢]= 1 ∫ −1 1 ∫ −1 1 2(|𝑢𝑥|2 + |𝑢𝑦|2)𝑑𝑥𝑑𝑦+ 1 ∫ −1 1 ∫ −1 𝐺(𝑢)𝑑𝑥𝑑𝑦. Here, 𝐺(𝑢) = 1 4𝜖2 (𝑢2−1)2 and 𝑔(𝑢) =𝐺′(𝑢) = 1 𝜖2 𝑢(𝑢2−1). Typically, 𝜖is set to 0.1. During the training process, we use Δ𝑡 =1 ×10−4, employ a grid with 201 ×201 spatial points, and select 20 training parameters 𝑎in the range of (0.05, 0.35). The selection of 𝑎and 𝑥 is performed in the same manner as in example 1. We compare the solutions with 𝑎 =0.08, 0.2, 0.32and 0.5, where 𝑎 =0.5is out of the training range. The mean squared error is shown in the Table4. In Fig.9, we assess the performance of both EDE-DeepONet and E-DeepONet. The latter is identical to EDE-DeepONet but lacks the support of SAV. The figure provides a comparative visual analysis of the solutions. In the figure, the top panel (Figs. 9a-9d) depicts the solutions produced via the EDE-DeepONet algorithm. The middle panel (Figs.9e-9h) showcases the canonical reference solutions. The bottom panel (Figs. 9i-9l) offers the solutions produced via the E-DeepONet algorithm. Across all panels, the initial input function is consistently 𝑢0(𝑥, 𝑦) =0.08 sin(𝜋𝑥)sin( 𝜋𝑦), facilitating a standardized comparison at 𝑇=0.02, 0.04, and 0.06. Journal of Computational Physics 498 (2024) 112638 14 J.Zhang,S.Zhang,J.Shenetal. Table 4 The mean squared error of the two-dimensional Allen- Cahn equation: The initial input function is 𝑢0(𝑥, 𝑦) = 𝑎 sin(𝜋𝑥)sin( 𝜋𝑦). Error T=0.02 T=0.04 T=0.06 a=0.08 2.37×10 −5 2.46×10 −4 1.06×10 −3 a=0.2 5.71×10 −5 3.41×10 −4 1.34×10 −3 a=0.32 9.57×10 −5 3.27×10 −4 1.32×10 −3 a=0.5 4.46×10 −4 8.62×10 −4 1.53×10 −3 Fig. 9. Two-dimensional Allen-Cahn equation: Figs.9a-9dd i s p l a y the solutions obtained by the EDE-DeepONet. Figs.9e-9hshowcase the reference solutions, while Figs.9i-9lrepresent another set of reference solutions. The initial input function is given by 𝑢0(𝑥, 𝑦) =0.08 sin(𝜋𝑥)sin( 𝜋𝑦). Solutions are compared at 𝑇=0.02, 0.04, and 0.06. EDE-DeepONet approximates the reference solution closely, but the E-DeepONet, without the aid of SAV, struggles to approximate the reference solution over extended periods. As evident from the visual data, the EDE-DeepONet provides a commendable approximation to the reference solution. In contrast, E-DeepONet, when bereft of the support from SAV, visibly lags in its approximation prowess, especially over more extended periods. In Fig.10, we present the solution derived from EDE-DeepONet for 𝑎 =0.5alongside its corresponding reference solution. Intrigu- ingly, while 𝑎 =0.5 falls outside the training domain, EDE-DeepONet retains its adeptness in closely mirroring the exact solution. This performance highlights its strong generalization, making the training process more efficient. 6.4. Example 4: reaction-diffusion equations in three dimensions Consider a three-dimensional reaction-diffusion system described by: 𝑢𝑡=Δ𝑢−𝑔(𝑢), 𝑢(𝑥,𝑦,𝑧,0)= 𝑎sin(𝜋𝑥)sin(𝜋𝑦)sin(𝜋𝑧), 𝑢=0 on 𝜕𝑋(Dirichletboundaryconditions ), where 𝑋=[−1, 1]3. Journal of Computational Physics 498 (2024) 112638 15 J.Zhang,S.Zhang,J.Shenetal. Fig. 10. Two-dimensional Allen-Cahn equation: Fig.10a-Fig.10d is the solution obtained by the EDE-DeepONet. Fig.10f-Fig.10h represents the reference solution of the two-dimensional Allen-Cahn equation with initial input function 𝑢0(𝑥, 𝑦) =0.5 sin(𝜋𝑥)sin( 𝜋𝑦). We compare the solutions at 𝑇=0.02, 0.04, 0.06. Table 5 The mean squared error of the three-dimensional reaction- diffusion equations. Error T=0.02 T=0.04 T=0.06 a=0.4 1.39×10 −7 2.13×10 −7 2.21×10 −7 a=0.6 3.05×10 −9 6.24×10 −8 1.47×10 −7 a=0.8 7.10×10 −9 1.21×10 −7 2.58×10 −7 For testing purposes, we adopt an exact solution given by: 𝑢(𝑥,𝑦,𝑧,𝑡)= 𝑎𝑒−10𝑡sin(𝜋𝑥)sin(𝜋𝑦)sin(𝜋𝑧), and the nonlinear term can be deduced as: 𝑔(𝑢)=(10−3 𝜋2)𝑢. For our simulations, we uniformly select 30 training samples of 𝑎in the interval (0.5, 1) and utilize a computational grid comprising 51 ×5 1 ×5 1spatial points. Leveraging the exact solution, we generate an error table for values 𝑎 =0 .4, 0.6, 0.8 as presented in Table5. The visual representation of the predicted solution and the exact solution with 𝑎 =0.8at 𝑇=0.06is depicted in Fig.11. Furthermore, EDE-DeepONet demonstrates its accuracy and capability in accurately solving PDEs even in complex three- dimensional scenarios. Its efficiency stands out, especially when handling higher-dimensional problems. The visualization of these solutions, as seen in the slices at varying 𝑧values, provides insight into the spatial distribution and behavior of the underlying system. The ability to achieve such accuracy in three-dimensional environments underscores the potential of EDE-DeepONet as a powerful tool for solving intricate reaction-diffusion equations. 7. Concluding remarks In this paper, we present a novel neural network architecture, EDE-DeepONet, designed for solving parametric partial differen- tial equations (PDEs) under varying initial conditions, all while preserving the energy dissipative nature of dynamic systems. Our approach incorporates the energy dissipative law of dynamic systems into the DeepONet framework. We also introduce two critical strategies: an adaptive time-stepping strategy and a restart strategy. Through our experiments, we demonstrate that both strategies contribute significantly to maintaining the modified energy’s proximity to the original energy during the evolution of the network. To mitigate the computational cost associated with training the DeepONet and keep physical properties of the dynamic system, we employ the Scalar Auxiliary Variable (SAV) method to evolve the EDE-DeepONet. This success paves the way for more exploration. For instance, extending our approach to address general Wasserstein gradient flow problems is a promising direction. While our work currently employs a basic DeepONet architecture, more advanced neural network architectures are compatible with our methodology. These advanced architectures hold the potential to further enhance the accuracy and capabilities of EDE- DeepONet. Journal of Computational Physics 498 (2024) 112638 16 J.Zhang,S.Zhang,J.Shenetal. Fig. 11. Three-dimensional Reaction-Diffusion Equations: The figure displays the solution obtained using EDE-DeepONet and the reference solution at 𝑇=0.06with 𝑎 =0.8. Two cross-sectional slices are depicted at 𝑧 =−0.6and 𝑧 =0.0. CRediT authorship contribution statement J. Z. and S. Z. conceived the mathematical models, implemented the methods, designed the numerical experiments, interpreted the results, and wrote the paper. G.L. and J. S. edited and reviewed the final manuscript. All the authors gave their final approval for publication. Declaration of competing interest The authors declare that they have no known competing financial interests or personal relationships that could have appeared to influence the work reported in this paper. Data availability No data was used for the research described in the article. Acknowledgements SJ and SZ gratefully acknowledge the support of NSF DMS-1720442, NSFC 11971407 and AFOSR FA9550-20-1-0309. GL and ZZ gratefully acknowledge the support of the National Science Foundation (DMS-2053746, DMS-2134209, ECCS-2328241, and OAC- 2311848), and U.S. Department of Energy (DOE) Office of Science Advanced Scientific Computing Research program DE-SC0021142, DE-SC0023161, and the Uncertainty Quantification for Multifidelity Operator Learning (MOLUcQ) project (Project No. 81739), and DOE – Fusion Energy Science, under grant number: DE-SC0024583. References [1] N. Kovachki, Z. Li, B. Liu, K. Azizzadenesheli, K. Bhattacharya, A. Stuart, A. Anandkumar, Neural operator: learning maps between function spaces, arXiv preprint, arXiv :2108 .08481, 2021. [2] Z. Li, N. Kovachki, K. Azizzadenesheli, B. Liu, K. Bhattacharya, A. Stuart, A. Anandkumar, Neural operator: graph kernel network for partial differential equations, arXiv preprint, arXiv :2003 .03485, 2020. [3] Y. Khoo, J. Lu, L. Ying, Solving parametric pde problems with artificial neural networks, Eur. J. Appl. Math. 32 (2021) 421–435. [4] K. Bhattacharya, B. Hosseini, N.B. Kovachki, A.M. Stuart, Model reduction and neural networks for parametric pdes, arXiv preprint, arXiv :2005 .03180, 2020. [5] N.H. Nelsen, A.M. Stuart, The random feature model for input-output maps between banach spaces, SIAM J. Sci. Comput. 43 (2021) A3212–A3243. Journal of Computational Physics 498 (2024) 112638 17 J.Zhang,S.Zhang,J.Shenetal. [6] Z. Li, N. Kovachki, K. Azizzadenesheli, B. Liu, K. Bhattacharya, A. Stuart, A. Anandkumar, Fourier neural operator for parametric partial differential equations, arXiv preprint, arXiv :2010 .08895, 2020. [7] R.G. Patel, N.A. Trask, M.A. Wood, E.C. Cyr, A physics-informed operator regression framework for extracting data-driven continuum models, Comput. Methods Appl. Mech. Eng. 373 (2021) 113500. [8] J.A. Opschoor, C. Schwab, J. Zech, Deep learning in high dimension: Relu network expression rates for bayesian pde inversion, SAM Research Report 2020, 2020. [9] C. Schwab, J. Zech, Deep learning in high dimension: neural network expression rates for generalized polynomial chaos expansions in uq, Anal. Appl. 17 (2019) 19–55. [10] T. O’Leary-Roseberry, U. Villa, P. Chen, O. Ghattas, Derivative-informed projected neural networks for high-dimensional parametric maps governed by pdes, Comput. Methods Appl. Mech. Eng. 388 (2022) 114199. [11] K. Wu, D. Xiu, Data-driven deep learning of partial differential equations in modal space, J. Comput. Phys. 408 (2020) 109307. [12] L. Lu, P. Jin, G. Pang, Z. Zhang, G.E. Karniadakis, Learning nonlinear operators via deeponet based on the universal approximation theorem of operators, Nat. Mach. Intell. 3 (2021) 218–229. [13] G. Cybenko, Approximation by superpositions of a sigmoidal function, Math. Control Signals Syst. 2 (1989) 303–314. [14] K. Hornik, Approximation capabilities of multilayer feedforward networks, Neural Netw. 4 (1991) 251–257. [15] K. Hornik, M. Stinchcombe, H. White, Multilayer feedforward networks are universal approximators, Neural Netw. 2 (1989) 359–366. [16] T. Chen, H. Chen, Universal approximation to nonlinear operators by neural networks with arbitrary activation functions and its application to dynamical systems, IEEE Trans. Neural Netw. 6 (1995) 911–917. [17] M. Raissi, P. Perdikaris, G.E. Karniadakis, Multistep neural networks for data-driven discovery of nonlinear dynamical systems, arXiv preprint, arXiv :1801 .01236, 2018. [18] T. Qin, Z. Chen, J.D. Jakeman, D. Xiu, Deep learning of parameterized equations with applications to uncertainty quantification, Int. J. Uncertain. Quantificat. 11 (2021). [19] N. Winovich, K. Ramani, G. Lin, Convpde-uq: convolutional neural networks with quantified uncertainty for heterogeneous elliptic partial differential equations on varied domains, J. Comput. Phys. 394 (2019) 263–279. [20] Y. Zhu, N. Zabaras, P.-S. Koutsourelakis, P. Perdikaris, Physics-constrained deep learning for high-dimensional surrogate modeling and uncertainty quantification without labeled data, J. Comput. Phys. 394 (2019) 56–81. [21] J. del Águila Ferrandis, M.S. Triantafyllou, C. Chryssostomidis, G.E. Karniadakis, Learning functionals via lstm neural networks for predicting vessel dynamics in extreme sea states, Proc. R. Soc. A 477 (2021) 20190897. [22] J. Jia, A.R. Benson, Neural jump stochastic differential equations, Adv. Neural Inf. Process. Syst. 32 (2019). [23] T. Chen, Y. Rubanova, J. Bettencourt, D. Duvenaud, Neural ordinary differential equations, in: Advances in Neural Information Processing Systems, La Jolla, 2018. [24] Y. Du, T.A. Zaki, Evolutional deep neural network, Phys. Rev. E 104 (2021) 045303. [25] S.M. Allen, J.W. Cahn, A microscopic theory for antiphase boundary motion and its application to antiphase domain coarsening, Acta Metall. 27 (1979) 1085–1095. [26] D.M. Anderson, G.B. McFadden, A.A. Wheeler, Diffuse-interface methods in fluid mechanics, Annu. Rev. Fluid Mech. 30 (1998) 139–165. [27] J.W. Cahn, J.E. Hilliard, Free energy of a nonuniform system. I. Interfacial free energy, J. Chem. Phys. 28 (1958) 258–267. [28] M. Doi, S.F. Edwards, S.F. Edwards, The Theory of Polymer Dynamics, vol. 73, Oxford University Press, 1988. [29] K. Elder, M. Katakowski, M. Haataja, M. Grant, Modeling elasticity in crystal growth, Phys. Rev. Lett. 88 (2002) 245701. [30] M.E. Gurtin, D. Polignone, J. Vinals, Two-phase binary fluids and immiscible fluids described by an order parameter, Math. Models Methods Appl. Sci. 6 (1996) 815–831. [31] F.M. Leslie, Theory of Flow Phenomena in Liquid Crystals, Advances in Liquid Crystals, vol.4, Elsevier, 1979, pp.1–81. [32] P. Yue, J.J. Feng, C. Liu, J. Shen, A diffuse-interface method for simulating two-phase flows of complex fluids, J. Fluid Mech. 515 (2004) 293–317. [33] J. Shen, J. Xu, J. Yang, The scalar auxiliary variable (sav) approach for gradient flows, J. Comput. Phys. 353 (2018) 407–416. [34] G. Caginalp, X. Chen, Convergence of the phase field model to its sharp interface limits, Eur. J. Appl. Math. 9 (1998) 417–445. [35] X. Chen, G. Caginalp, C. Eck, A rapidly converging phase field model, Discrete Contin. Dyn. Syst. 15 (2006) 1017.
采集于
查看校方原文 ↗