1 Introduction

In this paper, the optimum design problem for networks is considered. The dynamics on the networks are governed by hyperbolic PDEs with boundary or distributed control. The optimal control is uniquely determined by the optimality system for the distributed parameter control problem. The structure of the optimization model is divided into two levels. The lower level is an optimal control problem which delivers an optimal control and the optimal value of the cost. The higher level is a design problem that uses the optimal cost for the shape functional. In other words, the shape functional which is the objective functional on the higher level problem is defined using the optimal value of the lower level problem.

In general, the existence of an optimal shape is a difficult challenge for geometrical domains. However, for one dimensional state equations under reasonable assumptions, the existence of an optimal shape can be shown. The dynamics on the networks are covered by the framework presented in [1]. Thus, we consider bilevel optimization on graphs. The mathematical question that we consider in this paper is the possibility to approximate the dynamic optimal control for evolutionary state equations by the static optimal control obtained for the steady state equation. The approximation error decreases with growing time horizon T for the dynamic problem with fixed initial conditions. This is a significant simplification of the solution strategy when it can be applied. The proposed approximation is useful for large time horizons. The novelty of this paper is the exploitation of the turnpike structure in the framework of optimal shape design.

We consider two optimal control problems. The first problem (OCE) is governed by an evolution equation. In order to define the second problem (OCS), the evolution state equation is reduced to the steady state equation. The optimal controls are given by the appropriate optimality systems, see [2]. In order to justify the approximation of (OCE) by (OCS), we study the turnpike property of the couple (OCE)-(OCS). For a recent survey on the turnpike property in optimal control, see [3, 4] and the references therein. Several forms of the turnpike phenomenon have been studied in detail, for example, the exponential turnpike property (see [5]) and the interval turnpike property, see [6]. Numerical issues and the turnpike phenomenon in optimal shape design with parabolic PDEs have been studied in [7].

Note that in our paper, we study the application of the turnpike property to shape optimization. This is a novel approach. The turnpike property for control problems in variable domain setting has been considered in [8]. In this paper, the optimal control determined from the optimality system for (OCS) is used to construct an approach for the determination of the optimal shape that is computationally tractable. Simpler optimum design problems with linear models are considered, e.g., in [9]. Our approach is more general.

We specify our approach for the networks, but it could also be used for standard control problems if the existence of an optimal shape is known. In the case of networks the existence of an optimal shape \(\Omega \) is simpler compared to the case of PDEs defined in geometrical domains in \({\mathbb {R}}^n\) for \(n=2\), 3, see [10] for the elasticity system.

The outline of the paper is the following. We introduce two optimal control problems (OCE) and (OCS) with the controls \(u=u(t,x)\) and \(v=v(x)\) and the optimal controls \({\hat{u}}\) and \({\hat{v}}\), respectively. The geometrical domain of the network is designated by \(\Omega \). Thus \({\hat{u}}={\hat{u}}(T, \Omega ;t,x)\) and \({\hat{v}}={\hat{v}}(\Omega ;x)\) for the spatial variable \(x\in \Omega \) and the time horizon T for (OCE). The cost functional for (OCE) takes the form

$$\begin{aligned} u\longmapsto \frac{1}{2}\int _0^T\int _\Omega (y(u)-y_d)^2 + \gamma \, (y_t(u))^2 dx \, dt +\frac{1}{2}\int _0^T\int _\Gamma (u-u_d)^2d\Gamma (x)dt \nonumber \\ \end{aligned}$$
(1)

where y(u) denotes the state that is generated by the control u. For systems that are governed by the wave equation, a regularization parameter \(\gamma >0\) should be chosen, since we need the velocity part in the cost. In the parabolic case, we do not need such a term hence \(\gamma =0\) can be chosen.

Our aim is to study the shape optimization problem for the modified shape functional

$$\begin{aligned} \Omega \longmapsto \frac{1}{2}\int _0^T\int _\Omega (y({\hat{v}})-y_d)^2 + \gamma \, (y_t({\hat{v}}))^2 \, dx\,dt +\frac{1}{2}\int _0^T\int _\Gamma ({\hat{v}}-u_d)^2d\Gamma (x)dt. \nonumber \\ \end{aligned}$$
(2)

In this approach, we replace the optimal control for (OCE) by the optimal control for (OCS) and as a result we get the shape functional (2) for the optimum design of the network. Such a procedure will be justified by the turnpike property of the couple (OCE) and (OCS).

We want to mention some recent contributions about shape optimization problems from the literature. While the time-dependent shape optimization problem for the heat equation has already been studied in the literature (see e.g. [11]), fewer results are known for the hyperbolic case (see e.g. [12]). In [13] the problem of mitigation of coastal erosion is studied where the water flow is modeled by the porous shallow water equations.

2 Optimal Control Problems on Graphs

Let us consider the finite connected graph \(G=(V, \, E)\) with \(V=\{ P_j | j\in \mathcal {J}\}\) the set of vertices and \(E=\{ E_i | i\in \mathcal {I}\}\) the set of edges. We consider the evolution equations on the edges of G. The dynamics of the edges are coupled by suitable node conditions for example Kirchhoff–type. Therefore we assume that the edges correspond to curves \(\Omega _i\) in \({{\mathbb {R}}}^1\), \({{\mathbb {R}}}^2\), or \({{\mathbb {R}}}^3\).

Define \(\Omega = \overline{ \cup _{ i\in \mathcal {I} } \Omega _i} \). We are interested in control problems defined on G. The controls are denoted by \(v:=v(x)\) with \(x\in \Omega \), and by \(u_T:=u_T(x,t)\) with \(x\in \Omega \) and \(t\in (0,T)\). There are two control problems, the first is the static control problem, and the second is the evolution control problem. The static state equation gives the state \(z:=z(v;x)=z(x)\) that is determined by the state equation for

$$\begin{aligned} z\in H\,:\, a(z,\phi )=(L(v),\phi )+ (f,\phi ),\,\,\forall \phi \in H , \end{aligned}$$
(3)

where \(x\mapsto z(v;x)\) lives in the Hilbert space H. In the applications usually H is a Sobolev space. We assume that the bilinear form \(a(\cdot ,\cdot )\) is symmetric and coercive with a bounded linear operator L from the space of controls to H and \(f\in H\).

As an example, consider the evolution equation the governs the state denoted by \(y:=y(u;x,t)=y(x,t)\) in variational form for \(t\mapsto y(u;x,t)\):

$$\begin{aligned} \left( \frac{\partial ^2 y}{\partial ^2 t}(t),\varphi \right) +a(y(t),\varphi )= (L(u)(t),\varphi )+(F(t),\varphi ) \end{aligned}$$
(4)

for all \(\varphi \in H\) and a.e. for \(t\in (0,T)\), along with the initial conditions \(y(0,x)=y^0(x)\) and \(y_t(0,x)=y^1(x)\). Here H is the Hilbert space that contains the functions with \(H^1\)-regularity on the edges that are compatible with the node conditions that are prescribed on the vertices. Moreover, \(F(t)=f\) for all \(t\in (0, \, T)\).

In both cases, the controls are introduced as the distributed controls on edges and the boundary controls on vertices.

Remark 1

In order to solve the state equation (4) we will use the spectral method under some assumptions. There are two different types of networks under consideration. The first graph is a tree and the shape optimization with respect to the length of edges is analyzed. In such a case the first eigenvalue of the elliptic-steady state operator is supposed to be strictly positive uniformly on the set of admissible shapes. The set of admissible shapes for the tree is compact in the finite dimensional space \({\mathbb {R}}^N\). The second graph includes cycles.

Remark 2

For the purposes of topology optimization a small cycle replaces a central node \(P_0\) in the tree, the central node is selected by using the topological derivative of the cost, see Figs. 11 and 12.

Let us consider for the static problem the Laplacian \(-\partial _{xx}\) on the edges of the graph. Under appropriate geometric assumptions the eigenvalues supported by a small cycle of size \(\varepsilon \rightarrow zero\) are given e.g., by \(\mu _n=\left( \dfrac{n\Pi }{\varepsilon }\right) ^2\) for \(n=1,2,\dots \) with the eigenfunctions nontrivial only on the edges of the cycle \(\psi _n(x)=\sin {\left( \dfrac{n\Pi x}{\varepsilon }\right) }\). The singular behaviour of the branch \(\{ \mu _n\}_n\) of the spectrum means that for fixed n, \(\mu _n\rightarrow \infty \) with \(\varepsilon \rightarrow 0+\). The fundamental question is if the spectral proof of turnpike property holds in such a case. We need some regularity of solutions to the wave equation uniform with respect to the size of the cycle.

The required regularity assumption on the initial conditions of the wave equation assures the appropriate regularity of solutions with respect to time variable t. Such an assumption implies that the constant displacement on the cycle is not allowed, however, the constant velocity is allowed, see (77) for details.

Indeed, let us consider the constant displacement and denote by \(E(\varepsilon )\) the energy associated with the initial conditions in function of the size of the cycle. Such an energy associated with the constant initial state \(y(0)=1\) at the cycle can be evaluated using (77), where the coefficients of the expansion over the eigenfunctions read

$$\begin{aligned} a_k^\varepsilon =\int _0^\varepsilon \psi _k(x)dx =\int _0^\varepsilon \sin {\left( \dfrac{k\Pi x}{\varepsilon }\right) } dx= -\dfrac{\varepsilon }{k\Pi }\left. \cos {\left( \dfrac{k\Pi x}{\varepsilon }\right) }\right| ^\varepsilon _0. \end{aligned}$$

Therefore, the energy in (77) is unbounded, thus the constant initial state is not allowed for the cycle. Similarly, the positive result is shown for the constant velocity.

Remark 3

The singular perturbations of the geometry for networks are of different nature for the static state equations and for the wave equations. Therefore, we have constructive results in the case of elliptic problems which are combined with the turnpike property in order to design the topology of the network. This is a new result to our best knowledge.

We need as well the cost functional, the simplest possibility is the quadratic cost with the appropriate choice of norms in Hilbert function spaces. For the static problem, it is

$$\begin{aligned} I(v)=\frac{1}{2}\Vert z-z^d\Vert _{L^2(\Omega )}^2+\frac{1}{2}\Vert v-v^d\Vert _{L^2(\Gamma )}^2. \end{aligned}$$
(5)

For the evolution problem, it is

$$\begin{aligned} J_T(u)= & {} \frac{1}{2}\int _0^T\Vert y-y^d\Vert _{L^2(\Omega )}^2 + \gamma \, \Vert \partial _t( y-y^d)\Vert _{L^2(\Omega )}^2 dt\nonumber \\{} & {} +\frac{1}{2}\int _0^T\Vert u-u^d\Vert _{L^2(\Gamma )}^2dt \end{aligned}$$
(6)

where \(\gamma \in (0, \, \infty )\). For the sake of simplicity, we consider the control problems without constraints.

The optimality conditions are necessary and sufficient and can be obtained by using the Lagrangian formalism. To this end, we need the adjoint states, which simplify the formulas for the gradients of the cost with respect to controls. We ask two questions now: the first is the shape and topology optimization for the graph with respect to the control problem, this results in the bi-level optimization problem for the graph. The second question is the turnpike property for the two-level optimization problem for the graph. To our best knowledge, such a problem has not been considered in the literature.

3 Optimality System for the Static Problem

We denote by \(({\hat{v}},{\hat{z}},{\hat{p}})\) the unique optimal solution of static control problem. Let us note that the uniqueness of the optimal control \({\hat{u}}\) follows by convexity of variational problem under consideration with quadratic cost functional and the linear state equation. The optimal solution is given by the optimality system which depends on the shape, or design \(\Omega \) of the network as an infinite dimensional factor or parameter to be selected at the upper level of optimization over the class of admissible shapes. The class of admissible shapes is denoted by \(S_{ad}\), and the continuous variation of the shape is denoted by \(\Omega _{\tau }\in S_{ad}\) with the real parameter \(\tau \in (-\delta ,\delta )\) for some \(\delta >0\) for shape variations. We use as well the singular perturbations of the shape denoted by \(\Omega _{\epsilon }\in S_{ad}\) for the topology variations with \(\epsilon \rightarrow 0\).

Remark 4

In the case of a network, there are at least two possibilities of shape variations. The first is the change of the lengths of edges, it corresponds to the boundary variations in the classical shape optimization. The second, which corresponds to the topology variations in the shape optimization means the presence of a small cycle within the network with the small size of the cycle \(\epsilon \rightarrow 0\).

The optimality system for the static control problem is equivalent to the vanishing of the gradient for the cost, hence

$$\begin{aligned} \min _{v}\{ J(v) \}=J({\hat{v}}) \end{aligned}$$

iff the following optimality system is verified

$$\begin{aligned} {\hat{z}} \in H\, :\, a({\hat{z}},\varphi )&=(L({\hat{v}}),\varphi )+ (f,\varphi )\,\,\forall \varphi \in H \,, \end{aligned}$$
(7)
$$\begin{aligned} {\hat{p}}\in H\, :\, a({\hat{p}},\phi )&=(z_d-{\hat{z}},\phi )\,\,\forall \phi \in H \,, \end{aligned}$$
(8)
$$\begin{aligned} (v_d-{\hat{v}},v)_U&=(L^{\prime }({\hat{v}})\cdot v,{\hat{p}})\,\,\forall v\in U\,. \end{aligned}$$
(9)

In the linear case we have \(L^{\prime }({\hat{v}})\cdot v=L(v)\). The optimality system is derived using the Lagrangian formalism,

$$\begin{aligned} {\mathcal {L}}(v,z,\phi )=\frac{1}{2}\Vert z-z^d\Vert _{L^2(\Omega )}^2+\frac{1}{2}\Vert v-v^d\Vert _{L^2(\Gamma )}^2 + a(z,\phi )-(L(v),\phi )- (f,\phi ) \end{aligned}$$

Then the adjoint state \(p\in H\) is introduced

$$\begin{aligned} \partial _z{\mathcal {L}}(v,z,p)(\phi )=(z-z_d,\phi )_{\Omega }+a(p,\phi )=0\,\,\forall \phi \in H \end{aligned}$$

and the gradient of the cost is obtained

$$\begin{aligned} dI(v;\eta )=\partial _v{\mathcal {L}}(v,z,p)(\eta )=(v-v^d,\eta )_\Gamma -(p,\eta )_\Gamma \end{aligned}$$

which leads to the optimality condition

$$\begin{aligned} v-v^d=p \,\, \mathrm{a.e.\,\, on \,\,}\Gamma . \end{aligned}$$

In the case of distributed control, we have \(\Gamma =\Omega \).

Proposition There exists the unique solution \(({\hat{v}},{\hat{z}},{\hat{p}})\) to the optimality system (7)–(9). The optimal value of the cost \(J({\hat{v}}):=J({\hat{v}}(\Omega ))\) is defined as a shape functional over the set \(S_{ad}\). Therefore, we consider the optimum design of the network

$$\begin{aligned} \inf _{\Omega \in S_{ad}}J({\hat{v}}(\Omega )). \end{aligned}$$
(10)

The analysis of such a variational problem requires:

  1. 1.

    The existence of solutions;

  2. 2.

    The necessary optimality conditions;

  3. 3.

    Finally, numerical methods for solution.

In particular, we perform the shape calculus and determine the shape gradient of the optimal control cost

$$\begin{aligned} \Omega \longmapsto J({\hat{v}}(\Omega )) \end{aligned}$$

as well as the topological derivative obtained at \(\epsilon :=0^+\) for the mapping

$$\begin{aligned} \epsilon \longmapsto J({\hat{v}}(\Omega _{\epsilon })). \end{aligned}$$

Remark 5

It is useful for applications to introduce a random right-hand side \(f:=f(\omega ;x)\) to the state equation (3).

4 Optimality System for the Evolution Problem

Let \(Q = (0, T) \times \Omega \). integration by parts yields

$$\begin{aligned}&\int _0^T \left( \frac{\partial ^2 y}{\partial ^2 t}(t),p(t)\right) _{L^2(\Omega )}dt \\&\quad =-\int _0^T \left( \frac{\partial y}{\partial t}(t),\frac{\partial p}{\partial t}(t)\right) _{L^2(\Omega )}dt +\left( \frac{\partial y}{\partial t}(T),p(T) \right) _{L^2(\Omega )}-\left( \frac{\partial y}{\partial t}(0),p(0) \right) _{L^2(\Omega )} \\&\quad =-\int _0^T \left( \frac{\partial y}{\partial t}(t),\frac{\partial p}{\partial t}(t)\right) _{L^2(\Omega )}dt +\left( \frac{\partial y}{\partial t}(T),p(T) \right) _{L^2(\Omega )} -\left( y^1,p(0) \right) _{L^2(\Omega )}. \end{aligned}$$

Now, we assume \(p(T)=0\) which leads to the integration by parts formula

$$\begin{aligned} \int _0^T \left( \frac{\partial ^2 y}{\partial ^2 t}(t),p(t)\right) _{L^2(\Omega )}dt= -\int _0^T \left( \frac{\partial y}{\partial t}(t),\frac{\partial p}{\partial t}(t)\right) _{L^2(\Omega )}dt -\left( y^1,p(0) \right) _{L^2(\Omega )}. \end{aligned}$$

Remark 6

If we add the state constraint \(y_t(T)=0\) then the integration by parts formula is the same but the terminal condition for p(T) becomes undetermined, i.e., we loose the homogeneous condition for the terminal adjoint state.

We derive the optimality system for the optimal control problem with the evolution state equation. To this end, we introduce the Lagrangian \( {\mathcal {L}}(u, y, \varphi ) \) with \(y\in L^2(0,T;H^1(\Omega ))\), \(y_t\in L^2(Q)\), \(y(0)=y^0\), and \(\varphi \in L^2(0,T;H^1(\Omega ))\), \(\varphi _t\in L^2(Q)\), \(\varphi (T)=0\);

$$\begin{aligned} {\mathcal {L}}(u, y, \varphi )&= \frac{1}{2}\int _0^T\Vert y-y^d\Vert _{L^2(\Omega )}^2dt + \frac{1}{2}\int _0^T\Vert u-u^d\Vert _{L^2(\Gamma )}^2dt \\&\quad + \frac{\gamma }{2} \int _0^T \Vert \partial _t( y-y^d)\Vert _{L^2(\Omega )}^2 dt \\&\quad -\int _0^T \left( \frac{\partial y}{\partial t}(t),\frac{\partial \varphi }{\partial t}(t)\right) _{L^2(\Omega )}dt -\left( y^1,\varphi (0) \right) _{L^2(\Omega )} + \int _0^T a(y(t),\varphi )dt \\&\quad - \int _0^T (L(u)(t),\varphi )_{L^2(\Gamma )}dt - \int _0^T (F(t),\varphi )_{L^2(\Omega )}dt. \end{aligned}$$

The adjoint state \(p=p(u;x,t)\) is obtained by differentiation of Lagrangian with respect to the state, thus with \(Q(T) = (0, T) \times \Omega \)

$$\begin{aligned} (p_{tt},\varphi )_{Q(T)} + \int _0^T a(p,\varphi ) \, dt= & {} (y^d-y,\varphi )_{Q(T)} +\gamma \, (\partial _t( y^d-y), \; \varphi _t)_{Q(T)} \,\, \forall \varphi \in H(Q(T))\\ p(T)= & {} 0, p_t(T)= {\gamma \, y_t(T)}. \end{aligned}$$

The following lemma contains the necessary optimality conditions for the dynamic problem where \(J_T(u)\) as defined in (6) is minimized.

Lemma 1

The optimality system for the optimal control of evolution control problem is verified for a.e. \(t\in (0,T)\):

$$\begin{aligned} ({\hat{y}}_{tt},\varphi )_{Q(T)} +\int _0^T a({\hat{y}}(t),\varphi ) \, dt = \int _0^T(L({\hat{u}})(t),\varphi )_\Gamma \, dt +(F(t),\varphi )_{Q(T)}\,\, \end{aligned}$$
(11)
$$\begin{aligned} \forall \varphi \in H(Q(T)) \nonumber \\ {\hat{y}}(0)=y^0,\,\, {\hat{y}}_t(0)=y^1 \end{aligned}$$
(12)
$$\begin{aligned} ({\hat{p}}_{tt},\varphi )_{Q(T)}+ \int _0^T a({\hat{p}},\varphi ) \, dt = (y^d-{\hat{y}} + \gamma \, {\hat{y}}_{tt} ,\varphi )_{Q(T) }\, \end{aligned}$$
(13)
$$\begin{aligned} \forall \varphi \in H(Q(T)) \nonumber \\ {{\hat{p}}}(T)= 0,\, {{\hat{p}}}_t(T)= {\gamma \, {\hat{y}}_t(T)} \end{aligned}$$
(14)
$$\begin{aligned} ( {\hat{u}}-u^d,\eta )_{\Gamma }- (L(\eta )(t),{\hat{p}}(t))_{\Gamma }=0\,\,\forall \eta \in L^2(\Sigma ) \end{aligned}$$
(15)

The optimality system (11)–(15) admits a unique solution \(({\hat{u}},{\hat{y}},{\hat{p}})\).

Remark 7

We use the notation, \(({\hat{y}}_{tt},\varphi )_{Q(T)}\) and \(({\hat{p}}_{tt},\varphi )_{Q(T)}\) for the scalar product in \(L^2(Q(T))\) as well as for the duality pairing between \(L^2(0,T;H^1(\Omega ))\) and its dual.

5 The Difference of the Static and the Dynamic Optimality Systems for Distributed Control

In this section, we study a system that is satisfied by the ordered pair that has the difference between the optimal dynamic state for the time horizon T and the optimal static state as the first component and the difference between the optimal dynamic adjoint state for the time horizon T and the optimal static adjoint state as the second component. The question of long time versus steady state optimal control has already been studied in [14] where the focus is on the turnpike property of the state and the control without the adjoint state. The turnpike phenomenon for optimal boundary control problems with first order hyperbolic systems is considered in [15].

We assume that \(\Gamma =\Omega \) and the operators L(v) and L(u) are identity operators in \(L^2(\Omega )\) and \(F(t)=f\), \(u^d(t) = v_d\), \(y^d = z_d\) for \(t\in [0, \, T]\) almost everywhere. The optimality system for the static problem reads

$$\begin{aligned} {\hat{z}}^{\sigma } \in H\, :\, a({\hat{z}}^{\sigma },\varphi )&=({\hat{v}}^{\sigma },\, \varphi )_{L^2(\Omega )}+ (f,\varphi )_{L^2(\Omega )}\,\,\forall \varphi \in H, \end{aligned}$$
(16)
$$\begin{aligned} {\hat{p}}^{\sigma }\in H\, :\, a({\hat{p}}^{\sigma },\phi )&=(z_d-{\hat{z}}^{\sigma },\phi )_{L^2(\Omega )}\,\,\forall \phi \in H, \end{aligned}$$
(17)
$$\begin{aligned} {\hat{v}}^{\sigma } - v_d&= {\hat{p}}^{\sigma }\,\,\mathrm{a.e.\,\, in}\,\Omega . \end{aligned}$$
(18)

The optimality system for the evolution problem implies for \(t\in [0, \, T]\) almost everywhere (with \(F(t)=f\))

$$\begin{aligned} ({{\hat{y}}}^T_{tt}(t),\varphi )_{L^2(\Omega )} +a({{\hat{y}}}^T(t),\varphi )&= ({{\hat{u}}}^T(t),\varphi )_{L^2(\Omega )}+(F(t),\varphi )_{L^2(\Omega )}\,\,\forall \varphi \in H \end{aligned}$$
(19)
$$\begin{aligned} {{\hat{y}}}^T(0)&=y^0,\,\, {{\hat{y}}}^T_t(0)=y^1 \end{aligned}$$
(20)
$$\begin{aligned} ({{\hat{p}}}^T_{tt}(t),\varphi )_{L^2(\Omega )}+a({{\hat{p}}}^T(t),\varphi )&=(y^d-{{\hat{y}}}^T(t) +\gamma \, {\hat{y}}_{tt} ,\varphi )_{L^2(\Omega )}\, \,\forall \varphi \in H \end{aligned}$$
(21)
$$\begin{aligned} {{\hat{p}}}^T(T)&=0, \; {{\hat{p}}}^T_t(T)= {\gamma \, {\hat{y}}_t(T)} \end{aligned}$$
(22)
$$\begin{aligned} {{\hat{u}}}^T(t) - u^d&= {{\hat{p}}}^T(t)\,\,\mathrm{a.e.\,\, in}\,\,\Omega \times (0,T). \end{aligned}$$
(23)

Define the differences

$$\begin{aligned} \omega ^T = {{\hat{y}}}^T - {{\hat{z}}}^{\sigma }, \, \mu ^T = {{\hat{p}}}^T - {{\hat{p}}}^{\sigma }, \nu ^T = {{\hat{u}}}^T - {\hat{v}}^{\sigma }. \end{aligned}$$

Then for all \(\varphi \in H\) we have the initial condition

$$\begin{aligned} \omega ^T(0) = y^0- {{\hat{z}}}^{\sigma },\; \omega ^T_t(0) = y^1, \end{aligned}$$
(24)

the terminal conditions

$$\begin{aligned} \mu ^T(T) = -{{\hat{p}}}^{\sigma },\; \mu ^T_t(T) = {\gamma \, \omega _t(T) }, \end{aligned}$$
(25)

the dynamics

$$\begin{aligned} ( \omega ^T_{tt}(t),\varphi )_{L^2(\Omega )}+a(\omega ^T(t),\varphi ) =(\nu ^T(t),\varphi )_{L^2(\Omega )} = (\mu ^T(t),\varphi )_{L^2(\Omega )} \end{aligned}$$
(26)

and with the assumption that \(y^d = z_d\) and \(u^d =v_d\)

$$\begin{aligned} ( \mu ^T_{tt}(t),\varphi )_{L^2(\Omega )}+a(\mu ^T(t),\varphi ) = - (\omega ^T(t),\varphi )_{L^2(\Omega )} + \gamma \, ( \omega ^T_{tt}(t),\varphi )_{L^2(\Omega )}. \end{aligned}$$
(27)

Note that for the difference system, the existence of a solution is implied by the construction as the difference between two systems, for which solutions exist.

Note that for the energy

$$\begin{aligned}E(t) ={} & {} \frac{(\omega ^T_{t}(t), \, \omega ^T_{t}(t))_{L^2(\Omega )}+a( \omega ^T(t),\, \omega ^T(t))}{2} \\{} & {} \quad + \frac{(\mu ^T_{t}(t), \, \mu ^T_{t}(t))_{L^2(\Omega )}+a( \mu ^T(t), \, \mu ^T(t))}{2} \end{aligned}$$

due to (26) and (27) for \(\gamma =0\) we have

$$\begin{aligned}E''(t) \ge ( \omega ^T(t), \, \omega ^T(t))_{L^2(\Omega )} + ( \mu ^T(t), \, \mu ^T(t))_{L^2(\Omega )}\ge 0.\end{aligned}$$

Thus in this case E is convex on \([0, \, T]\).

Now we perform a spectral analysis to show the exponential turnpike property.

Assume that there exists a complete orthonormal sequence \((\psi _k)_{k=1}^\infty \) of eigenfunctions with \(a(\psi _k, \,\varphi ) = \lambda _k (\psi _k, \, \varphi )_{L^2(\Omega )}\) for all \(k\in \{0,1,2,3,..\}\) where

$$\begin{aligned} \lambda _k\ge {\gamma } >0 \end{aligned}$$
(28)

is a real number.

Remark 8

In the case of optimal design, the bilinear form depends on \(\Omega \). In the case of a graph, this means the dependence of the lengths of the edges. In this case, the eigenvalues and eigenfunctions depend on these parameters that we denote by \(\ell \). Therefore a meaningful analysis has to take into account the sensitivity with respect to \(\ell \).

Our assumption on the feasible designs is that the smallest eigenvalues is greater than or equal to the given strictly positive lower-bound \(\gamma >0\) uniformly on the set of admissible designs. In this way, we ensure that the turnpike property is valid for the bilevel optimization problem that we consider in this paper.

It is well known that the smallest eigenvalue that can be characterized as the Rayleigh quotient depends smoothly on the parameters, see [16]. In our analysis, the particular structure of the spectrum is not relevant.

Then we can use the representations

$$\begin{aligned} \omega ^T = \sum _{k=0}^\infty a_k(t) \,\psi _k(x), \;\; \mu ^T = \sum _{k=0}^\infty b_k(t) \,\psi _k(x) \end{aligned}$$
(29)

to show that \(\omega ^T\) and \(\mu ^T\) have the turnpike property.

It is clear that the functions \(a_k\) and \(b_k\) depend on T as a parameter, so a more precise notation would be \(a_{k,T}(t)\) and \(b_{k,T}(t)\). However, in order to make the text more concise we continue with the shorter notation \(a_k\) and \(b_k\).

From (26) and (27) we obtain \(a_k'' = - \lambda _k \, a_k + b_k\) and \(b_k'' = - \lambda _k \, b_k - a_k + \gamma \, a_k''\).

Thus we have the sequence of differential equations (for \(k \in \{0,1,2,...\}\))

$$\begin{aligned}{} & {} a_k^{(4)} + ( 2 \,\lambda _k - \gamma ) \, a_k^{(2)} + (\lambda _k^2 + 1) \, a_k =0,\nonumber \\{} & {} b_k^{(4)} + ( 2 \,\lambda _k - \gamma ) \, b_k^{(2)} + (\lambda _k^2 + 1) \, b_k =0. \end{aligned}$$
(30)

Define the characteristic polynomial

$$\begin{aligned}p_k(z) = z^4 + (2 \,\lambda _k - \gamma ) \,z^2 + (\lambda _k^2 + 1).\end{aligned}$$

Since \(p_k\) is a polynomial in \(z^2\), for the roots \(z^{(l)}_k\) of \(p_k\) we obtain

$$\begin{aligned} (z^{(l)}_k)^2 = \frac{\gamma }{2} - \lambda _k \pm \frac{i}{2} \sqrt{4 + 4 \lambda _k \,\gamma - \gamma ^2 } \end{aligned}$$

for \(l\in \{1,2,3,4\}\) which implies \( \left| (z^{(l)}_k)^2 \right| = \sqrt{ 1 +\lambda _k^2}. \) Thus there are two pairs of complex conjugate roots and we have the representation

$$\begin{aligned}p_k(z) = (z - z^{(1)}_k) (z - \overline{ z^{(1)}_k} ) (z + z^{(1)}_k ) (z + \overline{ z^{(1)}_k}).\end{aligned}$$

We have \(|z^{(l)}_k|^4 = \lambda _k^2 + 1 \), \( Re((z^{(l)})^2_k ) = \frac{\gamma }{2} - \lambda _k\) and \( |Im((z^{(l)})^2_k)| = \frac{ \sqrt{4 + 4\, \lambda _k \,\gamma - \gamma ^2 }}{2} \). Moreover, we have

$$\begin{aligned} |Re(z^{(l)}_k )| = \sqrt{\frac{\gamma }{4} + \frac{1}{2 (\lambda _k + \sqrt{ 1 + \lambda _k^2} ) } } \end{aligned}$$

and

$$\begin{aligned} |Re(z^{(l)}_k)| \ge \frac{ \sqrt{\gamma }}{2}. \end{aligned}$$
(31)

The initial condition (24) yields the values for \(a_k(0)\) and \(a_k'(0)\). The terminal condition (25) yields the value for \(b_k(T)\) and \(b_k'(T)= {\gamma \, a_k '(T) } \). Note that (25) implies that the value of \(b_k(T)\) is independent of T.

For the sake of conciseness, in the sequel we use the notation \(z_k = z^{(1)}_k\).

5.1 Representation of the Solution

Since

$$\begin{aligned} a_{k,T}' = \frac{1}{1 + \gamma \, \lambda _k} \left[ - b_{k,T}''' + (\gamma - \lambda _k ) b_{k,T}' \right] , \end{aligned}$$
(32)

the solution of the optimality system means that for the coefficients \(b_{k,T}\) of \(\mu ^T\) as defined in (29) we solve a boundary value problem with the ODE of order four (30) i.e.

$$\begin{aligned} \left\{ \begin{array}{rlc} b_{k,T}^{(4)} + ( 2 \,\lambda _k - \gamma ) \, b_{k,T}^{(2)} + (\lambda _k^2 + 1) \, b_{k,T} &{} = &{} 0 \\ b_{k,T}(T) &{} = &{} \beta _k \\ b_{k,T}'(T) &{} = &{} { \frac{ \gamma }{1 + \gamma \, \lambda _k} \left[ - b_{k, T}'''(T) + (\gamma - \lambda _k ) \, b_{k, T}'(T) \right] } \\ - b_{k,T}''(0)+ (\gamma - \lambda _k) \, b_{k,T}(0) &{} = &{} (1 + \gamma \, \lambda _k) \, a_{k,T}(0) \\ - b_{k,T}'''(0)+ (\gamma - \lambda _k) \, b_{k,T}'(0) &{} = &{} (1 + \gamma \, \lambda _k) \, a_{k,T}'(0). \end{array} \right. \end{aligned}$$
(33)

where the value of \(\beta _k\) is determined by the terminal condition \( \mu ^T(T) = - {{\hat{p}}}^{\sigma }\) in (25). We represent the solution in the form

$$\begin{aligned} b_{k,T}(t) = F_{k,T}(t) \, \beta _k + (1 + \gamma \, \lambda _k) [G_{k,T}(t) \, \, a_{k,T} (0) + H_{k,T}(t) \, a_{k,T}' (0)]. \end{aligned}$$
(34)

The following Lemma contains explicit representations of \(F_{k,T}\), \(G_{k,T}\) and \(H_{k,T}\). In the representation, the numbers d(kT) appear as multipliers, therefore it is important that for T sufficiently large we have \(d(k, T) \not = 0\). Since in the study of the turnpike phenomenon we are interested in large time horizons, the assumption that the time horizon T is large is not restrictive for us. We introduce the notation

$$\begin{aligned} \Xi _k:= \gamma - \lambda _k - z_k^2 = \frac{\gamma }{2} {\mp } \frac{i}{2} \sqrt{4 + 4 \,\lambda _k \gamma - \gamma ^2}. \end{aligned}$$
(35)

Lemma 2

Define

$$\begin{aligned} q_k = \frac{ \gamma ^2 - 2 \, \gamma \, \lambda _k -1}{\gamma }. \end{aligned}$$

For \(k \in \{0,1,2,...\}\) and T sufficiently large define the numbers

$$\begin{aligned}{} & {} d(k, T) \nonumber \\{} & {} \quad = - 2 Re \left( \frac{\Xi _k^2}{ { z_k^2 - q_k } } \right) + 2 |\Xi _k|^2 Re \left( \frac{1}{ { z_k^2 - q_k } } |\cosh ^2( z_k T )| - \frac{ \overline{z_k} }{z_k} \frac{1}{ {z_k}^2 - q_k } |\sinh ^2( z_k T )| \right) .\nonumber \\ \end{aligned}$$
(36)

Then we have

$$\begin{aligned}{} & {} d(k, T) \, F_{k,T}(t) \\{} & {} \quad = 2Re \left( \left[ - \frac{\overline{\Xi _k}^2 }{ \overline{z_k}^2 - q_k } + \frac{|\Xi _k|^2 }{{z_k}^2 - q_k } \cosh (z_k \, T) \cosh (\overline{z_k}T) \right] \cosh ( z_k (t- T) ) \right) \\{} & {} \qquad + 2Re \left( \frac{ |\Xi _k|^2 }{ z_k^2 - q_k } \cosh ( \overline{z_k} T) \sinh (z_k T) \sinh ( z_k(t - T) ) \right) \\{} & {} \qquad - 2 Re \left( \frac{ |\Xi _k|^2 }{ z_k^2 - q_k } \frac{\overline{z_k}}{z_k} \sinh ( \overline{z_k} T) \left[ \sinh (z_k \, T) \cosh ( z_k (t- T) ) + \cosh (z_k T) \sinh ( z_k(t - T) ) \right] \right) . \end{aligned}$$

Furthermore, it holds

$$\begin{aligned}{} & {} d(k, T) \, G_{k,T}(t) \nonumber \\{} & {} \quad = 2 Re \left( \frac{\overline{\Xi _k} }{ \overline{z_k}^2 - q_k } \cosh ( \overline{z_k} T) \left[ \cosh ( z_k (t- T) ) - \cosh (\overline{z_k} (t- T)) \right] \right) \nonumber \\{} & {} \qquad + 2 Re \left( \frac{1}{ {z_k}^2 - q_k } \left[ \frac{\overline{z_k} }{ {z_k} } \overline{\Xi _k} \sinh ( \overline{z_k} T) - {\Xi _k} \sinh ( {z_k} T) \right] \sinh ({z_k} (t- T) ) \right) \nonumber \\ \end{aligned}$$
(37)

and

$$\begin{aligned}{} & {} d(k, T) \, H_{k,T}(t) \\{} & {} \quad = - 2 Re \left( \frac{{\Xi _k} }{ z_k ({z_k}^2 - q_k) } \sinh ( {z_k} T) \left[ \cosh ( z_k (t- T) ) - \cosh ( \overline{z_k} (t- T) ) \right] \right) \\{} & {} \qquad + 2 Re \left( \frac{ \overline{\Xi _k} }{ {z_k} ({z_k}^2 - q_k) } \cosh ( \overline{z_k} T) \, \sinh ({z_k} (t- T) ) \right. \\{} & {} \qquad \left. - \frac{ \overline{\Xi _k} }{ \overline{z_k} (\overline{z_k}^2 - q_k) } \cosh ( \overline{z_k} T) \sinh (\overline{z_k} (t- T) ) \right) . \end{aligned}$$

Proof

Due to the properties of the hyperbolic functions that can be found for example in [17, 18] we have

$$\begin{aligned} d(k, T)= & {} - 2\, Re\left( \frac{\Xi _k^2}{ { z_k^2 - q_k } } \right) \nonumber \\{} & {} + |\Xi _k |^2 \left( \frac{ Re\left( ( {z_k}^2 - q_k) (|z_k|^2 - z_k^2 ) \right) }{ | z_k^2 | \, |{z_k}^2 - q_k| } \right) \cosh ( 2 \, Re(z_k)\, T) \nonumber \\{} & {} + |\Xi _k |^2 \left( \frac{ Re\left( ( {z_k}^2 - q_k) (|z_k|^2 + z_k^2 ) \right) }{ | z_k^2 | \, |{z_k}^2 - q_k| } \right) \cosh ( 2 \, Im(z_k)\, T). \end{aligned}$$
(38)

This implies \(\lim _{T\rightarrow \infty } | d(k, T) | = \infty \), hence for all sufficiently large T we have \( d(k, T) \not =0\). In the remaining part of the proof, we assume that \( d(k, T) \not =0\). Moreover, we see that d(kT) grows exponentially fast with T with the growth rate

$$\begin{aligned} 2{Re}(z_k)\ge \sqrt{\gamma } \end{aligned}$$
(39)

due to (31). To be more precise, note that \(|\Xi _k |^2 = 1 + \gamma \,\lambda _k \) grows with the order \(\lambda _k\).

At this point, elementary computations show that \({F_{k,T}(t)} \), \({G_{k,T}(t)} \) and \({H_{k,T}(t)} \) satisfy the differential equation and the boundary conditions where \(( \beta _k, a_{k,T} (0), \, \, a_{k,T}' (0)) \) have the values (1, 0, 0), (0, 1, 0), (0, 0, 1) respectively. Now we present details of the verification of these basic functions.

Since \( b_{k,T}'''(T) = q_k \, b_{k,T}'(T)\), we can make the ansatz

$$\begin{aligned}{} & {} b_{k,T}(t) = A_k^T \cosh ( z_k (t- T) ) + B_k^T \cosh ( \overline{z_k} (t- T) ) \nonumber \\{} & {} \quad + C_k^T \left[ \frac{1}{ z_k \, \left( z_k^2 - q_k \right) } \sinh ( z_k(t - T) ) - \frac{1}{ \overline{z_k} \left( \overline{z_k}^2 - q_k \right) } \sinh ( \overline{z_k}(t - T)) \right] .\nonumber \\ \end{aligned}$$
(40)

Now we return again to the sloppy notation \(a_k\), \(b_k\). Then

$$\begin{aligned} A_k^T + B_k^T = b_k(T). \end{aligned}$$

We have

$$\begin{aligned} a_k = \frac{ - b_k''+ (\gamma - \lambda _k) \, b_k}{ 1 + \gamma \, \lambda _k}. \end{aligned}$$
(41)

Hence we obtain

$$\begin{aligned}{} & {} (1 + \gamma \, \lambda _k) \, a_k (t) \\{} & {} \quad = A_k^T \left( (\gamma \!-\! \lambda _k) - z_k^2 \right) \cosh ( z_k(t \!-\! T) ) + B_k^T \left( (\gamma - \lambda _k) \!-\! \overline{z_k}^2 \right) \cosh (\overline{z_k}(t - T)) \\{} & {} \qquad + C_k^T \left[ \frac{\gamma - \lambda _k - z_k^2}{z_k \left( {z_k}^2 - q_k \right) } \sinh ( z_k(t - T) ) - \frac{\gamma - \lambda _k - \overline{z_k}^2}{ \overline{z_k} \left( \overline{z_k}^2 - q_k \right) } \sinh ( \overline{z_k}(t - T)) \right] . \end{aligned}$$

Therefore, we have

$$\begin{aligned}{} & {} (1 + \gamma \, \lambda _k) \, a_k (0) \\{} & {} \quad = A_k^T \left( (\gamma - \lambda _k) - z_k^2 \right) \cosh ( z_k\, T ) + B_k^T \left( (\gamma - \lambda _k) - \overline{z_k}^2 \right) \cosh (\overline{z_k} \, T) \\{} & {} \qquad + C_k^T \left[ - \frac{\gamma - \lambda _k - z_k^2}{z_k \left( {z_k}^2 - q_k \right) } \sinh ( z_k \, T ) + \frac{\gamma - \lambda _k - \overline{z_k}^2}{ \overline{z_k} \left( \overline{z_k}^2 - q_k \right) } \sinh ( \overline{z_k} \, T) \right] . \end{aligned}$$

Due to (32) we have

$$\begin{aligned} (1 + \gamma \, \lambda _k) \, a_{k}'(t)= & {} - b_{k}'''(t) + (\gamma - \lambda _k ) b_{k}'(t) \\= & {} A_k^T (-z_k^3 + (\gamma - \lambda _k ) z_k) \sinh ( z_k (t- T) ) B_k^T ( - {\overline{z}}_k^3 \\{} & {} + (\gamma - \lambda _k ){{\overline{z}}}_k) \sin ( \overline{z_k} (t- T) ) \\{} & {} + C_k^T \left[ \frac{ (-z_k^3 + (\gamma - \lambda _k ) z_k ) }{ z_k \, \left( z_k^2 - q_k \right) } \cosh ( z_k(t - T) ) \right. \\{} & {} \left. - \frac{ ( - {\overline{z}}_k^3 + (\gamma - \lambda _k ){{\overline{z}}}_k) }{ \overline{z_k} \left( \overline{z_k}^2 - q_k \right) } \cosh ( \overline{z_k}(t - T)) \right] . \end{aligned}$$

Hence we have

$$\begin{aligned} (1 + \gamma \, \lambda _k) \, a_{k}'(0)= & {} - b_{k}'''(0) + (\gamma - \lambda _k ) b_{k}'(0) \\= & {} A_k^T ( z_k^3 - (\gamma - \lambda _k ) z_k) \sinh ( z_k T ) + B_k^T ( {\overline{z}}_k^3 - (\gamma - \lambda _k ){{\overline{z}}}_k) \sin ( \overline{z_k} T ) \\{} & {} + C_k^T \left[ \frac{ (-z_k^3 + (\gamma - \lambda _k ) z_k ) }{ z_k \, \left( z_k^2 - q_k \right) } \cosh ( z_k \, T )\right. \\{} & {} \left. - \frac{ ( - {\overline{z}}_k^3 + (\gamma - \lambda _k ){{\overline{z}}}_k) }{ \overline{z_k} \left( \overline{z_k}^2 - q_k \right) } \cosh ( \overline{z_k} T) \right] . \end{aligned}$$

In order to obtain a unique solution for the vector of coefficients \((A_k^T, B_k^T, C_k^T)\) we investigate the determinant of the corresponding \(3\times 3\) matrix M(T). For this purpose we introduce the notation

$$\begin{aligned} m_{21}(T)= & {} \left( \gamma - \lambda _k - z_k^2 \right) \cosh ( z_k T ), \\ m_{22}(T)= & {} \left( \gamma - \lambda _k - \overline{z_k}^2 \right) \cosh (\overline{z_k} T), \\ m_{23}(T)= & {} - \frac{\gamma - \lambda _k - z_k^2}{z_k \left( {z_k}^2 - q_k \right) } \sinh ( z_k \, T ) + \frac{\gamma - \lambda _k - \overline{z_k}^2}{ \overline{z_k} \left( \overline{z_k}^2 - q_k \right) } \sinh ( \overline{z_k} \, T) \\ m_{31}(T)= & {} - z_k\left( \gamma - \lambda _k - z_k^2 \right) \sinh ( z_k T ) = - m_{21}'(T), \\ m_{32}(T)= & {} - \overline{z_k} \left( \gamma - \lambda _k - \overline{z_k}^2 \right) \sinh (\overline{z_k} T) = - m_{22}'(T), \\ m_{33}(T)= & {} \frac{ ( (\gamma - \lambda _k ) - z_k^2 ) }{ \left( z_k^2 - q_k \right) } \cosh ( z_k \, T ) - \frac{ ( (\gamma - \lambda _k ) - {\overline{z}}_k^2 ) }{ \left( \overline{z_k}^2 - q_k \right) } \cosh ( \overline{z_k} T) = - m_{23}'(T). \end{aligned}$$

Note that we have the equations

$$\begin{aligned} m_{23}(T)= & {} \frac{1}{z_k^2 \left( {z_k}^2 - q_k \right) } m_{31}(T) - \frac{1}{\overline{z_k}^2 \left( \overline{z_k}^2 - q_k \right) } m_{32}(T).\\ m_{33}(T)= & {} \frac{1}{ \left( {z_k}^2 - q_k \right) } m_{21}(T) - \frac{1}{ \left( \overline{z_k}^2 - q_k \right) } m_{22}(T),\end{aligned}$$

We have the matrix

$$\begin{aligned} M(T) = \begin{pmatrix} 1 &{} 1 &{} 0 \\ m_{21}(T) &{} m_{22}(T) &{} m_{23}(T) \\ m_{31}(T) &{} m_{32}(T) &{} m_{33}(T) \end{pmatrix} = \begin{pmatrix} 1 &{} 1 &{} 0 \\ m_{21}(T) &{} m_{22}(T) &{} m_{23}(T) \\ -m_{21}'(T) &{} -m_{22}'(T) &{} -m_{23}'(T) \end{pmatrix} \end{aligned}$$

and the right-hand side

$$\begin{aligned} r(T) = \begin{pmatrix} b_k(T) \\ (1 + \gamma \, \lambda _k) \, a_k(0) \\ (1 + \gamma \, \lambda _k) \, a_k' (0) \end{pmatrix} \end{aligned}$$

that is in fact independent of T, as stated earlier. \(\square \)

5.2 Computation of the Characteristic Determinant and an Inverse Matrix

For the determinant of M(T) we obtain

$$\begin{aligned} \begin{aligned} \det M(T)&= \, m_{22}(T) m_{33}(T) - m_{32}(T) m_{23}(T) - m_{21}(T) m_{33}(T) + m_{31}(T) m_{23}(T) \\&= \frac{1}{ \left( {z_k}^2 - q_k \right) } m_{22}(T) m_{21}(T) - \frac{1}{ \left( \overline{z_k}^2 - q_k \right) } m_{22}(T) m_{22}(T) \\&\quad - \frac{1}{z_k^2 \left( {z_k}^2 - q_k \right) } m_{32}(T) m_{31}(T) + \frac{1}{\overline{z_k}^2 \left( \overline{z_k}^2 - q_k \right) } m_{32}(T) m_{32}(T) \\&\quad - \frac{1}{ \left( {z_k}^2 - q_k \right) } m_{21}(T) m_{21}(T) + \frac{1}{ \left( \overline{z_k}^2 - q_k \right) } m_{21}(T) m_{22}(T) \\&\quad + \frac{1}{z_k^2 \left( {z_k}^2 - q_k \right) } m_{31}(T) m_{31}(T) - \frac{1}{\overline{z_k}^2 \left( \overline{z_k}^2 - q_k \right) } m_{31}(T) m_{32}(T). \end{aligned} \end{aligned}$$
(42)

We have \( m_{21}(T)^2 -\frac{1}{z_k^2} m_{31}(T)^2 = \left( \gamma - \lambda _k - z_k^2 \right) ^2 \) and \( m_{22}(T)^2 -\frac{1}{\overline{z_k}^2} m_{32}(T)^2 = \left( \gamma - \lambda _k - \overline{z_k}^2 \right) ^2 \). This yields

$$\begin{aligned} \begin{aligned} \det M(T)&= \, - \frac{\left( \gamma - \lambda _k - z_k^2 \right) ^2}{ z_k^2 - q_k } - \frac{ \left( \gamma - \lambda _k - \overline{z_k}^2 \right) ^2 }{ \overline{z_k}^2 - q_k } \\&\quad + \left( \frac{1}{{z_k}^2 - q_k } + \frac{1}{ \overline{z_k}^2 - q_k } \right) \, m_{22}(T) m_{21}(T) \\&\quad - \left( \frac{1}{{z_k}^2 \left( {z_k}^2 - q_k \right) } + \frac{1}{\overline{z_k}^2 \left( \overline{z_k}^2 - q_k \right) } \right) m_{32}(T) m_{31}(T). \end{aligned} \end{aligned}$$
(43)

We introduce the notation

$$\begin{aligned} \Xi _k = \gamma - \lambda _k - z_k^2. \end{aligned}$$

Since

$$\begin{aligned} \cosh ( z_k T ) \cosh (\overline{z_k}T) = \frac{1}{2} \left[ \cosh ( (z_k + \overline{z_k})T ) + \cosh ((z_k - \overline{z_k})T ) \right] \end{aligned}$$
(44)

and

$$\begin{aligned} \sinh ( z_k T ) \sinh (\overline{z_k}T) = \frac{1}{2} \left[ \cosh ( (z_k + \overline{z_k})T ) - \cosh ( (z_k - \overline{z_k})T ) \right] \end{aligned}$$
(45)

we obtain the equation

$$\begin{aligned} \det M(T)= & {} - \frac{\Xi _k^2}{ { z_k^2 - q_k } } - \frac{\overline{\Xi _k}^2}{ \overline{z_k}^2 - q_k } + \left( \frac{1}{ {z_k}^2 - q_k } + \frac{1}{ \overline{z_k}^2 - q_k } \right) \, |\Xi _k|^2 \cosh ( z_k T ) \cosh (\overline{z_k} T) \\ {}{} & {} - \left( \frac{1}{{z_k}^2 \left( {z_k}^2 - q_k \right) } + \frac{1}{\overline{z_k}^2 \left( \overline{z_k}^2 - q_k \right) } \right) z_k \overline{z_k} \, |\Xi _k|^2 \sinh ( z_k T ) \sinh (\overline{z_k} T). \end{aligned}$$

This yields the representation

$$\begin{aligned} \det M(T)= & {} - 2 Re \left( \frac{\Xi _k^2}{ { z_k^2 - q_k } } \right) + 2 |\Xi _k|^2 Re \left( \frac{1}{ { z_k^2 - q_k } } \right) |\cosh ^2( z_k T )| \nonumber \\{} & {} - 2 |\Xi _k|^2 Re \left( \frac{ \overline{z_k} }{z_k} \frac{1}{\left( {z_k}^2 - q_k \right) } \right) |\sinh ^2( z_k T )|. \end{aligned}$$
(46)

Due to (44) and (45) this can also be written in the form

$$\begin{aligned} \det M(T)= & {} - \frac{\Xi _k^2}{ { z_k^2 - q_k } } - \frac{\overline{\Xi _k}^2}{ \overline{z_k}^2 - q_k } \\{} & {} + \frac{ |\Xi _k|^2 }{2} \left[ \frac{1}{ {z_k}^2 - q_k } \left( 1 - \frac{ \overline{z_k}^2 }{|z_k|^2} \right) + \frac{1}{ \overline{z_k}^2 - q_k } \left( 1 - \frac{ {z_k}^2 }{|z_k|^2} \right) \right] \, \cosh ( (z_k + \overline{z_k})T ) \\{} & {} + \frac{ |\Xi _k|^2 }{2} \left[ \frac{1}{ {z_k}^2 - q_k } \left( 1 + \frac{ \overline{z_k}^2 }{|z_k|^2} \right) + \frac{1}{ \overline{z_k}^2 - q_k } \left( 1 + \frac{ {z_k}^2 }{|z_k|^2} \right) \right] \, \cosh ( (z_k - \overline{z_k})T ) \end{aligned}$$

We have

$$\begin{aligned}{} & {} \frac{1}{ {z_k}^2 - q_k } \left( 1 - \frac{ \overline{z_k}^2 }{|z_k|^2} \right) + \frac{1}{ \overline{z_k}^2 - q_k } \left( 1 - \frac{ {z_k}^2 }{|z_k|^2} \right) \\{} & {} \quad = \frac{ 2\, Re\left( ( {z_k}^2 - q_k) (|z_k|^2 - z_k^2 ) \right) }{ | z_k^2 | \, |{z_k}^2 - q_k| }. \end{aligned}$$

It follows that

$$\begin{aligned} Re\left( ( {z_k}^2 - q_k) (|z_k|^2 - z_k^2 ) \right)= & {} Re\left( ( |z_k|^2 + q_k) z_k^2 - q_k \, |z_k|^2 - z_k^4 \right) \\= & {} Re\left( \left( |z_k|^2 + q_k + 2\,\lambda _k - \gamma \right) z_k^2 + \lambda _k^2 + 1 - q_k \, |z_k|^2 \right) \\= & {} Re\left( \left( |z_k|^2 - \frac{1}{\gamma }\right) z_k^2 + \lambda _k^2 + 1 - q_k \, |z_k|^2 \right) \\= & {} \left( \sqrt{\lambda _k^2 + 1 } - \frac{1}{\gamma }\right) \left( \frac{\gamma }{2} - \lambda _k \right) + \lambda _k^2 + 1 \\{} & {} + ( 2 \lambda _k + \frac{1}{\gamma } - \gamma ) \sqrt{\lambda _k^2 + 1 } \\= & {} \sqrt{\lambda _k^2 + 1 } \left( \lambda _k + \frac{1}{\gamma } - \frac{\gamma }{2} \right) + \frac{1}{\gamma }\lambda _k + \lambda _k^2 + \frac{1}{2} >0 \end{aligned}$$

and

$$\begin{aligned}{} & {} \frac{1}{ {z_k}^2 - q_k } \left( 1 + \frac{ \overline{z_k}^2 }{|z_k|^2} \right) + \frac{1}{ \overline{z_k}^2 - q_k } \left( 1 + \frac{ {z_k}^2 }{|z_k|^2} \right) \\{} & {} \quad = \frac{ 2\, Re\left( ( {z_k}^2 - q_k) (|z_k|^2 + z_k^2 ) \right) }{ | z_k^2 | \, |{z_k}^2 - q_k| }, \end{aligned}$$

Hence we have

$$\begin{aligned} \begin{aligned} \det M(T)&= \, - 2\, Re\left( \frac{\Xi _k^2}{ { z_k^2 - q_k } } \right) \\&\quad + \frac{|\Xi _k |^2}{2} \, \frac{ 2\, Re\left( ( {z_k}^2 - q_k) (|z_k|^2 - z_k^2 ) \right) }{ | z_k^2 | \, |{z_k}^2 - q_k| } \cosh ( 2 \, Re(z_k)\, T) \\&\quad + \frac{|\Xi _k |^2}{2} \frac{ 2\, Re\left( ( {z_k}^2 - q_k) (|z_k|^2 + z_k^2 ) \right) }{ | z_k^2 | \, |{z_k}^2 - q_k| } \cosh ( 2 \, Im(z_k)\, T). \end{aligned} \end{aligned}$$
(47)

This implies \(\lim _{T\rightarrow \infty } |\det M(T)| = \infty \), hence for all sufficiently large T we have \(\det M(T)\not =0\). Moreover, we see that \(\det M(T)\) grows exponentially fast with T with the growth rate

$$\begin{aligned} 2{Re}(z_k)\ge \sqrt{\gamma } \end{aligned}$$
(48)

due to (31). Hence for all sufficiently large T the coefficients \((A_k^T,\, B_k^T,\, C_k^T)\) are uniquely determined.

For the computation of the inverse of M(T) we use the representation

$$\begin{aligned}{} & {} \det (M(T) \,\left[ M(T) \right] ^{-1} \\{} & {} \quad = \begin{pmatrix} \beta _{11}(T) &{} \beta _{12}(T) &{} \beta _{13}(T) \\ \beta _{21}(T) &{} \beta _{22}(T) &{} \beta _{23}(T) \\ \beta _{31}(T) &{} \beta _{32}(T) &{} \beta _{33}(T) \end{pmatrix} \\{} & {} \quad = \begin{pmatrix} m_{22}(T)m_{33}(T) -m_{23}(T)m_{32}(T) &{} &{} - m_{33}(T) &{}&{} m_{23}(T) \\ m_{23}(T) m_{31}(T) - m_{21}(T)m_{33}(T) &{}&{} m_{33}(T) &{} &{}- m_{23}(T) \\ m_{21}(T) \, m_{32}(T) - m_{22}(T) \, m_{31}(T) &{}&{} m_{31}(T) - m_{32}(T) &{}&{} m_{22}(T) - m_{21}(T) \end{pmatrix}. \end{aligned}$$

The element \(\beta _{11}(T)\) in the top-left corner of \(\det (M(T))\, M(T)^{-1}\) is given by the minor

$$\begin{aligned} \beta _{11}(T)= & {} m_{22}(T) \, m_{33}(T) - m_{23}(T) \, m_{32}(T)\nonumber \\= & {} {\overline{\Xi }}_k \cosh (\overline{z_k} T) \left\{ \frac{ \Xi _k }{ \left( z_k^2 - q_k \right) } \cosh ( z_k \, T ) - \frac{ {\overline{\Xi }}_k }{ \left( \overline{z_k}^2 - q_k \right) } \cosh ( \overline{z_k} T) \right\} \nonumber \\{} & {} + \left\{ - \frac{ \Xi _k }{z_k \left( {z_k}^2 - q_k \right) } \sinh ( z_k \, T ) + \frac{ {\overline{\Xi }}_k }{ \overline{z_k} \left( \overline{z_k}^2 - q_k \right) } \sinh ( \overline{z_k} \, T) \right\} \left\{ \overline{z_k} \, {\overline{\Xi }}_k \sinh (\overline{z_k} T) \right\} \nonumber \\= & {} \frac{|\Xi _k|^2}{z_k^2 - q_k} \cosh ( z_k T ) \cosh (\overline{z_k} T) - \frac{\overline{\Xi _k}^2}{ \overline{z_k}^2 - q_k } [\cosh ^2(\overline{z_k} T) - \sinh ^2(\overline{z_k} T)] \nonumber \\{} & {} - \frac{\overline{z_k}}{z_k} \frac{|\Xi _k|^2 }{z_k^2 - q_k} \sinh ( z_k T ) \sinh (\overline{z_k} T) \nonumber \\= & {} - \frac{\overline{\Xi _k}^2 }{ \overline{z_k}^2 - q_k } + \frac{|\Xi _k|^2 }{{z_k}^2 - q_k } \left[ \cosh ( z_k T ) \cosh (\overline{z_k} T) - \frac{\overline{z_k}}{z_k} \sinh ( z_k T ) \sinh ( \overline{z_k}T ) \right] . \nonumber \\ \end{aligned}$$
(49)

Due to (44) and (45) this yields

$$\begin{aligned} \beta _{11}(T)= & {} - \frac{\overline{\Xi _k}^2 }{ \overline{z_k}^2 - q_k } + \frac{1}{2} \, \frac{|\Xi _k|^2 }{{z_k}^2 - q_k } \left[ \left( 1 - \frac{\overline{z_k}}{z_k} \right) \cosh ( (z_k + \overline{z_k})T) \right. \\{} & {} \left. + \left( 1 + \frac{\overline{z_k}}{z_k} \right) \cosh ( (z_k - \overline{z_k})T) \right] . \end{aligned}$$

The second element \(\beta _{12}(T)\) in the top row of \(\det (M(T))\, M(T)^{-1}\) is given by

$$\begin{aligned}\beta _{12}(T) = - m_{33}(T) = -\frac{ \Xi _k }{ \left( z_k^2 - q_k \right) } \cosh ( z_k \, T ) + \frac{ {{\overline{\Xi }}}_k }{ \left( \overline{z_k}^2 - q_k \right) } \cosh ( \overline{z_k} T). \end{aligned}$$

The third element \(\beta _{13}(T)\) in the top row of \(\det (M(T))\, M(T)^{-1}\) is given by

$$\begin{aligned} \beta _{13}(T) = m_{23}(T) = -\frac{ \Xi _k }{z_k \left( {z_k}^2 - q_k \right) } \sinh ( z_k \, T ) + \frac{ \overline{\Xi _k} }{ \overline{z_k} \left( \overline{z_k}^2 - q_k \right) } \sinh ( \overline{z_k} \, T). \end{aligned}$$

Now we consider the entries in the second row. For the first element in the second row of the matrix \(\det (M(T))\, M(T)^{-1}\) we obtain

$$\begin{aligned} \beta _{21}(T)= & {} - [ m_{21}(T)m_{33}(T) - m_{23}(T) m_{31}(T)] \nonumber \\= & {} - \frac{ \Xi _k^2 }{ \left( z_k^2 - q_k \right) } \cosh ^2( z_k \, T ) + \frac{ |\Xi _k|^2 }{ \left( \overline{z_k}^2 - q_k \right) } \cosh ( z_k \, T ) \cosh ( \overline{z_k} T) \nonumber \\{} & {} +\frac{ \Xi _k^2 }{\left( {z_k}^2 - q_k \right) } \sinh ^2( z_k \, T ) - \frac{ z_k\, |\Xi _k|^2 }{ \overline{z_k} \left( \overline{z_k}^2 - q_k \right) } \sinh ( \overline{z_k} \, T) \sinh ( z_k T ) \nonumber \\= & {} - \frac{ \Xi _k^2 }{ \left( z_k^2 - q_k \right) } + \frac{ |\Xi _k|^2 }{ \left( \overline{z_k}^2 - q_k \right) } \cosh ( z_k \, T ) \cosh ( \overline{z_k} T) \nonumber \\{} & {} - \frac{z_k}{ \overline{z_k} } \frac{ |\Xi _k|^2 }{ \left( \overline{z_k}^2 - q_k \right) } \sinh ( \overline{z_k} \, T) \sinh ( z_k T ). \end{aligned}$$
(50)

Due to (44) and (45) this yields

$$\begin{aligned}\beta _{21}(T)= & {} - \frac{ \Xi _k^2 }{ \left( z_k^2 - q_k \right) } \\{} & {} + \frac{1}{2} \, \frac{ |\Xi _k|^2 }{ \left( \overline{z_k}^2 - q_k \right) } \left[ \left( 1 - \frac{z_k}{\overline{z_k}} \right) \cosh ( (z_k + \overline{z_k})T) + \left( 1 + \frac{z_k}{\overline{z_k}} \right) \cosh ( (z_k - \overline{z_k})T) \right] . \end{aligned}$$

The second element in the second row of the matrix \(\det (M(T))\, M(T)^{-1}\) is

$$\begin{aligned}\beta _{22}(T) = m_{33}(T) = \frac{ \Xi _k }{ \left( z_k^2 - q_k \right) } \cosh ( z_k \, T ) - \frac{ {{\overline{\Xi }}}_k }{ \left( \overline{z_k}^2 - q_k \right) } \cosh ( \overline{z_k} T). \end{aligned}$$

For the third element in the second row of the matrix \(\det (M(T))\, M(T)^{-1}\) we obtain

$$\begin{aligned}\beta _{23}(T) = - m_{23}(T) = \frac{ \Xi _k}{z_k \left( {z_k}^2 - q_k \right) } \sinh ( z_k \, T ) - \frac{ \overline{\Xi _k}}{ \overline{z_k} \left( \overline{z_k}^2 - q_k \right) } \sinh ( \overline{z_k} \, T). \end{aligned}$$

Finally let us look at the elements in the third row.

For the first element in the third row \(\beta _{31}(T)\) of the matrix \(\det (M(T))\, M(T)^{-1}\) we obtain

$$\begin{aligned} \beta _{31}(T)= & {} m_{21}(T) \, m_{32}(T) - m_{22}(T) \, m_{31}(T) \\= & {} |\Xi _k|^2 \left[ - \overline{z_k} \cosh (z_k\, T) \, \sinh (\overline{z_k}T) + z_k \cosh (\overline{z_k}T) \, \sinh (z_k\, T) \right] . \end{aligned}$$

For the hyperbolic functions we have the general identity

$$\begin{aligned} \cosh ( z_k T ) \sinh (\overline{z_k}T) = \frac{1}{2} \left[ \sinh ( (z_k + \overline{z_k})T ) - \sinh ( (z_k - \overline{z_k})T ) \right] \end{aligned}$$
(51)

and

$$\begin{aligned} \sinh ( z_k T ) \cosh (\overline{z_k}T) = \frac{1}{2} \left[ \sinh ( (z_k + \overline{z_k})T ) + \sinh ( (z_k - \overline{z_k})T ) \right] . \end{aligned}$$
(52)

Using (51) and (52) we obtain

$$\begin{aligned}\beta _{31}(T)= & {} |\Xi _k|^2 \left[ - \overline{z_k} \cosh (z_k\, T) \, \sinh (\overline{z_k}T) + z_k \cosh (\overline{z_k}T) \, \sinh (z_k\, T) \right] \\= & {} |\Xi _k|^2 \left[ - \overline{z_k} \frac{1}{2} \left[ \sinh ( (z_k + \overline{z_k})T ) - \sinh ( (z_k - \overline{z_k})T ) \right] \right. \\{} & {} \left. + z_k \frac{1}{2} \left[ \sinh ( (z_k + \overline{z_k})T ) + \sinh ( (z_k - \overline{z_k})T ) \right] \right] \\= & {} |\Xi _k|^2 \left[ \frac{ z_k - \overline{z_k} }{2} \sinh ( (z_k + \overline{z_k})T ) + \frac{ z_k + \overline{z_k} }{2} \sinh ( (z_k - \overline{z_k})T ) \right] . \end{aligned}$$

The second element in the third row \(\beta _{32}(T)\) of the matrix \(\det (M(T))\, M(T)^{-1}\) is

$$\begin{aligned}\beta _{32}(T) = - m_{32}(T) + m_{31}(T) = {\overline{z_k}} \, \overline{\Xi _k} \,\sinh ( \overline{z_k} T ) - {z_k} \, \Xi _k \,\sinh ( z_k T ). \end{aligned}$$

Finally the element \(\beta _{33}(T)\) of the matrix \(\det (M(T))\, M(T)^{-1}\) is

$$\begin{aligned}\beta _{33}(T) = m_{22}(T) - m_{21}(T) = \overline{\Xi _k} \, \cosh (\overline{z_k} T) - \Xi _k \, \cosh ( z_k T ). \end{aligned}$$

We summarize the entries of \(\det (M(T))\, M(T)^{-1}\) in a table:

$$\begin{aligned} \beta _{11}(T)= & {} - \frac{\overline{\Xi _k}^2 }{ \overline{z_k}^2 - q_k } + \frac{1}{2} \, \frac{|\Xi _k|^2 }{{z_k}^2 - q_k } \left[ \left( 1 - \frac{\overline{z_k}}{z_k} \right) \cosh ( (z_k + \overline{z_k})T) \right. \\{} & {} \left. + \left( 1 + \frac{\overline{z_k}}{z_k} \right) \cosh ( (z_k - \overline{z_k})T) \right] \\ \beta _{12}(T)= & {} -\frac{ \Xi _k }{ \left( z_k^2 - q_k \right) } \cosh ( z_k \, T ) + \frac{ {{\overline{\Xi }}}_k }{ \left( \overline{z_k}^2 - q_k \right) } \cosh ( \overline{z_k} T). \\ \beta _{13}(T)= & {} -\frac{ \Xi _k }{z_k \left( {z_k}^2 - q_k \right) } \sinh ( z_k \, T ) + \frac{ \overline{\Xi _k} }{ \overline{z_k} \left( \overline{z_k}^2 - q_k \right) } \sinh ( \overline{z_k} \, T). \\ \beta _{21}(T)= & {} - \frac{ \Xi _k^2 }{ \left( z_k^2 - q_k \right) } \\{} & {} + \frac{1}{2} \, \frac{ |\Xi _k|^2 }{ \left( \overline{z_k}^2 - q_k \right) } \left[ \left( 1 - \frac{z_k}{\overline{z_k}} \right) \cosh ( (z_k + \overline{z_k})T) + \left( 1 + \frac{z_k}{\overline{z_k}} \right) \cosh ( (z_k - \overline{z_k})T) \right] . \\ \beta _{22}(T)= & {} = \frac{ \Xi _k }{ \left( z_k^2 - q_k \right) } \cosh ( z_k \, T ) - \frac{ {{\overline{\Xi }}}_k }{ \left( \overline{z_k}^2 - q_k \right) } \cosh ( \overline{z_k} T). \\ \beta _{23}(T)= & {} \frac{ \Xi _k}{z_k \left( {z_k}^2 - q_k \right) } \sinh ( z_k \, T ) - \frac{ \overline{\Xi _k}}{ \overline{z_k} \left( \overline{z_k}^2 - q_k \right) } \sinh ( \overline{z_k} \, T). \\ \beta _{31}(T)= & {} |\Xi _k|^2 \left[ \frac{ z_k - \overline{z_k} }{2} \sinh ( (z_k + \overline{z_k})T ) + \frac{ z_k + \overline{z_k} }{2} \sinh ( (z_k - \overline{z_k})T ) \right] . \\ \beta _{32}(T)= & {} {\overline{z_k}} \, \overline{\Xi _k} \,\sinh ( \overline{z_k} T ) - {z_k} \, \Xi _k \,\sinh ( z_k T ). \\ \beta _{33}(T)= & {} \overline{\Xi _k} \, \cosh (\overline{z_k} T) - \Xi _k \, \cosh ( z_k T ). \end{aligned}$$

For

$$\begin{aligned} b_{k,T}(t)= & {} A_k^T \cosh ( z_k (t- T) ) + B_k^T \cosh ( \overline{z_k} (t- T) ) \\{} & {} + C_k^T \left[ \frac{ \sinh ( z_k(t - T) ) }{ z_k \, \left( z_k^2 - q_k \right) } - \frac{ \sinh ( \overline{z_k}(t - T)) }{ \overline{z_k} \left( \overline{z_k}^2 - q_k \right) } \right] \end{aligned}$$

we have

$$\begin{aligned} V(T) = \begin{pmatrix} A_k^T \\ B_k^T \\ C_k^T \end{pmatrix} = \frac{1}{\det M(T)} \begin{pmatrix} \beta _{11}(T) &{} \beta _{12}(T) &{} \beta _{13}(T) \\ \beta _{21}(T) &{} \beta _{22}(T) &{} \beta _{23}(T) \\ \beta _{31}(T) &{} \beta _{32}(T) &{} \beta _{33}(T) \end{pmatrix} \begin{pmatrix} b_k(T) \\ (1 + \gamma \, \lambda _k) a_k (0) \\ (1 + \gamma \, \lambda _k) \, a_k' (0) \end{pmatrix}. \end{aligned}$$
(53)

Due to (40) we have

$$\begin{aligned} b_{k,T}(t) = F_{k,T}(t) \, b_k(T) + G_{k,T}(t) \, (1 + \gamma \, \lambda _k) \, a_k (0) + H_{k,T}(t) \, (1 + \gamma \, \lambda _k) \, a_k' (0), \end{aligned}$$
(54)

where the terms that are multiplied with \(b_k(T)\) and come from the first column of \(M(T)^{-1}\) are collected in \(F_{k,T}(t)\), and analogously for \(G_{k,T}(t)\) and \(H_{k,T}(t)\).

Thus we have

$$\begin{aligned} F_{k,T}(t)= & {} \, \frac{\beta _{11}(T) }{\det M(T)} \cosh ( z_k (t- T) ) + \frac{\beta _{21}(T)}{\det M(T)} \cosh ( \overline{z_k} (t- T) ) \nonumber \\{} & {} + \frac{ \beta _{31}(T) }{\det M(T)} \left[ \frac{ \sinh ( z_k(t - T) ) }{ z_k \, \left( z_k^2 - q_k \right) } - \frac{ \sinh ( \overline{z_k}(t - T)) }{ \overline{z_k} \left( \overline{z_k}^2 - q_k \right) } \right] , \end{aligned}$$
(55)
$$\begin{aligned} G_{k,T}(t)= & {} \frac{\beta _{12}(T) }{\det M(T)} \cosh ( z_k (t- T) ) + \frac{\beta _{22}(T)}{\det M(T)} \cosh ( \overline{z_k} (t- T) ) \nonumber \\{} & {} + \frac{ \beta _{32}(T) }{\det M(T)} \left[ \frac{ \sinh ( z_k(t - T) ) }{ z_k \, \left( z_k^2 - q_k \right) } - \frac{ \sinh ( \overline{z_k}(t - T)) }{ \overline{z_k} \left( \overline{z_k}^2 - q_k \right) } \right] , \end{aligned}$$
(56)
$$\begin{aligned} H_{k,T}(t)= & {} \frac{\beta _{13}(T) }{\det M(T)} \cosh ( z_k (t- T) ) + \frac{\beta _{23}(T)}{\det M(T)} \cosh ( \overline{z_k} (t- T) ) \nonumber \\{} & {} + \frac{ \beta _{33}(T) }{\det M(T)} \left[ \frac{ \sinh ( z_k(t - T) ) }{ z_k \, \left( z_k^2 - q_k \right) } - \frac{ \sinh ( \overline{z_k}(t - T)) }{ \overline{z_k} \left( \overline{z_k}^2 - q_k \right) } \right] . \end{aligned}$$
(57)

Hence (with \(\det M(T)\) as in (46) )

$$\begin{aligned}{} & {} \det M(T) F_{k,T}(t) \\{} & {} \quad = \left[ - \frac{\overline{\Xi _k}^2 }{ \overline{z_k}^2 - q_k } + \frac{1}{2} \, \frac{|\Xi _k|^2 }{{z_k}^2 - q_k } \left[ \left( 1 - \frac{\overline{z_k}}{z_k} \right) \cosh ( (z_k + \overline{z_k})T) \right. \right. \\{} & {} \left. \left. \qquad + \left( 1 + \frac{\overline{z_k}}{z_k} \right) \cosh ( (z_k - \overline{z_k})T) \right] \right] \cosh ( z_k (t- T) ) \\{} & {} \qquad + \left[ \frac{ \Xi _k^2 }{ \left( z_k^2 - q_k \right) } + \frac{1}{2} \, \frac{ |\Xi _k|^2 }{ \left( \overline{z_k}^2 - q_k \right) } \left[ \left( 1 - \frac{z_k}{\overline{z_k}} \right) \cosh ( (z_k + \overline{z_k})T) \right. \right. \\{} & {} \left. \left. \qquad + \left( 1 + \frac{z_k}{\overline{z_k}} \right) \cosh ( (z_k - \overline{z_k})T) \right] \right] \cosh ( \overline{z_k} (t- T) ) \\{} & {} \qquad + |\Xi _k|^2 \left[ \frac{ z_k - \overline{z_k} }{2} \sinh ( (z_k + \overline{z_k})T ) + \frac{ z_k + \overline{z_k} }{2} \sinh ( (z_k - \overline{z_k})T ) \right] \\{} & {} \quad \left[ \frac{ \sinh ( z_k(t - T) ) }{ z_k \, \left( z_k^2 - q_k \right) } - \frac{ \sinh ( \overline{z_k}(t - T)) }{ \overline{z_k} \left( \overline{z_k}^2 - q_k \right) } \right] \\{} & {} \quad = 2Re \left( \left[ - \frac{\overline{\Xi _k}^2 }{ \overline{z_k}^2 - q_k } + \frac{1}{2} \, \frac{|\Xi _k|^2 }{{z_k}^2 - q_k } \left[ \left( 1 - \frac{\overline{z_k}}{z_k} \right) \cosh ( (z_k + \overline{z_k})T)\right. \right. \right. \\{} & {} \left. \left. \left. \qquad + \left( 1 + \frac{\overline{z_k}}{z_k} \right) \cosh ( (z_k - \overline{z_k})T) \right] \right] \cosh ( z_k (t- T) ) \right) \\{} & {} \qquad + |\Xi _k|^2 \left[ \frac{ z_k - \overline{z_k} }{2} \sinh ( (z_k + \overline{z_k})T ) + \frac{ z_k + \overline{z_k} }{2} \sinh ( (z_k - \overline{z_k})T ) \right] \\{} & {} \quad \left[ \frac{ \sinh ( z_k(t - T) ) }{ z_k \, \left( z_k^2 - q_k \right) } - \frac{ \sinh ( \overline{z_k}(t - T)) }{ \overline{z_k} \left( \overline{z_k}^2 - q_k \right) } \right] . \end{aligned}$$

Whence we have

$$\begin{aligned}{} & {} \det M(T) F_{k,T}(t) \\{} & {} \quad = 2Re \left( \left[ - \frac{\overline{\Xi _k}^2 }{ \overline{z_k}^2 - q_k } + \frac{|\Xi _k|^2 }{{z_k}^2 - q_k } \left[ \cosh (z_k \, T) \cosh (\overline{z_k}T) \right. \right. \right. \\{} & {} \left. \left. \left. \qquad - \frac{\overline{z_k}}{z_k} \sinh (z_k \, T) \sinh (\overline{z_k}\,T) \right] \right] \cosh ( z_k (t- T) ) \right) \\{} & {} \qquad + |\Xi _k|^2 [ z_k \sinh (z_k T) \cosh ( \overline{z_k} T)\\{} & {} \qquad - \overline{z_k} \cosh (z_k T) \sinh ( \overline{z_k} T) ] \left[ \frac{ \sinh ( z_k(t - T) ) }{ z_k \, \left( z_k^2 - q_k \right) } - \frac{ \sinh ( \overline{z_k}(t - T)) }{ \overline{z_k} \left( \overline{z_k}^2 - q_k \right) } \right] \\{} & {} \quad = 2Re \left( \left[ - \frac{\overline{\Xi _k}^2 }{ \overline{z_k}^2 - q_k } + \frac{|\Xi _k|^2 }{{z_k}^2 - q_k } \left[ \cosh (z_k \, T) \cosh (\overline{z_k}T) \right. \right. \right. \\{} & {} \left. \left. \left. \qquad - \frac{\overline{z_k}}{z_k} \sinh (z_k \, T) \sinh (\overline{z_k}\,T) \right] \right] \cosh ( z_k (t- T) ) \right) \\{} & {} \qquad + |\Xi _k|^2 2Re \left( \sinh (z_k T) \cosh ( \overline{z_k} T) \frac{ \sinh ( z_k(t - T) ) }{ \left( z_k^2 - q_k \right) }\right. \\{} & {} \left. \qquad - \frac{\overline{z_k}}{z_k} \cosh (z_k T) \sinh ( \overline{z_k} T) \left[ \frac{ \sinh ( z_k(t - T) ) }{ \left( z_k^2 - q_k \right) } \right] \right) . \end{aligned}$$

Verification of the basis function \(F_{k,T}(t)\)

We start with the function \({F_{k,T}(t)}\) from (34) that is multiplied with \( \beta _k \), i.e. we consider the product \(d(k, T) \, F_{k,T}(t) \). We will show that \({F_{k,T}(t)} \) satisfies the boundary conditions

$$\begin{aligned} F_{k,T}(T )= & {} 1, \\ F_{k,T}'''(T)= & {} { \frac{ \gamma ^2 - 2 \, \gamma \, \lambda _k -1}{\gamma } \, F_{k,T}'(T), } \\ - F_{k,T}''(0)+ (\gamma - \lambda _k) \, F_{k,T}(0)= & {} 0, \\ - F_{k,T}'''(0)+ (\gamma - \lambda _k) \, F_{k,T}'(0)= & {} 0. \end{aligned}$$

We have

$$\begin{aligned} d(k, T) \, F_{k,T}(t)= & {} 2Re \left( - \frac{\overline{\Xi _k}^2 }{ \overline{z_k}^2 - q_k } \cosh ( z_k (t- T) ) \right) \\{} & {} + 2Re \left( \frac{|\Xi _k|^2 }{{z_k}^2 - q_k } \cosh (\overline{z_k}T) \cosh (z_k \, T) \cosh ( z_k (t- T) ) \right) \\{} & {} + 2Re \left( \frac{ |\Xi _k|^2 }{ z_k^2 - q_k } \cosh ( \overline{z_k} T) \sinh (z_k T) \sinh ( z_k(t - T) ) \right) \\{} & {} - 2 Re \Bigg ( \frac{ |\Xi _k|^2 }{ z_k^2 - q_k } \frac{\overline{z_k}}{z_k} \sinh ( \overline{z_k} T) [ \sinh (z_k \, T) \cosh ( z_k (t- T) )\\{} & {} + \cosh (z_k T) \sinh ( z_k(t - T) ) ] \Bigg ). \end{aligned}$$

Hence for \(t=T\) we have

$$\begin{aligned} d(k, T) \, F_{k,T}(T)= & {} 2Re \left( - \frac{\overline{\Xi _k}^2 }{ \overline{z_k}^2 - q_k } \right) + 2Re \left( \frac{|\Xi _k|^2 }{{z_k}^2 - q_k } \cosh (\overline{z_k}T) \cosh (z_k \, T) \right. \\{} & {} \left. - \frac{ |\Xi _k|^2 }{ z_k^2 - q_k } \frac{\overline{z_k}}{z_k} \sinh ( \overline{z_k} T) \sinh (z_k \, T) \right) = d(k,T). \end{aligned}$$

Since \( d(k, T) \not =0 \), this implies \({F_{k,T}(T)}= 1\). For the derivative we obtain

$$\begin{aligned} d(k, T) \, F_{k,T}'(t)= & {} 2Re \left( - z_k \frac{\overline{\Xi _k}^2 }{ \overline{z_k}^2 - q_k } \sinh ( z_k (t- T) ) \right) \\{} & {} + 2Re \left( z_k \frac{|\Xi _k|^2 }{{z_k}^2 - q_k } \cosh (\overline{z_k}T) \cosh (z_k \, T) \sinh ( z_k (t- T) ) \right) \\{} & {} + 2Re \left( z_k \frac{ |\Xi _k|^2 }{ z_k^2 - q_k } \cosh ( \overline{z_k} T) \sinh (z_k T) \cosh ( z_k(t - T) ) \right) \\{} & {} - 2 Re \Bigg ( \frac{ |\Xi _k|^2 }{ z_k^2 - q_k } {\overline{z_k}} \sinh ( \overline{z_k} T) [ \sinh (z_k \, T) \sinh ( z_k (t- T) ) \\{} & {} + \cosh (z_k T) \cosh ( z_k(t - T) ) ] \Bigg ). \end{aligned}$$

Thus we have

$$\begin{aligned} d(k, T) \, F_{k,T}'(T)= & {} 2Re \left( z_k \frac{ |\Xi _k|^2 }{ z_k^2 - q_k } \cosh ( \overline{z_k} T) \sinh (z_k T) \right) \\{} & {} - 2 Re \left( \frac{ |\Xi _k|^2 }{ z_k^2 - q_k } {\overline{z_k}} \sinh ( \overline{z_k} T) \cosh (z_k T) \right) . \end{aligned}$$

For \(t=0\) we have

$$\begin{aligned} d(k, T) \, F_{k,T}(0)= & {} 2Re \left( - \frac{\overline{\Xi _k}^2 }{ \overline{z_k}^2 - q_k } \cosh ( z_k T ) \right) \\{} & {} + 2Re \left( \frac{|\Xi _k|^2 }{{z_k}^2 - q_k } \cosh (\overline{z_k}T) \cosh (z_k \, T) \cosh ( z_k T ) \right) \\{} & {} - 2Re \left( \frac{ |\Xi _k|^2 }{ z_k^2 - q_k } \cosh ( \overline{z_k} T) \sinh (z_k T) \sinh ( z_k T ) \right) \\{} & {} - 2 Re \Bigg ( \frac{ |\Xi _k|^2 }{ z_k^2 - q_k } \frac{\overline{z_k}}{z_k} \sinh ( \overline{z_k} T) [ \sinh (z_k \, T) \cosh ( z_k T ) \\{} & {} - \cosh (z_k T) \sinh ( z_k T ) ] \Bigg ) \\= & {} 2Re \left( - \frac{\overline{\Xi _k}^2 }{ \overline{z_k}^2 - q_k } \cosh ( z_k T ) + \frac{|\Xi _k|^2 }{{z_k}^2 - q_k } \cosh (\overline{z_k}T) \right) . \end{aligned}$$

For the second derivative, we have

$$\begin{aligned} d(k, T) \, F_{k,T}''(t)= & {} 2Re \left( - z_k^2 \frac{\overline{\Xi _k}^2 }{ \overline{z_k}^2 - q_k } \cosh ( z_k (t- T) ) \right) \\{} & {} + 2Re \left( z_k^2 \frac{|\Xi _k|^2 }{{z_k}^2 - q_k } \cosh (\overline{z_k}T) \cosh (z_k \, T) \cosh ( z_k (t- T) ) \right) \\{} & {} + 2Re \left( z_k^2 \frac{ |\Xi _k|^2 }{ z_k^2 - q_k } \cosh ( \overline{z_k} T) \sinh (z_k T) \sinh ( z_k(t - T) ) \right) \\{} & {} - 2 Re \Bigg ( \frac{ |\Xi _k|^2 }{ z_k^2 - q_k } |z_k|^2 \sinh ( \overline{z_k} T) [ \sinh (z_k \, T) \cosh ( z_k (t- T) ) \\{} & {} + \cosh (z_k T) \sinh ( z_k(t - T) ) ] \Bigg ). \end{aligned}$$

For \(t=0\) this yields

$$\begin{aligned} d(k, T) \, F_{k,T}''(0)= & {} 2Re \left( - z_k^2 \frac{\overline{\Xi _k}^2 }{ \overline{z_k}^2 - q_k } \cosh ( z_k T ) \right) \\{} & {} + 2Re \left( z_k^2 \frac{|\Xi _k|^2 }{{z_k}^2 - q_k } \cosh (\overline{z_k}T) \cosh (z_k \, T) \cosh ( z_k T ) \right) \\{} & {} - 2Re \left( z_k^2 \frac{ |\Xi _k|^2 }{ z_k^2 - q_k } \cosh ( \overline{z_k} T) \sinh (z_k T) \sinh ( z_k T) ) \right) \\{} & {} - 2 Re \Bigg ( \frac{ |\Xi _k|^2 }{ z_k^2 - q_k } |z_k|^2 \sinh ( \overline{z_k} T) [ \sinh (z_k \, T) \cosh ( z_k T ) \\{} & {} - \cosh (z_k T) \sinh ( z_k T ) ] \Bigg ) \\= & {} 2Re \left( z_k^2 \left[ - \frac{\overline{\Xi _k}^2 }{ \overline{z_k}^2 - q_k } \cosh ( z_k T ) + \frac{|\Xi _k|^2 }{{z_k}^2 - q_k } \cosh (\overline{z_k}T) \right) \right] . \end{aligned}$$

Hence due to (35) we have

$$\begin{aligned} d(k, T) \,&\left[ - F_{k,T}''(0)+ (\gamma - \lambda _k) \, F_{k,T}(0) \right] =0. \end{aligned}$$

Thus we have \(- F_{k,T}''(0)+ (\gamma - \lambda _k) \, F_{k,T}(0) = 0\).

To proceed, let us observe that

$$\begin{aligned} d(k, T) \, F_{k,T}'(0)= & {} 2Re \left( z_k \frac{\overline{\Xi _k}^2 }{ \overline{z_k}^2 - q_k } \sinh ( z_k T ) \right) \\{} & {} - 2Re \left( z_k \frac{|\Xi _k|^2 }{{z_k}^2 - q_k } \cosh (\overline{z_k}T) \cosh (z_k \, T) \sinh ( z_k T ) \right) \\{} & {} + 2Re \left( z_k \frac{ |\Xi _k|^2 }{ z_k^2 - q_k } \cosh ( \overline{z_k} T) \sinh (z_k T) \cosh ( z_k T ) \right) \\{} & {} - 2 Re \Bigg ( \frac{ |\Xi _k|^2 }{ z_k^2 - q_k } {\overline{z_k}} \sinh ( \overline{z_k} T) [ - \sinh (z_k \, T) \sinh ( z_k T ) \\{} & {} + \cosh (z_k T) \cosh ( z_k T ) ] \Bigg ) \\= & {} 2Re \left( z_k \frac{\overline{\Xi _k}^2 }{ \overline{z_k}^2 - q_k } \sinh ( z_k T ) \right) - 2 Re \left( {\overline{z_k}} \frac{ |\Xi _k|^2 }{ z_k^2 - q_k } \sinh ( \overline{z_k} T) \right) . \end{aligned}$$

For the third derivative, we have

$$\begin{aligned} d(k, T) \, F_{k,T}'''(t)= & {} 2 \, Re \left( - z_k^3 \frac{\overline{\Xi _k}^2 }{ \overline{z_k}^2 - q_k } \sinh ( z_k (t- T) ) \right) \nonumber \\{} & {} + 2 \, Re \left( z_k^3 \frac{|\Xi _k|^2 }{{z_k}^2 - q_k } \cosh (\overline{z_k} T) \cosh (z_k \, T) \sinh ( z_k (t- T) ) \right) \nonumber \\{} & {} + 2 \, Re \left( z_k^3 \frac{ |\Xi _k|^2 }{ z_k^2 - q_k } \cosh ( \overline{z_k} T) \sinh (z_k T) \cosh ( z_k (t - T) ) \right) \nonumber \\{} & {} - 2 \, Re \Bigg ( \frac{ |\Xi _k|^2 }{ z_k^2 - q_k } |z_k|^2 z_k \sinh ( \overline{z_k} T) [ \sinh (z_k \, T) \sinh ( z_k (t- T) ) \nonumber \\{} & {} + \cosh (z_k T) \cosh ( z_k(t - T) ) ] \Bigg ). \end{aligned}$$
(58)

This yields

$$\begin{aligned} \begin{aligned}&d(k, T) \, F_{k,T}'''(0) \\&\quad = \, 2 \, Re \left( z_k^3 \frac{\overline{\Xi _k}^2 }{ \overline{z_k}^2 - q_k } \sinh ( z_k T ) \right) \\&\qquad + 2 \, Re \left( - z_k^3 \frac{|\Xi _k|^2 }{{z_k}^2 - q_k } \cosh (\overline{z_k} T) \cosh (z_k \, T) \sinh ( z_k T ) \right) \\&\qquad + 2 \, Re \left( z_k^3 \frac{ |\Xi _k|^2 }{ z_k^2 - q_k } \cosh ( \overline{z_k} T) \sinh (z_k T) \cosh ( z_k T ) \right) \\&\qquad - 2 \, Re \left( \frac{ |\Xi _k|^2 }{ z_k^2 - q_k } |z_k|^2 z_k \sinh ( \overline{z_k} T) \left[ - \sinh (z_k \, T) \sinh ( z_k T ) + \cosh (z_k T) \cosh ( z_k T ) \right] \right) \\&\quad = \, 2 \, Re \left( z_k^3 \frac{\overline{\Xi _k}^2 }{ \overline{z_k}^2 - q_k } \sinh ( z_k T ) \right) - 2 \, Re \left( \frac{ |\Xi _k|^2 }{ z_k^2 - q_k } z_k^2 \overline{z_k} \sinh ( \overline{z_k} T) \right) . \end{aligned} \end{aligned}$$
(59)

Hence we have

$$\begin{aligned}&d(k, T) \, \left[ - F_{k,T}'''(0)+ (\gamma - \lambda _k) \, F_{k,T}'(0) \right] \\&\quad = 2Re \left( -z_k^3 \frac{\overline{\Xi _k}^2 }{ \overline{z_k}^2 - q_k } \sinh ( z_k T ) \right) + 2 Re \left( \frac{ |\Xi _k|^2 }{ z_k^2 - q_k } z_k^2 {\overline{z_k}} \sinh ( \overline{z_k} T) \right) \\&\qquad + (\gamma - \lambda _k ) \left[ 2Re \left( z_k \frac{\overline{\Xi _k}^2 }{ \overline{z_k}^2 - q_k } \sinh ( z_k T ) \right) - 2 Re \left( {\overline{z_k}} \frac{ |\Xi _k|^2 }{ z_k^2 - q_k } \sinh ( \overline{z_k} T) \right) \right] \\&\quad = 2Re \left( z_k \,\Xi _k \frac{\overline{\Xi _k}^2 }{ \overline{z_k}^2 - q_k } \sinh ( z_k T ) \right) - 2 Re \left( \frac{ |\Xi _k|^2 }{ z_k^2 - q_k } \Xi _k {\overline{z_k}} \sinh ( \overline{z_k} T) \right) =0. \end{aligned}$$

We have

$$\begin{aligned} d(k, T) \, F_{k,T}'''(T)= & {} 2Re \left( z_k^3 \frac{ |\Xi _k|^2 }{ z_k^2 - q_k } \cosh ( \overline{z_k} T) \sinh (z_k T) \right) \\{} & {} - 2 Re \left( \frac{ |\Xi _k|^2 }{ z_k^2 - q_k } |z_k|^2 z_k \sinh ( \overline{z_k} T) \cosh (z_k T) \right) . \end{aligned}$$

Whence we have

$$\begin{aligned} d(k, T) \left[ F_{k,T}'''(T) - q_k \, F_{k,T}'(T) \right]= & {} 2 \, Re \left( (z_k^2 - q_k) z_k \frac{ |\Xi _k|^2 }{ z_k^2 - q_k } \cosh ( \overline{z_k} T) \sinh (z_k T) \right) \nonumber \\{} & {} - 2 \, Re \left( (z_k^2 - q_k) \overline{z_k} \frac{ |\Xi _k|^2 }{ z_k^2 - q_k } \sinh ( \overline{z_k} T) \cosh (z_k T) \right) \nonumber \\ {}= & {} 0. \end{aligned}$$
(60)

Thus we have shown that \(F_{k, T}\) satisfies the required boundary conditions.

Verification of the basis function \(G_{k,T}(t)\).

We continue with \({G_{k,T}(t)} \) from (34) that is multiplied with \( (1 + \gamma \, \lambda _k) \, a_{k,T}(0) \), i.e.

$$\begin{aligned} d(k, T) \, G_{k,T}(t)&= 2 Re \left( \frac{\overline{\Xi _k} }{ \overline{z_k}^2 - q_k } \cosh ( \overline{z_k} T) \cosh ( z_k (t- T) ) \right) \\&\quad - 2 Re \left( \frac{\overline{\Xi _k} }{ \overline{z_k}^2 - q_k } \cosh ( \overline{z_k} T) \cosh ( \overline{z_k} (t- T) ) \right) \\&\quad + 2 Re \left( \frac{\overline{z_k}\ \overline{\Xi _k} }{ {z_k} ({z_k}^2 - q_k) } \sinh ( \overline{z_k} T) \sinh ( {z_k} (t- T) ) \right) \\&\quad - 2 Re \left( \frac{\overline{\Xi _k} }{ {\overline{z_k}}^2 - q_k } \sinh ( \overline{z_k} T) \sinh (\overline{z_k} (t- T) ) \right) . \end{aligned}$$

Due to the definition of \(z_k\), the function \(G_{k,T}(t) \) satisfies the ODE (30).

Moreover, for \(t=T\) we have

$$\begin{aligned} d(k, T) \, G_{k,T}(T) = 2 Re \left( \frac{\overline{\Xi _k} }{ \overline{z_k}^2 - q_k } \cosh ( \overline{z_k} T) \right) - 2 Re \left( \frac{\overline{\Xi _k} }{ \overline{z_k}^2 - q_k } \cosh ( \overline{z_k} T) \right) = 0. \end{aligned}$$

In addition, for the derivative, we obtain

$$\begin{aligned} d(k, T) \, G^{\prime }_{k,T}(t)&= 2 Re \left( \frac{z_k \ \overline{\Xi _k} }{ \overline{z_k}^2 - q_k } \cosh ( \overline{z_k} T) \sinh ( z_k (t- T) ) \right) \\&\quad - 2 Re \left( \frac{\overline{z_k} \ \overline{\Xi _k} }{ \overline{z_k}^2 - q_k } \cosh ( \overline{z_k} T) \sinh ( \overline{z_k} (t- T) ) \right) \\&\quad + 2 Re \left( \frac{\overline{z_k}\ \overline{\Xi _k} }{ {z_k}^2 - q_k } \sinh ( \overline{z_k} T) \cosh ( {z_k} (t- T) ) \right) \\&\quad - 2 Re \left( \frac{\overline{z_k} \ \overline{\Xi _k} }{ {\overline{z_k}}^2 - q_k } \sinh ( \overline{z_k} T) \cosh (\overline{z_k} (t- T) ) \right) . \end{aligned}$$

Hence for \(t=T\), we have the derivative

$$\begin{aligned} d(k, T) \, G^{\prime }_{k,T}(T)&= 2 Re \left( \frac{\overline{z_k}\ \overline{\Xi _k} }{ {z_k}^2 - q_k } \sinh ( \overline{z_k} T) \right) - 2 Re \left( \frac{\overline{z_k} \ \overline{\Xi _k} }{ {\overline{z_k}}^2 - q_k } \sinh ( \overline{z_k} T) \right) . \end{aligned}$$

For the second derivative, we obtain

$$\begin{aligned} d(k, T) \, G^{\prime \prime }_{k,T}(t)&= 2 Re \left( \frac{{z_k}^2 \ \overline{\Xi _k} }{ \overline{z_k}^2 - q_k } \cosh ( \overline{z_k} T) \cosh ( z_k (t- T) ) \right) \\&\quad - 2 Re \left( \frac{\overline{z_k}^2 \ \overline{\Xi _k} }{ \overline{z_k}^2 - q_k } \cosh ( \overline{z_k} T) \cosh ( \overline{z_k} (t- T) ) \right) \\&\quad + 2 Re \left( \frac{{z_k} \overline{z_k} \ \overline{\Xi _k} }{ {z_k}^2 - q_k } \sinh ( \overline{z_k} T) \sinh ( {z_k} (t- T) ) \right) \\&\quad - 2 Re \left( \frac{\overline{z_k}^2 \ \overline{\Xi _k} }{ {\overline{z_k}}^2 - q_k } \sinh ( \overline{z_k} T) \sinh (\overline{z_k} (t- T) ) \right) . \end{aligned}$$

For \(t=0\) this implies

$$\begin{aligned} d(k, T) \, G^{\prime \prime }_{k,T}(0)&= 2 Re \left( \frac{{z_k}^2 \ \overline{\Xi _k} }{ \overline{z_k}^2 - q_k } \cosh ( \overline{z_k} T) \cosh ( z_k T ) \right) - 2 Re \left( \frac{\overline{z_k}^2 \ \overline{\Xi _k} }{ \overline{z_k}^2 - q_k } \cosh ^2 ( \overline{z_k} T) ) \right) \\&\quad - 2 Re \left( \frac{{z_k} \overline{z_k} \ \overline{\Xi _k} }{ {z_k}^2 - q_k } \sinh ( \overline{z_k} T) \sinh ( {z_k} T ) \right) + 2 Re \left( \frac{\overline{z_k}^2 \ \overline{\Xi _k} }{ {\overline{z_k}}^2 - q_k } \sinh ^2 ( \overline{z_k} T) \right) . \end{aligned}$$

For \(t=0\), equation (37) implies

$$\begin{aligned} d(k, T) \, G_{k,T}(0)&= 2 Re \left( \frac{\overline{\Xi _k} }{ \overline{z_k}^2 - q_k } \cosh ( \overline{z_k} T) \cosh ( z_k T ) \right) - 2 Re \left( \frac{\overline{\Xi _k} }{ \overline{z_k}^2 - q_k } \cosh ^2 ( \overline{z_k} T) \right) \\&\quad - 2 Re \left( \frac{\overline{z_k}\ \overline{\Xi _k} }{ {z_k} ({z_k}^2 - q_k) } \sinh ( \overline{z_k} T) \sinh ( {z_k} T ) \right) + 2 Re \left( \frac{\overline{\Xi _k} }{ {\overline{z_k}}^2 - q_k } \sinh ^2( \overline{z_k} T) \right) . \end{aligned}$$

Hence in view of (35) we obtain

$$\begin{aligned}&d(k, T) \, \left[ - G_{k,T}''(0)+ (\gamma - \lambda _k) \, G_{k,T}(0) \right] \\&\quad = - 2 Re \left( \frac{{z_k}^2 \ \overline{\Xi _k} }{ \overline{z_k}^2 - q_k } \cosh ( \overline{z_k} T) \cosh ( z_k T ) \right) + 2 Re \left( \frac{\overline{z_k}^2 \ \overline{\Xi _k} }{ \overline{z_k}^2 - q_k } \cosh ^2 ( \overline{z_k} T) ) \right) \\&\qquad + 2 Re \left( \frac{{z_k} \overline{z_k} \ \overline{\Xi _k} }{ {z_k}^2 - q_k } \sinh ( \overline{z_k} T) \sinh ( {z_k} T ) \right) - 2 Re \left( \frac{\overline{z_k}^2 \ \overline{\Xi _k} }{ {\overline{z_k}}^2 - q_k } \sinh ^2 ( \overline{z_k} T) \right) \\&\qquad + (\Xi _k + z_k^2) d(k, T) \, G_{k,T}(0) \\&\quad = - 2 Re \left( \frac{\Xi _k^2}{ { z_k^2 - q_k } } \right) + 2 |\Xi _k|^2 Re \left( \frac{1}{ { z_k^2 - q_k } } |\cosh ^2( z_k T )| - \frac{ \overline{z_k} }{z_k} \frac{1}{ {z_k}^2 - q_k } |\sinh ^2( z_k T )| \right) \\&\quad = d(k, T) \end{aligned}$$

due to the definition (36). Since \( d(k, T) \not =0 \), this yields

$$\begin{aligned} - G_{k,T}''(0)+ (\gamma - \lambda _k) \, G_{k,T}(0) = 1. \end{aligned}$$

For \(t=0\), the derivative satisfies the equation

$$\begin{aligned} d(k, T) \, G^{\prime }_{k,T}(0)&= - 2 Re \left( \frac{z_k \ \overline{\Xi _k} }{ \overline{z_k}^2 - q_k } \cosh ( \overline{z_k} T) \sinh ( z_k T) \right) \\&\quad + 2 Re \left( \frac{\overline{z_k} \ \overline{\Xi _k} }{ \overline{z_k}^2 - q_k } \cosh ( \overline{z_k} T) \sinh ( \overline{z_k} T ) \right) \\&\quad + 2 Re \left( \frac{\overline{z_k}\ \overline{\Xi _k} }{ {z_k}^2 - q_k } \sinh ( \overline{z_k} T) \cosh ( {z_k} T) \right) \\&\quad - 2 Re \left( \frac{\overline{z_k} \ \overline{\Xi _k} }{ {\overline{z_k}}^2 - q_k } \sinh ( \overline{z_k} T) \cosh (\overline{z_k} T) \right) \\&= - 2 Re \left( \frac{z_k \ \overline{\Xi _k} }{ \overline{z_k}^2 - q_k } \cosh ( \overline{z_k} T) \sinh ( z_k T) \right) \\&\quad + 2 Re \left( \frac{\overline{z_k}\ \overline{\Xi _k} }{ {z_k}^2 - q_k } \sinh ( \overline{z_k} T) \cosh ( {z_k} T) \right) . \end{aligned}$$

For the third derivative, we obtain

$$\begin{aligned} d(k, T) \, G^{\prime \prime \prime }_{k,T}(t)&= 2 Re \left( \frac{{z_k}^3 \ \overline{\Xi _k} }{ \overline{z_k}^2 - q_k } \cosh ( \overline{z_k} T) \sinh ( z_k (t- T) ) \right) \\&\quad - 2 Re \left( \frac{\overline{z_k}^3 \ \overline{\Xi _k} }{ \overline{z_k}^2 - q_k } \cosh ( \overline{z_k} T) \sinh ( \overline{z_k} (t- T) ) \right) \\&\quad + 2 Re \left( \frac{{z_k}^2 \overline{z_k} \ \overline{\Xi _k} }{ {z_k}^2 - q_k } \sinh ( \overline{z_k} T) \cosh ( {z_k} (t- T) ) \right) \\&\quad - 2 Re \left( \frac{\overline{z_k}^3 \ \overline{\Xi _k} }{ {\overline{z_k}}^2 - q_k } \sinh ( \overline{z_k} T) \cosh (\overline{z_k} (t- T) ) \right) . \end{aligned}$$

Hence for \(t=0\) we have

$$\begin{aligned} d(k, T) \, G^{\prime \prime \prime }_{k,T}(0)&= - 2 Re \left( \frac{{z_k}^3 \ \overline{\Xi _k} }{ \overline{z_k}^2 - q_k } \cosh ( \overline{z_k} T) \sinh ( z_k T) \right) \\&\quad + 2 Re \left( \frac{\overline{z_k}^3 \ \overline{\Xi _k} }{ \overline{z_k}^2 - q_k } \cosh ( \overline{z_k} T) \sinh ( \overline{z_k} T ) \right) \\&\quad + 2 Re \left( \frac{{z_k}^2 \overline{z_k} \ \overline{\Xi _k} }{ {z_k}^2 - q_k } \sinh ( \overline{z_k} T) \cosh ( {z_k} T ) \right) \\&\quad - 2 Re \left( \frac{\overline{z_k}^3 \ \overline{\Xi _k} }{ {\overline{z_k}}^2 - q_k } \sinh ( \overline{z_k} T) \cosh (\overline{z_k} T) \right) \\&= - 2 Re \left( \frac{{z_k}^3 \ \overline{\Xi _k} }{ \overline{z_k}^2 - q_k } \cosh ( \overline{z_k} T) \sinh ( z_k T) \right) \\&\quad + 2 Re \left( \frac{{z_k}^2 \overline{z_k} \ \overline{\Xi _k} }{ {z_k}^2 - q_k } \sinh ( \overline{z_k} T) \cosh ( {z_k} T ) \right) . \end{aligned}$$

In order to verify the fourth boundary condition in (33), in view of (35) we obtain the equation

$$\begin{aligned}&d(k, T) \left[ - G_{k,T}'''(0) + (\gamma - \lambda _k) \, G_{k,T}'(0)\right] \\&\quad = 2 Re \left( \frac{{z_k}^3 \ \overline{\Xi _k} }{ \overline{z_k}^2 - q_k } \cosh ( \overline{z_k} T) \sinh ( z_k T) \right) - 2 Re \left( \frac{{z_k}^2 \overline{z_k} \ \overline{\Xi _k} }{ {z_k}^2 - q_k } \sinh ( \overline{z_k} T) \cosh ( {z_k} T ) \right) \\&\qquad + (\Xi _k + z_k^2) \left( - 2 Re \left( \frac{z_k \ \overline{\Xi _k} }{ \overline{z_k}^2 - q_k } \cosh ( \overline{z_k} T) \sinh ( z_k T) \right) \right) \\&\qquad + (\Xi _k + z_k^2) 2 Re \left( \frac{\overline{z_k}\ \overline{\Xi _k} }{ {z_k}^2 - q_k } \sinh ( \overline{z_k} T) \cosh ( {z_k} T) \right) \\&\quad = 0. \end{aligned}$$

We have

$$\begin{aligned} d(k, T) \, G^{\prime \prime \prime }_{k,T}(T)&= 2 Re \left( \frac{{z_k}^2 \overline{z_k} \ \overline{\Xi _k} }{ {z_k}^2 - q_k } \sinh ( \overline{z_k} T) \right) - 2 Re \left( \frac{\overline{z_k}^3 \ \overline{\Xi _k} }{ {\overline{z_k}}^2 - q_k } \sinh ( \overline{z_k} T) \right) . \end{aligned}$$

Hence we have

$$\begin{aligned}{} & {} d(k, T)\left[ G_{k, T}^{\prime \prime \prime }(T)-q_k G_{k, T}^{\prime }(T)\right] \\{} & {} \quad = 2 {Re}\left( z_k^2\overline{z_k} \frac{\overline{\Xi _k}}{z_k^2-q_k} \sinh (\overline{z_k} T)\right) -2{Re}\left( \overline{z_k}^3 \frac{\overline{\Xi _k}}{\overline{z_k}^2-q_k} \sinh \left( \overline{z_k} T\right) \right) \\{} & {} \quad - 2 {Re}\left( q_k \overline{z_k} \frac{\overline{\Xi _k}}{z_k^2-q_k} \sinh \left( \overline{z_k} T\right) \right) + 2{Re}\left( q_k \overline{{z}_k} \frac{\overline{\Xi _k}}{\overline{z_k}^2-q_k} \sinh \left( \overline{z_k} T\right) \right) \\{} & {} \quad = 2 {Re}\left( \overline{z_k} \overline{\Xi _k} \sinh \left( \overline{z_k} T\right) \right) -2 {Re}\left( \overline{z_k} \overline{\Xi _k} \sinh \left( \overline{z_k} T\right) \right) \\{} & {} \quad =0.\\ \end{aligned}$$

Thus we have shown that

$$\begin{aligned} G_{k,T}(T )= & {} 0, \\ { G_{k,T}^{\prime \prime \prime }(T )}= & {} {\frac{ \gamma ^2 - 2 \, \gamma \, \lambda _k -1}{\gamma } \, G_{k,T}^{\prime }(T) }, \\ - G_{k,T}''(0)+ (\gamma - \lambda _k) \, G_{k,T}(0)= & {} 1, \\ - G_{k,T}'''(0)+ (\gamma - \lambda _k) \, G_{k,T}'(0)= & {} 0. \end{aligned}$$

Verification of the basis function \(H_{k,T}(t)\).

Now we consider \({H_{k,T}(t)} \) from (34) that is multiplied with \( (1 + \gamma \, \lambda _k) \, a_{k,T}'(0) \), i.e.

$$\begin{aligned} d(k, T) \, H_{k,T}(t)&= - 2 Re \left( \frac{{\Xi _k} }{ z_k ({z_k}^2 - q_k) } \sinh ( {z_k} T) \cosh ( z_k (t- T) ) \right) \\&\quad + 2 Re \left( \frac{{\Xi _k} }{ z_k ({z_k}^2 - q_k) } \sinh ( {z_k} T) \cosh ( \overline{z_k} (t- T) ) \right) \\&\quad + 2 Re \left( \frac{\overline{\Xi _k} }{ {z_k} ({z_k}^2 - q_k) } \cosh ( \overline{z_k} T) \sinh ( {z_k} (t- T) ) \right) \\&\quad - 2 Re \left( \frac{\overline{\Xi _k} }{ {\overline{z_k}} ({\overline{z_k}}^2 - q_k )} \cosh ( \overline{z_k} T) \sinh (\overline{z_k} (t- T) ) \right) . \end{aligned}$$

Due to the definition of \(z_k\), the function \(H_{k,T}(t) \) satisfies the ODE (30). Moreover, for \(t=T\) we have

$$\begin{aligned} d(k, T) \, H_{k,T}(T) \!=\! - 2 Re \left( \frac{{\Xi _k} }{ z_k ({z_k}^2 - q_k) } \sinh ( {z_k} T) \right) \!+\! 2 Re \left( \frac{{\Xi _k} }{ z_k ({z_k}^2 - q_k) } \sinh ( {z_k} T) \right) \!=\! 0. \end{aligned}$$

For the derivative we have

$$\begin{aligned} d(k, T) \, H_{k,T}^{\prime }(t)&= - 2 Re \left( \frac{ \Xi _k}{ {z_k}^2 - q_k } \sinh ( {z_k} T) \sinh ( z_k (t- T) ) \right) \\&\quad + 2 Re \left( \frac{\overline{z_k} {\Xi _k} }{ z_k ({z_k}^2 - q_k) } \sinh ( {z_k} T) \sinh ( \overline{z_k} (t- T) ) \right) \\&\quad + 2 Re \left( \frac{ \overline{\Xi _k} }{ {z_k}^2 - q_k } \cosh ( \overline{z_k} T) \cosh ( {z_k} (t- T) ) \right) \\&\quad - 2 Re \left( \frac{ \overline{\Xi _k} }{ \overline{z_k}^2 - q_k } \cosh ( \overline{z_k} T) \cosh ( \overline{z_k} (t- T) ) \right) . \end{aligned}$$

Hence for \(t=T\) we obtain

$$\begin{aligned} d(k, T) \, H_{k,T}^{\prime }(T)&= 2 Re \left( \frac{ \overline{\Xi _k} }{ {z_k}^2 - q_k } \cosh ( \overline{z_k} T) \right) - 2 Re \left( \frac{ \overline{\Xi _k} }{ {\overline{z_k}}^2 - q_k } \cosh ( \overline{z_k} T) \right) . \end{aligned}$$

For \(t=0\), we have

$$\begin{aligned} d(k, T) \, H_{k,T}(0)&= - 2 Re \left( \frac{{\Xi _k} }{ z_k ({z_k}^2 - q_k) } \sinh ( {z_k} T) \cosh ( z_k T ) \right) \\&\quad + 2 Re \left( \frac{{\Xi _k} }{ z_k ({z_k}^2 - q_k) } \sinh ( {z_k} T) \cosh ( \overline{z_k} T ) \right) \\&\quad - 2 Re \left( \frac{\overline{\Xi _k} }{ {z_k} ({z_k}^2 - q_k) } \cosh ( \overline{z_k} T) \sinh ( {z_k} T ) \right) \\&\quad + 2 Re \left( \frac{\overline{\Xi _k} }{ {\overline{z_k}} ({\overline{z_k}}^2 - q_k )} \cosh ( \overline{z_k} T) \sinh (\overline{z_k} T ) \right) . \end{aligned}$$

For the second derivative, we have

$$\begin{aligned}&d(k, T) \, H_{k,T}^{\prime \prime }(t) \\&= - 2 Re \left( \frac{ z_k \Xi _k}{ {z_k}^2 - q_k } \sinh ( {z_k} T) \cosh ( z_k (t- T) ) \right) \\&\quad + 2 Re \left( \frac{\overline{z_k}^2 {\Xi _k} }{ z_k ({z_k}^2 - q_k) } \sinh ( {z_k} T) \cosh ( \overline{z_k} (t- T) ) \right) \\&\quad + 2 Re \left( \frac{ z_k \overline{\Xi _k} }{ {z_k}^2 - q_k } \cosh ( \overline{z_k} T) \sinh ( {z_k} (t- T) ) \right) \\&\quad - 2 Re \left( \frac{ \overline{z_k} \overline{\Xi _k} }{ \overline{z_k}^2 - q_k } \cosh ( \overline{z_k} T) \sinh ( \overline{z_k} (t- T) ) \right) . \end{aligned}$$

For \(t=0\) this implies

$$\begin{aligned}&d(k, T) \, H_{k,T}^{\prime \prime }(0) \\&= - 2 Re \left( \frac{ z_k \Xi _k}{ {z_k}^2 - q_k } \sinh ( {z_k} T) \cosh ( z_k T) \right) \\&\quad + 2 Re \left( \frac{\overline{z_k}^2 {\Xi _k} }{ z_k ({z_k}^2 - q_k) } \sinh ( {z_k} T) \cosh ( \overline{z_k} T) \right) \\&\quad - 2 Re \left( \frac{ z_k \overline{\Xi _k} }{ {z_k}^2 - q_k } \cosh ( \overline{z_k} T) \sinh ( {z_k} T ) \right) \\&\quad + 2 Re \left( \frac{ \overline{z_k} \overline{\Xi _k} }{ \overline{z_k}^2 - q_k } \cosh ( \overline{z_k} T) \sinh ( \overline{z_k} T ) \right) . \end{aligned}$$

Hence in view of (35) we obtain

$$\begin{aligned} - d(k, T) \,H_{k,T}''(0)+ (\gamma - \lambda _k) \,\det (M(T)) \, H_{k,T}(0) = 0. \end{aligned}$$

Now we verify that the fourth boundary condition in (33) is satisfied.

For the third derivative, we have

$$\begin{aligned} d(k, T) \, H_{k,T}^{\prime \prime \prime }(t)&= - 2 Re \left( \frac{ {z_k}^2 \Xi _k}{ {z_k}^2 - q_k } \sinh ( {z_k} T) \sinh ( z_k (t- T) ) \right) \\&\quad + 2 Re \left( \frac{\overline{z_k}^3 {\Xi _k} }{ z_k ({z_k}^2 - q_k) } \sinh ( {z_k} T) \sinh ( \overline{z_k} (t- T) ) \right) \\&\quad + 2 Re \left( \frac{ {z_k}^2 \overline{\Xi _k} }{ {z_k}^2 - q_k } \cosh ( \overline{z_k} T) \cosh ( {z_k} (t- T) ) \right) \\&\quad - 2 Re \left( \frac{ {\overline{z_k}}^2 \overline{\Xi _k} }{ \overline{z_k}^2 - q_k } \cosh ( \overline{z_k} T) \cosh ( \overline{z_k} (t- T) ) \right) . \end{aligned}$$

For \(t=0\) this yields

$$\begin{aligned} d(k, T) \, H_{k,T}^{\prime \prime \prime }(0)&= 2 Re \left( \frac{ {z_k}^2 \Xi _k}{ {z_k}^2 - q_k } \sinh ( {z_k} T) \sinh ( z_k T ) \right) \\&\quad - 2 Re \left( \frac{\overline{z_k}^3 {\Xi _k} }{ z_k ({z_k}^2 - q_k) } \sinh ( {z_k} T) \sinh ( \overline{z_k} T ) \right) \\&\quad + 2 Re \left( \frac{ {z_k}^2 \overline{\Xi _k} }{ {z_k}^2 - q_k } \cosh ( \overline{z_k} T) \cosh ( {z_k} T ) \right) \\&\quad - 2 Re \left( \frac{ {\overline{z_k}}^2 \overline{\Xi _k} }{ \overline{z_k}^2 - q_k } \cosh ( \overline{z_k} T) \cosh ( \overline{z_k} T ) \right) . \end{aligned}$$

Using again the definition (35) of \(\Xi _k\) it follows that

$$\begin{aligned} - d(k, T) \,H_{k,T}'''(0)+ (\gamma - \lambda _k) \, d(k, T) \, H_{k,T}'(0) = d(k,T) \end{aligned}$$

by the definition (36) of d(kT) . We have

$$\begin{aligned} d(k, T) \, H_{k,T}^{\prime \prime \prime }(T)&= 2 Re \left( \frac{ {z_k}^2 \overline{\Xi _k} }{ {z_k}^2 - q_k } \cosh ( \overline{z_k} T) \right) - 2 Re \left( \frac{ {\overline{z_k}}^2 \overline{\Xi _k} }{ \overline{z_k}^2 - q_k } \cosh ( \overline{z_k} T) \right) . \end{aligned}$$

Hence, we have

$$\begin{aligned} \begin{aligned}&d(k, T)\left[ H_{k, T}^{\prime \prime \prime }(T)-q_k H_{k, T}^{\prime }(T)\right] \\&\quad = 2 Re \left( \frac{ {z_k}^2 \overline{\Xi _k} }{ {z_k}^2 - q_k } \cosh ( \overline{z_k} T) \right) - 2 Re \left( \frac{ {\overline{z_k}}^2 \overline{\Xi _k} }{ \overline{z_k}^2 - q_k } \cosh ( \overline{z_k} T) \right) \\&\qquad + 2 {Re}\left( q_k \frac{\overline{\Xi _k}}{z_k^2-q_k} \cosh \left( \overline{z_k} T\right) \right) - 2{Re}\left( q_k \frac{\overline{\Xi _k}}{\overline{z_k}^2-q_k} \cosh \left( \overline{z_k} T\right) \right) \\&\quad =0.\\ \end{aligned} \end{aligned}$$

Thus we have shown that

$$\begin{aligned} H_{k,T}(T )= & {} 0, \\ { H_{k,T}^{\prime \prime \prime }(T ) }= & {} {\frac{ \gamma ^2 - 2 \, \gamma \, \lambda _k -1}{\gamma } \, H_{k,T}^{\prime }(T) }, \\ - H_{k,T}''(0)+ (\gamma - \lambda _k) \, H_{k,T}(0)= & {} 0, \\ - H_{k,T}'''(0)+ (\gamma - \lambda _k) \, H_{k,T}'(0)= & {} 1. \end{aligned}$$

The proof of Lemma 2 is complete.

In the next section, it is shown that each of the functions \(F_{k,T}\), \(G_{k,T}\), \(H_{k,T}\) in the representation (34) of the solution \(b_{k,T}\) that are provided in Lemma 2 satisfies an exponential turnpike inequality on the interval [0, T] in the sense that for \(I \in \{F,\, G, \, H\}\) for all \(t\in [0, \, T]\) the following inequality holds:

$$\begin{aligned} |I_{k,T}(t ) | \le C_@ \, \left[ \exp \left( - \frac{\sqrt{\gamma }}{2} t \right) + \exp \left( - \frac{\sqrt{\gamma }}{2} (T-t) \right) \right] . \end{aligned}$$

Here \(C_@\) is a constant that is independent of T and k.

The turnpike inequality that we have obtained is used for the applications in shape optimization as described in the subsequent sections. An important point is that the inequality is independent of the properties of the sequence of eigenvalues \(\lambda _k\) as long as (28) holds. Therefore the inequality is valid over a compact set of perturbations of the state equation (see Theorem 1 and also Remark 9).

6 The Turnpike Property by the Spectral Method for Trees

In this section, we continue our analysis of the structure of the optimal solutions, in particular for the adjoint states. We have in mind the shape optimization problems for the trees. Therefore, we restrict our analysis to the networks in the form of trees. The case of small cycles for the purposes of topology optimization is considered separately. In the latter case, the spectrum is of a specific structure with the branch supported exclusively on the cycle. We show that the difference between the static optimal adjoint state and the dynamic optimal adjoint state satisfies an exponential turnpike inequality as explained above. Our method is to show that all three basis functions in the representation of the difference between the static optimal adjoint state and the dynamic optimal adjoint state that we have obtained from the respective optimality systems satisfy such an exponential turnpike inequality. More precisely, we show that the basis function with a non-zero value at the time \(t=0\) (namely \(G_{k, T}\) and \(H_{k, T}\)) decay exponentially fast with t. The basis function with a non-zero value at the time \(t=T\) (namely \(F_{k, T}\)) decay exponentially fast as a function of \(T-t\), that is backward in time.

6.1 The Turnpike Inequalities for the Basis Functions

Exponential turnpike inequality for the basis function \(F_{k,T}(t)\).

In order to verify the turnpike property we use the following representation where the hyperbolic tangent appears:

$$\begin{aligned}{} & {} d(k, T) \, F_{k,T}(t) \\{} & {} \quad = 2Re \left( - \frac{\overline{\Xi _k}^2 }{ \overline{z_k}^2 - q_k } \cosh ( z_k (T- t) ) \right) \\{} & {} \qquad + 2Re \left( \frac{ |\Xi _k|^2 }{ z_k^2 - q_k } \cosh ( \overline{z_k} T) \cosh (z_k T) \left[ 1 - \tanh (z_k T) \tanh ( z_k(T - t) ) \right] \cosh ( z_k(T - t)) \right) \\{} & {} \qquad + 2 Re \Bigg ( \frac{ |\Xi _k|^2 }{ z_k^2 - q_k } \frac{\overline{z_k}}{z_k} \cosh ( \overline{z_k} T) \tanh ( \overline{z_k} T) \cosh (z_k \, T) [ \tanh ( z_k(T - t) )\\{} & {} \qquad - \tanh (z_k \, T) ] \cosh ( z_k(T - t) ) \Bigg ). \end{aligned}$$

For our analysis, we define the auxiliary functions

$$\begin{aligned} S^1_{k, T}(t)= & {} \frac{2Re \left( - \frac{\overline{\Xi _k}^2 }{ \overline{z_k}^2 - q_k } \cosh ( z_k (T - t) ) \right) }{ d(k, T)}, \\ S^2_{k, T}(t)= & {} \frac{ 2Re \left( \frac{ |\Xi _k|^2 }{ z_k^2 - q_k } \cosh ( \overline{z_k} T) \cosh (z_k T) \left[ 1 - \tanh (z_k T) \tanh ( z_k(T - t) ) \right] \cosh ( z_k(T - t)) \right) }{ d(k, T)}, \end{aligned}$$

and

$$\begin{aligned}{} & {} S^3_{k, T}(t) \\{} & {} = \frac{ 2 Re \left( \frac{ |\Xi _k|^2 }{ z_k^2 - q_k } \frac{\overline{z_k}}{z_k} \cosh ( \overline{z_k} T) \tanh ( \overline{z_k} T) \cosh (z_k \, T) \left[ \tanh ( z_k(T - t) ) - \tanh (z_k \, T) \right] \cosh ( z_k(T - t) ) \right) }{ d(k, T)}. \end{aligned}$$

Then we have

$$\begin{aligned} F_{k,T}(t) = S^1_{k, T}(t) + S^2_{k, T}(t) + S^3_{k, T}(t). \end{aligned}$$
(61)

Define \( I_-= \frac{{Re}\left( (z_k^2 - q_k)(|z_k|^2 - z_k^2) \right) }{|z_k^2| \, |z_k^2 - q_k|}\), \( I_+ = \frac{{Re}\left( (z_k^2 - q_k)(|z_k|^2 + z_k^2) \right) }{|z_k^2| \, |z_k^2 - q_k|}\).

The numbers d(kT) can be represented as

$$\begin{aligned} d(k, T)= & {} -2\, {Re}\left( \frac{\Xi _k^2}{z_k^2 - q_k} \right) + |\Xi _k|^2 I_- \cosh (2 \, {Re}(z_k)\, T) \nonumber \\{} & {} + |\Xi _k|^2 I_+ \cosh (2 \, {Im}(z_k)\, T). \end{aligned}$$
(62)

Hence we obtain the upper bound

$$\begin{aligned} |S^1_{k, T}(t)| \le \frac{ \left| 2Re \left( \frac{ 1 }{ \overline{z_k}^2 - q_k } \cosh ( z_k (T - t) ) \right) \right| }{ |I_-| \cosh (2 \, {Re}(z_k)\, T) - \left| I_+ \cosh (2 \, {Im}(z_k)\, T) -2 {Re}\left( \frac{ \Xi _k^2 }{|\Xi _k|^2(z_k^2 - q_k)} \right) \right| }. \end{aligned}$$

This implies the inequality

$$\begin{aligned} |S^1_{k,T}(t)| \le M_1 \exp ( - |Re(z_k)| (T- t)) \end{aligned}$$
(63)

with a constant \(M_1 \ge 1\) that is independent of k and T. We have

$$\begin{aligned}1 -{} & {} \tanh (z_k\, T) \tanh ( z_k \, (T - t)) \\{} & {} \quad = \frac{ 2[ \exp ( 2 \, z_k\, T ) + \exp ( 2 \, z_k\, (T - t) ) ] }{ (\exp ( 2 \, z_k\, T ) + 1) \, (\exp ( 2 \, z_k\, (T - t) ) + 1) } \\{} & {} \quad = \frac{ 2 }{ ( 1 + \exp ( -2 \, z_k\, T ) ) \, (\exp ( 2 \, z_k\, (T - t) ) + 1) }\\{} & {} \qquad + \frac{ 2 }{ ( 1 + \exp ( -2 \, z_k\, (T - t) ) ) \, (\exp ( 2 \, z_k\, T ) + 1) }. \end{aligned}$$

Hence for \(T\rightarrow \infty \) this term converges to zero exponentially fast. More precisely, due to (31) for all \(k\in \{0,1,2,..\}\) for T sufficiently large we have the inequality

$$\begin{aligned} |1 - \tanh (z_k\, T) \tanh ( z_k \, (T - t)) | \le 16 \exp ( - 2 \, |Re (z_k)|\, (T - t) ). \end{aligned}$$
(64)

Thus we have

$$\begin{aligned} |S^2_{k, T}(t)| \le \frac{ 32 | Re\left( \frac{ 1 }{ z_k^2 - q_k } |\cosh ( z_k T ) |^2\, \cosh ( {z_k} \,(T - t)) | \right) \exp ( - 2 \, |Re (z_k)|\, (T - t) ) | }{ |I_-| \cosh (2 \, {Re}(z_k)\, T) - \left| I_+ \cosh (2 \, {Im}(z_k)\, T) -2 {Re}\left( \frac{ \Xi _k^2 }{|\Xi _k|^2(z_k^2 - q_k)} \right) \right| }. \end{aligned}$$

This implies the inequality

$$\begin{aligned} |S^2_{k,T}(t)| \le M_2 \exp ( - |Re(z_k)| (T- t)) \end{aligned}$$
(65)

with a constant \(M_2 \ge 1\) that is independent of k and T.

In addition, we have

$$\begin{aligned} \tanh ({z_k}\, (T-t)) - \tanh ( {z_k}T) = \frac{ 2[ \exp ( 2 \, z_k\, T ) - \exp ( 2 \, z_k\, (T - t) ) ] }{ (\exp ( 2 \, z_k\, T ) + 1) \, (\exp ( 2 \, z_k\, (T - t) ) + 1) } \end{aligned}$$

so as above for T sufficiently large, we obtain the inequality

$$\begin{aligned} | \tanh ({z_k}\, (T-t)) - \tanh ( {z_k}T) | \le 16 \exp ( - 2 \, |Re (z_k)|\, (T - t) ). \end{aligned}$$
(66)

This yields the bound

$$\begin{aligned}{} & {} |S^3_{k, T}(t)| \\{} & {} \quad \le \frac{ 32 | Re\left( \frac{ 1 }{ z_k^2 - q_k } \frac{\overline{z_k}}{z_k} \cosh ( z_k T ) \cosh (\overline{z_k} T) \cosh ( {z_k} \,(T - t)) \tanh ( \overline{z_k}T) \right) | \exp ( - 2 \, |Re (z_k)|\, (T - t) ) }{ |I_-| \cosh (2 \, {Re}(z_k)\, T) - \left| I_+ \cosh (2 \, {Im}(z_k)\, T) -2 {Re}\left( \frac{ \Xi _k^2 }{|\Xi _k|^2(z_k^2 - q_k)} \right) \right| }. \end{aligned}$$

Thus we obtain the inequality

$$\begin{aligned}|S^3_{k,T}(t)| \le M_3 \exp ( - |Re(z_k)| (T- t))\end{aligned}$$

with a constant \(M_3 \ge 1\) that is independent of k and T. Together with (63) and (65) due to (61) and (31) this implies that for \(F_{k,T}(t) \) we have

$$\begin{aligned} |F_{k,T}(t ) | \le (M_1 + M_2 + M_3)\, \exp \left( - \frac{\sqrt{\gamma }}{2} (T-t) \right) . \end{aligned}$$
(67)

Exponential turnpike inequality for the basis function \(G_{k,T}(t)\).

Now we derive the turnpike inequality for \(G_{k,T}(t)\). Again we use a representation with the hyperbolic tangent. We have

$$\begin{aligned}{} & {} d(k, T) \, G_{k,T}(t) \nonumber \\{} & {} \quad = - 2 Re \left( \frac{{\Xi _k} }{ {z_k}^2 - q_k } \cosh ( {z_k} T) \left[ 1 + \tanh ( {z_k} T) \tanh ({z_k} (t- T) ) \right] \cosh ( {z_k} (t- T)) \right) \nonumber \\{} & {} \qquad + 2 Re \left( \frac{\overline{\Xi _k} }{ \overline{z_k}^2 - q_k } \cosh ( \overline{z_k} T) \right. \nonumber \\{} & {} \left. \qquad \left[ 1 - \frac{\overline{z_k}^2 - q_k}{ {z_k}^2 - q_k } \frac{\overline{z_k} }{ {z_k} } \tanh ( \overline{z_k} T) \tanh ( {z_k} (t- T) ) \right] \cosh ( {z_k} (t- T) ) \right) \end{aligned}$$
(68)

We have

$$\begin{aligned} \lim _{T \rightarrow \infty } \left[ 1 - \frac{\overline{z_k}^2 - q_k}{ {z_k}^2 - q_k } \frac{\overline{z_k} }{ {z_k} } \, \tanh ( \overline{z_k} \, T) \tanh ( {z_k}(t - T)) \right] = 1 + \frac{\overline{z_k}^2 - q_k}{ {z_k}^2 - q_k } \frac{\overline{z_k} }{ {z_k} }. \end{aligned}$$

Similarly, we have

$$\begin{aligned} \lim _{T \rightarrow \infty } \left[ 1 + \tanh ( z_k T )\, \tanh ( z_k(t - T) ) \right] =0 \end{aligned}$$

and for the absolute value we have the bound (64).

For our analysis, we define the auxiliary functions

$$\begin{aligned}&{{\tilde{S}}}^1_{k, T}(t)\\&= \frac{ - 2 Re \left( \frac{{\Xi _k} }{ {z_k}^2 - q_k } \cosh ( {z_k} T) \left[ 1 + \tanh ( {z_k} T) \tanh ({z_k} (t- T) ) \right] \cosh ( {z_k} (t- T)) \right) }{ d(k, T)},\\ {{\tilde{S}}}^2_{k, T}(t)&= \frac{ 2 Re \left( \frac{\overline{\Xi _k} }{ \overline{z_k}^2 - q_k } \cosh ( \overline{z_k} T) \left[ 1 - \frac{\overline{z_k}^2 - q_k}{ {z_k}^2 - q_k } \frac{\overline{z_k} }{ {z_k} } \tanh ( \overline{z_k} T) \tanh ( {z_k} (t- T) ) \right] \cosh ( {z_k} (t- T) ) \right) }{ d(k, T)}. \end{aligned}$$

Then we have

$$\begin{aligned} G_{k,T}(t) = {{\tilde{S}}}^1_{k, T}(t) + {{\tilde{S}}}^2_{k, T}(t). \end{aligned}$$
(69)

Due to (64) we obtain the inequality

$$\begin{aligned} |{{\tilde{S}}}^1_{k, T}(t)| \le \frac{ 32\, \left| Re\left( \frac{\Xi _k}{ | \Xi _k^2 | (z_k^2 - q_k) } \cosh ( z_k T ) \, \cosh ( z_k(t - T) ) \right) \right| \exp ( - 2 \, |Re (z_k)|\, (T - t) ) }{ |I_-| \cosh (2 \, {Re}(z_k)\, T) - \left| I_+ \cosh (2 \, {Im}(z_k)\, T) -2 {Re}\left( \frac{ \Xi _k^2 }{|\Xi _k|^2(z_k^2 - q_k)} \right) \right| }. \end{aligned}$$

This implies the inequality

$$\begin{aligned} |{{\tilde{S}}}^1_{k,T}(t)| \le \frac{1}{|\Xi _k|} \, {{\tilde{M}}}_1 \exp ( - |Re(z_k)| (T- t)) \end{aligned}$$
(70)

with a constant \({{\tilde{M}}}_1 >0\) that is independent of k and T. Moreover, we have

$$\begin{aligned} |{{\tilde{S}}}^2_{k, T}(t)| \le \frac{ 32 \left| Re\left( \frac{ \overline{\Xi _k} }{ | \Xi _k^2 | (z_k^2 - q_k) } \cosh ( \overline{z_k} \, T) \cosh ( {z_k}(t - T)) \right) \right| }{ |I_-| \cosh (2 \, {Re}(z_k)\, T) - \left| I_+ \cosh (2 \, {Im}(z_k)\, T) -2 {Re}\left( \frac{ \Xi _k^2 }{|\Xi _k|^2(z_k^2 - q_k)} \right) \right| }. \end{aligned}$$

This implies the inequality

$$\begin{aligned} |{{\tilde{S}}}^2_{k,T}(t)| \le \frac{1}{|\Xi _k|} \, {{\tilde{M}}}_2 \left[ \exp ( - |Re(z_k)| \, t) + \exp ( - |Re(z_k)| (T- t)) \right] \end{aligned}$$
(71)

with a constant \({{\tilde{M}}}_2 >0\) that is independent of k and T. With (70) and (71) due to (69) and (31) this implies that for \(G_{k,T}(t) \) we have

$$\begin{aligned} |G_{k,T}(t ) | \le \frac{1}{|\Xi _k|} \, ({{\tilde{M}}}_1 + {{\tilde{M}}}_2)\, \left[ \exp ( - \frac{\sqrt{\gamma }}{2} \, t) + \exp ( - \frac{\sqrt{\gamma }}{2} (T- t)) \right] . \end{aligned}$$
(72)

Exponential turnpike inequality for the basis function \(H_{k,T}(t)\).

Finally we show the exponential turnpike inequality for the third basis function \(H_{k,T}\). We have

$$\begin{aligned} d(k, T) \, H_{k,T}(t)= & {} 2 Re \left( \frac{ \overline{\Xi _k} }{ \overline{z_k} ( \overline{z_k}^2 - q_k) } \sinh ( \overline{z_k} T) \cosh ( {z_k} (t- T) ) \right. \\{} & {} \left. + \frac{ \overline{\Xi _k} }{ {z_k} ({z_k}^2 - q_k) } \cosh ( \overline{z_k} T) \, \sinh ({z_k} (t- T) ) \right) \\{} & {} - 2 Re \left( \frac{{\Xi _k} }{ z_k ({z_k}^2 - q_k) } \sinh ( {z_k} T) \cosh ( z_k (t- T) )\right. \\{} & {} \left. + \frac{ {\Xi _k} }{ {z_k} ({z_k}^2 - q_k) } \cosh ( {z_k} T) \sinh ({z_k} (t- T) ) \right) . \end{aligned}$$

For our analysis, we define the auxiliary functions

$$\begin{aligned}{} & {} {{\hat{S}}}^1_{k, T}(t) \\{} & {} \quad = \frac{ 2 Re\left( \overline{\Xi _k} \cosh (\overline{z_k}T) \left[ \frac{ 1 }{ \overline{z_k} (\overline{z_k}^2 - q_k) } \tanh ( \overline{z_k}T) + \frac{ 1 }{ {z_k} ({z_k}^2 - q_k) } \tanh ( z_k (t - T) ) \right] \cosh ( {z_k} (t- T) ) \right) }{ d(k, \, T) }, \\{} & {} \quad {{\hat{S}}}^2_{k, T}(t) = \frac{ 2 Re\left( \frac{ {\Xi _k} }{ {z_k} ({z_k}^2 - q_k) } \cosh ({z_k}T) \left[ \tanh ( {z_k}T) + \tanh ( z_k (t - T) ) \right] \cosh ( z_k (t- T) ) \right) }{ d(k, \, T) }. \end{aligned}$$

Then we have

$$\begin{aligned} H_{k,T}(t) = {{\hat{S}}}^1_{k, T}(t) -{{\hat{S}}}^2_{k, T}(t). \end{aligned}$$
(73)

For T sufficiently large (uniformly with respect to k due to (31)) we have the bound

$$\begin{aligned} \left| \frac{ 1 }{ \overline{z_k} (\overline{z_k}^2 - q_k) } \tanh ( \overline{z_k}T) + \frac{ 1 }{ {z_k} ({z_k}^2 - q_k) } \tanh ( z_k (t - T) ) \right| \le \frac{ 4 }{ |{z_k} ({z_k}^2 - q_k) |}. \end{aligned}$$

This yields

$$\begin{aligned} |{{\hat{S}}}^1_{k, T}(t) | \le \frac{ \frac{1}{ |\Xi _k| } \frac{ 8 }{ |{z_k} ({z_k}^2 - q_k) |} \left| \cosh (\overline{z_k}T) \cosh ( {z_k} (t- T) ) \right| }{ \left| I_- \right| \cosh (2 \, {Re}(z_k)\, T) - \left| I_+ \cosh (2 \, {Im}(z_k)\, T) -2 {Re}\left( \frac{ \Xi _k^2 }{|\Xi _k|^2(z_k^2 - q_k)} \right) \right| }. \end{aligned}$$

This implies the inequality

$$\begin{aligned} |{{\hat{S}}}^1_{k,T}(t)| \le \frac{1}{|\Xi _k|^2} \, {{\hat{M}}}_2 \left[ \exp ( - |Re(z_k)| \, t) + \exp ( - |Re(z_k)| (T- t)) \right] \end{aligned}$$
(74)

with a constant \({{\hat{M}}}_2 >0\) that is independent of k and T.

For T sufficiently large (uniformly with respect to k due to (31)) we have the bound \( \left| \tanh ( z_k T ) + \tanh ( z_k(t - T) ) \right| \le 4. \) This yields the bound

$$\begin{aligned} |{{\hat{S}}}^2_{k, T}(t) | \le \frac{ 8\frac{1}{ |\Xi _k| } \left| \frac{ 1 }{ {z_k} ({z_k}^2 - q_k) } \cosh ({z_k}T) \, \cosh ( z_k (t- T) ) \right| }{ \left| I_- \right| \cosh (2 \, {Re}(z_k)\, T) - \left| I_+ \cosh (2 \, {Im}(z_k)\, T) -2 {Re}\left( \frac{ \Xi _k^2 }{|\Xi _k|^2(z_k^2 - q_k)} \right) \right| }. \end{aligned}$$

Hence we obtain the inequality

$$\begin{aligned} |{{\hat{S}}}^2_{k,T}(t)| \le \frac{1}{|\Xi _k|^2} \, {{\hat{M}}}_1 \left[ \exp ( - |Re(z_k)| \, t) + \exp ( - |Re(z_k)| (T- t)) \right] \end{aligned}$$
(75)

with a constant \({{\hat{M}}}_1 >0\) that is independent of k and T.

With (74) and (75) due to (73) and (31) this implies that for \(H_{k,T}(t) \) we have

$$\begin{aligned} |H_{k,T}(t ) | \le \frac{1}{|\Xi _k|^2} \, ({{\hat{M}}}_1 + {{\hat{M}}}_2)\, \left[ \exp ( - \frac{\sqrt{\gamma }}{2} \, t) + \exp ( - \frac{\sqrt{\gamma }}{2} (T- t)) \right] . \end{aligned}$$
(76)

6.2 Turnpike Theorem Between the Dynamic and Static Optimality Systems

We have unique solutions for the optimality systems governed by static and dynamic state equations. Now, we compare the elements of optimality systems and obtain the turnpike inequalities for the Optimality Systems.

Indeed, the turnpike inequalities that we have derived lead to the useful for applications Turnpike Theorem which means that:

The difference \(\nu ^T\) of the optimal dynamic control and the optimal static control and the corresponding differences \(\omega ^T\) for the state and \(\mu ^T\) the adjoint state admits an exponential turnpike property.

To this end, we need some additional regularity assumptions.

Theorem 1

Assume that (28) holds and that the initial state satisfies the regularity condition

$$\begin{aligned} \sum _{k=0}^\infty \lambda _k \, |a_k (0)|^2 +|a_k' (0)|^2 < \infty , \end{aligned}$$
(77)

that is the initial state belongs to the energy space of the elliptic problem defined by the bilinear form \(a(\cdot , \, \cdot )\). If \(\Omega = \Gamma \) then there exists a constant \({{\tilde{D}}} = {{\tilde{D}}}(y_0, \, y_1, \, p^{\sigma } )\) that is independent of T and t such that for all \(t \in [0, \, T]\)

$$\begin{aligned} \Vert \omega ^T(t) \Vert _{L^2(\Omega )}^2 + \Vert \nu ^T(t) \Vert _{L^2(\Omega )}^2 + \Vert \mu ^T(t) \Vert _{L^2(\Omega )}^2 \le {{\tilde{D}}} \left[ \textrm{e}^{ - \sqrt{\gamma }\, t } + \textrm{e}^{ - \sqrt{\gamma } (T- t) } \right] . \end{aligned}$$
(78)

Moreover, the constant \({{\tilde{D}}}\) depends on \(\Omega \) only as a function of the energy norm for the initial state that is determined by \(\Omega \) as in (77).

Remark 9

In the case of boundary control problems on networks, the Turnpike Property for optimality systems can be shown. The difference between the boundary control and the distributed control is the appearance of a linear operator in the optimality conditions. In the optimality conditions of the boundary control problem, a linear operator maps the adjoint state into the optimal control.

For the optimal cost the exponential turnpike inequality (78) implies the so-called integral turnpike property (see e.g. [15])

$$\begin{aligned} \sup _{T>0} \int _0^T \Vert \omega ^T(t) \Vert _{L^2(\Omega )}^2 + \Vert \nu ^T(t) \Vert _{L^2(\Omega )}^2 + \Vert \mu ^T(t) \Vert _{L^2(\Omega )}^2 \, dt < \infty . \end{aligned}$$

This implies in turn

$$\begin{aligned} \lim _{ T\rightarrow \infty } \frac{1}{T} J_T({{\hat{u}}}^T) = I({{\hat{v}}}), \end{aligned}$$
(79)

see for example [19].

In shape sensitivity analysis [20] we avoid, if possible, the dependence of the shape gradient of the cost with respect to given data including e.g., the given initial conditions. Thus, we define the initial conditions, say \(y_0(x)\) and \(y_1(x)\), \(x\in \Omega _\tau \), for variable domains \(\tau \rightarrow \Omega _\tau \) used for the derivation of shape gradient of the cost. If \(\Omega _\tau \) is e.g., the cross with variable length of the edges, we select the elements \(y_0, y_1\) as the restrictions to \(\Omega _\tau \) of functions \(Y_0(x), Y_1(x)\) defined on the cross with the edges of maximal lengths. The shape derivatives of the restrictions are zero. Therefore, there is no contribution from the initial conditions to the shape gradient of the cost.

Remark 10

We use the material derivative method [20] for the purposes of shape sensitivity analysis for networks. The general rule for the data of initial-boundary value problems is to select the given functions by the restriction to actual domain of some functions defined everywhere. The shape gradients of such initial data are simply zero and the material derivatives are given by the gradients, thus some regularity is required. In this way the shape gradient of the cost is independent of the initial data. In our case, this selection can be used for the initial conditions of the displacement and the velocity. The material derivatives of such initial conditions \(Y=Y(x)\) take the form \(Y^\prime (x){\mathcal {V}}(0,x)\), where \({\mathcal {V}}(\tau ,x)\) is the velocity field of the material derivative method. In another words, the initial conditions are selected in such a way that there is no contribution of the initial conditions to the shape gradient of the cost function.

The following corollary states a shape-turnpike result. It is a relation between the optimal values of a dynamic optimal shape problem for large time horizons and the optimal values for the static optimal shape problem. For the proof we suggest to proceed by contradiction.

Assumption 1

Let us consider a tree \(G=\{ E,V\}\) with the set of edges \(E_i=[0,L_i]\), \(i=1,\dots ,N\), and denote by \(\ell =\textrm{col}\,(L_1,\dots ,L_N)\). The set of admissible trees \(\Omega (\ell )\in {\mathcal {A}}\) is defined by the conditions \(M^{min}_i\le L_i\le M^{max}_i\), where \(0<M_0\le M^{min}_i< M^{max}_i<M_1<\infty \). The set of admissible trees is convex and compact, therefore, for the minimizing sequence \(\ell _n\) of optimization problem there is a subsequence, still denoted by the same symbol such that we have \(\ell _n\rightarrow \ell _\infty \) in \({\mathbb {R}}^N\), and in addition \(\Omega (\ell _\infty )\in {\mathcal {A}}\).

Corollary 1

Let Assumption 1 hold. Let a sequence of shape parameters \((\ell _n)_n\) and a bounded sequence of controls \(({{\hat{u}}}_n)_n\) with \({{\hat{u}}}_n(t) \in L^2(\Omega (\ell _n))\) for all \(n \in \{1,2,3,...\}\) be given. Let \({{\hat{y}}}_n\) denote the generated state and \({{\hat{p}}}_n\) the corresponding adjoint state. Assume that for all \(n \in \{1,2,3,...\}\) we have

$$\begin{aligned}{} & {} \Vert \omega _n^T(t) \Vert _{ L^2(\Omega (\ell _n)) }^2 + \Vert \nu _n^T(t) \Vert _{ L^2(\Omega (\ell _n)) }^2 + \Vert \mu _n^T(t) \Vert _{ L^2(\Omega (\ell _n)) }^2 \nonumber \\{} & {} \quad \le {{\tilde{D}}} \left[ \textrm{e}^{ - \sqrt{\gamma }\, t } + \textrm{e}^{ - \sqrt{\gamma } (T- t) } \right] \end{aligned}$$
(80)

where \( \omega ^T_n = {{\hat{y}}}^T_n - {{\hat{z}}}^{\sigma }_n, \, \mu ^T_n = {{\hat{p}}}^T_n - {{\hat{p}}}^{\sigma }_n, \nu ^T_n = {{\hat{u}}}^T_n - {\hat{v}}^{\sigma }_n\) and \(({\hat{v}}_n,{\hat{z}}_n,{\hat{p}}_n)\) is optimal for \(\Omega (\ell _n)\)

Assume that \(\lim _{n\rightarrow \infty } \ell _{opt}(T_n) = {{\hat{\ell }}} \) and that \({{\hat{u}}}_n\) converges weakly to \(u_{opt}\).

Assume that the optimal shape problem with (OCE) has a solution \((\ell _{opt}, u_{opt})\). Then \(u_{opt}\) is a solution of (OCE).

Let \({{\hat{v}}}_{opt}\) denote the solution of (OCS) for \(\ell _{opt}\).

Then we have

$$\begin{aligned}{} & {} \Vert \omega ^T_{opt}(t) \Vert _{L^2(\Omega ( \ell _{opt} ))}^2 + \Vert \nu ^T_{opt}(t) \Vert _{L^2 (\Omega ( \ell _{opt} )) }^2 + \Vert \mu ^T_{opt}(t) \Vert _{L^2(\Omega ( \ell _{opt} ))}^2 \nonumber \\{} & {} \quad \le {{\tilde{D}}} \left[ \textrm{e}^{ - \sqrt{\gamma }\, t } + \textrm{e}^{ - \sqrt{\gamma } (T- t) } \right] . \end{aligned}$$
(81)

Assume that for a subsequence we have \(\lim _{T_n\rightarrow \infty } \ell _{opt}(T_n) = {{\hat{\ell }}} \).

Then we have

$$\begin{aligned} \lim _{ n\rightarrow \infty } \frac{1}{T_n} J_{T_n} ({{\hat{u}}}^{T_n}_{opt}, \ell _{opt}(T_n) ) = I({{\hat{v}}}, \, {{\hat{\ell }}}). \end{aligned}$$
(82)

and

\({{\hat{v}}} \) is the optimal control for the network defined in \(\Omega ({{\hat{\ell }}})\), the limit shape parameter \({{\hat{\ell }}}\) is optimal for the static problem \(\ell \rightarrow (OCS)(\ell )\), the optimal shape reads \(\Omega ({{\hat{\ell }}})\). In general, an optimal shape is not unique but it does exist for the compact set of admissible shapes.

Remark 11

Under Assumption 1 the set of admissible shapes is convex and compact in \({\mathbb {R}}^N\). Denote by \({{\hat{\ell }}}\) an optimal shape for the static problem, note that the optimal shape is not unique, and let the admissible sequence of shapes \(\ell _n\) be convergent to an optimal shape for \(n\rightarrow \infty \),

$$\begin{aligned} \ell _n\rightarrow {{\hat{\ell }}} \end{aligned}$$

then

$$\begin{aligned} I({{\hat{v}}}, \, {{\hat{\ell }}})= \lim _{ n\rightarrow \infty } \frac{1}{T_n} J_{T_n} ({{\hat{u}}}^{T_n}_{opt}, \ell _n )\ge \lim _{ n\rightarrow \infty } \frac{1}{T_n} J_{T_n} ({{\hat{u}}}^{T_n}_{opt}, \ell _{opt}(T_n) ) = I({{\hat{v}}}, \, {{\tilde{\ell }}}) \end{aligned}$$
(83)

therefore

$$\begin{aligned} I({{\hat{v}}}, \, {{\hat{\ell }}})=I({{\hat{v}}}, \, {{\tilde{\ell }}}). \end{aligned}$$

Proof of the corollary.

The constant control with the value \({{\hat{v}}}\) can be considered as an element of \(L^2(\Omega ( \ell _{opt}(T_n) ))\). We have the inequality

$$\begin{aligned}{} & {} \left| \Vert {{\hat{u}}}^{T_n}_{opt}(\ell _{opt}(T_n)) - u_d \Vert ^2_{ L^2(\Omega ( \ell _{opt}(T_n) )) } - \Vert {{\hat{v}}} - u_d \Vert ^2_{ L^2(\Omega ( \ell _{opt}(T_n) )) } \right| \\{} & {} \quad \le \Vert {{\hat{u}}}^{T_n}_{opt}(\ell _{opt}(T_n)) - {{\hat{v}}} \Vert _{ L^2(\Omega ( \ell _{opt}(T_n) )) } \\{} & {} \quad \left( \Vert {{\hat{u}}}^{T_n}_{opt}(\ell _{opt}(T_n)) - u_d \Vert _{ L^2(\Omega ( \ell _{opt}(T_n) )) } + \Vert {{\hat{v}}} - u_d \Vert _{ L^2(\Omega ( \ell _{opt}(T_n) )) } \right) . \end{aligned}$$

Integration from 0 to \(T_n\) and division by \(T_n\) yields

$$\begin{aligned}{} & {} \left| \frac{ \int _0^{T_n} \Vert {{\hat{u}}}^{T_n}_{opt}(\ell _{opt}(T_n)) - u_d \Vert ^2_{ L^2(\Omega ( \ell _{opt}(T_n) )) } \, dt }{T_n} - \Vert {{\hat{v}}} - u_d \Vert ^2_{ L^2(\Omega ( \ell _{opt}(T_n) )) } \right| \\{} & {} \quad \le \tfrac{ \int _0^{T_n} \Vert {{\hat{u}}}^{T_n}_{opt}(\ell _{opt}(T_n)) - {{\hat{v}}} \Vert _{ L^2(\Omega ( \ell _{opt}(T_n) )) } \left( \Vert {{\hat{u}}}^{T_n}_{opt}(\ell _{opt}(T_n)) - u_d \Vert _{ L^2(\Omega ( \ell _{opt}(T_n) )) } + \Vert {{\hat{v}}} - u_d \Vert _{ L^2(\Omega ( \ell _{opt}(T_n) )) } \right) \, dt }{{T_n}} \\{} & {} \quad \le \frac{ \int _0^{T_n} \Vert {{\hat{u}}}^{T_n}_{opt}(\ell _{opt}(T_n)) - {{\hat{v}}} \Vert _{ L^2(\Omega ( \ell _{opt}(T_n) )) }^2 \, dt}{T_n} \\{} & {} \qquad + \frac{ 2 \Vert {{\hat{v}}} - u_d \Vert _{ L^2(\Omega ( \ell _{opt}(T_n) )) } \,\int _0^{T_n} \Vert {{\hat{u}}}^{T_n}_{opt}(\ell _{opt}(T_n)) - {{\hat{v}}} \Vert _{ L^2(\Omega ( \ell _{opt}(T_n) )) } \, dt }{{T_n}}. \end{aligned}$$

For the state we obtain a similar inequality, namely

$$\begin{aligned}{} & {} \left| \frac{ \int _0^{T_n} \Vert {{\hat{y}}}^{T_n}_{opt}(\ell _{opt}(T_n)) - y_d \Vert ^2_{ L^2(\Omega ( \ell _{opt}(T_n) )) } \, dt }{T_n} - \Vert {{\hat{z}}} - y_d \Vert ^2_{ L^2(\Omega ( \ell _{opt}(T_n) )) } \right| \\{} & {} \quad \le \frac{ \int _0^{T_n} \Vert {{\hat{y}}}^{T_n}_{opt}(\ell _{opt}(T_n)) - {{\hat{z}}} \Vert _{ L^2(\Omega ( \ell _{opt}(T_n) )) }^2 \, dt}{T_n} \\{} & {} \qquad + \frac{ 2 \Vert {{\hat{z}}} - y_d \Vert _{ L^2(\Omega ( \ell _{opt}(T_n) )) } \,\int _0^{T_n} \Vert {{\hat{y}}}^{T_n}_{opt}(\ell _{opt}(T_n)) - {{\hat{z}}} \Vert _{ L^2(\Omega ( \ell _{opt}(T_n) )) } \, dt }{{T_n}}. \end{aligned}$$

For the optimal cost the exponential turnpike inequality (78) implies the integral turnpike property (see e.g. [15])

$$\begin{aligned} \sup _{T>0} \sup _{\ell } \int _0^T \Vert \omega ^T(t) \Vert _{L^2(\Omega )}^2 + \Vert \nu ^T(t) \Vert _{L^2(\Omega )}^2 + \Vert \mu ^T(t) \Vert _{L^2(\Omega )}^2 \, dt < \infty . \end{aligned}$$

Moreover, we have

$$\begin{aligned} \sup _{T>0} \sup _{\ell } \int _0^T \Vert \omega ^T(t) \Vert _{L^2(\Omega )} + \Vert \nu ^T(t) \Vert _{L^2(\Omega )} + \Vert \mu ^T(t) \Vert _{L^2(\Omega )} \, dt < \infty . \end{aligned}$$

Thus adding up the inequalities for the control and the state and taking the limit for \(T_n\rightarrow \infty \) yields (82).

Remark 12

For tree-shaped graphs often the system is exactly controllable in some finite time \(t_{\min }\). Recently it was shown that if there is also control action at the interior nodes of the graph, exact controllability is also possible for a graph with cycles, see [21].

In this case we can choose for all \(n \in \{1,2,3,...\}\) a control function \(u_{init}^{(n)}(t) \in L^2\left( 0, \, t_{\min }; L^2( \Omega ( \ell _{opt}(T_n) ))\right) \) that steers the system to the constant state \(y(t_{\min },\,\cdot ) = {{\hat{y}}}\), \(y_t(t_{\min },\,\cdot ) = 0\) and satisfies

$$\begin{aligned} \max _n \Vert u_{init}^{(n)}\Vert _{ L^2\left( 0, \, t_{\min }; L^2( \Omega ( \ell _{opt}(T_n) ))\right) } < \infty . \end{aligned}$$
(84)

Such a control can be determined using the classical method of moments as described for example in [22].

We define the control \({{\tilde{v}}}^{(n)}(t) = \left\{ \begin{array}{c} u_{init}^{(n)}(t), \, t\in (0, \, t_{\min }), \\ {{\hat{v}}}, \, t \ge t_{\min }. \end{array} \right. \)

Then \( {{\tilde{v}}}^{(n)}\) is feasible for \((OCE)(T_n, \, \Omega ( \ell _{opt}(T_n) ) )\) and thus we have

$$\begin{aligned} J_{T_n} ({{\hat{u}}}^{T_n}_{opt}, \ell _{opt}(T_n) ) \le J_{T_n} ({{\tilde{v}}}^{(n)}, \ell _{opt}(T_n) ). \end{aligned}$$
(85)

Moreover, (82) implies that for all \(\varepsilon >0\) if \(T_n>0\) is sufficiently large we have

$$\begin{aligned} \lim _{T_n \rightarrow \infty } \frac{1}{T_n} J_{T_n} ({{\tilde{v}}}^{(n)}, \ell _{opt}(T_n) ) \le \frac{1}{T_n} J_{T_n} ({{\hat{u}}}^{T_n}_{opt}, \ell _{opt}(T_n) ) + \varepsilon . \end{aligned}$$
(86)

This can be seen as follows. Since \(\lim _{n\rightarrow \infty } T_n = \infty \) due to (84) the contribution of the integral on the time interval \((0, \, t_{\min })\) vanishes in the limit, that is we have

$$\begin{aligned} \lim _{ n\rightarrow \infty } \frac{ \int _0^{t_{\min }} \Vert y({{\tilde{v}}}^{(n)}) -y^d\Vert _{L^2(\Omega )}^2 + \gamma \, \Vert \partial _t( y({{\tilde{v}}}^{(n)}) -y^d)\Vert _{L^2(\Omega )}^2 + \Vert {{\tilde{v}}}^{(n)} - u^d\Vert _{L^2(\Gamma )}^2\,dt}{T_n} =0 \end{aligned}$$

and since \(\lim _{T_n\rightarrow \infty } \ell _{opt}(T_n) = {{\hat{\ell }}} \) we have

$$\begin{aligned} \lim _{ n\rightarrow \infty } \frac{ J_{T_n} ({{\tilde{v}}}^{(n)}, \ell _{opt}(T_n) ) }{T_n} = \lim _{ n\rightarrow \infty } \frac{T_n - t_{\min }}{T_n} I({{\hat{v}}}, \, \ell _{opt}(T_n) ) = I({{\hat{v}}}, \, {{\hat{\ell }}}). \end{aligned}$$

Assuming the exact controllability of the system in the finite time \(t_{\min }\) allows to choose for all \(n \in \{1,2,3,...\}\), a control function \(u_{init}^{(n)}(t) \in L^2\left( 0, \, t_{\min }; L^2( \Omega ( \ell _{opt}(T_n) ))\right) \) that steers the system to the constant state \(y(t_{\min },\,\cdot ) = {{\hat{y}}}\), \(y_t(t_{\min },\,\cdot ) = 0\) and satisfies

$$\begin{aligned} \max _n \Vert u_{init}^{(n)}\Vert _{ L^2\left( 0, \, t_{\min }; L^2( \Omega ( \ell _{opt}(T_n) ))\right) } < \infty . \end{aligned}$$
(87)

Such a control can be determined using the classical method of moments as described for example in [22].

We define the control \({{\tilde{v}}}^{(n)}(t) = \left\{ \begin{array}{c} u_{init}^{(n)}(t), \, t\in (0, \, t_{\min }], \\ {{\hat{v}}}, \, t \ge t_{\min }. \end{array} \right. \)

For all \(n \in \{1,2,3,...\}\) this implies the inequality

$$\begin{aligned} \frac{1}{T_n} J_{T_n} ({{\hat{u}}}^{T_n}_{opt}, \ell _{opt}(T_n) ) \le \frac{1}{T_n} J_{T_n} ({{\tilde{v}}}^{(n)}, \ell _{opt}(T_n) ). \end{aligned}$$

This yields (85).

Assume that the optimal shape problem with (OCE) has a solution \((\ell _{opt}, u_{opt})\). Then \(u_{opt}\) is a solution of (OCE). Let \({\hat{v}}_{opt}\) denote the solution of (OCS) for \( \ell _{opt} \). Then Theorem 1 implies that (81) holds.

Proof of Theorem 1

Define \(M_F = M_1 + M_2 + M_3\), \(M_G = {{\tilde{M}}}_1 + {{\tilde{M}}}_2\), \(M_H = {{\hat{M}}}_1 + {{\hat{M}}}_2\).

Due to (34), (67), (72) and (76) for all \(k \in \{0,1,2,3,...\}\) we have

$$\begin{aligned} |b_{k,T}(t)|\le & {} M_F e^{ - \frac{\sqrt{\gamma }}{2} (T- t)} \, |b_{k, T}(T)| \nonumber \\{} & {} + [ \sqrt{1 + \gamma \, \lambda _k } \, M_G \, |a_k (0)| \nonumber \\{} & {} + M_H \, |a_k' (0)| ] \left[ \exp ( - \frac{\sqrt{\gamma }}{2} \, t) + \exp ( - \frac{\sqrt{\gamma }}{2} (T- t)) \right] . \end{aligned}$$
(88)

For the square, this yields the bound

$$\begin{aligned} |b_{k,T}(t)|^2\le & {} 3 M_F^2 e^{ - \sqrt{\gamma } (T- t)} \, |b_{k, T}(T)|^2 \nonumber \\{} & {} + [ 6 (1 + \gamma \, \lambda _k ) \, M_G^2 \, |a_k (0)|^2 \nonumber \\{} & {} + 6 M_H^2 \, |a_k' (0)|^2 ] \left[ \exp ( - \sqrt{\gamma } \, t) + \exp ( - \sqrt{\gamma } (T- t)) \right] . \end{aligned}$$
(89)

Due to Parseval’s equation this implies for all \(t \in [0, \, T]\)

$$\begin{aligned} \Vert \mu ^T(t) \Vert _{L^2(\Omega )}^2= & {} \sum _{k=0}^\infty |b_k(t)|^2 \le \sum _{k=0}^\infty 3 \, M_F^2 e^{ - {\sqrt{\gamma }} (T- t)} \, |b_k(T)|^2 \\{} & {} + [ 6 (1 + \gamma \, \lambda _k ) \, M_G^2 \, |a_k (0)|^2 \\{} & {} + 6 M_H^2 \, |a_k' (0)|^2 ] \left[ \exp ( - \sqrt{\gamma } \, t) + \exp ( - \sqrt{\gamma } (T- t)) \right] . \end{aligned}$$

Since the initial state \((y^0, \, y^1)\) satisfies

$$\begin{aligned} \sum _{k=0}^\infty \lambda _k \, |a_k (0)|^2 +|a_k' (0)|^2 < \infty , \end{aligned}$$

this yields an exponential turnpike property for the adjoint state. To be precise, we have for all \(t \in [0, \, T]\)

$$\begin{aligned} \Vert \mu ^T(t) \Vert _{L^2(\Omega )}^2 \le {{\tilde{C}}}(y_0, \, y_1, \, p^{\sigma } ) \left[ \exp ( - \sqrt{\gamma } \, t) + \exp ( - \sqrt{\gamma } (T- t)) \right] \end{aligned}$$
(90)

with a real number \({{\tilde{C}}}(y_0, \, y_1, \, p^{\sigma } )\) that is independent of T and k.

For the optimal controls, for \(\Gamma = \Omega \) we have \(\nu ^T = \mu ^T\), hence we have a similar inequality as (90) for \( \Vert \nu ^T(t) \Vert _{L^2(\Omega )}^2\).

Note that in proof of (67), (72) and (76) in the estimates we did not take advantage of the real part that appears in the representations. In fact, we have always used upper bound for the modulus of the complex number whose real part appears in the expressions. In the representation of the second order derivatives, the only change is that the factor \(z_k^2\) appears in the complex variable representations compared to the original expression. Therefore our proof also yields the inequality

$$\begin{aligned} |b_{k,T}''(t)|^2\le & {} 3 |z_k|^2 M_F^2 e^{ - \sqrt{\gamma } (T- t)} \, |b_{k, T}(T)|^2 \nonumber \\{} & {} +|z_k|^2 [ 6 (1 + \gamma \, \lambda _k ) \, M_G^2 \, |a_k (0)|^2 \nonumber \\{} & {} + 6 M_H^2 \, |a_k' (0)|^2 ] \left[ \exp ( - \sqrt{\gamma } \, t) + \exp ( - \sqrt{\gamma } (T- t)) \right] . \end{aligned}$$
(91)

We have

$$\begin{aligned} a_k = \frac{ - b_k''+ (\gamma - \lambda _k) \, b_k}{ 1 + \gamma \, \lambda _k}. \end{aligned}$$
(92)

Define

$$\begin{aligned} M_\alpha := \sup _k \frac{ |z_k|^2}{ 1 + \gamma \, \lambda _k } = \sup _k \frac{ \sqrt{1 + \lambda _k^2 }}{ 1 + \gamma \, \lambda _k }< \infty , \; M_\beta := \sup _k \frac{ \lambda _k - \gamma }{ 1 + \gamma \, \lambda _k } < \infty \end{aligned}$$

and

$$\begin{aligned} M_\kappa := M_F \, |b_{k, T}(T)| + \sqrt{1 + \gamma \, \lambda _k } \, M_G \, |a_k (0)| + M_H \, |a_k' (0)|. \end{aligned}$$

Due to (92) we also have the following exponential inequality for the coefficients in the expansion of the optimal state:

$$\begin{aligned} |a_k(t)| \le \left( M_\alpha + M_\beta \right) M_\kappa \left[ \text {e}^{ - \tfrac{\sqrt{\gamma }}{2} \, t } + \text {e}^{ - \tfrac{\sqrt{\gamma }}{2} (T- t) } \right] . \end{aligned}$$

This yields the turnpike inequality for the state \(\omega ^T\):

$$\begin{aligned} \Vert \omega ^T(t) \Vert _{L^2(\Omega )}^2 \le {{\tilde{C}}}(y_0, \, y_1, \, p^{\sigma } ) \left[ \exp ( - \sqrt{\gamma } \, t) + \exp ( - \sqrt{\gamma } (T- t)) \right] \end{aligned}$$
(93)

with a real number \({{\tilde{C}}}(y_0, \, y_1, \, p^{\sigma } )\) that is independent of T.

Note that in proof of (67), (72) and (76) in the estimates we did not take advantage of the structure of the spectrum. In fact, the constants in the turnpike inequalities (67) and \(M_G = {{\tilde{M}}}_1 + {{\tilde{M}}}_2\) in (72) and \(M_H = {{\hat{M}}}_1 + {{\hat{M}}}_2\) in (76) are independent of k. \(\square \)

Remark 13

From mathematical point of view, it is of interest to analyze the nucleation of a cycle at the internal node of network. This means that the internal node is replaced by a small cycle, see Figs. 1112. The question which internal node is selected can be solved in the steady state case, the topological derivative of the cost is introduced to this end. The domain decomposition method is applied in order to derive the form of the topological derivative. The associated Steklov-Poincaré operator is represented by a matrix \(\varepsilon \rightarrow \Lambda (\varepsilon )\) which is semidefinite positive and differentiable at \(\varepsilon ={0+}\), the derivative is denoted \(\Lambda ^\prime (0)\) for the sake of simplicity. In the case of wave equation such a result is not known, however the numerical experiments show that dependence is regular. Therefore, we assume that for a given initial conditions the solution of wave equation enjoys the properties of the steady state boundary value problem for the nucleation of the small cycle. Let us note that for \(\varepsilon >0\) the wave equation is well defined and the regularity of initial conditions required for the turnpike property are already given. Here we assume that the limit of the cost for \(\varepsilon \rightarrow {0+}\) is well defined and the value of the cost is continuous \(\varepsilon =0\). This assumption does not imply the differentiability of the cost at \(\varepsilon \rightarrow {0+}\).

Assumption 2

Let us consider the wave equation on network and let \({\mathcal {J}}(\Omega )\) be the cost for given initial conditions \(y_0, y_1\) and given time horizon \(T>0\). At the internal node \(P_0\) of the network a cycle of size \(\varepsilon >0\) is introduced, which leads to the cost \({\mathcal {J}}(\Omega _\varepsilon )\). The topological variation of the network is admissible provided we have

$$\begin{aligned} \lim _{\varepsilon \rightarrow 0+}{\mathcal {J}}(\Omega _\varepsilon )={\mathcal {J}}(\Omega ). \end{aligned}$$

7 Control Problem for a Single Edge

Let real numbers \(L>0\), \(T>0\), \(c>0\) and \(\gamma >0\) be given. Let \(y_0 \in H^1(0, \, L)\) with \(y_0(0)=0\) and \(y_1 \in L^2(0, L)\), \(z \in H^1(0, \, L)\) with \(\zeta =z^{\prime }(L)\) be given. Consider the problem

$$\begin{aligned} \min \int _0^T \int _0^L |y(t,x)-z(x)|^2 + \gamma \,|y_t(t,x)|^2 \, dx + |u(t)-\zeta |^2 \, dt \end{aligned}$$

subject to

$$\begin{aligned} \left\{ \begin{array}{l} y(0, x) = y_0(x), \, x\in (0, L), \\ y_t(0, x) = y_1(x), \, x\in (0, L), \\ y_{tt}(t, x) = c^2 y_{xx}(t, x), \, (t,x) \in (0, T) \times (0, L), \\ y(t,0)= 0, \,t\in (0, T), \\ y_x(t, L) = u(t), \, t\in (0, T). \end{array} \right. \end{aligned}$$
(94)

The solution to the initial boundary value problem for a control \(u \in L^2(0, \, T)\) is stated in [23], Theorem 2.3, p. 17 in the form

$$\begin{aligned} y(t, x) = \sum _{n=0}^\infty \alpha _n(t) \,\varphi _n(x) \end{aligned}$$
(95)

with the eigenfunctions \(\varphi _n(x) = \frac{\sqrt{2}}{\sqrt{L}} \sin \left( \left( \frac{\pi }{2} + n \pi \right) \frac{x}{L} \right) \), \(n \in \{0,1,2,...\}\). For the eigenvalues we have

$$\begin{aligned}\lambda _n = \frac{1}{L^2} \left( \frac{\pi }{2} + n \pi \right) ^2 \end{aligned}$$

and the minimal eigenvalue is \(\lambda _0 = \frac{\pi ^2}{4} \ \frac{1}{L^2} \). For \(n \in \{0,1,2,...\}\), let

$$\begin{aligned} \alpha _n^0 = \int _0^L y_0(x) \, \varphi _n(x) \, dx, \; \alpha _n^1 = \int _0^L y_1(x) \, \varphi _n(x) \, dx. \end{aligned}$$
(96)

We have

$$\begin{aligned} \alpha _n(t)= & {} \alpha _n^0 \cos \left( (\frac{\pi }{2} + n \pi ) \frac{t}{t_0} \right) + \alpha _n^1 \frac{ t_0 }{ \frac{\pi }{2} + n \pi } \sin \left( (\frac{\pi }{2} + n \pi ) \frac{t}{t_0} \right) \nonumber \\{} & {} + (-1)^n \, c^2 \, \frac{\sqrt{2}}{\sqrt{L}} \frac{ t_0 }{ \frac{\pi }{2} + n \pi } \int _0^t u(s) \, \sin \left( (\frac{\pi }{2} + n \pi ) \frac{t-s}{t_0} \right) \, ds, \end{aligned}$$
(97)

where \(t_0=\frac{L}{c}\). Since Parseval’s identity states that almost everywhere on [0, T], we have

$$\begin{aligned} \int _0^L y(t,x)^2 \, dx = \sum _{n=0}^\infty |\alpha _n(t)|^2 \,\; \text{ and } \; \int _0^L y_t(t,x)^2 \, dx = \sum _{n=0}^\infty |\alpha _n'(t)|^2. \end{aligned}$$

We can represent the objective functional in the form

$$\begin{aligned} \begin{aligned}&\int _0^T \int _0^L |y(t,x)-z(x)|^2 + \gamma \,|y_t(t,x)|^2 \, dx + |u(t)-\zeta |^2 \, dt \\&\quad =\int _0^T \sum _{n=0}^\infty |\alpha _n(t)|^2 + \gamma |\alpha _n'(t)|^2+|u(t)-\zeta |^2 \, dt\\&\qquad +\int _0^T\int _0^L z^2(x) + \sum _{n=0}^\infty 2\alpha _n(t)\varphi _n(x)z(x) \, dxdt. \end{aligned} \end{aligned}$$

If the control space \(L^2(0, T)\) is replaced by a finite dimensional space of piecewise constant control functions, this yields a finite dimensional quadratic optimization problem. Since in this case, the necessary optimality conditions are a finite dimensional system of linear equations, this can be used to obtain numerical approximations of the optimal control.

8 Numerical Solutions of Three Examples

In this section, we discuss the numerical solution. We consider the following problem data:

$$\begin{aligned} c:=1;\,\,\gamma :=0.1;\,\,T:=1,10,100;\, L:=1; \end{aligned}$$

We choose \(\,\,y_1(x):=0\quad (x\in (0,1))\).

  1. 1.

    \( y_0(x):=x,\, z=0, \zeta = 0\, \text{(in } \text{ Example } \text{1) }\);

  2. 2.

    \( y_0(x):=\pi ^{-1}\sin (\pi x),\, z=0, \zeta = 0 \text{(in } \text{ Example } \text{2) };\)

  3. 3.

    \( y_0(x):=\pi ^{-1}\sin (\pi x),\, z=x, \zeta = 1 \text{(in } \text{ Example } \text{3) };\)

The coefficients \(\alpha _n^0\) and \(\alpha _n^1\) in (96) are obtained as the Fourier coefficients of the chosen functions \(y_0(x), y_1(x)\).

In order to solve the optimal boundary control problem numerically, a finite-dimensional approximation is used on two sides of (94) simultaneously:

First, the series expansion in the objective functional has to be cut after N terms which leads us to the consideration of the problem \(\mathbf {(OPT)}(\gamma ,\,N)\). Second, we compute approximations for the optimal controls \(u \in L^2(0,\,T) \) in the space of piecewise constant functions. Let a grid \(0=t_0<t_1<t_2<...<t_M=T\) be given. For \(i\in \{1,\ldots ,M\}\) let

$$\begin{aligned} v_j(t):= \left\{ \begin{array}{ll} 1 &{} \text{ if } t\in [t_{j-1},t_j),\\ 0 &{} \text{ elsewhere },\\ \end{array} \right. \end{aligned}$$

and, define the finite dimensional space \(X_M(T)\) by

$$\begin{aligned} X_M(T):= \textrm{span}\{ v_j(\cdot ): j=1,\ldots ,M\}. \end{aligned}$$

For any \(u\in X_M(T)\) we use the representation

$$\begin{aligned} u(t) = \sum _{j=1}^M u(t_{j-1}) v_j(t), \qquad t\in [0,T), \end{aligned}$$

where \(v_j(t)\) stands for the characteristic function \(\chi _{[t_{j-1},t_j)}(t)\) of the interval \([t_{j-1},t_j)\) and the approximation of control is defined by the vector \(U=\textrm{col}(U_1,\dots ,U_M)\in {\mathbb {R}}^M\). Hence, we are finally led to solve the problem

$$\begin{aligned} \begin{aligned}&\mathbf {(D_{opt})}(\gamma ,\,N,\,M) \min \limits _{u\in X_{M}(T)}\;\sum \limits _{j=1}^M(t_j-t_{j-1})\, (u(t_{j-1})^2+ 2u(t_{j-1})\zeta + \zeta ^2)\\&\quad + \sum \limits _{j=1}^M \sum _{n=0}^N \int _{t_{j-1}}^{t_j} |\alpha _n(t)|^2 + \gamma |\alpha _n'(t)|^2 \, dt \\&\quad + \sum \limits _{j=1}^M \sum _{n=0}^N \int _{t_{j-1}}^{t_j} \int _{0}^{L}2\alpha _n(t)\varphi _n(x)z(x) + z^2(x)\, dx dt \end{aligned} \end{aligned}$$
(98)

with \(\alpha _j(t) \) as defined in (97). Problem

$$\begin{aligned} \mathbf {(D_{opt})}(\gamma ,\,N,\,M) \end{aligned}$$

can be equivalently formulated as a quadratic programming problem in \({\mathbb {R}}^M\)

$$\begin{aligned} \min \limits _{U\in {\mathbb {R}}^M}\;U^\top \, Q \, U+q^\top U + W \end{aligned}$$

where the matrix \(Q(N)_{M\times M}\), depending on the fixed number N, and the vector \(q\in {\mathbb {R}}^M\) are to be assembled for fixed N from the cost as stated in (98). The assemblage is described below. We use the notation \(U_j=u(t_{j-1})\), (\(j\in \{1,\dots ,M\}\)) and take into account a constant term W that is independent of U. We have

$$\begin{aligned} U^\top Q U+q^\top U +W&= \sum \limits _{j=1}^M(t_j-t_{j-1})\, (u(t_{j-1})^2+ 2u(t_{j-1})\zeta + \zeta ^2)\\&\quad + \;\sum \limits _{j=1}^M \sum _{n=0}^N \int _{t_{j-1}}^{t_j} |\alpha _n(t)|^2 + \gamma |\alpha _n'(t)|^2 \, dt\\&\quad + \;\sum \limits _{j=1}^M \sum _{n=0}^N \int _{t_{j-1}}^{t_j} \int _{0}^{L}2\alpha _n(t)\varphi _n(x)z(x) + z^2(x)\, dx dt. \end{aligned}$$

For the convergence of the approximation, it is important to increase both N and M simultaneously. Otherwise, if only \(M\rightarrow \infty \) convergence to the optimal control in general does not occur (due to a possible spillover effect). For \(t\in (t_{j-1},t_{j})\) we have

$$\begin{aligned} \alpha _n(t)&= \alpha _n^0 \cos \left( (\frac{\pi }{2} + n \pi ) t \right) +(-1)^n \frac{ \sqrt{2} }{ \frac{\pi }{2} + n \pi } \int _0^t u(s)\, \sin \left( (\frac{\pi }{2} + n \pi )(t-s) \right) \,ds \\&= \alpha _n^0 \cos \left( (\frac{\pi }{2} + n \pi ) t \right) + (-1)^n \frac{ \sqrt{2} }{ \frac{\pi }{2} + n \pi } \, \sum _{k=1}^j U_k\int _0^t \, v_k(s) \, \sin \left( (\frac{\pi }{2} + n \pi )(t-s) \right) \,ds \\&= \alpha _n^0 \cos \left( (\frac{\pi }{2} + n \pi ) t \right) + (-1)^n \frac{ \sqrt{2} }{\frac{\pi }{2} + n \pi } V_{j}^\top U, \end{aligned}$$

where \(V_{j} = \textrm{col}(V_{j,1},V_{j,2},\cdots ,V_{j,j},0,\cdots ,0)\),

$$\begin{aligned} V_{j,k} = \left\{ \begin{array}{ll} \int _{t_{k-1}}^{t_{k}}\sin \left( (\frac{\pi }{2} + n \pi )(t-s)\right) ds &{} \text {if } k<j, \\ \int _{t_{k-1}}^{t}\sin \left( (\frac{\pi }{2} + n \pi )(t-s)\right) ds &{} \text {if } k=j, \\ 0 &{} \text {if } k>j. \end{array} \right. \end{aligned}$$

and

$$\begin{aligned} \begin{aligned} |\alpha _n(t)|^2&= (\alpha _n^0)^2 \cos ^2\left( (\frac{\pi }{2} + n \pi ) t \right) + \frac{ 2 }{ (\frac{\pi }{2} + n \pi )^2} U^\top V_{j}V_{j}^\top U \\&\quad + (-1)^n \frac{ 2\sqrt{2}\alpha _n^0 }{\frac{\pi }{2} + n \pi } \cos \left( (\frac{\pi }{2} + n \pi ) t \right) V_{j}^\top U. \end{aligned} \end{aligned}$$
(99)

This implies

$$\begin{aligned} \sum \limits _{j=1}^M \sum _{n=0}^N \int _{t_{j-1}}^{t_j} |\alpha _n(t)|^2&= \sum \limits _{j=1}^M \sum _{n=0}^N (\alpha _n^0)^2\int _{t_{j-1}}^{t_j} \cos ^2\left( (\frac{\pi }{2} + n \pi ) t \right) dt\nonumber \\&\quad + \sum \limits _{j=1}^M \sum _{n=0}^N \frac{ 2 }{ (\frac{\pi }{2} + n \pi )^2} U^\top \int _{t_{j-1}}^{t_j} V_{j}V_{j}^\top dt \, U \nonumber \\&\quad + \sum \limits _{j=1}^M \sum _{n=0}^N (-1)^n \frac{ 2\sqrt{2}\alpha _n^0 }{\frac{\pi }{2} + n \pi } \int _{t_{j-1}}^{t_j} \cos \left( (\frac{\pi }{2} + n \pi ) t \right) V_{j}^\top dt\, U\nonumber \\&= W_1+U^\top Q_1U + q_1^\top U. \end{aligned}$$
(100)

Moreover, for the derivatives \(\alpha ^{\prime }_n(t)\), we have for \(t\in (t_{j-1},t_{j})\)

$$\begin{aligned} \begin{aligned} \alpha ^{\prime }_n(t)&= -(\frac{\pi }{2} + n \pi )\alpha _n^0 \sin \left( (\frac{\pi }{2} + n \pi ) t \right) \\&\quad + (-1)^n \sqrt{2} \, \sum _{k=1}^j U_k\int _0^t \, v_k(s) \, \cos \left( (\frac{\pi }{2} + n \pi )(t-s) \right) \,ds \\&= -(\frac{\pi }{2} + n \pi )\alpha _n^0 \sin \left( (\frac{\pi }{2} + n \pi ) t \right) + (-1)^n \sqrt{2} \tilde{V}_{j}^\top U, \end{aligned} \end{aligned}$$
(101)

where \(\tilde{V}_{j} = \textrm{col}(\tilde{V}_{j,1},\tilde{V}_{j,2},\cdots ,\tilde{V}_{j,j},0,\cdots ,0)\),

$$\begin{aligned} \tilde{V}_{j,k} = {\left\{ \begin{array}{ll} \int _{t_{k-1}}^{t_{k}}\cos \left( (\frac{\pi }{2} + n \pi )(t-s)\right) ds &{}(k<j), \\ \int _{t_{k-1}}^{t}\cos \left( (\frac{\pi }{2} + n \pi )(t-s)\right) ds&{}(k=j), \\ 0 &{}(k>j). \\ \end{array}\right. } \end{aligned}$$

This yields

$$\begin{aligned} |\alpha ^{\prime }_n(t)|^2&= (\alpha _n^0)^2(\frac{\pi }{2} + n \pi )^2 \sin ^2\left( (\frac{\pi }{2} + n \pi ) t \right) + 2U^\top \tilde{V}_{j}\tilde{V}_{j}^\top U \\&\quad +(-1)^{n+1} 2\sqrt{2} \alpha _n^0 (\frac{\pi }{2} + n \pi )\sin \left( (\frac{\pi }{2} + n \pi ) t \right) \tilde{V}_{j}^\top U. \end{aligned}$$

Hence we obtain

$$\begin{aligned} \gamma \sum \limits _{j=1}^M \sum _{n=0}^N \int _{t_{j-1}}^{t_j} |\alpha ^{\prime }_n(t)|^2&=\gamma \sum \limits _{j=1}^M \sum _{n=0}^N (\alpha _n^0)^2(\frac{\pi }{2} + n \pi )^2\int _{t_{j-1}}^{t_j} \sin ^2\left( (\frac{\pi }{2} + n \pi ) t \right) dt\\&\quad +\gamma \sum \limits _{j=1}^M \sum _{n=0}^N 2 U^\top \int _{t_{j-1}}^{t_j} \tilde{V}_{j}\tilde{V}_{j}^\top dt\, U \\&\quad +\gamma \sum \limits _{j=1}^M \sum _{n=0}^N (-1)^{n+1} 2\sqrt{2}\alpha _n^0(\frac{\pi }{2} + n \pi )\int _{t_{j-1}}^{t_j} \sin \left( (\frac{\pi }{2} + n \pi ) t \right) \tilde{V}_{j}^\top dt \, U\\&= \gamma ( W_2+U^\top Q_2 U+q_2^\top U ). \end{aligned}$$

And we have

$$\begin{aligned} \begin{aligned} \sum \limits _{j=1}^M \sum _{n=0}^N \int _{t_{j-1}}^{t_j} \alpha _n(t)\varphi _n(x)z(x)&= \sum \limits _{j=1}^M \sum _{n=0}^N \int _{t_{j-1}}^{t_j} \alpha _n^0\cos \left( (\frac{\pi }{2} + n \pi ) t \right) dt \int _{0}^{L}z(x)\varphi (x) dx \\&\quad + \sum \limits _{j=1}^M \sum _{n=0}^N (-1)^n \frac{\sqrt{2} }{ \frac{\pi }{2} + n \pi } \int _{t_{j-1}}^{t_j} V_{j}^\top dt \, U \\&= W_3 + q_3^\top U. \end{aligned} \end{aligned}$$
(102)

For the objective function, this implies

$$\begin{aligned} \begin{aligned}&\sum \limits _{j=1}^M(t_j-t_{j-1})\, (u(t_{j-1})^2+ 2u(t_{j-1})\zeta + \zeta ^2):= U^\top Q_3 U + 2q_\tau ^\top U +W_\tau , \\&\;\sum \limits _{j=1}^M\sum _{n=0}^N \int _{t_{j-1}}^{t_j} |\alpha _n(t)|^2 + \gamma |\alpha _n'(t)|^2 \, dt:=U+q_1^\top U + W_1+\gamma (U^\top Q_2\,U+q_2^\top U + W_2), \\&\;\sum \limits _{j=1}^M \sum _{n=0}^N \int _{t_{j-1}}^{t_j} \int _{0}^{L}2\alpha _n(t)\varphi _n(x)z(x) + z^2(x)\, dx dt = 2 q_3^\top U + W_3. \end{aligned} \end{aligned}$$

Thus

$$\begin{aligned} U^\top Q U+q^\top U +W= & {} U^\top (Q_1+\gamma Q_2+Q_3)U\\{} & {} +(q_1+\gamma q_2+q_3+q_\tau )^\top U +W_1+\gamma W_2+W_3+W_\tau . \end{aligned}$$

Here we use the notation

$$\begin{aligned} Q_1&= \sum \limits _{j=1}^M \sum \limits _{n=0}^N \frac{2}{ (\frac{\pi }{2} + n \pi )^2} \int _{t_{j-1}}^{t_j} V_{j}V_{j}^\top dt,\\ Q_2&= \sum \limits _{j=1}^M \sum \limits _{n=0}^N 2\int _{t_{j-1}}^{t_j} \tilde{V}_{j}\tilde{V}_{j}^\top dt,\\ Q_3&= {\textrm{diag}}(t_1-t_0,\cdots ,t_k-t_{k-1},\cdots ,t_{M}-t_{M-1}), \\ q_1&= \sum \limits _{j=1}^M \sum \limits _{n=0}^N (-1)^n \frac{ 2\sqrt{2}\alpha _n^0 }{\frac{\pi }{2} + n \pi } \int _{t_{j-1}}^{t_j} \cos \left( (\frac{\pi }{2} + n \pi ) t \right) V_{j} dt,\\ q_2&= \sum \limits _{j=1}^M \sum \limits _{n=0}^N (-1)^{n+1} 2\sqrt{2}\alpha _n^0(\frac{\pi }{2} + n \pi )\int _{t_{j-1}}^{t_j} \sin \left( (\frac{\pi }{2} + n \pi ) t \right) \tilde{V}_{j} dt,\\ q_3&= \sum \limits _{j=1}^M \sum \limits _{n=0}^N (-1)^n \frac{\sqrt{2} }{ \frac{\pi }{2} + n \pi } \int _{t_{j-1}}^{t_j} V_{j}^\top dt,\\ q_\tau&=(t_1-t_0,t_2-t_1,\cdots ,t_M-t_{M-1})^\top , \\ W_1&= \sum \limits _{j=1}^M \sum \limits _{n=0}^N (\alpha _n^0)^2\int _{t_{j-1}}^{t_j} \cos ^2\left( (\frac{\pi }{2} + n \pi ) t \right) dt,\\ W_2&= \sum \limits _{j=1}^M \sum \limits _{n=0}^N (\alpha _n^0)^2\int _{t_{j-1}}^{t_j} \sin ^2\left( (\frac{\pi }{2} + n \pi ) t \right) dt,\\ W_3&= \sum \limits _{j=1}^M \sum \limits _{n=0}^N \int _{t_{j-1}}^{t_j} \alpha _n^0\cos \left( (\frac{\pi }{2} + n \pi ) t \right) dt \int _{0}^{L}z(x)\varphi (x) dx. \end{aligned}$$

We employ Matlab for the computational analysis of all examples. Figures 1 and 2 illustrate the optimal control and state, respectively, for varying values of \(T\) in example 1. Notably, as \(T\) increases significantly, the control variable \(u\) converges to \(\zeta \). Moreover, with the increment in \(T\), there is a discernible trend towards stabilization in the norms of both \(u\) and \(y\), as evidenced in Fig. 3. Figures 4, 2, and 6 present the results obtained from example 2, whereas Figs. 7 to 9 depicts the outcomes of example 3. Additionally, Fig. 10 presents the quotient of the optimal value of \(\mathbf {(D_{opt})}(\gamma ,\,N,\,M)\), which adheres to the turnpike property, thereby providing valuable insights into the behavior of the system concerning varying \(T\) values.

Fig. 1
figure 1

Optimal control u(t) for different values of T in Example 1

Fig. 2
figure 2

Optimal state y(tx) for different values of T in Example 1

Fig. 3
figure 3

Optimal \(\int _0^t (u-\xi )^2 \textrm{d}t \) and \(\int _0^t \int _0^L (y-z)^2 \textrm{d}x \textrm{d}t \) for different values of T in Example 1 (\(\xi = 0, \ z=0, y_0 = x \))

Fig. 4
figure 4

Optimal control u(t) for different values of T in Example 2

Fig. 5
figure 5

Optimal state y(tx) for different values of T in Example 2

Fig. 6
figure 6

Optimal \(\int _0^t (u-\xi )^2 \textrm{d}t \) and \(\int _0^t \int _0^L (y-z)^2 \textrm{d}x \textrm{d}t \) for different values of T in Example 2 (\(\xi = 0, \ z=0, y_0 = \pi ^{-1} \sin (\pi x)\))

Fig. 7
figure 7

Optimal control u(t) for different values of T in Example 3

Fig. 8
figure 8

Optimal state y(tx) for different values of T in Example 3

Fig. 9
figure 9

Optimal \(\int _0^t (u-\xi )^2 \textrm{d}t \) and \(\int _0^t \int _0^L (y-z)^2 \textrm{d}x \textrm{d}t \) for different values of T in Example 3 (\(\xi = 1, \ z=x, y_0 = \pi ^{-1} \sin (\pi x)\))

Fig. 10
figure 10

Convergence for different examples

9 Topological Derivatives for Network Optimal Control Problems

The topology of network for the purposes of optimal control problems is selected in the framework of the topological derivative method for static problems, we refer to [24] for an elementary example. It turns out, that the topological derivatives for a class of cost functions can be determined by using the domain decomposition technique for the state equation [25]. We describe in details the topological derivative method and present numerical results for examples.

Let us consider the network static problem. We define the topological derivatives for optimal cost of network control problems with respect to nucleation of a small cycle. We present also numerical examples. The simplest example of a network is the three-star graph with one central vertex \(P_0\) and three boundary vertices \(P_1,P_2,P_3\), thus \(V=\{ P_0,P_1, P_2,P_3\}\) (See Fig. 11). There are three edges \(E=\{ E_1,E_2,E_3\}\).

Fig. 11
figure 11

The three-star graph

For the steady state problem, singular domain perturbations of the shape are considered. The topological derivatives of the shape functional are defined. The shape and topology optimization is performed. The network is singularly perturbed by a small cycle of the size \(\varepsilon \rightarrow 0\) (See Fig. 12). In such a case the domain decomposition technique is used and the Steklov-Poincaré operator is introduced. The topological derivative technique is employed in order to decide if a small cycle is useful for the topology optimization of the network.

Fig. 12
figure 12

Nucleation of a cycle of size \(\varepsilon \) in three-star graph

We introduce multiple perturbations of network represented in Fig. 13. The Steklov-Poincaré operator \(\Lambda _\varepsilon \) replaces the subgraph \(G_\varepsilon \) in the state equation of the network. In this way the topological derivative of the cost for optimal control problem on perturbed network is obtained for the nucleation of multiple cycle in the three-star graph.

Fig. 13
figure 13

Multiple perturbations of the three-star graph for domain decomposition technique

9.1 Shape and Topology Optimization on Networks

We recall briefly the shape and topological derivatives of a given cost for the network. We restrict ourselves to static problems however the shape and topology optimization can also be performed for dynamic optimal control problems on networks. For the optimal control problems with the Turnpike Property the analysis of static problem is useful for the solution of dynamic problem. In particular, the topology of the network is designed using the static problem.

The shape \(\Omega \) of the network for fixed topology is governed by the finite dimensional vector \(\ell \), which contains the lengths of edges, \(\ell =\textrm{col}\,(L_1,\dots ,L_N)\) where \(N=\#E=\{ E_i | i\in \mathcal {I}\}\). Therefore, \(\Omega :=\Omega (\ell )\), and the cost \(\ell \mapsto {\mathcal {I}}(\ell ):={\mathcal {J}}(\Omega (\ell ))\) is defined by the optimal cost of control problem \({\mathcal {J}}(\Omega ):=J({{\hat{u}}}(\Omega ))\) for evolution problem. For the steady state problem the optimal cost of control problem is denoted by \(\ell \mapsto J({{\hat{v}}}(\Omega (\ell )))\), where \({{\hat{v}}}(\Omega (\ell ))\) is steady state optimal control in the domain defined by the shape \(\Omega (\ell )\). We consider the Neumann control in the numerical examples presented for the wave equation.

We use the standard technique for shape [20] and topology optimization [26]. Namely, the material derivatives are employed in the shape sensitivity analysis in the framework of speed method [20]. The parameter \(\tau \rightarrow 0\) is used for the boundary variations of \(\tau \mapsto {\mathcal {J}}(\Omega _\tau )\), at \(\tau =0\), the material derivatives of the cost and the state with respect to the parameter \(\tau \) are denoted with the dot

$$\begin{aligned} \mathcal {\dot{J}}(\Omega )=\lim _{\tau \rightarrow 0}\dfrac{1}{\tau }\left( {\mathcal {J}}(\Omega _\tau )-{\mathcal {J}}(\Omega )\right) \end{aligned}$$

which leads to the expansion

$$\begin{aligned} {\mathcal {J}}(\Omega _\tau )={\mathcal {J}}(\Omega )+\tau \mathcal {\dot{J}}(\Omega ) +o(\tau ). \end{aligned}$$

In addition, the topology optimization is considered in the case of nucleation of the small cycle of the size \(\varepsilon \rightarrow 0\). The topological derivative of the cost is defined as follows

$$\begin{aligned} {\mathcal {T}}(\Omega )=\lim _{\varepsilon \rightarrow 0}\dfrac{1}{\varepsilon }\left( {\mathcal {J}}(\Omega _\varepsilon )-{\mathcal {J}}(\Omega )\right) \end{aligned}$$

which leads to the expansion

$$\begin{aligned} {\mathcal {J}}(\Omega _\varepsilon )={\mathcal {J}}(\Omega )+\varepsilon {\mathcal {T}}(\Omega ) +o(\varepsilon ). \end{aligned}$$

The topological derivative \({\mathcal {T}}(\Omega )\) for nucleation of small cycles of the size \(\varepsilon \rightarrow 0\) is evaluated for two examples of static problems, and applied to the topological optimization for dynamic problem in the first example.

9.2 Examples of Topological Derivatives for Networks

Two examples are presented of singular network perturbation by nucleation of a small cycle. In the first example, the topological derivative is evaluated for the optimal control problem with the static state equation, and then for the dynamic state equation, the optimal size of the cycle is determined. In the second example, the topological derivative is evaluated for multiple singular perturbations of the three-star network.

Example 4 (for one cycle): In this example the optimal control u is computed for the geometry depicted in Fig. 14. The variables z and \(\zeta \) satisfy

$$\begin{aligned} \left\{ \begin{array}{l} -z_{i}^{\prime \prime }=0, x \in [0,L_i],\, i = 1, \cdots , 6, \\ z_{1}^{\prime }(0)=\zeta , z_2(L_2)=z_3(L_3)=0,\\ \text {Continuity and Kirchhoff Condition}. \end{array}\right. \end{aligned}$$
(103)
Fig. 14
figure 14

Domain decomposition for tripod directed network with an elementary small cycle

Set \(\zeta =1\), \(L_1=L_2=L_3=2\), \(\varepsilon _0 = 0.5\), \(\varepsilon _{\max }=1,\) and \(0\le \varepsilon \le \varepsilon _{\max }.\) Here, \(G_\varepsilon =\{E_\varepsilon ,V_\varepsilon \}\) contains a small cycle. \(E_\varepsilon =\{E_{\varepsilon ,1},E_{\varepsilon ,2},\cdots ,E_{\varepsilon ,6}\}\), \(V_\varepsilon =\{Q_1,Q_2,Q_3,P_4,P_5,P_6\}\), \(|E_{\varepsilon ,1}|=|E_{\varepsilon ,2}|=|E_{\varepsilon ,3}|=\varepsilon _{\max }-\varepsilon =1-\varepsilon \), \(|E_{\varepsilon ,4}|=|E_{\varepsilon ,5}|=|E_{\varepsilon ,6}|=\varepsilon \). The cost functional under consideration is defined as:

$$\begin{aligned} J(u)=\frac{1}{2}\sum _{i=1}^{3}\int _0^{L_i-\varepsilon _{\max }}(y_i-z_i)^2+ \frac{1}{2}|u-\zeta |^2. \end{aligned}$$

By the Lagrange method, the optimality system is given by

$$\begin{aligned} \left\{ \begin{array}{l} \sum \limits _{i=1}^3 \int _0^{L_i-\varepsilon _{\max }} y_i \phi _i+a(\Omega ^{0};p,\phi ) -\phi (L_i-\varepsilon _{\max })^{\top } \Lambda _{\varepsilon } p(L_i-\varepsilon _{\max })=\sum \limits _{i=1}^3 \int _0^{L_i-\varepsilon _{\max }} z_i \phi _i, \\ a(\Omega ^{0};y,\phi )-p_1(0) \phi _1(0)-y(L_i-\varepsilon _{\max })^{\top } \Lambda _{\varepsilon } \phi (L_i-\varepsilon _{\max })=-\zeta \phi _1(0), \end{array}\right. \end{aligned}$$

where

$$\begin{aligned} \phi \in H=\big \{\phi _i,\phi _i^{\prime } \in L^2\left( 0, L_i\right) , \phi _2(0)=\phi _3(0)=0, \text{ continuity } \text{ at } \text{ interior } \text{ vertices. } \big \} \end{aligned}$$

and

$$\begin{aligned} \Lambda _\varepsilon =\frac{1}{2 \varepsilon -3}\left( \begin{array}{ccc} 2 &{} -1 &{} -1 \\ -1 &{} 2 &{} -1 \\ -1 &{} -1 &{} 2 \end{array}\right) . \end{aligned}$$
(104)

Figure 15 shows the shape functional with respect to \(\varepsilon \). The derivative of \(J\) with respect to \(\varepsilon \) is consistently negative as \(\varepsilon \) approaches 0. This is the information that allows for the topology variations by nucleation of a small cycle at an interior vertex of the graph. Another observation emerges: as \(\varepsilon \) approaches \(\varepsilon _0\), the cost functional (\(J\)) converges to 0, indicating an optimal length for the introduced cycle. This implies that at \(\varepsilon = \varepsilon _0\), the network experiences an optimal configuration, emphasizing the critical nature of this parameter in shaping the network.

Fig. 15
figure 15

The shape functional for \(\varepsilon \in [0,1]\) in Example 4

Now, considering the dynamic example in Fig. 14, where the damping parameter is set to \(\alpha = 0\), the cost functional is defined as:

$$\begin{aligned} J(u)= & {} \frac{1}{2} \sum _{i=1}^3 \int _0^T \int _0^{L_i-\varepsilon } (y_i-z_i)^2 d x d t+\frac{\gamma }{2} \sum _{i=1}^3\int _0^T \int _0^{L_i-\varepsilon }(y_{i})_t^2\\{} & {} +\frac{1}{2} \int _0^T(u(t)-\zeta )^2 d t. \end{aligned}$$

The state equation is given by:

$$\begin{aligned} \left\{ \begin{array}{l} (y_{i})_{tt}-(y_{i})_{xx}+\alpha y_i =0, t \in [0, T], x \in [0,L_i],\, i=1,2,\cdots ,6, \\ y_i(0, x)=y_i^0(x),\ (y_{i})_{t}(0, x)=y_i^1(x), \, i=1,2,\cdots ,6, \\ (y_1)^{\prime }(t, 0)= u(t),\ y_2(t, 0)=0,\ y_3(t, 0)=0,\\ \text {Continuity and Kirchhoff conditions.} \end{array}\right. \end{aligned}$$
(105)

The adjoint equation is:

$$\begin{aligned} \left\{ \begin{array}{l} (p_{i})_{tt}-(p_{i})_{xx}+\alpha p_i=(\gamma y_{i,tt}-y_i+z_i)\chi (x), t \in [0, T], x \in [0,L_i],\, i=1,2,3, \\ (p_{i})_{tt}-(p_{i})_{xx}+\alpha p_i =0, t \in [0, T], x \in [0,L_i],\, i=4,5,6, \\ p_i(T, x)=0, \ (p_{i})_{t}(T, x)=0,\, i = 1,2,\cdots ,6,\\ (p_{1})_{x}(t, 0)=0, \ p_2(t, 0)=0,\, p_3(t, 0)=0,\,t \in [0,T], \\ \text {Continuity and Kirchhoff conditions,} \end{array}\right. \end{aligned}$$
(106)

where \(\chi (x)\) is the characteristic function of \([0,L_i-\varepsilon _{\max }]\), i.e., \(\chi (x)=1\) on \([0,L_i-\varepsilon _{\max }]\) and \(\chi (L_i-x)=0\).

The optimal control \(u(t)\) is obtained from the optimality system as

$$\begin{aligned} u(t) = \zeta - p(t,0). \end{aligned}$$

This formulation provides insights into the dynamical optimization of the system.

In Fig. 16, we illustrate the temporal evolution of the shape functional across varying \(\varepsilon \in [0,1]\). Subfigures (a), (b), and (c) correspond to \(T=1\), \(T=10\), and \(T=100\), respectively, offering insights into the functional’s behavior over different time scales. It is evident from the results that the minimization of the cost functional consistently occurs when \(\varepsilon = \varepsilon _0\), emphasizing the pivotal role of this parameter in optimizing the system’s response.

Fig. 16
figure 16

The shape functional for \(\varepsilon \in [0,1]\), \(T=1,10,100\) in Example 4

Fig. 17
figure 17

The shape functional for the size of cycle \(\varepsilon \in [0,1]\) in Example 5

Example 5 (for multiple cycles): In this example, the geometry is depicted in Fig. 13. Here, \(G_\varepsilon =\{E_\varepsilon ,V_\varepsilon \}\) contains a small cycle. \(E_\varepsilon =\{E_{\varepsilon ,1},E_{\varepsilon ,2},\cdots ,E_{\varepsilon ,9}\}\), \(V_\varepsilon =\{Q_1,Q_2,\cdots ,Q_5,P_4,P_5,P_6\}\), \(|Q_1P_5|=|Q_2P_6|=|Q_3P_4|=\varepsilon _{\max }-\varepsilon =1-\varepsilon \), \(|E_{\varepsilon ,5}|=|E_{\varepsilon ,6}|=|E_{\varepsilon ,9}|=\varepsilon ^2\), \(|E_{\varepsilon ,4}|=|E_{\varepsilon ,7}|=\varepsilon -\varepsilon ^2\), \(|E_{\varepsilon ,8}|=\varepsilon \), and \(|P_iQ_i|=L_i-\varepsilon _{\max }\) (\(i=1,2,3\)). The parameters, cost functional, and optimality system remain consistent with the Example for one cycle (static), with the sole distinction being the form of \(\Lambda _\varepsilon \). The Steklov-Poincaré operator for the small, double cycle is:

$$\begin{aligned} \Lambda _\varepsilon =-\frac{1}{2 \varepsilon -3} \left( \begin{array}{ccc} -2 &{} 1 &{} 1 \\ 1 &{} \dfrac{-5\varepsilon ^2+20\varepsilon -18}{2{\varepsilon }^2-10\varepsilon +9} &{} \dfrac{3{\varepsilon }^2-10\varepsilon +9}{2{\varepsilon }^2-10\varepsilon +9} \\ 1 &{} \dfrac{3{\varepsilon }^2-10\varepsilon +9}{2{\varepsilon }^2-10\varepsilon +9} &{} \dfrac{-5\varepsilon ^2+20\varepsilon -18}{2{\varepsilon }^2-10\varepsilon +9} \end{array}\right) . \end{aligned}$$

For numerical results, refer to Fig. 17. The topological derivative at \(\varepsilon =0^+\) is negative. And the optimal size of the cycle is \(\varepsilon =\varepsilon _0=0.5\).

10 Conclusions

In this paper, we exploit the properties of shape and topology optimization problems on networks modelled by graphs. The optimal control problems are considered in static and dynamic cases. For the tree network, we show the exponential turnpike property for the wave equation and consider the geometric shape optimization. The new case is the tree with small cycles. In such a case the topology of the optimal network is determined by using the topological derivatives obtained in the static case. Numerically, the case of multiple cycles also does not pose a problem. This is a novel result which shows that also in situations of this type shape optimization is applicable, as long as in the shape optimization no topology change occurs, that is no cycle vanishes.

The turnpike property also holds if a cycle disappears. We have shown this under the assumption that the initial state is not supported on the cycle. We expect that this condition is not sharp.

The convergence of gradient flow for shape optimization is also relevant to networks. The modeling of the shapes of animals is another possibility for the application of spectral methods. We refer to [27], and [28] for the related results. Further research will concern the corresponding shape optimization problems in the general three dimensional case.