OF VARIATIONS AND OPTIMAL CONTROL FOR GENERALIZED FUNCTIONS

GAST¨I¿ŒO S.F. FREDERICO, PAOLO GIORDANO, ALEXANDR A. BRYZGALOV, AND MATHEUS J. LAZO

Abstract. We present an extension of some results of higher order calculus of variations and optimal control to generalized functions. The framework is the category of generalized smooth functions, which includes Schwartz distributions, while sharing many nonlinear prop- erties with ordinary smooth functions. We prove the higher order Euler-Lagrange equations, the D’Alembert principle in differential form, the du Bois-Reymond optimality condition and the Noether’s theorem. We start the theory of optimal control proving a weak form of the Pontryagin maximum principle and the Noether’s theorem for optimal control. We close with a study of a singularly variable length pendulum, oscillations damped by two media and the Pais–Uhlenbeck oscillator with singular frequencies.

Contents 1. Introduction: singular Lagrangian mechanics1 2. Basic notions 3 2.1. Open, closed and bounded sets generated by nets5 2.2. Generalized smooth functions and their calculus5 2.3. Embedding of Sobolev-Schwartz distributions and Colombeau generalized functions8 2.4. Functionally compact sets and multidimensional integration 10 3. Higher-order calculus of variations for generalized functions 13 3.1. Higher-order Euler–Lagrange equation, D’Alembert principle and du Bois–Reymond optimality condition 15 3.2. Higher-order Noether’s theorem 19 4. Optimal control problems 22 4.1. Weak Pontryagin Maximum Principle 24 4.2. Noether’s Principle for optimal control 29 5. Examples and applications 31 5.1. Modeling singular dynamical systems 31 5.2. How to use numerical solutions 31 5.3. Singularly variable length pendulum 32 5.4. Oscillations damped by two media 36 arXiv:2011.09660v1 [math.FA] 18 Nov 2020 5.5. Pais–Uhlenbeck oscillator with singular frequencies 38 6. Conclusions 39 References 40

1. Introduction: singular Lagrangian mechanics Leibniz’s axiom Natura non facit saltus seems to be inconsistent not only at the atomic level, but also for several macroscopic phenomena. Even the simple motion of an elastic bouncing

2020 Mathematics Subject Classification. 49-XX, 46Fxx, 46F30. Key words and phrases. Calculus of variations, optimal control, Schwartz distributions, generalized functions for nonlinear analysis. M.J. Lazo has been supported by CNPq and FAPERGS. P. Giordano has been supported by grants P30407, P33538 of the Austrian Science Fund FWF. 1 2 GAST¨I¿ŒO S.F. FREDERICO, PAOLO GIORDANO, ALEXANDR A. BRYZGALOV, AND MATHEUS J. LAZO ball seems to be more easily modeled using non-differentiable functions than classical C2 ones, at least if we are not interested to model the non-trivial behavior at the collision times. Clearly, we can always use smooth functions to approximately model the forces acting on the ball, but this would introduce additional parameters (see e.g. [58, 65] for smooth approximations of steep potentials in the billiard problem). Therefore, the motivation to introduce a suitable kind of generalized functions formalism in classical mechanics is clear: is it possible, e.g., to generalize Lagrangian mechanics so that the Lagrangian can be presented as a generalized function? This would undoubtedly be of an applicable advantage, since many relevant systems are described by singular Lagrangians: non-smooth constraints, collisions between two or more bodies, motion in different or in granular media, discontinuous propagation of rays of light, even turning on the switch of an electrical circuit, to name but a few, and only in the framework of classical physics. Indeed, this type of problems is widely studied (see e.g. [4,28,34,37,42–44,62,64]), but sometimes the presented solutions are not general or hold only for special conditions and particular potentials. From the purely mathematical point of view, an enlarged space of solutions (with distributional derivatives) for variational problems leads to the the so-called Lavrentiev phenomenon, see [5,27]. Variational problems with singular solutions (e.g. non-differentiable on a dense set, or with infinite derivatives at some points) are also studied, see [10, 11, 27, 61]. In this sense, the fact that since J.D. Marsden’s works [49–51] there has not been many further attempt to use Sobolev-Schwartz distributions for the description of Hamiltonian mechanics, can be considered as a clue that the classical distributional framework is not well suited to face this problem in general terms (see also [56] for a similar approach with a greater focus on the gener- alization in geometry). In [49–51], J.D. Marsden introduces distributions on manifolds based on flows. Since the traditional system of Hamilton’s equations breaks down, Marsden considers the flow as a limit of smooth ones. On the other hand, Kunzinger et al. in [36] (using Colombeau generalized functions) critically analyses the regularization approach put forward by Marsden and constructed a counter example for the main flow theorems of [49]. In this field, a number of prob- lems remains open, see again [49]. For example, in the non-smooth case the variational theorems fail, and the study of the virial equation for hard spheres in a box is still an open question. All this motivates the use of different spaces of nonlinear generalized functions in mathematical physics and in singular calculus of variations, see e.g. [2,8, 25, 29, 34, 66]. In this paper, we introduce an approach to variational problems involving singularities that allows the extension of the classical theory with very natural statements and proofs. We are interested in extremizing functionals which are either distributional themselves or whose set of extremals includes generalized functions. Clearly, distribution theory, being a linear theory, has certain difficulties when nonlinear problems are in play. To overcome this type of problems, we are going to use the category of generalized smooth functions (GSF), see [20–23, 41]. This theory seems to be a good candidate, since it is an exten- sion of classical distribution theory which allows to model nonlinear singular problems, while at the same time sharing many nonlinear properties with ordinary smooth functions, like the closure with respect to composition and several non trivial classical theorems of the calculus. One could describe GSF as a methodological restoration of Cauchy-Dirac’s original conception of generalized function, see [12,33,39]. In essence, the idea of Cauchy and Dirac (but also of Poisson, Kirchhoff, Helmholtz, Kelvin and Heaviside) was to view generalized functions as suitable types of smooth set-theoretical maps obtained from ordinary smooth maps depending on suitable infinitesimal or infinite parameters. For example, the density of a Cauchy-Lorentz distribution with an infini- tesimal scale parameter was used by Cauchy to obtain classical properties which nowadays are attributed to the Dirac delta, cf. [33]. In the present work, the foundation of the calculus of variations is set for functionals defined by arbitrary GSF. This in particular applies to any Schwartz distribution and any Colombeau generalized function (see e.g. [7, 29]). The main aim of the paper is to start the higher-order calculus of variations and the theory of optimal control for GSF. The structure of the paper is as follows. We start with an introduction into the setting of GSF and give basic notions concerning GSF and their calculus that are needed for the calculus of variations (Sec.2). After the basic definitions to set the problem in the framework of CALCULUS OF VARIATIONS AND OPTIMAL CONTROL FOR GF 3

GSF, we prove the higher order Euler-Lagrange equations, the D’Alembert principle in differential form, the du Bois-Reymond optimality condition and the Noether’s theorem (Sec.3). In Sec.4, we start the theory of optimal control proving a weak form of the Pontryagin maximum principle and the Noether’s theorem, and in Sec.5 we close with a study of a singularly variable length pendulum, oscillations damped by two media and the Pais–Uhlenbeck oscillator with singular frequencies. The paper is self-contained, in the sense that it contains all the statements required for the proofs of calculus of variations we are going to present. If proofs of preliminaries are omitted, we clearly give references to where they can be found. Therefore, to understand this paper, only a basic knowledge of distribution theory is needed.

2. Basic notions The new ring of scalars. In this work, I denotes the interval (0, 1] ⊆ R and we will always use I the variable ε for elements of I; we also denote ε-dependent nets x ∈ R simply by (xε). By N we denote the set of natural numbers, including zero. We start by defining a new simple non-Archimedean ring of scalars that extends the real field R. The entire theory is constructive to a high degree, e.g. neither ultrafilter nor non-standard method are used. For all the proofs of results in this section, see [20–23].

I + Definition 1. Let ρ = (ρε) ∈ (0, 1] be a non-decreasing net such that (ρε) → 0 as ε → 0 (in the following, such a net will be called a gauge), then −a (i) I(ρ) := {(ρε ) | a ∈ R>0} is called the asymptotic gauge generated by ρ. 0 (ii) If P(ε) is a property of ε ∈ I, we use the notation ∀ ε : P(ε) to denote ∃ε0 ∈ I ∀ε ∈ (0, ε0]: P(ε). We can read ∀0ε as for ε small. I (iii) We say that a net (xε) ∈ R is ρ-moderate, and we write (xε) ∈ Rρ if + ∃(Jε) ∈ I(ρ): xε = O(Jε) as ε → 0 , i.e., if 0 −N ∃N ∈ N ∀ ε : |xε| ≤ ρε . I (iv) Let (xε), (yε) ∈ R , then we say that (xε) ∼ρ (yε) if −1 + ∀(Jε) ∈ I(ρ): xε = yε + O(Jε ) as ε → 0 , that is if 0 n ∀n ∈ N ∀ ε : |xε − yε| ≤ ρε . (2.1) This is a congruence relation on the ring Rρ of moderate nets with respect to pointwise operations, and we can hence define

ρ Re := Rρ/ ∼ρ, which we call Robinson-Colombeau ring of generalized numbers. This name is justified by [6, 59]: Indeed, in [59] A. Robinson introduced the notion of moderate and negligible nets depending on an arbitrary fixed infinitesimal ρ (in the framework of nonstandard analysis); independently, J.F. Colombeau, cf. e.g. [6] and references therein, studied the same concepts without using nonstandard analysis, but considering only the particular gauge ρε = ε.

ρ I We can also define an order relation on Re by saying that [xε] ≤ [yε] if there exists (zε) ∈ R such that (zε) ∼ρ 0 (we then say that (zε) is ρ-negligible) and xε ≤ yε + zε for ε small. Equivalently, we have that x ≤ y if and only if there exist representatives [xε] = x and [yε] = y such that xε ≤ yε for all ε. Although the order ≤ is not total, we still have the possibility to define the infimum [xε] ∧ [yε] := [min(xε, yε)], the supremum [xε] ∨ [yε] := [max(xε, yε)] of a finite number ρ of generalized numbers. Henceforth, we will also use the customary notation Re∗ for the set of ρ invertible generalized numbers, and we write x < y to say that x ≤ y and x − y ∈ Re∗. Our ρ notations for intervals are: [a, b] := {x ∈ Re | a ≤ x ≤ b},[a, b]R := [a, b] ∩ R, and analogously for ρ n n n segments [x, y] := {x + r · (y − x) | r ∈ [0, 1]} ⊆ Re and [x, y]R = [x, y] ∩ R . As in every non-Archimedean ring, we have the following 4 GAST¨I¿ŒO S.F. FREDERICO, PAOLO GIORDANO, ALEXANDR A. BRYZGALOV, AND MATHEUS J. LAZO

ρ Definition 2. Let x ∈ Re be a generalized number, then (i) x is infinitesimal if |x| ≤ r for all r ∈ R>0. If x = [xε], this is equivalent to limε→0+ xε = 0. We write x ≈ y if x − y is infinitesimal. (ii) x is infinite if |x| ≥ r for all r ∈ R>0. If x = [xε], this is equivalent to limε→0+ |xε| = +∞. (iii) x is finite if |x| ≤ r for some r ∈ R>0. ρ n ρ For example, setting dρ := [ρε] ∈ Re, we have that dρ ∈ Re, n ∈ N>0, is an invertible infinitesimal, −n −n whose reciprocal is dρ = [ρε ], which is necessarily a positive infinite number. Of course, in ρ the ring Re there exist generalized numbers which are not in any of the three classes of Def.2, like 1 1  e.g. xε = ε sin ε . The following result is useful to deal with positive and invertible generalized numbers. For its proof, see e.g. [29].

ρ Lemma 3. Let x ∈ Re. Then the following are equivalent: (i) x is invertible and x ≥ 0, i.e. x > 0. 0 (ii) For each representative (xε) ∈ Rρ of x we have ∀ ε : xε > 0. 0 m (iii) For each representative (xε) ∈ Rρ of x we have ∃m ∈ N ∀ ε : xε > ρε . 0 m (iv) There exists a representative (xε) ∈ Rρ of x such that ∃m ∈ N ∀ ε : xε > ρε . ρ ρ ρ Topologies on Ren. On the Re-module Ren we can consider the natural extension of the Euclidean ρ ρ n ρ norm, i.e. |[xε]| := [|xε|] ∈ Re, where [xε] ∈ Re . Even if this generalized norm takes values in Re, it shares some essential properties with classical norms: |x| = x ∨ (−x) |x| ≥ 0 |x| = 0 ⇒ x = 0 |y · x| = |y| · |x| |x + y| ≤ |x| + |y| ||x| − |y|| ≤ |x − y|.

ρ It is therefore natural to consider on Ren a topology generated by balls defined by this generalized ρ norm and the set of radii Re>0 of positive invertible numbers: ρ ρ Definition 4. Let c ∈ Ren and x, y ∈ Re, then: n ρ n o ρ (i) Br(c) := x ∈ Re | |x − c| < r for each r ∈ Re>0. E n n (ii) Br (c) := {x ∈ R | |x − c| < r}, for each r ∈ R>0, denotes an ordinary Euclidean ball in R if c ∈ Rn. The relation < has better topological properties as compared to the usual strict order relation n ρ ρ no a ≤ b and a 6= b (that we will never use) because the set of balls Br(c) | r ∈ Re>0, c ∈ Re ρ is a base for a sequentially Cauchy complete topology on Ren called sharp topology. We will call sharply open set any open set in the sharp topology. The existence of infinitesimal neighborhoods (e.g. r = dρ) implies that the sharp topology induces the discrete topology on R. This is a necessary result when one has to deal with continuous generalized functions which have infinite 0 derivatives. In fact, if f (x0) is infinite, we have f(x) ≈ f(x0) only for x ≈ x0 , see [21]. Also ρ open intervals are defined using the relation <, i.e. (a, b) := {x ∈ Re | a < x < b}. Note that by ρ m Lem.3.(iii), for all r ∈ Re>0 there exists m ∈ N such that r ≥ dρ . Therefore, also the set of n ρ no balls Bdρm (c) | m ∈ N, c ∈ Re is a base for the sharp topology. ρ The lecturer can feel uneasy in considering a ring of scalar such as Re instead of a field. On the other hand, as mentioned above, we will see that all our generalized functions are continuous in the sharp topology. Therefore, the following result is partly reassuring:

ρ Lemma 5. Invertible elements of Re are dense in the sharp topology, i.e. ρ ρ ∀h ∈ Re ∀δ ∈ Re>0 ∃k ∈ (h − δ, h + δ): k is invertible. CALCULUS OF VARIATIONS AND OPTIMAL CONTROL FOR GF 5

2.1. Open, closed and bounded sets generated by nets. A natural way to obtain sharply ρ n n open, closed and bounded sets in Re is by using a net (Aε) of subsets Aε ⊆ R . We have two ρ n ways of extending the membership relation xε ∈ Aε to generalized points [xε] ∈ Re (cf. [22, 54]): n Definition 6. Let (Aε) be a net of subsets of R , then n ρ n 0 o (i)[ Aε] := [xε] ∈ Re | ∀ ε : xε ∈ Aε is called the internal set generated by the net (Aε). n (ii) Let (xε) be a net of points of R , then we say that xε ∈ε Aε, and we read it as (xε) strongly belongs to (Aε), if 0 (i) ∀ ε : xε ∈ Aε. 0 0 (ii) If (xε) ∼ρ (xε), then also xε ∈ Aε for ε small. n ρ n o Moreover, we set hAεi := [xε] ∈ Re | xε ∈ε Aε , and we call it the strongly internal set generated by the net (Aε). ρ (iii) We say that the internal set K = [Aε] is sharply bounded if there exists M ∈ Re>0 such that K ⊆ BM (0). (iv) Finally, we say that the (Aε) is a sharply bounded net if there exists N ∈ R>0 such that 0 −N ∀ ε ∀x ∈ Aε : |x| ≤ ρε .

Therefore, x ∈ [Aε] if there exists a representative [xε] = x such that xε ∈ Aε for ε small, whereas this membership is independent from the chosen representative in case of strongly internal sets. n An internal set generated by a constant net Aε = A ⊆ R will simply be denoted by [A]. The following theorem (cf. [22,23,54]) shows that internal and strongly internal sets have dual topological properties:

n n Theorem 7. For ε ∈ I, let Aε ⊆ R and let xε ∈ R . Then we have 0 q (i) [xε] ∈ [Aε] if and only if ∀q ∈ R>0 ∀ ε : d(xε,Aε) ≤ ρε. Therefore [xε] ∈ [Aε] if and only if ρ [d(xε,Aε)] = 0 ∈ Re. 0 c q c n (ii) [xε] ∈ hAεi if and only if ∃q ∈ R>0 ∀ ε : d(xε,Aε) > ρε, where Aε := R \ Aε. Therefore, c c if (d(xε,Aε)) ∈ Rρ, then [xε] ∈ hAεi if and only if [d(xε,Aε)] > 0. (iii) [Aε] is sharply closed. (iv) hAεi is sharply open. n (v) [Aε] = [cl (Aε)], where cl (S) is the closure of S ⊆ R . n (vi) hAεi = hint(Aε)i, where int (S) is the interior of S ⊆ R . For example, it is not hard to show that the closure in the sharp topology of a ball of center c = [cε] and radius r = [rε] > 0 is n o h i B (c) = x ∈ ρ d | |x − c| ≤ r = BE (c ) , (2.2) r Re rε ε whereas n o B (c) = x ∈ ρ d | |x − c| < r = hBE (c )i. r Re rε ε

ρ 2.2. Generalized smooth functions and their calculus. Using the ring Re, it is easy to consider a Gaussian with an infinitesimal standard deviation. If we denote this probability density ρ by f(x, σ), and if we set σ = [σε] ∈ Re>0, where σ ≈ 0, we obtain the net of smooth functions (f(−, σε))ε∈I . This is the basic idea we are going to develop in the following

ρ ρ Definition 8. Let X ⊆ Ren and Y ⊆ Red be arbitrary subsets of generalized points. Then we say that f : X −→ Y is a generalized smooth function ∞ d if there exists a net fε ∈ C (Ωε, R ) defining f in the sense that (i) X ⊆ hΩεi, (ii) f([xε]) = [fε(xε)] ∈ Y for all x = [xε] ∈ X, α d n (iii)( ∂ fε(xε)) ∈ Rρ for all x = [xε] ∈ X and all α ∈ N . The space of generalized smooth functions (GSF) from X to Y is denoted by ρGC∞(X,Y ). 6 GAST¨I¿ŒO S.F. FREDERICO, PAOLO GIORDANO, ALEXANDR A. BRYZGALOV, AND MATHEUS J. LAZO

Let us note explicitly that this definition states minimal logical conditions to obtain a set- theoretical map from X into Y and defined by a net of smooth functions of which we can take arbitrary derivatives still remaining in the space of ρ-moderate nets. In particular, the following Thm.9 states that the equality f([xε]) = [fε(xε)] is meaningful, i.e. that we have independence α ρ d n from the representatives for all derivatives [xε] ∈ X 7→ [∂ fε(xε)] ∈ Re , α ∈ N . ρ n ρ d Theorem 9. Let X ⊆ Re and Y ⊆ Re be arbitrary subsets of generalized points. Let fε ∈ ∞ d C (Ωε, R ) be a net of smooth functions that defines a generalized smooth map of the type X −→ Y , then n 0 n 0 α α 0 (i) ∀α ∈ N ∀(xε), (xε) ∈ Rρ :[xε] = [xε] ∈ X ⇒ [∂ fε(xε)] = [∂ fε(xε)]. (ii) Each f ∈ ρGC∞(X,Y ) is continuous with respect to the sharp topologies induced on X, Y . ∞ n d (iii) f : X −→ Y is a GSF if and only if there exists a net vε ∈ C (R , R ) defining a generalized smooth map of type X −→ Y such that f = [vε(−)]|X . ρ (iv) GSF are closed with respect to composition, i.e. subsets S ⊆ Res with the trace of the sharp topology, and GSF as arrows form a subcategory of the category of topological spaces. We will call this category ρGC∞, the category of GSF. Therefore, with pointwise sum and product, ρ ∞ ρ any space GC (X, Re) is an algebra. Similarly, we can define generalized functions of class ρGCk, with k ≤ +∞:

ρ ρ Definition 10. Let X ⊆ Ren and Y ⊆ Red be arbitrary subsets of generalized points and k ∈ N ∪ {+∞}. Then we say that f : X −→ Y is a generalized Ck function k d if there exists a net fε ∈ C (Ωε, R ) defining f in the sense that (i) X ⊆ hΩεi, (ii) f([xε]) = [fε(xε)] ∈ Y for all x = [xε] ∈ X, α d n (iii)( ∂ fε(xε)) ∈ Rρ for all x = [xε] ∈ X and all α ∈ N such that |α| ≤ k. n 0 0 α α 0 (iv) ∀α ∈ N ∀[xε], [xε] ∈ X : |α| = k, [xε] = [xε] ⇒ [∂ fε(xε)] = [∂ fε(xε)]. n α ρ d (v) For all α ∈ N , with |α| = k, the map [xε] ∈ X 7→ [∂ fε(xε)] ∈ Re is continuous in the sharp topology. The space of generalized Ck functions from X to Y is denoted by ρGCk(X,Y ). Note that properties (iv), (v) are required only for |α| = k because for lower length they can be proved using property (iii) and the classical mean value theorem for fε (see e.g. [22, 23]). From (i) and (ii) of Thm.9 it follows that this definition of ρGCk is equivalent to Def.8 if k = +∞. Moreover, properties similar to (iii), (iv) of Thm.9 can also be proved for ρGCk. The differential calculus for ρGCk+1 maps can be introduced by showing existence and unique- ness of another ρGCk map serving as incremental ratio (sometimes this is called derivative ¨ı¿œla Carath¨ı¿œodory, see e.g. [35]).

ρ n ρ n Theorem 11. Let U ⊆ Re be a sharply open set, let v = [vε] ∈ Re , k ∈ N ∪ {+∞}, and let ρ k+1 ρ ρ k+1 k+1 f ∈ GC (U, Re) be a GC map generated by the net of functions fε ∈ C (Ωε, R). Then ρ k ρ (i) There exists a sharp neighborhood T of U × {0} and a map r ∈ GC (T, Re), called the generalized incremental ratio of f along v, such that ∀(x, h) ∈ T : f(x + hv) = f(x) + h · r(x, h). (ii) Any two generalized incremental ratios coincide on a sharp neighborhood of U × {0}, so that we can use the notation ∂f [x; h] := r(x, h) if (x, h) are sufficiently small. h ∂v i ∂f ∂fε ∂f (iii) We have [x; 0] = (xε) for every x ∈ U and we can thus define Df(x) · v := (x) := ∂v ∂vε ∂v ∂f ∂f ρ k ρ ∂v [x; 0], so that ∂v ∈ GC (U, Re). Note that this result permits us to consider the partial derivative of f with respect to an ρ arbitrary generalized vector v ∈ Ren which can be, e.g., infinitesimal or infinite. Using recursively this result, we can also define subsequent differentials Djf(x) as j−multilinear maps, and we set CALCULUS OF VARIATIONS AND OPTIMAL CONTROL FOR GF 7

j ρ  ρ Djf(x)·hj := Djf(x)(h, . . .j . . . , h) if j ≤ k. The set of all the j−multilinear maps Ren −→ Red ρ j ρ n ρ d j ρ n ρ d over the ring Re will be denoted by L ( Re , Re ). For A = [Aε(−)] ∈ L ( Re , Re ), we set |A| := [|Aε|], the generalized number defined by the operator norms of the multilinear maps j n d Aε ∈ L (R , R ). The following result follows from the analogous properties for the nets of smooth functions defining f and g.

ρ ρ Theorem 12. Let U ⊆ Ren be an open subset in the sharp topology, let v ∈ Ren and f, g ∈ ρ k+1 ρ GC (U, Red). Then ∂(f+g) ∂f ∂g (i) ∂v = ∂v + ∂v ∂(r·f) ∂f ρ (ii) ∂v = r · ∂v ∀r ∈ Re ∂(f·g) ∂f ∂g (iii) ∂v = ∂v · g + f · ∂v ∂f ρ ρ ρ n (iv) For each x ∈ U, the map df(x).v := ∂v (x) ∈ Re is Re-linear in v ∈ Re ρ ρ ρ k+1 (v) Let U ⊆ Ren and V ⊆ Red be open subsets in the sharp topology and g ∈ GC (V,U), ρ k+1 ρ ρ f ∈ GC (U, Re) be generalized maps. Then for all x ∈ V and all v ∈ Red, we have ∂(f◦g) ∂g ∂v (x) = df (g(x)) . ∂v (x).

ρ ρ Note that the absolute value function | − | : Re −→ Re is not a GSF because its derivative is not sharply continuous at the origin; clearly, it is a ρGC0 function. This is a good motivation to introduce integration of ρGCk functions. One dimensional integral calculus is based on the following

ρ k ρ ρ Theorem 13. Let k ∈ N ∪ {+∞} and f ∈ GC ([a, b], Re) be defined in the interval [a, b] ⊆ Re, where a < b. Let c ∈ [a, b]. Then, there exists one and only one generalized Ck+1 map F ∈ ρ k+1 ρ GC ([a, b], Re) such that F (c) = 0 and F 0(x) = f(x) for all x ∈ [a, b]. Moreover, if f is defined k h xε i by the net fε ∈ C ( , ) and c = [cε], then F (x) = fε(s)ds for all x = [xε] ∈ [a, b]. R R cε ´ We can thus define (−) (−) Definition 14. Under the assumptions of Thm. 13, we denote by c f := c f(s) ds ∈ ρ k+1 ρ GC ([a, b], Re) the unique generalized Ck+1 map such that: ´ ´ c (i) c f = 0 0 ´ (−)  d x (ii) u f (x) = dx u f(s)ds = f(x) for all x ∈ [a, b]. ´ ´ All the classical rules of integral calculus hold in this setting:

ρ k ρ ρ k ρ Theorem 15. Let f ∈ GC (U, Re) and g ∈ GC (V, Re) be generalized Ck maps defined on sharply ρ ρ open domains in Re. Let a, b ∈ Re with a < b and c, d ∈ [a, b] ⊆ U ∩ V , then d d d (i) c (f + g) = c f + c g ´ d d ´ ´ ρ (ii) c λf = λ c f ∀λ ∈ Re ´ d e ´ d (iii) c f = c f + e f for all e ∈ [a, b] ´ d ´ c ´ (iv) c f = − d f ´ d 0 ´ (v) c f = f(d) − f(c) ´ d 0 d d 0 (vi) c f · g = [f · g]c − c f · g ´ ´ b b (vii) If f(x) ≤ g(x) for all x ∈ [a, b], then a f ≤ a g. ρ ρ k+1 ρ (viii) Let a, b, c, d ∈ Re, with a < b and c <´ d, and´ f ∈ GC ([a, b] × [c, d], Red), then d b b ∂ f(τ, s) dτ = f(τ, s) dτ ∀s ∈ [c, d]. ds ˆa ˆa ∂s 8 GAST¨I¿ŒO S.F. FREDERICO, PAOLO GIORDANO, ALEXANDR A. BRYZGALOV, AND MATHEUS J. LAZO

ρ k ρ ρ k+1 Theorem 16. Let f ∈ GC (U, Re) and ϕ ∈ GC (V,U) be GSF defined on sharply open domains ρ ρ in Re. Let a, b ∈ Re, with a < b, such that [a, b] ⊆ V , ϕ(a) < ϕ(b), [ϕ(a), ϕ(b)] ⊆ U. Finally, assume that ϕ([a, b]) ⊆ [ϕ(a), ϕ(b)]. Then ϕ(b) b f(t)dt = f [ϕ(s)] · ϕ0(s)ds. ˆϕ(a) ˆa We also have a generalization of Taylor formula:

ρ k ρ Theorem 17. Let f ∈ GC (U, Re) be a generalized Ck+1 function defined in the sharply open set ρ ρ U ⊆ Red. Let a, b ∈ Red such that the line segment [a, b] ⊆ U, and set h := b − a. Then, for all n ∈ N≤k we have j n+1 Pn d f(a) j d f(ξ) n+1 (i) ∃ξ ∈ [a, b]: f(a + h) = j=0 j! · h + (n+1)! · h . j Pn d f(a) j 1 1 n n+1 n+1 (ii) f(a + h) = j=0 j! · h + n! · 0 (1 − t) d f(a + th) · h dt. ρ ´ Moreover, there exists some R ∈ Re>0 such that n X djf(a) dn+1f(ξ) ∀k ∈ B (0) ∃ξ ∈ [a, a + k]: f(a + k) = · kj + · kn+1 (2.3) R j! (n + 1)! j=0 dn+1f(ξ) 1 1 · kn+1 = · (1 − t)n dn+1f(a + tk) · kn+1 dt ≈ 0. (2.4) (n + 1)! n! ˆ0 Formulas (i) and (ii) correspond to a plain generalization of Taylor’s theorem for ordinary functions with Lagrange and integral remainder, respectively. Dealing with generalized functions, it is important to note that this direct statement also includes the possibility that the differential dn+1f(ξ) may be infinite at some point. For this reason, in (2.3) and (2.4), considering a sufficiently small increment k, we get more classical infinitesimal remainders dn+1f(ξ) · kn+1 ≈ 0. We can 0 0 0 also define right and left derivatives as e.g. f (a) := f+(a) := limt→a f (t), which always exist if a

ρ ρ ∞ ρ Lemma 18. Let X ⊆ Re and let f ∈ GC (X, Re). 0 (i) If x0 ∈ X is a sharply interior local minimum of f then f (x0) = 0. ρ (ii) Let a, b ∈ Re with a < b, [a, b] ⊆ X and x0 be a sharply interior point of [a, b]. Assume that 00 0 00 x0 is a local minimum of f. Then f (x0) ≥ 0. Vice versa, if f (x0) = 0 and f (x0) > 0, then x0 is a local minimum of f. 2.3. Embedding of Sobolev-Schwartz distributions and Colombeau generalized func- tions. We finally recall two results that give a certain flexibility in constructing embeddings of Schwartz distributions. Note that both the infinitesimal ρ and the embedding of Schwartz dis- tributions have to be chosen depending on the problem we aim to solve. A trivial example in this direction is the ODE y0 = y/dε, which cannot be solved for ρ = (ε), but it has a solution for ρ = (e−1/ε). As another simple example, if we need the property H(0) = 1/2, where H is the Heaviside function, then we have to choose the embedding of distributions accordingly. See also [24, 46] for further details. n n n If ϕ ∈ D(R ), r ∈ R>0 and x ∈ R , we use the notations r ϕ for the function x ∈ R 7→ 1 x  n rn · ϕ r ∈ R and x ⊕ ϕ for the function y ∈ R 7→ ϕ(y − x) ∈ R. These notations permit us n to highlight that is a free action of the multiplicative group (R>0, ·, 1) on D(R ) and ⊕ is a n free action of the additive group (R>0, +, 0) on D(R ). We also have the distributive property r (x ⊕ ϕ) = rx ⊕ r ϕ.

ρ Lemma 19. Let b ∈ Re be a net such that limε→0+ bε = +∞. Let d ∈ (0, 1). There exists a net n (ψε)ε∈I of D(R ) with the properties: CALCULUS OF VARIATIONS AND OPTIMAL CONTROL FOR GF 9

(i) supp(ψε) ⊆ B1(0) and ψε is even for all ε ∈ I. n−1 2n (ii) Let ωn denote the surface area of S and set cn := for n > 1 and c1 := 1, then ωn ψε(0) = cn for all ε ∈ I. (iii) ψε = 1 for all ε ∈ I. n α p + (iv) ´∀α ∈ ∃p ∈ : sup n |∂ ψ (x)| = O(b ) as ε → 0 . N N x∈R ε ε 0 α (v) ∀j ∈ N ∀ ε : 1 ≤ |α| ≤ j ⇒ x · ψε(x)dx = 0. 0 (vi) ∀η ∈ R>0 ∀ ε : |ψε| ≤ 1 +´η. ´ 0 (vii) If n = 1, then the net (ψε)ε∈I can be chosen so that −∞ ψε = d. b −1 ´ In particular ψε := bε ψε satisfies (iii)- (vi). Concerning embeddings of Schwartz distributions, we have the following result, where c(Ω) := 0 n {[xε] ∈ [Ω] | ∃K b Ω ∀ ε : xε ∈ K} is called the set of compactly supported points in Ω ⊆ R . n b Theorem 20. Under the assumptions of Lemma 19, let Ω ⊆ R be an open set and let (ψε) be the net defined in 19. Then the mapping b 0  b  ρ ∞ ρ ιΩ : T ∈ E (Ω) 7→ T ∗ ψε (−) ∈ GC (c(Ω), Re) uniquely extends to a sheaf morphism of real vector spaces b 0 ρ ∞ ρ ι : D −→ GC (c((−)), Re), and satisfies the following properties: ∞ ρ ∞ ρ −a b ∞ (i) If b ≥ dρ for some a ∈ R>0, then ι |C (−) : C (−) −→ GC (c((−)), Re) is a sheaf b ∞ morphism of algebras and ιΩ(f)(x) = f(x) for all smooth functions f ∈ C (Ω) and all x ∈ Ω; 0 b (ii) If T ∈ E (Ω) then supp(T ) = supp(ιΩ(T )); b 0 (iii) limε→0+ Ω ιΩ(T )ε · ϕ = hT, ϕi for all ϕ ∈ D(Ω) and all T ∈ D (Ω); b α b  b α 0 (iv) ι commutes´ with partial derivatives, i.e. ∂ ιΩ(T ) = ιΩ (∂ T ) for each T ∈ D (Ω) and α ∈ N. Concerning the embedding of Colombeau generalized functions, we recall that the special s s Colombeau algebra on Ω is defined as the quotient G (Ω) := EM (Ω)/N (Ω) of moderate nets over negligible nets, where the former is ∞ I n α −N EM (Ω) := {(uε) ∈ C (Ω) | ∀K b Ω ∀α ∈ N ∃N ∈ N : sup |∂ uε(x)| = O(ε )} x∈K and the latter is s ∞ I n α m N (Ω) := {(uε) ∈ C (Ω) | ∀K b Ω ∀α ∈ N ∀m ∈ N : sup |∂ uε(x)| = O(ε )}. x∈K Using ρ = (ε), we have the following compatibility result:

s d s d Theorem 21. A Colombeau generalized function u = (uε) + N (Ω) ∈ G (Ω) defines a GSF u : d s d ρ ∞ ρ d [xε] ∈ c(Ω) −→ [uε(xε)] ∈ Re . This assignment provides a bijection of G (Ω) onto GC (c(Ω), Re ) for every open set Ω ⊆ Rn. Example 22. ρ ∞ ρ ρ (i) Let δ, H ∈ GC ( Re, Re) be the corresponding ιb-embeddings of the Dirac delta and of the Heaviside function. Then δ(x) = b · ψ(b · x), where ψ(x) := [ψε(xε)]. We have that δ(0) = b ≥ dρ−a and δ(x) = 0 if |bx| ≥ 1 because of Lem. 19.(i). The condition |bx| ≥ 1 −1 −a surely holds e.g. if |x| > k log dρ ≈ 0 for some k ∈ R>0 because b ≥ dρ ; in particular, it is satisfied if |x| > r for some r ∈ R>0. By the intermediate value theorem (see [23]), ρ δ takes any value in the interval [0, b] ⊆ Re. Similar properties can be stated e.g. for δ2(x) = b2 · ψ(b · x)2. (ii) Analogously, we have H(x) = 1 if |bx| ≥ 1 and x > 0; H(x) = 0 if |bx| ≥ 1 and x < 0; finally 1 H(0) = 2 because of Lem. 19.(i). By the intermediate value theorem, H takes any value in ρ the interval [0, 1] ⊆ Re. 10 GAST¨I¿ŒO S.F. FREDERICO, PAOLO GIORDANO, ALEXANDR A. BRYZGALOV, AND MATHEUS J. LAZO

Figure 2.1. Representations of Dirac delta and Heaviside function

ρ ∞ ρ ρ 2  (iii) The composition δ ◦ δ ∈ GC ( Re, Re) is given by (δ ◦ δ)(x) = bψ b ψ(bx) and is an even function. If |bx| ≥ 1, then (δ ◦ δ)(x) = b. Since (δ ◦ δ)(0) = 0, again using the intermediate ρ value theorem, we have that δ ◦ δ takes any value in the interval [0, b] ⊆ Re. Suitably 1 1 choosing the net (ψε) it is possible to have that if − 2b ≤ x ≤ 2b (hence x is infinitesimal), k then (δ ◦ δ)(x) = 0. If x = b for some k ∈ N>0, then x is still infinitesimal but (δ ◦ δ)(x) = b. Analogously, one can deal with compositions such as H ◦ δ and δ ◦ H. See Fig. 2.1 for a graphical representations of δ and H. The infinitesimal oscillations shown in this figure occur only in an infinitesimal neighborhood of the origin because of (i) in example 22 −1 and because k log dρ ≈ 0. They can be proved to actually occur as a consequence of Lem. 19.(v) which is a necessary property to prove Thm. 20.(i), see [23, 24]. It is well-known that the latter property is one of the core ideas to bypass the Schwartz’s impossibility theorem, see e.g. [29].

2.4. Functionally compact sets and multidimensional integration. 2.4.1. Extreme value theorem and functionally compact sets. For GSF, suitable generalizations of many classical theorems of differential and integral calculus hold: intermediate value theorem, mean value theorems, suitable sheaf properties, local and global inverse function theorems, Banach fixed point theorem and a corresponding Picard-Lindel¨ı¿œf theorem both for ODE and PDE, see [20, 22–24, 46]. Even though the intervals [a, b] ⊆ Re, a, b ∈ R, are not compact in the sharp topology (see [22]), analogously to the case of smooth functions, a ρGCk map satisfies an extreme value theorem on such sets. In fact, we have:

ρ k Theorem 23. Let f ∈ GC (X, Re) be a generalized Ck function defined on the subset X of Ren. Let ∅= 6 K = [Kε] ⊆ X be an internal set generated by a sharply bounded net (Kε) of compact sets n Kε b R , then ∃m, M ∈ K ∀x ∈ K : f(m) ≤ f(x) ≤ f(M). (2.5) CALCULUS OF VARIATIONS AND OPTIMAL CONTROL FOR GF 11

We shall use the assumptions on K and (Kε) given in this theorem to introduce a notion of “compact subset” which behaves better than the usual classical notion of compactness in the sharp topology.

n n Definition 24. A subset K of Re is called functionally compact, denoted by K bf Re , if there exists a net (Kε) such that n (i) K = [Kε] ⊆ Re . ρ (ii) ∃R ∈ Re>0 : K ⊆ BR(0), i.e. K is sharply bounded. n (iii) ∀ε ∈ I : Kε b R . n If, in addition, K ⊆ U ⊆ Re then we write K bf U. Finally, we write [Kε] bf U if (ii), (iii) and [Kε] ⊆ U hold. Any net (Kε) such that [Kε] = K is called a representative of K. We motivate the name functionally compact subset by noting that on this type of subsets, GSF have properties very similar to those that ordinary smooth functions have on standard compact sets. Remark 25.

(i) By Thm.7.(iii), any internal set K = [Kε] is closed in the sharp topology. In particular, the open interval (0, 1) ⊆ Re is not functionally compact since it is not closed. n (ii) If H b R is a non-empty ordinary compact set, then the internal set [H] is functionally compact. In particular, [0, 1] = [[0, 1]R] is functionally compact. (iii) The empty set ∅ = e∅ bf Re. (iv) Ren is not functionally compact since it is not sharply bounded. (v) The set of compactly supported points c(R) is not functionally compact because the GSF f(x) = x does not satisfy the conclusion (2.5) of Thm. 23. In the present paper, we need the following properties of functionally compact sets.

n ρ k d n d Theorem 26. Let K ⊆ X ⊆ Re , f ∈ GC (X, Re ). Then K bf Re implies f(K) bf Re . As a corollary of this theorem and Rem. (25).(ii) we get

Corollary 27. If a, b ∈ Re and a ≤ b, then [a, b] bf Re. Let us note that a, b ∈ Re can also be infinite numbers, e.g. a = dρ−N , b = dρ−M or a = −dρ−N , b = dρ−M with M > N, so that e.g. [−dρ−N , dρM ] ⊇ R. Finally, in the following result we consider the product of functionally compact sets:

n d n+d Theorem 28. Let K bf Re and H bf Re , then K × H bf Re . In particular, if ai ≤ bi for Qn n i = 1, . . . , n, then i=1[ai, bi] bf Re . A theory of compactly supported GSF has been developed in [20], and it closely resembles the classical theory of LF-spaces of compactly supported smooth functions. It establishes that for suit- able functionally compact subsets, the corresponding space of compactly supported GSF contains extensions of all Colombeau generalized functions, and hence also of all Schwartz distributions. As in the classical case (see e.g. [19]), thanks to the extreme value theorem 23 and the property ρ k ρ of functionally compact sets K, we can naturally define a topology on the space GC (K, Red):

◦ ρ n Definition 29. Let K bf Re be a functionally compact set such that K = K (so that partial derivatives at sharply boundary points can be defined as limits of partial derivatives at sharply ρ k ρ d interior points; such K are called solid sets). Let l ∈ N≤k and v ∈ GC (K, Re ). Then α i α i  ρ kvkl := max max ∂ v (Mni) , ∂ v (mni) ∈ Re, |α|≤l 1≤i≤d where Mni, mni ∈ K satisfy α i α i α i ∀x ∈ K : ∂ v (mni) ≤ ∂ v (x) ≤ ∂ v (Mni). 12 GAST¨I¿ŒO S.F. FREDERICO, PAOLO GIORDANO, ALEXANDR A. BRYZGALOV, AND MATHEUS J. LAZO

The following result (see [41]) permits us to calculate the (generalized) norm kvkl using any net (vε) that defines v.

ρ n Lemma 30. Under the assumptions of Def. 29, let [Kε] = K bf Re be any representative of K. Then we have:   α i ρ (i) If the net (vε) defines v, then kvkl = max |α|≤l maxx∈Kε ∂ vε(x) ∈ Re; 1≤i≤d (ii) kvkl ≥ 0; (iii) kvkl = 0 if and only if v = 0; ρ (iv) ∀c ∈ Re : kc · vkl = |c| · kvkl; ρ k ρ d (v) For all u ∈ GC (K, Re ), we have ku + vkl ≤ kukl + kvkl and ku · vkl ≤ cl · kukl · kvkl for ρ some cl ∈ Re>0.

ρ ρ k ρ Using these Re-valued norms, we can naturally define a topology on the space GC (K, Red).

ρ n ρ k ρ d ρ Definition 31. Let K bf Re be a solid set. Let l ∈ N≤k, u ∈ GC (K, Re ), r ∈ Re>0, then l n ρ k ρ d o (i) Br(u) := v ∈ GC (K, Re ) | kv − ukl < r ρ k ρ (ii) If U ⊆ GC (K, Red), then we say that U is a sharply open set if

ρ l ∀u ∈ U ∃l ∈ N≤k ∃r ∈ Re>0 : Br(u) ⊆ U. One can easily prove that sharply open sets form a sequentially Cauchy complete topology on ρ k ρ d ρ k ρ d  GC (K, Re ), see e.g. [21, 47]. The structure GC (K, Re ), (k−kl)l≤k has the usual properties ρ of a graded Fr¨ı¿œchet space if we replace everywhere the field R with the ring Re, and for this ρ reason it is called an Re-graded Fr¨ı¿œchet space.

2.4.2. Multidimensional integration. Finally, to deal with higher-order calculus of variations, we ρ have to introduce multidimensional integration of GSF on suitable subsets of Ren (see [23]).

ρ Definition 32. Let µ be a measure on Rn and let K be a functionally compact subset of Ren. Then, we call K µ-measurable if the limit

E µ(K) := lim [µ(B ρm (Kε))] (2.6) m→∞ ε exists for some representative (Kε) of K. Here m ∈ N, the limit is taken in the sharp topology on ρ ρ n since [µ(BE m (K ))] ∈ , and BE (A) := {x ∈ : d(x, A) ≤ r}. Re ρε ε Re r R In the following result, we show that this definition generates a correct notion of multidimensional integration for GSF.

ρ Theorem 33. Let K ⊆ Ren be µ-measurable.

(i) The definition of µ(K) is independent of the representative (Kε). (ii) There exists a representative (Kε) of K such that µ(K) = [µ(Kε)]. ρ ∞ ρ (iii) Let (Kε) be any representative of K and let f ∈ GC (K, Re) be a GSF defined by the net (fε). Then   ρ f dµ := lim fε dµ ∈ e m→∞ R ˆK ˆBE m (K ) ρε ε

exists and its value is independent of the representative (Kε). (iv) There exists a representative (Kε) of K such that   ρ f dµ = fε dµ ∈ Re (2.7) ˆK ˆKε

ρ ∞ ρ for each f ∈ GC (K, Re). CALCULUS OF VARIATIONS AND OPTIMAL CONTROL FOR GF 13

Qn n (v) If K = i=1[ai, bi], then K is λ-measurable (λ being the Lebesgue measure on R ) and for ρ ∞ ρ all f ∈ GC (K, Re) we have

" b1,ε bn,ε # ρ f dλ = dx1 ... fε(x1, . . . , xn) dxn ∈ Re ˆK ˆa1,ε ˆan,ε

for any representatives (ai,ε), (bi,ε) of ai and bi respectively. Therefore, if n = 1, this notion of integral coincides with that of Thm. 13 and Def. 14. ρ ρ ∞ ρ (vi) Let K ⊆ Ren be λ-measurable, where λ is the Lebesgue measure, and let ϕ ∈ GC (K, Red) ρ ∞ ρ be such that ϕ−1 ∈ GC (ϕ(K), Ren). Then ϕ(K) is λ-measurable and

f dλ = (f ◦ ϕ) |det(dϕ)| dλ ˆϕ(K) ˆK

ρ ∞ ρ for each f ∈ GC (ϕ(K), Re).

3. Higher-order calculus of variations for generalized functions In this section we prove for GSF the higher-order Euler-Lagrange equation, the du Bois- Reymond optimality condition and the Noether’s theorem. We start with some definition of basic notions and notations. Using the sharp topology of Def. 31, we can define when a curve is a minimizer of a given functional. Note explicitly that there are no ρ restrictions on the generalized numbers a, b ∈ Re, a < b, e.g. they can also both be infinite.

ρ Definition 34. Let t1, t2 ∈ Re, with t1 < t2, and let m ∈ N>0, then (i) For all q := q0 , . . . , qm−1, q := q0 , . . . , qm−1 ∈ ρ d×m, we set t1 t1 t1 t2 t2 t2 Re n o ρGC∞ (q , q ; m) := q ∈ ρGC∞([t , t ], ρ d) | q(i)(t ) = qi ∀i = 0, . . . , m − 1, j = 1, 2 . bd t1 t2 1 2 Re j tj

ρ ∞ ρ ∞ ρ ∞ ρ ∞ We simply set GC0 (m) := GCbd(0, 0; m) and GC0 := GCbd(0, 0; 1). The subscript “bd” stands here for “boundary values”. ρ ρ ∞ ρ d ρ ∞ ρ d×(m+1) ρ (ii) Let t1, t2 ∈ Re with t1 < t2. Let q ∈ GC ([t1, t2], Re ) and L ∈ GC ([t1, t2]× Re , Re) and define

m  (1) (m)  [q] (t) := t, q(t), q (t), . . . , q (t) ∀t ∈ [t1, t2] (3.1)

m  (1) (m)  L[q] (t) :=L t, q(t), q (t), . . . , q (t) ∀t ∈ [t1, t2] (3.2)

t2 m ρ J[q] := L[q] (t) dt ∈ Re. (3.3) ˆt1 Note explicitly that Thm. (iv).9 (closure of GSF with respect to composition) and Def. 14 of 1-dimensional integral of GSF (i.e. Thm. 13) allows us to say that J(q) is a well-defined ρ number in Re. ρ ∞ ρ ∞ (iii) We say that q is a local minimizer of J in GCbd(qt1 , qt2 ; m) if q ∈ GCbd(qt1 , qt2 ; m) and

ρ l ρ ∞ ∃r ∈ Re>0 ∃l ∈ N ∀p ∈ Br(q) ∩ GCbd(qt1 , qt2 ; m): J(p) ≥ I(q) (3.4)

ρ ∞  ρ  (iv) Let q ∈ GC [t1, t2], Re . We define the first and second variation of J in direction ρ ∞ h ∈ GC0 (m) at q as 2 d 2 d δJ(q; h) := J(q + sh) δ J(q; h) := 2 J(q + sh) . ds s=0 d s s=0

ρ ∞ The GSF q is called weak extremal of J if δJ(q; h) = 0 for all h ∈ GC0 (m). 14 GAST¨I¿ŒO S.F. FREDERICO, PAOLO GIORDANO, ALEXANDR A. BRYZGALOV, AND MATHEUS J. LAZO

ρ ∞  ρ  ρ ∞ ρ d×(m+1) ρ (v) More generally, if q ∈ GC [t1, t2], Re and Q ∈ GC ([t1, t2]× Re , Re), we say that ρ ∞ J satisfies at q the D’Alembert’s principle with generalized forces Q if for all h ∈ GC0 (m):

t2 t s1 sm−1 ! (m) m δJ(q; h) = h (t) · ... Q[q] (sm) dsm ... ds2 ds1 dt. ˆt1 ˆt1 ˆt1 ˆt1 | {z } m times The following results establish classical necessary and sufficient conditions to decide if a function u is a local minimizer for the functional (3.3).

ρ ρ ∞ ρ d×(m+1) ρ ρ d Theorem 35. Let t1, t2 ∈ Re with t1 < t2, let L ∈ GC ([t1, t2]× Re , Re), let qt1 , qt2 ∈ Re ρ ∞ and let q be a local minimizer of J in GCbd(qt1 , qt2 ; m). Then ρ ∞ (i) δJ(q; h) = 0 for all h ∈ GC0 (m); 2 ρ ∞ (ii) δ J(q; h) ≥ 0 for all h ∈ GC0 (m).

ρ ρ ∞ ρ Proof. Let r ∈ Re>0 be such that (3.4) holds. Since h ∈ GC0 (m), the map s ∈ Re 7→ q + sh ∈ ρ ∞ GCbd(qt1 , qt2 ; m) is well defined and continuous with respect to the trace of the sharp topology in ρ l ρ ∞ its codomain. Therefore, we can findr ¯ ∈ Re>0 such that q + sh ∈ Br(q) ∩ GCbd(qt1 , qt2 ; m) for all ρ s ∈ Br¯(0). We hence have J(q +sh) ≥ J(q). This shows that the GSF s ∈ Br¯(0) 7→ J(q +sh) ∈ Re has a local minimum at s = 0. Now, we apply Lem. 18 and thus the claims are proven.  ρ ρ d ρ ∞ Theorem 36. Let t1, t2 ∈ Re with t1 < t2 and qt1 , qt2 ∈ Re . Let q ∈ GCbd(qt1 , qt2 ; m) be such that ρ ∞ (i) δJ(q; h) = 0 for all h ∈ GC0 (m). 2 ρ ∞ l ρ ∞ ρ (ii) δ J(v; h) ≥ 0 for all h ∈ GC0 (m) and for all v ∈ Br(q) ∩ GCbd(qt1 , qt2 ; m), where r ∈ Re>0 and l ∈ N. ρ ∞ 2 Then q is a local minimizer of the functional J in GCbd(qt1 , qt2 ; m). Moreover, if δ J(v; h) > 0 for ρ ∞ l ρ ∞ all h ∈ GC0 (m) such that khkl > 0 and for all v ∈ B2r(u) ∩ GCbd(qt1 , qt2 ; m), then J(v) > J(q) l ρ ∞ for all v ∈ Br(q) ∩ GCbd(qt1 , qt2 ; m) such that kv − qkl > 0.

l ρ ∞ ρ Proof. For any v ∈ Br(q) ∩ GCbd(qt1 , qt2 ; m), we set ψ(s) := J(q +s(v −q)) ∈ Re for all s ∈ B1(0), l ρ ∞ so that q + s(v − q) ∈ Br(q). Since (v − q)(t1) = 0 = (v − q)(t2), we have v − q ∈ GC0 (m), and properties (i), (ii) yield ψ0(0) = δJ(q; v − q) = 0 and ψ00(s) = δ2J(q + s(v − q); v − q) ≥ 0 for all s ∈ B1(0). We claim that s = 0 is a minimum of ψ. In fact, for all s ∈ B1(0) by Taylor’s Thm. 17 s2 ψ(s) = ψ(0) + sψ0(0) + ψ00(ξ) 2 0 s2 00 for some ξ ∈ [0, s]. But ψ (0) = 0 and hence ψ(s) − ψ(0) = 2 ψ (ξ) ≥ 0. Finally, since by Thm.7.(iii) the interval [0 , +∞) is closed in the sharp topology lim ψ(s) = J(v) ≥ ψ(0) = J(u), s→1− 2 ρ ∞ which is our conclusion. Note explicitly that if δ J(v; h) = 0 for all h ∈ GC0 (m) and for all l ρ ∞ 00 v ∈ Br(u) ∩ GCbd(qt1 , qt2 ; m), then ψ (ξ) = 0 and hence J(v) = J(q). 2 ρ ∞ Now, assume that δ J(v; h) > 0 for all h ∈ GC0 (m) such that khkl > 0 and for all v ∈ l ρ ∞ l ρ ∞ B2r(u) ∩ GCbd(qt1 , qt2 ; m), and take v ∈ Br(u) ∩ GCbd(qt1 , qt2 ; m) such that kv − qkl > 0. As ρ l above set ψ(s) := J(q + s(v − q)) ∈ Re for all s ∈ B3/2(0), so that q + s(v − q) ∈ B2r(q). We 0 00 2 have ψ (0) = 0 and ψ (s) = δ J(q + s(v − q); v − q) > 0 for all s ∈ B3/2(0) because kv − ukl > 0. 1 00 Using Taylor’s theorem, we get ψ(1) = ψ(0) + 2 ψ (ξ) for some ξ ∈ [0, 1]. Therefore ψ(1) − ψ(0) = 1 00 J(v) − J(q) = 2 ψ (ξ) > 0.  In the following, we always assume the notations of Def. 34. Moreover, we also set

ρ n ρ o Red[t] := p ∈ Re[t] | deg(p) ≤ d

ρ for the set of all the polynomials with coefficients in the ring Re having degree less of equal to d ∈ N. CALCULUS OF VARIATIONS AND OPTIMAL CONTROL FOR GF 15

In order to prove the higher-order version of the fundamental lemma, we need the following

ρ ρ ∞  ρ  b Lemma 37. Let a, b ∈ Re be such that a < b, and let f ∈ GC [a, b], Re≥0 . If a f(t) dt = 0, then f = 0. ´

Proof. By contradiction, assume that f(x) 6= 0 for some x ∈ [a, b]. Let (fε) be a net of smooth functions that define the GSF f and let [xε] = x be a representative of x. The property

0 q ∀q ∈ N ∀ ε : fε(xε) ≤ ρε (3.5) implies f(x) ≤ dρq and hence also, letting q → +∞, f(x) ≤ 0. Since f(x) ≥ 0, this would imply f(x) = 0. Therefore, taking the negation of (3.5) we get

q ∃q ∈ N ∃L ⊆ I : 0 ∈ L, ∀ε ∈ L : fε(xε) > ρε,

¯ ¯ 1 q where L is the closure of L in I. Set fε := fε for ε ∈ L and fε := 2 (fε + ρε) otherwise. Directly ¯  ¯  ρ ∞ ρ ¯ q+1 from Def.8, it follows that f := fε(−) ∈ GC ([a, b], Re≥0) and f(x) > dρ . The sharp continuity of f¯ at x (Thm.9.(ii)) implies

¯ q+1 ∃c, d : c < d, [c, d] ⊆ [a, b], f|[c,d] > dρ . (3.6)

Moreover, from f ≥ 0 and Thm. 15 we obtain

b c d b d 0 = f ≥ f + f + f ≥ f. ˆa ˆa ˆc ˆd ˆc

dε Thereby, we can find a negligible net [zε] = 0 such that zε ≥ fε for all ε sufficiently small, cε where [cε] = c,[dε] = d with cε < dε because c < d (see Lem.´ 3). In particular, for ε ∈ L ¯ dε dε ¯ sufficiently small fε = fε and hence fε = fε ≤ zε. But then (3.6) and Thm. 15.(vii) yield cε cε ´ ´ dε dε 0 ¯ q+1 q+1 ∀ ε ∈ L : zε ≥ fε ≥ ρε = ρε (dε − cε) . ˆcε ˆcε h i Therefore, ρq+1 ≤ zε . However, zε = [zε] = 0 and hence ρq+1 ≤ ρq+2 by (2.1), a ε dε−cε dε−cε d−c ε ε contradiction. 

3.1. Higher-order Euler–Lagrange equation, D’Alembert principle and du Bois–Rey- mond optimality condition. In this section, we first compute the first variation δJ(q; h) and thereby we deduce the Euler-Lagrange equations both in integral and differential forms, and the D’Alembert principle in differential form.

ρ ∞  ρ  ρ ∞ Lemma 38. If q ∈ GC [t1, t2], Re and h ∈ GC0 (m), then

" m !# t2 X t s1 sm−i−1   δJ(q; h) = h(m)(t)· (−1)i ... ∂ L[q]m(s ) ds ... ds ds dt. ˆ ˆ ˆ ˆ i+2 m−i m−i 2 1 t1 i=0 t1 t1 t1 | {z } m−i times

ρ ∞ Proof. According to Def. 34, and to Thm. 15 for any h ∈ GC0 (m) we have

m ! t2 X δJ(q; h) = ∂ L[q]m(t) · h(i)(t) dt. (3.7) ˆ i+2 t1 i=0 16 GAST¨I¿ŒO S.F. FREDERICO, PAOLO GIORDANO, ALEXANDR A. BRYZGALOV, AND MATHEUS J. LAZO

By repeated integration by parts (Thm. 15.(vi)) one has

m X t2 ∂ L[q]m(t) · h(i)(t) dt ˆ i+2 i=0 t1 m ("m−i !#t2 X X t s1 sj−1   = (−1)j+1h(i+j−1)(t) · ... ∂ L[q]m(s ) ds ... ds ds ˆ ˆ ˆ i+2 j j 2 1 i=0 j=1 t1 t1 t1 | {z } t1 j times

t2 t s1 sm−i−1 ! ) i (m)  m  + (−1) h (t) · ... ∂i+2L[q] (sm−i) dsm−i ... ds2 ds1 dt (3.8) ˆt1 ˆt1 ˆt1 ˆt1 | {z } m−i times

(i) (i) Since h (t1) = 0 = h (t2), i = 0, . . . , m − 1, the first summands in (3.8) vanish. Therefore, equations (3.7) and (3.8) yield the conclusion. 

In order to prove the Euler-Lagrange equation in integral form (see below Cor. 41), we first need to show the higher order du Bois–Reymond lemma of the calculus of variations for generalized functions.

ρ Lemma 39 (Fundamental higher order du Bois–Reymond lemma). Let a, b ∈ Re be such that ρ ∞  ρ  a < b, and let f ∈ GC [a, b], Re . If

b (m) ρ ∞ f(t)h (t) dt = 0 for all h ∈ GC0 (m) (3.9) ˆa

ρ Then f(t) ∈ Rem−1[t]. Proof. We generalize the proof of [63, Lem. 4.1]. Considering the change of variable t 7→ f(t + a), without loss of generality we may assume a = 0. Note that the last apparently trivial step is correct because our generalized functions are ordinary set-theoretical functions (and hence their pointwise evaluation is obvious; it is well-known, see e.g. [45], that this is not the case for Sobolev- Schwartz distributions), and because GSF are close with respect to composition, Thm.9 (e.g. this step would be possible for Colombeau generalized functions only if a is finite, see e.g. [29]). The composition of primitives

t x1 x2 xm−1 H(t) := ... f(x) dx1 ... dxn−1 dx ∀t ∈ [0, b] (3.10) ˆ0 ˆ0 ˆ0 ˆ0

ρ ∞ ρ is a GSF H ∈ GC ([0, b], Re) because of Def. 14 and of Thm.9. By repeated application of Def. 14 we have that H(m)(t) = f(t) for all t ∈ [0, b] and H(k)(0) = 0 for k = 0, . . . , m − 1. We note that b > 0, so that b is invertible, and we can recursively define

−m z0 := b H(b) k −m (k+1) X −j−1 zk+1 := b H (b) − (k + 1) m(m − 1) · ... · (m − j)b · zk−j ∀k = 0, . . . , m − 2. j=0 (3.11)

Pm−1 zk k ρ m ρ (m) Finally, set z(t) := k=0 k! (t − b) ∈ Rem−1[t], P (t) := t z(t) ∈ Rem−1[t], p(t) := P (t) ∈ ρ (k) (k) (k) Rem−1[t] and h(t) := H(t) − P (t). In this way, we have h (0) = H (0) − P (0) = 0, hence ρ ∞ h ∈ GC0 (m), and, from (3.11):

k−1 (k) (k) m X m−j−1 h (b) = H (b) − b zk − k m(m − 1) · ... · (m − j)b · zk−1−j = 0 ∀k = 0, . . . , m − 1. j=0 CALCULUS OF VARIATIONS AND OPTIMAL CONTROL FOR GF 17

By these boundary equalities of h at 0 and b, and by repeated integration by parts, we get b b b p(t)h(m)(t) dt = − p0(t)h(m−1)(t) dt = ··· = p(m)(t)h(t) dt = 0 (3.12) ˆ0 ˆ0 ˆ0 ρ (m) 2 (m) because p ∈ Rem−1[t]. Since h (t) = f(t) − p(t), we have (f(t) − p(t)) = (f(t) − p(t))h (t) and hence (3.12), Thm. 15.(vii) and assumption (3.9) yield b b b 0 ≤ (f(t) − p(t))2 dt = (f(t) − p(t))h(m)(t) dt = f(t)h(m)(t) dt = 0. ˆ0 ˆ0 ˆ0 Therefore, the conclusion f(t) = p(t) follows from Lem. 37.

 As a simple consequence, we have the following

ρ ρ ∞ ρ Corollary 40. Let a, b ∈ Re be such that a < b, and let f, g ∈ GC ([a, b], Re). If b 0 ρ ∞ (f(t)h(t) + g(t)h (t)) dt = 0 for all h ∈ GC0 , ˆa then g0 = f. In particular, for g = 0, if b ρ ∞ f(t)h(t) dt = 0 for all h ∈ GC0 , ˆa then f = 0.

x ρ ∞ ρ 0 Proof. Set F (x) := a f(t) dt for x ∈ [a, b], so that F ∈ GC ([a, b], Re) and F = f by Def. 14. Integrating by parts´ (Thm. 15.(vi)), we get b b (f(t)h(t) + g(t)h0(t)) dt = (g(t) − F (t)) h0(t) dt = 0 ˆa ˆa ρ ∞ ρ for all h ∈ GC0 . Therefore, Lem. 39 implies that g(t) − F (t) is a constant (in Re), and hence 0 0 g = F = f as claimed.  Applying the higher-order du Bois–Reymond Lem. 39, we arrive at the first form of the Euler- Lagrange equations:

ρ ∞  ρ  Corollary 41. If q ∈ GC [t1, t2], Re is a weak extremal of functional (3.3), then q satisfies the following higher-order Euler–Lagrange integral equation:

m t s1 sm−i−1 ! X i  m  ρ (−1) ... ∂i+2L[q] (t) dsm−i ... ds1 ∈ em−1[t]. (3.13) ˆ ˆ ˆ R i=0 t1 t1 t1 | {z } m−i times Taking the derivative of order m to (3.13), we obtain

ρ ∞  ρ  Corollary 42 (Higher-order Euler–Lagrange equations in differential form). If q ∈ GC [t1, t2], Re is a weak extremal of functional (3.3), then m X di (−1)i ∂ L[q]m(t) = 0 ∀t ∈ [t , t ]. (3.14) dti i+2 1 2 i=0 Finally, Lem. 38 and Def. 34.(v) yield the D’Alembert principle in differential form:

ρ ∞  ρ  ρ ∞ ρ d×(m+1) ρ Corollary 43. Let q ∈ GC [t1, t2], Re , Q ∈ GC ([t1, t2] × Re , Re) and assume that J satisfies at q the D’Alembert’s principle with generalized forces Q, then m X di (−1)i ∂ L[q]m(t) = Q[q]m(t) ∀t ∈ [t , t ]. dti i+2 1 2 i=0 18 GAST¨I¿ŒO S.F. FREDERICO, PAOLO GIORDANO, ALEXANDR A. BRYZGALOV, AND MATHEUS J. LAZO

Proof. In fact, we have

t2 t s1 sm−1 ! (m) m δJ(q; h) − h (t) · ... Q[q] (sm) dsm ... ds2 ds1 dt = ˆt1 ˆt1 ˆt1 ˆt1 | {z } m times  m ! t2 X t s1 sm−i−1   = h(m)(t) ·  (−1)i ... ∂ L[q]m(s ) ds ... ds ds − ˆ  ˆ ˆ ˆ i+2 m−i m−i 2 1 t1 i=0 t1 t1 t1 | {z } m−i times 

t s1 sm−1 ! m  − ... Q[q] (sm) dsm ... ds2 ds1  dt = 0. ˆt1 ˆt1 ˆt1  | {z } m times Thereby, Lem. 39 gives

m ! X t s1 sm−i−1   (−1)i ... ∂ L[q]m(s ) ds ... ds ds − ˆ ˆ ˆ i+2 m−i m−i 2 1 i=0 t1 t1 t1 | {z } m−i times

t s1 sm−1 ! m ρ − ... Q[q] (sm) dsm ... ds2 ds1 ∈ Rem−1[t]. ˆt1 ˆt1 ˆt1 | {z } m times

Taking the derivative of order m yields the conclusion. 

ρ ∞  ρ  Associated to a given function q ∈ GC [t1, t2], Re , it is convenient to introduce the following quantities (see [18]):

m−j X di ϕj(q)(t) := (−1)i ∂ L[q]m(t) ∀j = 0, . . . , m ∀t ∈ [t , t ] (3.15) dti i+j+2 1 2 i=0 These operators are useful for our purposes because of the following properties: d ϕj(q) = ∂ L[q]m − ϕj−1(q) ∀j = 1, . . . , m. (3.16) dt j+1 We are now in conditions to prove a higher-order du Bois–Reymond optimality condition.

ρ ∞  ρ d Theorem 44. If q ∈ GC [t1, t2], Re is a weak extremal of functional (3.3), then

 m  d X L[q]m − ϕj(q) · q(j) = ∂ L[q]m. (3.17) dt   1 j=1

Proof. Using, for simplicity, ϕj := ϕj(q), we have

 m  d X L[q]m − ϕj · q(j) = dt   j=1

 m m  m X m (j+1) X  j (j) j (j+1) = ∂1L[q] + ∂j+2L[q] · q − ϕ˙ · q + ϕ · q  . (3.18) j=0 j=1 CALCULUS OF VARIATIONS AND OPTIMAL CONTROL FOR GF 19

Using (3.16), equation (3.18) becomes

 m  m d X X L[q]m − ϕj · q(j) = ∂ L[q]m + ∂ L[q]m · q(j+1) dt   1 j+2 j=1 j=0 m X  m j−1 (j) j (j+1) − ∂j+1L[q] − ϕ · q + ϕ · q . (3.19) j=1 We now simplify the second term on the right-hand side of (3.19), which forms a telescopic sum:

m X  m j−1 (j) j (j+1) ∂j+1L[q] − ϕ · q + ϕ · q = j=1 m−1 X  m j (j+1) j+1 (j+2) = ∂j+2L[q] − ϕ · q + ϕ · q = j=0 m−1 X  m (j+1) 0 m (m+1) = ∂j+2L[q] · q − ϕ · q˙ + ϕ · q . (3.20) j=0 Substituting (3.20) into (3.19) and using the higher-order Euler–Lagrange equations (3.14), and since, by definition, m m ϕ = ∂m+2L[q] and m X di ϕ0 = (−1)i ∂ L[q]m = 0 , dti i+2 i=0 we obtain the intended result, that is,

 m  d X L[q]m − ϕj · q(j) = dt   j=1 m m (m+1) = ∂1L[q] + ∂m+2L[q] · q 0 m (m+1) m + ϕ · q˙ − ϕ · q = ∂1L[q] .  3.2. Higher-order Noether’s theorem. In our approach to Noether’s theorem, we can use the ρ non-Archimedean language of Re to formalize some infinitesimal properties frequently informally used in this topic.

ρ k ρ ∞ Definition 45. Let D ⊆ Re be a sharply open set. We say that Ψ = {ψ(s, ·)}s∈P ∈ GC (D,D) is a one parameter group of diffeomorphisms of D if it satisfies: (i) P is a sharply open set, 0 ∈ P and ψ ∈ ρGC∞(P × D,D); (ii) For each s ∈ P , the map ψ(s, ·) ∈ ρGC∞(D,D) is invertible, and ψ(s, ·)−1 ∈ ρGC∞(D,D); (iii) ψ(0, ·) = IdD; (iv) ∀s, s0 ∈ P : s + s0 ∈ P ⇒ ψ(s, ·) ◦ ψ(s0, ·) = ψ(s + s0, ·).

ρ We will see on Sec. 5.5 the actual usefulness of the case D ⊂ Rek. Note that, because of properties (i) and (iii), from Taylor’s formula Thm. 17, we get

ρ ∂ψ ∃S ∈ e>0 ∀s ∈ [0,S] ∩ P : ψ(s, q(t)) ≈ q(t) + s (0, q(t)). R ∂s Therefore, for a sufficiently small infinitesimal s, we can always say that ψ(s, t) is infinitely close to ∂ψ a transformation of the form q(t) 7→ q(t) + sη(q(t)), where η(q) := ∂s (0, q). To write an equality ∂ψ sign instead of the infinitely close sign ≈, we can use Thm. 11 and the notation ∂s [0, q(t); s] for 20 GAST¨I¿ŒO S.F. FREDERICO, PAOLO GIORDANO, ALEXANDR A. BRYZGALOV, AND MATHEUS J. LAZO the generalized partial incremental ratio with respect to the variable s (we recall that it is another GSF):

ρ ∂ψ ∃S ∈ e>0 ∀s ∈ [0,S] ∩ P : ψ(s, q(t)) = q(t) + s [0, q(t); s] R ∂s ∂ψ ∂ψ [0, q(t); s] ≈ (0, q(t)). ∂s ∂s ρ ∞ 0 0 ρ ∞ 0 0 Definition 46. Let both T = {τ(s, ·)}s∈P ∈ GC (T ,T ) and S = {σ(s, ·)}s∈P ∈ GC (S ,S ) 0 0 ρ d be one parameter groups of diffeomorphims on the open sets T ⊆ [t1, t2] and S ⊆ Re respectively. The functional (3.3) is said to be invariant under the action of T and S, if for any weak extremal ρ ∞ 0 q ∈ GC ([t1, t2],S ) it satisfies  dσ(s, q(t)) dmσ(s, q(t)) ∂τ L[q]m(t) = L τ(s, t), σ(s, q(t)), ,..., (s, t) (3.21) dτ(s, t) dτ m(s, t) ∂t

i 0 d σ(s,q(t)) for all s ∈ P and all t ∈ T , where the expressions dτ i(s,t) , i = 1, . . . , m are defined in the following Rem. 47.(ii). Remark 47. (i) From Def. 45.(ii) we have τ s, τ(s, ·)−1(t) = t, thereby the chain rule Thm. 12 yields that ∂τ 0 ∂t (s, t) is invertible for all s ∈ P , t ∈ T . diσ(s,q(t)) (ii) Based on the previous remark, in (3.21) the expressions dτ i(s,t) , i = 1, . . . , m are defined as dσ(s, q(t)) ∂σ(s,q(t)) (s, t) := ∂t , (3.22) dτ(s, t) ∂τ ∂t (s, t) and  di−1σ(s,q(t))  i ∂ d σ(s, q(t)) ∂t dτ i−1(s,t) (s, t) := , ∀i = 2, . . . , m. (3.23) dτ i(s, t) ∂τ ∂t (s, t) i d σ(0,q(t)) (i) As usual, because of Def. 45.(iii), we have dτ i(0,t) = q (t). (iii) Using again the generalized incremental ratios, i.e Thm. 11, for all s ∈ P , all t ∈ T 0 and for ρ h ∈ Re sufficiently small, we have ∂σ(s, q(t)) σ(s, q(t + h)) = σ(s, q(t)) + h · [s, t; h] ∂t ∂τ τ(s, t + h) = τ(s, t) + h · [s, t; h]. ∂t Therefore, the ratio (of differentials):

σ(s, q(t + h)) − σ(s, q(t)) ∂σ(s,q(t)) [s, t; h] ∂σ(s,q(t)) (s, t) = ∂t ≈ ∂t τ(s, t + h) − τ(s, t) ∂τ ∂τ ∂t [s, t; h] ∂t (s, t) for all sufficiently small invertible h. (iv) On the basis of Def. 14, condition (3.21) is equivalent to

tb tb  m  m dσ(s, q(t)) d σ(s, q(t)) ∂τ L[q] (t) dt = L τ(s, t), σ(s, q(t)), ,..., m (s, t) dt ˆta ˆta dτ(s, t) dτ (s, t) ∂t 0 for all s ∈ P and for any subinterval [ta, tb] ⊆ T with ta < tb, even if L can also be a distribution. Clearly, if L is not a , this equivalence is due to the ρ ∞ ρ regularization process inherent to the embedding ιb : D0 −→ GC (c(−), Re) of Sec. 2.3. The next lemma gives a necessary condition for the functional (3.3) to be invariant under ρ ∞ 0 0 the action of the parameter groups of diffeomorphisms T = {τ(s, ·)}s∈P ∈ GC (T ,T ) and ρ ∞ 0 0 S = {σ(s, ·)}s∈P ∈ GC (S ,S ). CALCULUS OF VARIATIONS AND OPTIMAL CONTROL FOR GF 21

Lemma 48. If the functional (3.3) is invariant in the sense of Def. 46, then

m ∂L[q]m ∂τ ∂τ X ∂L[q]m d ∂τ (0, t) + (0, t) · ηi(q, ·) + L[q]m (0, ·) = 0 ∀t ∈ T 0 (3.24) ∂t ∂t ∂t ∂q(i) dt ∂s i=0

ρ ∞ 0 for any weak extremal q ∈ GC ([t1, t2],S ). In (3.24), we set

( 0 ∂σ η (q, ·) := ∂s (0, q(·)), i−1 (3.25) i dη (q,·) (i) d ∂τ η (q, ·) := dt − q dt ∂s (0, ·), ∀i = 1, . . . , m. Proof. Differentiating (3.21) with respect to s at s = 0 ∈ P and t ∈ T 0 and using Rem 47.(ii), we obtain m ∂L[q]m ∂τ ∂τ X ∂L[q]m ∂ diσ(s, q(t)) ∂2τ (0, t) + (0, t) · + L[q]m(t) (0, t) = 0. (3.26) ∂t ∂t ∂t ∂q(i) ∂s dτ i(s, t) ∂s∂t i=0 s=0 Note explicitly that using two times Thm. 11, for any GSF f we always have 2  2   2  ∂ f ∂fε ∂fε (x0, y0) = (x0ε, y0ε) = (x0ε, y0ε) = ∂x∂y ∂xε∂yε ∂yε∂xε 2   ∂ f d ∂f d ∂f = (x0, y0) = (x, y0) = (x0, y0). ∂y∂x dx ∂y dx ∂y x0 Using Rem. 47.(ii) and (3.25), we have

  2 2 ∂ dσ(s, q(t)) ∂ σ(s, q(t)) ∂ τ = (0, t) − q˙(t) (0, t) (3.27) ∂s dτ(s, t) s=0 ∂s∂t ∂s∂t   2 d ∂σ(s, q(t)) ∂ τ = (t) − q˙(t) (0, t) (3.28) dt ∂s s=0 ∂s∂t dη0(q, t) ∂2τ = − q˙(t) (0, t) = η1(q, t), (3.29) dt ∂s∂t and for all i = 2, . . . , m ! ! ∂ diσ(s, q(t)) ∂2 di−1σ(s, q(t)) ∂2τ = − q(i)(t) (0, t) ∂s dτ i(s, t) ∂s∂t dτ i−1(s, t) ∂s∂t s=0 s=0 ! ! d ∂ di−1σ(s, q(t)) ∂2τ = (t) − q(i)(t) (0, t) (3.30) dt ∂s dτ i−1(s, t) ∂s∂t s=0 dηi−1(q, t) ∂2τ = − q(i)(t) (0, t) = ηi(q, t). (3.31) dt ∂s∂t Substituting (3.30) into (3.26), we obtain the conclusion. 

0 m ρ ∞  0 ρ d Definition 49. Let T ⊆ [t1, t2] be a sharply open set. We say that a GSF C[q] (·) ∈ GC T , Re is a constant of motion on T 0, S0 if d C[q]m(t) = 0 ∀t ∈ T 0 (3.32) dt ρ ∞ 0 along all the weak extremals q ∈ GC ([t1, t2],S ). Note that Thm. 13 implies that condition (3.32) is equivalent to ask that C[q]m(·) is constant on any interval J ⊆ T 0. In fact, if t0 ∈ J, F (t) := C[q]m(t) − C[q]m(t0) is the unique GSF such that F (t0) = 0 and F 0(t) = 0 on any closed interval contained in T 0 (and hence on an arbitrary interval by sharp continuity). 22 GAST¨I¿ŒO S.F. FREDERICO, PAOLO GIORDANO, ALEXANDR A. BRYZGALOV, AND MATHEUS J. LAZO

Theorem 50. If functional (3.3) is invariant in the sense of Def. 46, then the quantity C[q]m(t) ρ ∞ 0 0 defined for all q ∈ GC ([t1, t2],S ) and t ∈ T by m m ! X X ∂τ C[q]m(t) := ϕi(q, t) · ηi−1(q, t) + L[q]m(t) − ϕi(q, t) · q(i)(t) (0, t) (3.33) ∂s i=1 i=1 is a constant of motion on T 0 and S0. Proof. The proof follows directly from the previous results and no specific property of GSF is needed. For simplicity, we use the notations ϕi := ϕi(q, ·) and ηi := ηi(q, ·).

m m ! X X ∂τ C[q]m(·) = ϕ1 · η0 + ϕi · ρi−1 + L[q]m − ϕi · q(i) (0, ·). (3.34) ∂s i=2 i=1 Differentiating (3.34) with respect to t, we obtain

m d d d X  d d  C[q]m(t) = η0 · ϕ1 + ϕ1 · η0 + ηi−1 · ϕi + ϕi · ρi−1 dt dt dt dt 1 dt i=2 m ! ∂τ d X + (0, ·) L[q]m − ϕi · q(i) ∂s dt i=1 m ! X d ∂τ + L[q]m − ϕi · q(i) (0, ·). (3.35) dt ∂s i=1 Using the higher order Euler–Lagrange equation (3.14), the higher order du Bois–Reymond con- dition (3.17), relations (3.15) and (3.25) in (3.35), one gets

d ∂σ  d ∂τ  C[q]m(t) = ∂ L[q]m · (0, q(·)) + ϕ1 · η1 +q ˙ (0, ·) dt 2 ∂s dt ∂s m X   d ∂τ  + ∂ L[q]m − ϕi−1 · ηi−1 + ϕi · ηi + q(i) (0, ·) i+1 dt ∂s i=2 m ! ∂τ X d ∂τ + ∂ L[q]m (0, ·) + L[q]m − ϕi · q(j) (0, ·) 1 ∂s dt ∂s i=1 ∂τ d ∂τ ∂σ = ∂ L[q]m (0, ·) + L[q]m (0, ·) + ∂ L[q]m · (0, q(·)) 1 ∂s dt ∂s 2 ∂s  d ∂τ  + ϕ1 · η1 +q ˙ (0, ·) − ϕ1 · η1 dt ∂s m d ∂τ X − ϕ1 · q˙ (0, ·) + ϕm · ηm + ∂ L[q]m · ηi−1 = 0. (3.36) dt ∂s i+1 i=2 

4. Optimal control problems Thm. 50 gives a Lagrangian formulation of Noether’s principle extended to the generalized smooth functions setting. In this section, we adopt the Hamiltonian formalism in order to gener- alize Noether’s principle to the wider context of optimal control, see e.g. [13]. Let us consider the optimal control problem for GSF in Lagrange form, i.e. the minimization of the functional: t2 L (t, q(t), u(t)) dt −→ min (4.1) ˆt1 subject to the Cauchy problem CALCULUS OF VARIATIONS AND OPTIMAL CONTROL FOR GF 23

( q˙(t) = ϕ (t, q(t), u(t)) , (CP) q(t1) = q1 . We explicitly note here that, because our generalized functions are set-theoretical maps, and because of the closure with respect to composition, the natural notion of solution for a differential equation with GSF is given by pointwise equality. On the other hand, Thm. 13 and Cor. 40 imply that, for GSF, the notion of pointwise solution is equivalent to that of weak solution. ρ d ρ In problem (4.1)–(CP), q1 ∈ Re , the Lagrangian L :[t1, t2] × H × K −→ Re, the state equation ρ d ϕ :[t1, t2] × H × K −→ Re , the state q :[t1, t2] −→ H and the control u :[t1, t2] −→ K are ρ d ρ l assumed to be GSF with respect to all the arguments, where H bf Re , K bf Re are functionally compact sets. Note that a particular case of this assumption is e.g. H = [−dρ−q, dρ−q]d ⊇ Rd because dρ−q is an infinite number. Since Sobolev-Schwartz distributions can be embedded as GSF (see Sec. 2.3), this is clearly more general than the usual traditional case, where state and control functions are assumed to be piecewise smooth. In particular, we will always consider state and control functions in the following spaces

ρ ∞ q ∈ Q := {q ∈ GC ([t1, t2],H) | kq − q1k0 ≤ r} ρ ∞ u ∈ A := GC ([t1, t2],K),

ρ where r ∈ Re>0 is a fixed generalized radius such that Br(q1) ⊆ H. In this section, we use simplified notations, e.g., of the form L(·, q, q˙) or ϕ(·, q, u) to denote compositions t ∈ [t1, t2] 7→ ρ ρ d L(t, q(t), q˙(t)) ∈ Re and t ∈ [t1, t2] 7→ ϕ(t, q(t), u(t)) ∈ Re . In developing this topic, it is therefore essential to already have suitable results about solutions of ODE with GSF. The Banach fixed point theorem can be easily generalized to spaces of gener- alized continuous functions with the sup-norm k − k0 (see Def. 29). As a consequence, we have the following Picard-Lindel¨ı¿œftheorem for ODE in the ρGCk setting, see [14, 47].

ρ ρ d ρ ρ k ρ d Theorem 51. Let t0 ∈ Re, y0 ∈ Re , α, r ∈ Re>0. Let F ∈ GC ([t0 − α, t0 + α] × Br(y0), Re ). ρ Set M := max |F (t, y)|, L := max |∂yF (t, y)| ∈ Re and assume that t0−α≤t≤t0+α t0−α≤t≤t0+α |y−y0|≤r |y−y0|≤r α · M ≤ r,

lim αnLn = 0, (4.2) n→+∞ where the limit in (4.2) is clearly taken in the sharp topology. Then there exists a unique solution ρ k+1  ρ d y ∈ GC [t0 − α, t0 + α], Re of the Cauchy problem ( y0(t) = F (t, y(t)) (4.3) y(t0) = y0. This solution is given by n y = lim P (y0) n→+∞ t P (y)(t) : = y0 + F (s, y(s)) ds ∀t ∈ [t0 − α, t0 + α], ˆt0 n P+∞ αnLn and for all n ∈ N satisfies ky − P (y0)k0 ≤ αM k=n n! and ky − y0k0 ≤ r. Finally, we have the following Gr¨ı¿œnwall-Bellman inequality in integral form:

ρ ρ k  ρ  Theorem 52. Let α ∈ Re>0. Let u, a, b ∈ GC [0, α], Re and assume that kak0 · α < N · −1 log dρ for some N ∈ N. Assume that a(t) ≥ 0 for all t ∈ [0, α], and that u(t) ≤ b(t) + t 0 a(s)u(s) ds. Then ´ 24 GAST¨I¿ŒO S.F. FREDERICO, PAOLO GIORDANO, ALEXANDR A. BRYZGALOV, AND MATHEUS J. LAZO

(i) For every t ∈ [0, α] we have t t a(r) dr u(t) ≤ b(t) + a(s)b(s)e s ds; ´ ˆ0 (ii) If b(t) ≤ b(s) for all t ≤ s, i.e. if b is non-decreasing, then for every t ∈ [0, α] we have t a(s) ds u(t) ≤ b(t)e 0 ; ´ In this section, we always assume that the state equation ϕ satisfies the assumptions of Thm. 51 for each control u ∈ A, i.e. setting:

∀u ∈ A : Mu := max |ϕ(t, q, u(t))| t1≤t≤t2 |q−q1|≤r

Lu := max |∂qϕ(t, q, u(t))| , (4.4) t1≤t≤t2 |q−q1|≤r we assume that

∀u ∈ A :(t2 − t1)Mu ≤ r n n lim (t2 − t1) Lu = 0. (4.5) n→+∞ Therefore, Thm. 51 allows us to state that u ∀u ∈ A ∃!q ∈ Q :(CP) holds for all t ∈ [t1, t2]. (4.6) Note explicitly, the importance in this deduction of the closure of GSF (of which, we recall, Sobolev-Schwartz distributions are a particular case) with respect to composition (Thm.9.(iv)). ρ Finally, observe that the constant Lu ∈ Re defined in (4.4) and Taylor Thm. 17 yield the Lipschitz condition

∀u ∈ A ∀t ∈ [t1, t2] ∀q, q˜ ∈ Br(q1): |ϕ(t, q, u(t)) − ϕ(t, q,˜ u(t))| ≤ Lu |q − q˜| . (4.7) 4.1. Weak Pontryagin Maximum Principle. Based on (4.6), we can introduce the notation and the optimization problem

t2 ∀u ∈ A : I[u] := L (t, qu(t), u(t)) dt (4.8) ˆt1 ρ l Find v ∈ A :(CP) and ∃r ∈ Re>0 ∃l ∈ N ∀u ∈ A ∩ Br(v): I[v] ≤ I[u]. (4.9) In order to develop the necessary optimality condition for Problem (4.8), we first assume that ◦ ρ u ∈ A in the sharp topology of the Re-graded Fr¨ı¿œchet space (A, k − k0), see Sec. 2.4.1, i.e.   ρ ∃r ∈ Re>0 : Br(u) = u¯ ∈ A | max |u¯(t) − u(t)| < r ⊆ A. t1≤t≤t2 Thereby, for all controlu ¯ ∈ A, and for some δ = δ(u, u¯) ∈ (0, 1) sufficiently small ∀h ∈ (−δ, δ): u + hu¯ ∈ A, (4.10)

ρ and hence we can evaluate I[u + hu¯] ∈ Re. ρ To define the first variation of I[−]: A −→ Re at u ∈ A in the directionu ¯ ∈ A, we can intuitively think at a sort of first order Taylor sum of I[u + hu¯] at u:

ρ ρ Definition 53. Let δ ∈ Re>0 be such that (4.10) holds. We say that R :(−δ, δ) −→ Re is an incremental ratio of I[−] at u ∈ A in the direction u¯ ∈ A, if there exists a function Rˆ :(−δ, δ) −→ ρ Re (called remainder) such that: (i) ∀h ∈ (−δ, δ): I[u + hu¯] = I[u] + h · R(h) + Rˆ(h) (ii) R is continuous at 0 in the sharp topology

ρ ˆ 2 (iii) ∃A ∈ Re>0 ∀h ∈ (−δ, δ): R(h) ≤ A · h .

ρ We first prove that R(0) ∈ Re is unique: CALCULUS OF VARIATIONS AND OPTIMAL CONTROL FOR GF 25

◦ Theorem 54. Let u ∈ A and u¯ ∈ A. If R, S are incremental ratios of I[−] at u in the direction u¯, then R(0) = S(0).

ρ ρ Proof. We have R :(−δ1, δ1) −→ Re and S :(−δ2, δ2) −→ Re from Def. 53. Set δ := min(δ1, δ2), so that δ > 0 by Lem.3. Let Rˆ and Sˆ be remainders of R, S respectively. Take an invertible   h ∈ (−δ, δ); from Def. 53.(i), we get R(h)−S(h) = h−1· Rˆ(h) − Sˆ(h) . Therefore, |R(h) − S(h)| ≤

(A + Aˆ)h from Def. 53.(iii), and hence lim h→0 |R(h) − S(h)| = 0. But invertible elements h invertible are dense in the sharp topology (Lem.5), and thus lim h→0 |R(h) − S(h)| = 0 = R(0) − S(0) using Def. 53.(ii).  ◦ Definition 55. We can therefore define the first variation of I[−] at u ∈ A in the direction u¯ ∈ A as δIu(u;u ¯) := R(0), where R is any incremental ratio of I[−]. Moreover, we say that u ∈ A is a weak extremal of I[−] if for anyu ¯ ∈ A, δI(u;u ¯) = 0. Using Def. 53 and similarly to Thm. 35, we can prove the following

◦ Theorem 56. If v ∈ A solves problem (4.9), then it is a weak extremal of I[−].

ρ l Proof. Letu ¯ ∈ A and let δ ∈ Re>0 be such that (4.10) holds and such that v + hu¯ ∈ Br(v) for all h ∈ (−δ, δ). From Def. 53.(i) of incremental ratio, we have I[v + hu¯] = I[v] + hR(h) + Rˆ(h) ≥ I[v]. Therefore, for all k ∈ (0, δ), we get kR(k) ≥ −Rˆ(k) and hence −R(k) ≤ Ak = A|k| by Def.53.(iii). Similarly, for all k ∈ (−δ, 0), we get R(k) ≤ −Ak = A|k|. Thereby, |R(k)| = max (R(k), −R(k)) ≤ A|k| for all invertible k ∈ (−δ, δ), which implies R(0) = δI(v;u ¯) = 0. 

ρ We will later prove that δI(u; ·) is an Re-linear continuous map. We first show the following continuity conditions for the map u ∈ A 7→ qu ∈ Q (see [9] for a similar proof):

◦ Theorem 57 (Stability of order 1 and 2). Let u ∈ A, u¯ ∈ A and δ ∈ (0, 1) as in (4.10). Assume that −1 ∀u, u¯ ∈ A ∃N ∈ N ∀h ∈ (−δ, δ): Lu+hu¯(t2 − t1) ≤ N log(dρ ). (4.11) ρ Then, there exist constants A, A¯ ∈ Re (depending only on u, u¯ and clearly on ϕ) such that for all | h |< δ, we have

u+hu¯ u q − q 0 ≤ |h| A (4.12) u+hu¯ u ¯ 2 q − q − hq¯ 0 ≤ Ah , (4.13) ρ ∞ ρ d where q¯ ∈ GC ([t1, t2], Re ) is the unique global solution of the following Cauchy’s problem  ∂ϕ ∂ϕ  q¯˙ = (t, qu, u) · q¯ + (t, qu, u) · u¯ ∂q ∂u (LCP1)  q¯(t1) = 0 Proof. We prove in detail (4.12); the proof of (4.13) is similar. Let h ∈ (−δ, δ). From the evolution ODE (CP), for all t ∈ [t1, t2], we have t u+hu¯ u u+hu¯ u  q (t) − q (t) ≤ ϕ(s, q (s), u(s) + hu¯(s)) − ϕ(s, q (s), u(s)) ds ≤ ˆt1 t u+hu¯ u ≤ ϕ(s, q (s), u(s) + hu¯(s)) − ϕ(s, q (s), u(s)) ds (4.14) ˆt1 for all s ∈ [t1, t], we have u+hu¯  u  ϕ s, q (s), u(s) + hu¯(s) − ϕ s, q (s), u(s) ≤ u+hu¯  u  ≤ ϕ s, q (s), u(s) + hu¯(s) − ϕ s, q (s), u(s) + hu¯(s) + u  u  + ϕ s, q (s), u(s) + hu¯(s) − ϕ s, q (s), u(s) . (4.15) 26 GAST¨I¿ŒO S.F. FREDERICO, PAOLO GIORDANO, ALEXANDR A. BRYZGALOV, AND MATHEUS J. LAZO

Now, we apply the Lipschitz condition (4.7) to the first summand, and a first order Taylor expan- sion with Lagrange remainder (Thm. 17.(i)) to the second one, obtaining u+hu¯  u  u+hu¯ u ϕ s, q (s), u(s) + hu¯(s) − ϕ s, q (s), u(s) + hu¯(s) ≤ Lu+hu¯ · q (s) − q (s) (4.16)

u  u  ∂ϕ u ϕ s, q (s), u(s) + hu¯(s) − ϕ s, q (s), u(s) ≤ |h| s, q (s), ξ) · u¯(s) (4.17) ∂u ρ where ξ = ξ(u, h, u,¯ s) ∈ [u(s), u(s) + hu¯(s)] ⊆ Rel. The extreme value Thm. 23 applied to u,u ¯ ρ on the functionally compact set [t1, t2] yields the existence of constants B1, B2 ∈ Re>0 such that l [u(s), u(s) + hu¯(s)] ⊆ [B1,B2] ; since |h| < δ, we can always assume that these constants do not depend on h but only on u andu ¯. In the same way, applying the extreme value theorem with ∂ϕ on the functionally compact set [t , t ] × B (q ) × [B ,B ]l, we get the existence of a constant ∂u 1 2 r 1 1 2 ρ C ∈ Re (depending only on u,u ¯) such that

∂ϕ u ∀s ∈ [t1, t2]: s, q (s), ξ) · u¯(s) ≤ C. ∂u Thereby, considering (4.17): t u  u  ϕ s, q (s), u(s) + hu¯(s) − ϕ s, q (s), u(s) ds ≤ |h|C(t2 − t1). (4.18) ˆt1 And, using inequalities (4.14), (4.15), (4.16), and (4.18), we have: t u+hu¯ u u+hu¯ u ∀t ∈ [t1, t2]: q (t) − q (t) ≤ Lu+hu¯ · q (s) − q (s) ds + |h|C(t2 − t1). (4.19) ˆt1 Finally, we apply Gr¨ı¿œnwall-Bellman Thm. 52 to (4.19) and use assumption (4.11) to obtain

u+hu¯ u Lu+hu¯ (t2−t1) −N kq − q k0 ≤ |h|C(t2 − t1)e ≤ |h|C(t2 − t1)dρ . (4.20) −N Setting A := C(t2 − t1)dρ ,(4.20) proves the claim, because also N does not depend on h but only on u andu ¯. 

Note that the existence of a solution of the Cauchy problem (LCP1) can be directly proved by setting for all t ∈ [t1, t2] ∂ϕ a(t) := (t, qu(t), u(t)) (4.21) ∂q ∂ϕ b(t) := (t, qu(t), u(t)) (4.22) ∂u  t  t  t  q¯(t) := exp a · b(s) · exp − a ds. ˆt1 ˆt1 ˆt1

ρ ∞ ρ d In fact, y ∈ GC ([t1, t2], Re ) because primitives of GSF are GSF (Thm. 13), because of the closure with respect to composition (Thm.9.(iv)), and because of condition (4.11), which implies   that exp t a ∈ ρ . The uniqueness of the solution follows from the Picard-Lindel¨ı¿œfThm. 51 t1 Re ´   considering e.g. r := (t2 − t1) Lu + max t1≤t≤t2 |∂qϕ(t, q, u(t))| . |q−q1|≤r Theorem 58. In the assumptions of Thm. 57, the following equality holds: t2 ∂L ∂L  δI(u;u ¯) = (s, qu(s), u(s)) · q¯(s) + (t, qu(s), u(s)) · u¯(s) ds (4.23) ˆt1 ∂q ∂u where q¯ =q ¯(¯u) ∈ Q is the unique global solution of problem (LCP1). Moreover, u¯ ∈ A 7→ ρ ρ ρ δI(u;u ¯) ∈ Re is an Re-continuous linear map, i.e. it is Re-linear and satisfies ρ ρ ∃K ∈ Re>0 ∃r ∈ Re>0 ∀u,¯ v¯ ∈ Br(0) : |δI(u;u ¯) − δI(u;v ¯)| ≤ K · ku¯ − v¯k0. (4.24) CALCULUS OF VARIATIONS AND OPTIMAL CONTROL FOR GF 27

◦ ρ h u+hu¯ u Proof. Since u ∈ A, there always exists δ ∈ Re>0 such that (4.10) holds. Set v := q −q −hq¯ for all h ∈ (−δ, δ), so that h 2 kυ k0 ≤ Ah¯ (4.25)

ρ ρ d ρ l by Thm. 57. For t ∈ [t1, t2] and k = (0, kq, ku) ∈ Re × Re × Re , let

u u u RL(t, q (t), u(t); k) := L(t, q (t) + kq, u(t) + ku) − L(t, q (t), u(t)) u u − ∂qL(t, q (t), u(t)) · kq − ∂uL(t, q (t), u(t)) · ku be the remainder of the first order Taylor formula of L at the point (t, qu(t), u(t)) with increment k = (0, kq, ku) (see Thm. 17). Thereby, for all h ∈ (−δ, δ), we get

t2 I[u + hu¯] − I[u] = L(·, qu+hu¯, u + hu¯) − L(·, qu, u) = ˆt1 t2 = L(·, qu + hq¯ + vh, u + hu¯) − L(·, qu, u) = ˆt1 t2  u h u = ∂qL(·, q , u) · (hq¯ + v ) + ∂uL(·, q , u) · hu¯+ ˆt1

u h +RL(·, q , u;(·, hq¯ + v , hu¯)) =

t2 u u = h {∂qL(·, q , u) · q¯+ ∂uL(·, q , u) · u¯} + ˆt1 t2  u h u h + ∂qL(·, q , u) · v + RL(·, q , u;(·, hq¯ + v , hu¯)) . ˆt1 Setting

t2 u u R := {∂qL(·, q , u) · q¯+ ∂uL(·, q , u) · u¯} ˆt1 t2  u h u h Rˆ(h) := ∂qL(·, q , u) · v + RL(·, q , u;(·, hq¯ + v , hu¯)) , ˆt1

ρ ˆ 2 Taylor Thm. 17 and (4.25) yield the existence of a constant D ∈ Re>0 such that |R(h)| ≤ Dh . This proves that R = R(0) = δJ(u;u ¯) is the incremental ratio of I[−] with remainder Rˆ (Def. 53), which is claim (4.23) Using the notationq ¯ =q ¯(¯u) and the uniqueness of solution of problem (LCP1), it follows ρ thatq ¯(αu¯ + βv¯) = αq¯(¯u) + βq¯(¯v) for all α, β ∈ Re andu ¯,v ¯ ∈ A. Thereby, (4.23) implies that ρ ρ δI(u; ·): A −→ Re is an Re-linear map. Finally, with the simplified notations (4.21) and (4.22), we have (·) (·) q¯(¯u) − q¯(¯v) = a ·{q¯(¯u) − q¯(¯v)} + b · (¯u − v¯) ˆt1 ˆt1 kq¯(¯u) − q¯(¯v)k0 ≤ kq¯(¯u) − q¯(¯v)k0 · (t2 − t1)Lu + kbk0(t2 − t1)ku¯ − v¯k0.

N N Note that kak0 = Lu by (4.4). But assumption (4.5) implies that (t2 − t1) Lu < 1 for some N ∈ N and hence that 1 − (t2 − t1)Lu is invertible, yielding −1 kq¯(¯u) − q¯(¯v)k0 ≤ (1 − (t2 − t1)Lu) kbk0(t2 − t1)ku¯ − v¯k0.

Now, the conclusion (4.24) follows from this Lipschitz property and (4.23). 

ρ Note that the Lipschitz constant K ∈ Re in (4.24) can be an infinite number, e.g. if the Lagrangian L shows some kind of singularity as a generalized function. 28 GAST¨I¿ŒO S.F. FREDERICO, PAOLO GIORDANO, ALEXANDR A. BRYZGALOV, AND MATHEUS J. LAZO

Definition 59. Let H be the Hamiltonian associated to the Lagrangian L and the state equation (CP), i.e. the GSF

ρ d H :[t1, t2] × H × K × Re −→ Re (4.26) (t, q, u, p) 7−→ L(t, q, u) + p · ϕ(t, q, u).

u ρ ∞ ρ d Moreover, for any control u ∈ A, let p ∈ GC ([t1, t2], Re ) denote the adjoint variable (general- ized momentum), i.e. the unique GSF solution of the Cauchy problem  T ∂H ∂L ∂ϕ   p˙u = − (t, qu, u, pu) = − (t, qu, u) − (t, qu, u) · pu ∂q ∂q ∂q (LCP2)  u  p (t2) = 0.

As we showed above, this problem has a unique solution on [t1, t2] because of our assumptions (4.5). We want to close this section, giving a proof of the weak Pontryagin Maximum Principle, i.e. a theorem where instead of the usual condition v v v v H(t, q (t), v(t), p (t)) = min H(t, q (t), k, p (t)) ∀t ∈ [t1, t2] k∈K (if v is an optimal control, i.e. it solves problem (4.9); see e.g. [31,57]) we have instead the necessary v v condition ∂uH(t, q (t), v(t), p (t)) = 0 assuming that v ∈ A is a local minimum of the functional I[−]. Directly from the definition of Hamiltonian, we get that, for any control u ∈ A, the pair (qu, pu) is a solution of the following Hamiltonian system:  ∂H  q˙ = (t, q, u, p)  ∂p (HS) ∂H  p˙ = − (t, q, u, p).  ∂q Next, we prove the following optimality condition for the functional (4.8)

◦ Theorem 60. Let u ∈ A and u¯ ∈ A. Then t2 ∂H δI(u, u¯) = (·, qu, u, pu) · u.¯ ˆt1 ∂u Therefore u is a weak extremal of I[−] if and only if (qu, u, pu) satisfy the equation: ∂H (t, qu, u, pu) = 0. (GSE) ∂u Proof. Letu ¯ ∈ A. Thm. 58 asserts that t2 ∂L ∂L  δI(u;u ¯) = (·, qu, u) · q¯+ (·, qu, u) · u¯ . (4.27) ˆt1 ∂q ∂u Equation (4.27) can be written as

T ! t2 ∂L ∂ϕ  δI(u;u ¯) = (·, qu, u) + (·, qu, u) · pu · q¯ ˆt1 ∂q ∂q ∂ϕ  ∂L  − (·, qu, u) · q¯ · pu + (·, qu, u) · u¯ . (4.28) ∂q ∂u

By (LCP1) and (LCP2), we have

(·) ∂ϕ ∂ϕ  q¯ = (·, qu, u) · q¯ + (·, qu, u) · u¯ (4.29) ˆt1 ∂q ∂u and CALCULUS OF VARIATIONS AND OPTIMAL CONTROL FOR GF 29

! (·) ∂L ∂ϕ T pu = − (·, qu, u) + (·, qu, u) · pu . (4.30) ˆt1 ∂q ∂q

Now, using in (4.28) equalities (4.29), (4.30) and integrating by parts (Thm. 15.(vi)) withq ¯(t1) = 0, u p (t2) = 0, we get

t2  ∂ϕ ∂ϕ  δI(u;u ¯) = pu · (·, qu, u) · q¯ + (t, qu, u) · u¯ ˆt1 ∂q ∂u ∂ϕ  ∂L  − (·, qu, u) · q¯ · pu + (·, qu, u) · u¯ = ∂q ∂u T ! t2 ∂ϕ  ∂L = (·, qu, u) · pu + (·, qu, u) · u¯ = ˆt1 ∂u ∂u t2 ∂H = (·, qu, u, pu) · u.¯ ˆt1 ∂u The proof is now completed applying the fundamental lemma Cor. 40.  Summarizing these results yields the weak Pontryagin Maximum Principle:

◦ Corollary 61 (Weak Pontryagin Maximum Principle). If v ∈ A is a local extremal of I[−], i.e. it v v ρ ∞ ρ d solves problem (4.9), then (q , v, p ) ∈ GC ([t1, t2], Re ) are solution of the system  ∂H  q˙ = (t, q, v, p)  ∂p   ∂H  p˙ = − (t, q, v, p) ∂q (WPS)  ∂H  (t, q, v, p) = 0  ∂u    q(t1), p(t2) = (0, 0).

ρ ∞ ρ d u u Moreover, if (q, u, p) ∈ GC ([t1, t2], Re ) solve (WPS), then necessarily (q, p) = (q , p ). Proof. By Thm. 56, we get that v is also a weak extremal of the functional I[−]. Therefore, the conclusion follows by (HS), Thm. 60 and (LCP1), (LCP2). 

ρ ∞ ρ d Definition 62. Any triple (q, u, p) ∈ GC ([t1, t2], Re ) satisfying the system (WPS) is called a weak Pontryagin extremals. The next proposition generalizes the du Bois–Reymond necessary optimality condition Thm. 44 (as usual, set in the following theorem: m = 1, ϕ(t, q, u) = u so thatq ˙ = u). Its proof follows directly from (4.26) and the system(WPS). Theorem 63. The following property holds for any weak Pontryagin extremals (q, u, p): d ∂H (H(t, q(t), u(t), p(t))) = (t, q(t), u(t), p(t)) ∀t ∈ [t , t ]. (4.31) dt ∂t 1 2 4.2. Noether’s Principle for optimal control. In classical optimal control, (see e.g. [13,26,60]) the optimal problem (4.9) is equivalent to minimize the augmented functional I[q, u, p] defined by

t2 I[q, u, p] := (H (t, q(t), u(t), p(t)) − p(t) · q˙(t)) dt, (4.32) ˆt1 with H given by (4.26). The notion of variational invariance for problem (4.9) is then defined with the help of the augmented functional (4.32). In the GSF setting, we follow the same approach: 30 GAST¨I¿ŒO S.F. FREDERICO, PAOLO GIORDANO, ALEXANDR A. BRYZGALOV, AND MATHEUS J. LAZO

ρ ∞ 0 0 ρ ∞ 0 0 Definition 64. Let T = {τ(s, ·)}s∈P ∈ GC (T ,T ), S = {σ(s, ·)}s∈P ∈ GC (S ,S ), U = ρ ∞ 0 0 ρ ∞ 0 0 {υ(s, ·)}s∈P ∈ GC (U ,U ), and A = {π(s, ·)}s∈P ∈ GC (A ,A ) be one parameter groups of ρ ρ ρ diffeomorphisms of the open sets T 0 ⊆ Re, S0, A0 ⊆ Red and U 0 ⊆ Rel. The augmented functional (4.32) is said to be invariant under the action of T , S, U, A, if for any weak Pontryagin extremal (q, u, p) such that q ∈ ρGC∞(T 0,S0), u ∈ ρGC∞(T 0,U 0) and p ∈ ρGC∞(T 0,A0), the following equality holds  dσ(s, q(t)) ∂τ H (τ(s, t), σ(s, q(t)), υ(s, u(t)), π(s, p(t))) − π(s, p(t)) · (s, t) = dτ(s, t) ∂t = H (t, q(t), u(t), p(t)) − p(t) · q˙(t). (4.33) for all s ∈ P and all t ∈ T 0. Theorem 65 (Necessary condition of invariance for problem (4.9)). If the augmented functional (4.32) is invariant in the sense of Def. 64, then for all weak Pontryagin extremal (q, u, p) such that q ∈ ρGC∞(T 0,S0), u ∈ ρGC∞(T 0,U 0) and p ∈ ρGC∞(T 0,A0), we have ∂H ∂τ ∂H ∂σ d ∂τ d ∂σ (·, q, u, p) (0, ·) + (·, q, u, p) · (0, q) + H(·, q, u, p) (0, ·) = p · (0, q) (4.34) ∂t ∂s ∂q ∂s dt ∂s dt ∂s Proof. We obtain (4.34) by differentiating (4.33) with respect to s at s = 0 and then considering Rem. 47 and (WPS).  Note that for the particular case of calculus of variations (ϕ(t, q, u) = u and hence H = L+p·q˙) one obtains from (4.34) the necessary condition of invariance Lem. 48. Definition 66 (Constants of Motion/conservation law for problem (4.9)). We say that a function ρ t ∈ T 0 7→ C(t, q(t), u(t), p(t)) ∈ Re is a constant of motion on T 0, S0, U 0, A0 if along any weak Pontryagin extremal (q, u, p) such that q ∈ ρGC∞(T 0,S0), u ∈ ρGC∞(T 0,U 0) and p ∈ ρGC∞(T 0,A0), we have d C(t, q(t), u(t), p(t)) = 0 ∀t ∈ T 0. (4.35) dt By the uniqueness of Thm. 13, condition 4.35 implies that ρ t ∈ J 7→ C(t, q(t), u(t), p(t)) ∈ Re is constant along any interval J ⊆ T 0. Theorem 67 (Noether’s theorem for optimal control). If the augmented functional (4.32) is in- variant in the sense of Def. 64, then the quantity defined for all q ∈ ρGC∞(T 0,S0), u ∈ ρGC∞(T 0,U 0), p ∈ ρGC∞(T 0,A0) and t ∈ T 0 by ∂τ ∂σ C(t, q(t), u(t), p(t)) := H(t, q(t), u(t), p(t)) (0, t) − p(t) · (0, q(t)) ∀t ∈ T 0 (4.36) ∂s ∂s is a constant of motion on T 0, S0, U 0, A0. Proof. By Thm. 63 we have d  ∂τ ∂σ  ∂H ∂τ d ∂τ H(·, q, u, p) (0, ·) − p · (0, q) = (·, q, u, p) (0, ·) + H(·, q, u, p) (0, ·)− dt ∂s ∂s ∂t ∂s dt ∂s ∂σ d ∂σ − p˙ · (0, q) − p · (0, q). ∂s dt ∂s Considering (4.34) and (WPS), we obtain: d  ∂τ ∂σ  ∂H ∂σ ∂σ H(·, q, u, p) (0, ·) − p · (0, q) = (·, q, u, p) · (0, q) +p ˙ · (0, q) = dt ∂s ∂s ∂q ∂s ∂s ∂H  ∂σ = (·, q, u, p) +p ˙ (0, q) = 0. ∂q ∂s  Repeating the usual calculations, it is possible to prove Thm. 50 also as a particular case of Thm. 67 (cf. e.g. [17]). CALCULUS OF VARIATIONS AND OPTIMAL CONTROL FOR GF 31

5. Examples and applications 5.1. Modeling singular dynamical systems. In this section we show several applications of the calculus of variations with GSF we introduced above. As we already mentioned in the intro- duction, we will not consider mathematical models of singular dynamical systems at the times when singularities occur. Indeed, this would clearly require new physical ideas, e.g. in order to consider the nonlinear behavior of objects or materials for the entire duration of the singularity. Like in every mathematical model, the correct point of view concerns J. von Neumann’s reasonably wide area of applicability of a mathematical model: To begin, we must emphasize a statement which I am sure you have heard be- fore, but which must be repeated again and again. It is that the sciences do not try to explain, they hardly ever try to interpret, they mainly make models. By a model is meant a mathematical construct which, with the addition of some verbal interpretations, describes observed phenomena. The justification of such a mathematical construct is solely and precisely that it is expected to work - that is correctly to describe phenomena from a reasonably wide area. [67, pag. 492] Therefore, it is not epistemologically correct to use the theory described in the present article to deduce a physical property of our modeled systems when a singularity occurs. Stating it with a language typically used in physics, we consider physical systems where the duration of the sin- gularity is negligible with respect to the durations of the other phenomena that take place in the system. Mathematically, this means to consider as infinitesimal the duration of the singularities. As a consequence, several quantities changing during this infinitesimal interval of time have in- finite derivatives. We can hence paraphrase the latter sentence saying that the amplitude (of the derivatives) of these physical quantities is much larger than all the other quantities we can estimate in the system. However, this is a logical consequence of our lacking of interest to include in our mathematical model what happen during the singularity, constructing at the same time a beautiful and sufficiently powerful mathematical model, and not because these quantities really become infinite. As we will see below for the singularly variable length pendulum (Sec. 5.3), only a rigorous mathematical theory of infinitesimal quantities is able to resolve, e.g., the apparent inconsistency of considering infinitesimal oscillations and at the same time neglecting the infinitesimal duration of the singularity. On the other hand, the aforementioned “wide area” is now able to include in a single equation the dynamical properties of our modeled systems, without being forced to subdivide into cases of the type “before/after the occurrence of each singularity”. Which is not even reasonable in several cases, e.g. in the motion of a particle in a granular medium or of a ray of light in an optical fiber. Finally, note that remaining far from the singularity (from the point of view of the physical interpretation), is what allow us to state that in several cases this kind of models are already experimentally validated.

5.2. How to use numerical solutions. The applications we are going to present always end up with an ODE. Existence and uniqueness of the solution is therefore guaranteed by Thm. 51. Clearly, if an explicit analytic solution is possible, this is preferable, but this is a rare event. On the other hand, in numerous cases we have to deal with a differential equation whose singularities are generated by Heaviside’s functions or Dirac’s deltas and linear or nonlinear operations with them. Embeddings of this generalized functions as GSF are studied and quite well-known, see Sec. 2.3. Their pictures, Fig. 2.1, are clearly obtained by numerical methods, but their properties can be fully justified by suitable theorems, see e.g. example 22. In the same way, we can consider numerical solutions of our differential equations as empirical laboratories helping us to guess suitable properties and hence conjectures on the solutions. In principle, these properties must be justified by corresponding theorems. From this point of view, the fact that GSF share with ordinary smooth functions a lot of classical theorems (such as the intermediate value, the extreme value, the mean value, Taylor theorems, etc.) is usually of great help. 32 GAST¨I¿ŒO S.F. FREDERICO, PAOLO GIORDANO, ALEXANDR A. BRYZGALOV, AND MATHEUS J. LAZO

Figure 5.1. Oscillations of a pendulum wrapping on a parallelepiped

5.3. Singularly variable length pendulum. As a first example, we want to study the dynamics of a pendulum with singularly variable length, e.g. because it is wrapping on a parallelepiped (see Fig. 5.1; see [52] for a similar but non-singular case). The pendulum length function is therefore Λ(θ) = H(θ0 −θ)L1 +L2, where H is the (embedding ρ of the) Heaviside function. We always assume that L1, L2 ∈ Re>0 are finite. From this it follows dρ−L2 L2 that for all θ, H(θ0 − θ) > ≈ − and hence that also Λ(θ) > dρ is invertible (recall that H L1 L1 has negative infinitesimal oscillations in an infinitesimal neighborhood of the origin, see Fig. 2.1). The kinetic energy is given by: 1 T (θ, θ˙) = mθ˙2Λ(θ)2. (5.1) 2 The potential energy (the zero level being the suspension point of the pendulum) is:

U(θ) = −mgΛ(θ) cos θ − mg(1 − H(θ0 − θ))L1 cos θ0. (5.2) Let us define the Lagrangian L for this problem as L(θ, θ˙) := T (θ, θ˙) − U(θ). (5.3)

The equation of motion is given by the Euler–Lagrange equation, Cor. 42, and can be written as: ∂L d ∂L = . (5.4) ∂θ dt ∂θ˙ Thereby d ∂L d ∂ 1  d   = mθ˙2Λ(θ)2 = mθ˙Λ(θ)2 = mΛ(θ)2θ¨ + 2mθ˙Λ(θ)Λ(˙ θ), (5.5) dt ∂θ˙ dt ∂θ˙ 2 dt ˙ d where Λ(θ) := dt Λ(θ(t)). From (5.2), the left side of the Euler–Lagrange equation (5.4) reduces to ∂L ∂T ∂(−U) = + = mθ˙2Λ(θ)Λ0(θ) + mgΛ0(θ) (cos θ − cos θ ) − mgΛ(θ) sin θ, (5.6) ∂θ ∂θ ∂θ 0 where d Λ0(θ) = (H(θ − θ)L + L ) = −δ(θ − θ)L , (5.7) dθ 0 1 2 0 1 and δ is the Dirac delta function. We then obtain the following equation of motion: ˙2 0 0 2 ¨ ˙ mθ Λ(θ)Λ (θ) + mgΛ (θ) (cos θ − cos θ0) − mgΛ(θ) sin θ = mΛ(θ) θ + 2mθΛ(θ)Λ(˙ θ). (5.8) CALCULUS OF VARIATIONS AND OPTIMAL CONTROL FOR GF 33

Taking into account that Λ(˙ θ) = Λ0(θ)θ˙, we finally obtain the equation of motion for the variable length pendulum: ˙ ˙ ¨ ˙ Λ(θ) Λ(θ) g θ + θ − g (cos θ − cos θ0) + sin θ = 0. (5.9) Λ(θ) θ˙Λ(θ)2 Λ(θ) Note in (5.9) the nonlinear operations on the Sobolev-Schwartz distribution Λ, on the GSF θ and the composition t 7→ Λ(θ(t)). Since the Lagrangian L is autonomous, in the usual way Noether’s Thm. 50 implies that the mechanical energy of the system is a constant of motion: 1 E(θ, θ˙) = T (θ, θ˙) + U(θ) = mθ˙2Λ(θ)2 − mgΛ(θ) cos θ − mg(1 − H(θ − θ))L cos θ = constant. 2 0 1 0 (5.10) Even if local (in time) existence and uniqueness of the solution θ of (5.10) is easily granted by Thm. 51 and by the extreme value Thm. 23, the existence of a global solution is not so easy to show (see in [47] the general theory) and is out of the scope of the present work. Before showing the numerical solution of (5.9), let us consider the simplest case of the dynamics far from the singularity and that of small oscillations. The former, as we mentioned above, is the only physically meaningful one. 5.3.1. Description far from singularity and small oscillations. For simplicity, let us consider the simplest case θ0 = 0. Furthermore, we consider that the pendulum is initially at rest and starts ρ its movement at t1 ∈ Re. The initial conditions we use are hence: ( θ(t1) = θ1; ˙ (5.11) θ(t1) = 0,

ρ with θ1 < 0. Assuming that at some time t3 ∈ Re we have θ(t3) > 0, by the intermediate ρ value theorem for GSF, there exists t2 ∈ Re where we have the singularity, i.e. θ(t2) = 0 and the length of the pendulum smoothly changes from L1 + L2 to L2 after the rope touches the parallelepiped. By example 22, it follows that this change happens in an infinitesimal interval, −1 because by contradiction it is possible to prove that if Λ(θ) ∈ (L2,L1 + L2), then |θ| ≤ log dρ ≈ 0.

ρ a Definition 68. Let x, y ∈ Re. We say that x is far from y if |x − y| ≥ dρ for all a ∈ R>0. ρ More generally, we say that x is far from y with respect to the class of infinitesimals I ⊂ Re, if |x − y| ≥ i for all i ∈ I.

For example, if |x| ≥ r for some r ∈ R>0, then x is far from 0, but also the infinitesimal number −1 −1 x = k log dρ (k ∈ R>0) is far from 0; similarly, the infinitesimal x = k log log dρ if far from 0 with −1 respect to all the infinitesimals of the type h log dρ for h ∈ R>0. −a −a −a/2 If θ is far from 0 and b ≥ dρ , a ∈ R>0, then |bθ| ≥ dρ |θ| ≥ dρ ≥ 1. Therefore, from example 22, it follows that H(−θ) ∈ {0, 1} and hence Λ(˙ θ(t)) = 0. Equation (5.9) becomes ( θ¨ + g sin θ(t) = 0 if θ(t) < 0, θ(t) is far from 0 ⇒ L1+L2 (5.12) θ¨ + g sin θ(t) = 0 if θ(t) > 0. L2

If we assume that θ(t1) = θ1 < 0 and θ(t3) > 0 are far from 0, the sharp continuity of θ yields the ρ existence of δ1, δ3 ∈ Re>0 such that

∀t ∈ [t1, t1 + δ1) ∪ (t3 − δ3, t3]: θ(t) is far from 0

∀t ∈ [t1, t1 + δ1): θ(t) < 0 (5.13)

∀t ∈ (t3 − δ3, t3]: θ(t) > 0

(and hence t2 ∈/ [t1, t1 + δ1) ∪ (t3 − δ3, t3] because θ(t2) = 0). Assuming that t1, t3 are far from t2, without loss of generality we can also assume to have taken δi so small that also t1 + δ1 and t3 − δ3 are far from t2. ρ We now employ the non Archimedean framework of Re in order to formally consider small oscillations, i.e. θ1 ≈ 0. We first note that we cannot only assume θ1 infinitesimal, because if θ1 34 GAST¨I¿ŒO S.F. FREDERICO, PAOLO GIORDANO, ALEXANDR A. BRYZGALOV, AND MATHEUS J. LAZO

is not far from 0 then our solution will not be physically meaningful. However, we already have −1 seen that we can take θ1 far from 0 and infinitesimal at the same time, e.g. θ1 = log dρ . In other a words, θ1 is a “large” infinitesimal with respect to all the infinitesimals of the form dρ . Let ϑ1, ϑ3 be the solution of the linearized problems (¨ g (¨ g ϑ1 + ϑ1 = 0, t1 ≤ t < t1 + δ1 ϑ3 + ϑ3 = 0, t3 − δ3 < t ≤ t3 L1+L2 L2 ˙ ˙ ˙ ϑ1(t1) = 0, ϑ1(t1) = θ1 ϑ1(t3) = θ(t3), ϑ1(t3) = θ(t3), (5.14) ˙ q g 0 θ(t3) 0 i.e. ϑ1(t) = θ1 cos (ω(t − t1)), ω := , and ϑ3(t) = θ(t3) cos (ω (t3 − t))− 0 sin (ω (t3 − t)), L1+L2 ω 0 q g ω = . We want to show that θ(t) ≈ ϑi(t) at least in an infinitesimal neighborhood of t1 and L2 t3 exactly because θ1 ≈ 0. For simplicity, we proceed only for ϑ1, the other case being similar. For ¨ g any t ∈ [t1, t1 +δ1), we have that θ(t) < 0 is far from 0 from (5.13), and hence θ+ sin θ(t) = 0 L1+L2 from (5.12). Recalling the initial conditions, we obtain

t1+h 2 θ(t1 + h) − θ1 = −ω sin θ(s) ds ∀h ∈ (0, δ1). ˆt1 Similarly, integrating (5.14), we get

t1+h 2 ϑ1(t1 + h) − θ1 = −ω ϑ(s) ds ∀h ∈ (0, δ1). ˆt1

Using Taylor Thm. 17 at t1 with increment h of these integral GSF, we obtain 2 n ˙ ˙ 2 o θ(t1 + h) − ϑ(t1 + h) = −ω sin θ1 − θ1 + h cos θ1 · θ(t1) − hϑ1(t1) + h R(h) = 2  2 = −ω sin θ1 − θ1 + h R(h) , 2 2 where R(−) is a suitable GSF. Thereby, θ(t1 + h) − ϑ(t1 + h) ≈ −ω h R(h) ≈ 0 for all h ≈ 0 sufficiently small because sin θ1 ≈ θ1 since θ1 ≈ 0. Since each t ∈ [t1, t1 +δ1)∪(t3 −δ3, t3] is far from t2, we can also formally join the two solutions ϑi using the Heaviside’s function:

θ(t) ≈ ϑ1(t) + H(t2 − t)(ϑ3(t) − ϑ1(t)) ∀t ∈ [t1, t1 + h) ∪ (t3 − h, t3]. (5.15) For the motivations previously stated, this infinitesimal approximation cannot be extended to a neighborhood of t2. We close this section noting that all these deductions can be repeated using any GSF H ∈ ρ ∞ ρ ρ GC ( Re, Re) satisfying for all x far from zero H(x) = 1 if x > 0 and H(x) = 0 if x < 0. This allows us to consider e.g. a GSF that do not show the infinitesimal oscillations of the Heaviside’s function in an infinitesimal neighborhood of the origin.

5.3.2. Numerical Solution. The numerical solution of equation (5.9) has been computed using Mathematica Solver NDSolve (see [68]). Initial conditions we used are: ( θ(0) = 0 rad, (5.16) θ˙(0) = 1 rad/s.

The graph of θ(t), and its derivative θ˙(t), based on the Mathematica definitions of H(x) and δ(x) (see [69]) are shown in Figure 5.2. In Figure 5.3 we show the second derivative graph. Directly from (5.9) and (5.7) we can prove ¨ ˙ that when θ(t) = θ0, θ(t) is an infinite number and hence θ(t) has a corner point. Note finally that no infinitesimal oscillations are represented in an infinitesimal neighborhood of the singularities. This is due to the Mathematica implementation of H and δ: we could hence say that these graphs represent the solution far from the singularities. CALCULUS OF VARIATIONS AND OPTIMAL CONTROL FOR GF 35

Figure 5.2. 8 times re-scaled solution (violet line) in radians and its derivative in rad/s (at θ = θ0 = π/40 rad we can see a corner point). Parameters used: 2 L1 = 0.4 m, L2 = 0.2 m, g = 9.8 m/s .

Figure 5.3. 8 times re-scaled solution in radians (violet line) and its second derivative in rad/s2

Figure 5.4. Simple pendulum moving in two media 36 GAST¨I¿ŒO S.F. FREDERICO, PAOLO GIORDANO, ALEXANDR A. BRYZGALOV, AND MATHEUS J. LAZO

5.4. Oscillations damped by two media. The second example concerns oscillations of a pen- dulum in the interface of two media. Since we have to neglect the dynamics occurring at singular times (i.e. at the changing of the medium), this can be considered only a toy model approximating the case of a very small but sufficiently heavy moving particle. We hence want to model the system employing a “jump” in the damping coefficient β, i.e. a finite change occurring in an infinitesimal interval of time, see Fig. 5.4. Since the frictional forces acting in this case are not conservative, it is well-known that the Euler-Lagrange equations cannot be assumed to describe the dynamics of the system and we have to use the D’Alembert principle Cor. 43; see [40] for a deeper study. The kinetic energy is given by: 1 T (θ˙) = mθ˙2Λ2, (5.17) 2 and the potential energy (the zero level is the suspension point of the pendulum) is: U(θ) = −mgΛ cos θ. (5.18) In case of fluid resistance proportional to the velocity, we can introduce the generalized forces Q as: Q(θ˙) = −rΛ2θ,˙ (5.19) where r is a proportional coefficient depending on the media. Let’s define the Lagrangian L as L(θ, θ˙) := T (θ˙) − U(θ). (5.20) We hence assume that the equation of motion for this non-conservative system is given by the D’Alembert’s principle, so that Cor. 43 gives d ∂L ∂L − = Q. (5.21) dt ∂θ˙ ∂θ Inserting (5.17), (5.18) and (5.19) into (5.21) we obtain the following equation of motion: mΛ2θ¨ + mgΛ sin θ = −rΛ2θ.˙ (5.22) By introducing the damping coefficient β(θ) := r(θ)/(2m) (we clearly assume that the mass ρ m ∈ Re > 0 is invertible) we obtain the classical form of the equation of motion for damped oscillations: g sin θ θ¨ + 2β(θ)θ˙ + = 0. (5.23) Λ If the pendulum crosses the boundary between two media (see Fig. 5.4) with damping coefficients β1 and β2, we can model the system using the Heaviside function H:

β(θ) = β1 + (H(θ + θ0) − H(θ − θ0)) (β2 − β1), (5.24) where θ = ±θ0 are the angles at which we have the changing of the medium (singularities). The numerical solution of (5.23) with β defined by (5.24) and initial conditions (5.16) is pre- sented in Fig. 5.5. The numerical solution has been computed using Mathematica Solver NDSolve, but with an implementation of the Heaviside’s function H corresponding to Thm. 20, i.e. as rep- resented in Fig. 2.1. We also include the graphs of the angular frequency θ˙ (which shows corner points) and of the angular acceleration θ¨ (which shows “jumps”, i.e. infinite derivatives at singular times, as we can directly see from (5.23) and (5.24)). Note that, to simplify our analysis, we considered a fixed length Λ for the pendulum. However, in the framework of the suggested model, we could also consider a singularly variable length pendulum dumped by two media. Once again, we note that the model can be refined by considering, instead of the Heaviside’s ρ ∞ ρ ρ function, any GSF H ∈ GC ( Re, Re) satisfying for all x far from zero H(x) = 1 if x > 0 and H(x) = 0 if x < 0; e.g. this refinement could allows one to consider different “large” infinitesimal neighborhoods of the origin in order to take into account a better modeling near the singularities. CALCULUS OF VARIATIONS AND OPTIMAL CONTROL FOR GF 37

Figure 5.5. Solution θ of (5.23) (blue line). For comparison, the violet line is the case β = const. = β1. Used parameters: β1 = 0.0064 (air), β2 = 0.3859 2 (water), θ0 = π/40 rad, Λ = 0.6 m, g = 9.8 m/s .

Figure 5.6. First derivative θ˙ of the solution of (5.23) (blue line). The case with β = const = β1 is also shown for comparison (violet line). Note the corner points at the singular moments, for example at t = 0.083 s (scaled in the right figure).

Figure 5.7. Second derivative θ¨ of the solution of (5.23) (blue line). The case with β = const = β1 is also shown for comparison (violet line). Note the “jumps” at the singular moments, for example at t = 0.083 s (scaled in the right figure). The infinitesimal oscillations are caused by the embedding as GSF of the Heaviside function. 38 GAST¨I¿ŒO S.F. FREDERICO, PAOLO GIORDANO, ALEXANDR A. BRYZGALOV, AND MATHEUS J. LAZO

5.5. Pais–Uhlenbeck oscillator with singular frequencies. An interesting higher order sys- tem with several applications in Physics is the Pais–Uhlenbeck (PU) oscillator [55]. The PU oscil- lator is usually studied as a toy model of recent higher-derivative theories like gravity, quantum- mechanical field theories and others (see for example [1,3,30,48]), but it can also describe simple real word systems such as, for example, electrical circuits [3]. Actually, the PU oscillator is a bi-harmonic oscillator with two natural frequencies and is described by a fourth-order equation of motion. An example of PU GSF oscillator would be a PU electric circuit with singularly variable frequencies. We can think at an (exogenous or endogenous) force acting on the system and rapidly changing these frequencies. The oscillator we consider is given by the following Lagrangian function m L(t, q, q,˙ q¨) = q¨2 − ω2(t) + ω2(t) q˙2 + ω2(t)ω2(t)q2 ∀t ∈ [t , t ] (5.25) 2 1 2 1 2 1 3 where the natural frequencies 0 0 ω1(t) = ω1 + H(ts − t) (ˆω1 − ω1) , 0 0 (5.26) ω2(t) = ω2 + H(ts − t) (ˆω2 − ω2)

0 0 0 ρ changes from ωi toω ˆi (i = 1, 2) at t = ts ∈ (t1, t2), and m, ω1, ω2,ω ˆ1,ω ˆ2 ∈ Re>0 are constants. The resulting equation of motion for the PU oscillator can be obtained from the Euler-Lagrange equation Cor. 42. We have: (4) 2 2 2 2 q + ω1 + ω2 q¨+ 2 (ω1ω˙ 1 + ω2ω˙ 2)q ˙ + ω1ω2q = 0, (5.27) where 0 ω˙ i(t) = −δ(ts − t) (ˆωi − ωi)(i = 1, 2). (5.28) Once again, note the nonlinear operations in (5.27) on the Sobolev-Schwartz distributions ωi. 0 We now consider an open set of the form T := (t1, ts − δ) ∪ (ts + δ, t2) and assume that 0 b b ∃b ∈ R>0 ∀t ∈ T ∀s ∈ (−dρ , dρ ): t + s is far from ts 0 1 (in particular any t ∈ T is far from ts). For example, it suffices to take δ ≥ − h log dρ , h ∈ R>1, 1 b 1 a so that if t ∈ (t1, ts − δ), then ts − t − s ≥ δ − s ≥ − h log dρ − dρ ≥ − (h−1) log dρ ≥ dρ for any 0 a, b ∈ R>0; similarly we can proceed if t ∈ (ts + δ, t2). Then ωi(t + s) = ωi(t) for all t ∈ T and all s ∈ (−dρb, dρb) =: P , and hence the Lagrangian (5.25) is invariant for the translation τ(t, s) := t + s defined only for t ∈ T 0 and with parameter s ∈ P . From the Noether’s Thm. 50, we hence obtain the followings conserved quantity on the intervals (t1, ts − δ) and (ts + δ, t2): m h i E = 2qq ˙ (3) − q¨2 + ω2 + ω2 q˙2 + ω2ω2q2 (5.29) 2 1 2 1 2 that coincides with the total energy for the PU oscillator [1, 55]. As it is shown in Fig. 5.10, the 0 total energy (5.29) is not preserved on the entire T = (t1, ts − δ) ∪ (ts + δ, t2) and we have a 0 0 decreasing of energy switching from ωi toω ˆi > ωi. For the numerical solution of the PU oscillator’s equation of motion (5.27), we used Mathematica Solver NDSolve (see [68]) and Mathematica implementation of H and δ (see [69]), and considered the initial conditions:

q(0) = 1 rad,  q˙(0) = 2 rad/s, 2 (5.30) q¨(0) = 0 rad/s ,  3 q(3)(0) = 1 rad/s . See Fig. 5.8 and Fig. 5.9, where we can note the corner point for the third derivative q(3) and (4) the jump for the fourth derivative q at t = ts. The analytical solution of (5.27) for constant ωi is given by q(t; ω1, ω2) := A1 sin(ω1t + ϕ1) + A2 sin(ω2t + ϕ2), where Ai and ϕi are integration constants that for our initial conditions (5.30) are given by A1 = ±6.02827, A2 = ±1.81181, ϕ1 = −2.88742 or ϕ1 = 0.254175, ϕ2 = 0.288674 or ϕ2 = −2.85292 = 0.288674 − π. Exactly as we 0 0 did in Sec. 5.3, we can hence prove that q(t) = q(t; ω1, ω2) for t ∈ (t1, ts − δ) and q(t) = q(t;ω ˆ1, ωˆ2) CALCULUS OF VARIATIONS AND OPTIMAL CONTROL FOR GF 39

Figure 5.8. Numerical solution of the PU oscillator and its derivativesq ˙,q ¨. 0 Switching time is at ts = 15 s, m = 1 kg, ω1 = 0.5 rad/s,ω ˆ1 = 0.7 rad/s, 0 ω2 = 1 rad/s,ω ˆ2 = 1.2 rad/s.

Figure 5.9. Third and fourth derivatives of the numerical solution of the PU oscillator.

Figure 5.10. Energy of the PU oscillator.

0 0 for t ∈ (ts + δ, t2). The non-singular solution q(−; ω1, ω2) is also presented as a violet line in Fig. 5.8.

6. Conclusions The present paper concretely shows the possibility to develop calculus of variations and optimal control for a class of generalized functions extending Sobolev-Schwartz distributions. On the one 40 GAST¨I¿ŒO S.F. FREDERICO, PAOLO GIORDANO, ALEXANDR A. BRYZGALOV, AND MATHEUS J. LAZO

hand, we have clearly only presented basic results, but, on the other hand, this pave the way for a lot of further results in pure and applied mathematics, theoretical physics and engineer. We have also shown that generalized smooth function theory has features that closely resemble classical smooth functions. In contrast, some differences have to be carefully considered, such as ρ the fact that the new ring of scalars Re is not a field, it is not totally ordered, it is not ordered complete, so that its theory of supremum and infimum is more involved (see [53]), and its intervals are not connected in the sharp topology because the set of all the infinitesimals is a clopen set. Almost all these properties are necessarily shared by other non-Archimedean rings because their opposite are incompatible with the existence of infinitesimal numbers. ρ Conversely, the ring of Robinson-Colombeau generalized numbers Re is a framework where the use of infinitesimal and infinite quantities is available, it is defined using elementary mathematics, and with a strong connection with infinitesimal and infinite functions of classical analysis (see Def.2). As we have shown in Sec. 5.3 with the singularly variable length pendulum, this leads to a better understanding and opens the possibility to define new models of physical systems.

References [1] Abakumova, V.A., Kaparulin, D.S., Lyakhovich, S.L., Conservation laws and stability of higher derivative extended Chern-Simons, Journal of Physics: Conf. Series 1337, 012001, 2019. [2] Benci, V., Luperi Baglini, L., Squassina, M., Generalized solutions of variational problems and applications, Adv. Nonlinear Anal. 9, pp. 124-147, 2020. [3] Biolek, Z., Biolek, D., Biolkova, V., Lagrangian for Circuits with Higher-Order Elements, Entropy 21(11), 1059, 2019. [4] Brogliato, B., Nonsmooth Mechanics. Models, Dynamics and Control. 2nd ed. Springer Verlag London, 1999. [5] Cheng, C.-W., Mizel, V.J., On the Lavrentiev phenomenon for autonomous second-order integrands, Arch. Rational Mech. Anal. 126 (1994) 21-33. [6] Colombeau, J.F., New generalized functions and multiplication of distributions. North-Holland, Amsterdam, 1984. [7] Colombeau, J.F., Multiplication of Distributions; A Tool in Mathematics, Numerical Engineering and Theo- retical Physics, Lecture Notes in Mathematics, 1532, Springer-Verlag, Berlin, 1992. [8] Colombeau, J.F., Mathematical problems on generalized functions and the canonical Hamiltonian formalism, 2007 see https://arxiv.org/abs/0708.3425 [9] Cresson, J., (editor) Fractional calculus in Analysis, dynamics and optimal control, Mathematics research developments, Nova Publishers, New York, 2014. [10] Cs¨ı¿œrnyei, M., Kirchheim, B., O’Neil, T.C., Preiss, D., Winter, S., Universal Singular Sets in the Calculus of Variations, Arch. Rational Mech. Anal. 190 (2008) 371–424. [11] Davie, A.M., Singular minimisers in the calculus of variations in one dimension. Arch. Rational Mech. Anal. 101(2), 161–177, 1988. [12] Dirac, P.A.M., The physical interpretation of the quantum dynamics, Proc. R. Soc. Lond. A, 113, 1926-27, 621-641. [13] Djuki´c,D.S., Noether’s theorem for optimum control systems, Internat. J. Control 1, no 18, 667–672, 1973. [14] Erlacher, E., Grosser, M., Ordinary Differential Equations in Algebras of Generalized Functions, in Pseudo- Differential Operators, Generalized Functions and Asymptotics, S. Molahajloo, S. Pilipovi´c,J. Toft, M. W. Wong eds, Operator Theory: Advances and Applications Volume 231, 2013, 253–270. [15] Frederico, G.S.F., Torres, D.F.M., Conservation laws for invariant functionals containing compositions, Appl. Anal. 86, no. 9, 1117–1126, 2007. arXiv:0704.0949 [16] Frederico, G.S.F., Torres, D.F.M., Non-conservative Noether’s theorem for fractional action-like variational problems with intrinsic and observer times, Int. J. Ecol. Econ. Stat. 9, no. F07, 74–82, 2007. arXiv:0711.0645 [17] Frederico, G.S.F., Torres, D.F.M., A non-differentiable quantum variational embedding in presence of time delays, Int. J. Difference Equ. 8, no. 1, 49–62, 2013. [18] Frederico, G.S.F., Odzijewicz, T., Torres, D.F.M., Noether’s theorem for nonsmooth extremals of variational problems with time delay, Applicable Analysis 93, no. 1, 153–170, 2014. [19] Gelfand, I.M., Fomin, S.V., Calculus of variations, Dover Publications, 2000. [20] Giordano, P., Kunzinger, M., Inverse Function Theorems for Generalized Smooth Functions. Invited paper for the Special issue ISAAC - Dedicated to Prof. Stevan Pilipovic for his 65 birthday. Eds. M. Oberguggenberger, J. Toft, J. Vindas and P. Wahlberg, Springer series Operator Theory: Advances and Applications, Birkhaeuser Basel, 2016. [21] Giordano, P., Kunzinger, M., A convenient notion of compact sets for generalized functions. Proceedings of the Edinburgh Mathematical Society, Volume 61, Issue 1, February 2018, pp. 57-92. [22] Giordano, P., Kunzinger, M., Vernaeve, H., Strongly internal sets and generalized smooth functions. Journal of and Applications, volume 422, issue 1, 2015, pp. 56-71. CALCULUS OF VARIATIONS AND OPTIMAL CONTROL FOR GF 41

[23] Giordano, P., Kunzinger, M., Vernaeve, H., A Grothendieck topos of generalized functions I: basic theory. Preprint. See: https://www.mat.univie.ac.at/~giordap7/ToposI.pdf [24] Giordano, P., Luperi Baglini, L., Asymptotic gauges: Generalization of Colombeau type algebras. Math. Nachr. Volume 289, Issue 2-3, pages 247–274, 2016.endieck topos of generalized functions I: basic theory. [25] Giunashvili, Z., Bott Connection and Generalized Functions on Poisson Manifold, 2003. See https://arxiv. org/abs/math/0301364 [26] Gogodze, I.K., Symmetry in problems of optimal control (in Russian). Proc. of extended sessions of seminar of the Vekua Institute of Applied Mathematics, Tbilisi University, Tbilisi, 3, no 3, 39–42, 1988. [27] Gratwick, R., Preiss, D., A One-Dimensional Variational Problem with Continuous Lagrangian and Singular Minimizer, Arch. Rational Mech. Anal. 202 (2011) 177–211. [28] Graves, L.M., Discontinuous solutions in the calculus of variations. Bull. Amer. Math. Soc. 36, 831–846, 1930. [29] Grosser, M., Kunzinger, M., Oberguggenberger, M., Steinbauer, R., Geometric theory of generalized functions, Kluwer, Dordrecht (2001). [30] Hawking, S.W., Hertog, T., Living with ghosts, Phys. Rev. D 65, 103515, 2002. [31] Hestenes, M.R., Calculus of variations and optimal control theory, John Wiley & Sons,1966. [32] Jost, J., Li-Jost, X., Calculus of variations, Cambridge Studies in Advanced Mathematics, 64, Cambridge Univ. Press, Cambridge, 1998. [33] Katz, M.G., Tall, D., A Cauchy-Dirac delta function. Foundations of Science, 2012. See http://arxiv.org/ abs/1206.0119 [34] Konjik, S., Kunzinger, M., Oberguggenberger, M.: Foundations of the Calculus of Variations in Generalized Function Algebras. Acta Applicandae Mathematicae 103 n. 2, 169–199 (2008). [35] Kuhn, S., The derivative ¨ı¿œla Carath¨ı¿œodory, The American Mathematical Monthly, Vol. 98, No. 1 (Jan., 1991), pp. 40-44. [36] Kunzinger, M., Oberguggenberger, M., Steinbauer, R., Vickers, J.A., Generalized Flows and Singular ODEs on Differentiable Manifolds, Acta Applicandae Mathematicae, 80(2), pp 221-241, 2004. [37] K¨ı¿œnzle,A.F., Singular Hamiltonian systems and symplectic capacities, Singularities and Differential Equa- tions Banach Center Publications, 33, pp.171-187, 1996. See http://pldml.icm.edu.pl/pldml/element/ bwmeta1.element.bwnjournal-article-bcpv33z1p171bwm [38] Lakshminarayanan, V., Ghatak, A.K. , Thygarajan, K., Lagrangian Optics, Springer Science Business Media, LLC, 2002. [39] Laugwitz, D., Definite values of infinite sums: aspects of the foundations of infinitesimal analysis around 1820, Arch. Hist. Exact Sci. 39 (3): 195-245, 1989. [40] Lazo, M.J., Krumreich, C.E., The action principle for dissipative systems, Journal of Mathematical Physics 55, 122902, 2014. [41] Lecke, A., Luperi Baglini, L., Giordano, P., The classical theory of calculus of variations for generalized functions, Advances in Nonlinear Analysis, 779–808, 2019. [42] Lerman, E., Montgomery, R., Sjamaar, R., Examples of singular reduction. Symplectic geometry, London Math. Soc. Lecture Note Ser., 192, Cambridge Univ. Press, Cambridge, 1993. [43] Li, F., Hua, Q., Zhang, S., New periodic solutions of singular Hamiltonian systems with fixed energies, J Inequal Appl 2014: 400. See https://doi.org/10.1186/1029-242X-2014-400 [44] Lim, C.C., On singular Hamiltonians: the existence of quasi-periodic solutions and nonlinear stability, Bull. Amer. Math. Soc. (N.S.) 20(1) 35-40, 1989. [45] Lojasiewicz, S., Sur la valeur et la limite d’une distribution en un point, Studia Math. 16 (1957), 1-36. [46] Luperi Baglini, L., Giordano, P., The category of Colombeau algebras. Monatshefte f¨ı¿œrMathematik. 2017. [47] Luperi Baglini, L., Giordano, P., A Grothendieck topos of generalized functions II: ODE. See https:/https: //www.mat.univie.ac.at/giordap7/ToposII.pdf/www.mat.univie.ac.at/giordap7/ToposII.pdf [48] Mannheim, P.D., Davidson, A., Dirac quantization of the Pais-Uhlenbeck fourth order oscillator, Phys. Rev. A 71, 042110, 2005. [49] Marsden, J.E., Generalized Hamiltonian mechanics, Arch. Rat. Mech. Anal., 28(4), pp. 323- 361, 1968. [50] Marsden, J.E., Hamiltonian one parameter groups. A mathematical exposition of infinite dimensional Hamil- tonian systems with applications in classical and , Arch. Rat. Mech. Anal., 28(5), pp. 362- 396, 1968. [51] Marsden, J.E., Non-smooth geodesic flows and classical mechanics, Canad. Math. Bull., 12, pp. 209-212, 1969. [52] Mazaheri, H., Hosseinzadeh, A., Ahmadian, M.T. , Nonlinear oscillation analysis of a pendulum wrapping on a cylinder. Scientia Iranica Transactions B: Mechanical Engineering, 19 (2), pp. 335–340, 2012. [53] Mukhammadiev, A., Tiwari, D., Apaaboah, G., Giordano, P., Supremum, Infimum and hyperlimits of Colombeau generalized numbers. Article in preparation, 2020. See http://www.mat.univie.ac.at/~giordap7/ Hyperlim.pdf. [54] Oberguggenberger, M., Vernaeve, H., Internal sets and internal functions in Colombeau theory, J. Math. Anal. Appl. 341 (2008) 649–659. [55] Pais, A., Uhlenbeck, G.E., On Field Theories with Non-Localized Action, Phys. Rev. 79, 145–165, 1950. [56] Parker, P.E., Distributional geometry, Journal of Mathematical Physics 20, 1423, 1979. 42 GAST¨I¿ŒO S.F. FREDERICO, PAOLO GIORDANO, ALEXANDR A. BRYZGALOV, AND MATHEUS J. LAZO

[57] Pontryagin, L.S., Boltyanskii, V.G., Gamkrelidze, R.V., Mishchenko, E.F., Selected works. Vol. 4. The mathe- matical theory of optimal processes. Translated from the Russian by K. N. Trirogoff, Translation edited by L. W. Neustadt, Reprint of the 1962 English translation, Gordon & Breach, New York, 1986. [58] Rapoport, A., Rom-Kedar, V., Turaev, D., Approximating Multi-Dimensional Hamiltonian Flows by Billiards. Commun. Math. Phys. 272, 567–600 (2007). [59] Robinson, A., Function theory on some nonarchimedean fields, Amer. Math. Monthly 80 (6) 87–109; Part II: Papers in the Foundations of Mathematics (1973). [60] Sage, A.P., Optimum Systems Control, Englewood Cliffs, N.J., Prentice-Hall, Inc., 1968. [61] Sychev, M.A., Another Theorem of Classical Solvability ‘In Small’ for One-Dimensional Variational Problems, Arch. Rational Mech. Anal. 202 (2011) 269–294. [62] Tanaka, K., A Prescribed Energy Problem for a Singular Hamiltonian System with a Weak Force, Journal of Functional Analysis 113(2), pp 351-390, 1993. [63] Troutman, J.L., (1996) The Lemmas of Lagrange and du Bois-Reymond. In: Variational Calculus and Optimal Control. Undergraduate Texts in Mathematics. Springer, New York, NY. [64] Tuckey, C., Nonstandard methods in the calculus of variations, Pitman Research Notes in Mathematics Series 297. Longman Scientific & Technical, Harlow, 1993. [65] Turaev, D., Rom-Kedar, V. (1998) On smooth Hamiltonian flows limited to ergodic billiards. In: Benkadda S., Zaslavsky G.M. (eds) Chaos, Kinetics and Nonlinear Dynamics in Fluids and Plasmas. Lecture Notes in Physics, vol 511. Springer, Berlin, Heidelberg. [66] Vickers, J.A., Distributional geometry in general relativity, Journal of Geometry and Physics 62 (2012) 692–705. [67] von Neumann, J., Method in the Physical Sciences. Collected Works Vol. VI. Theory of Games, Astrophysics, Hydro-dynamics and Meteorology, A.H. Taub (ed.), Pergamon Press, Oxford, 1961. [68] See https://reference.wolfram.com/language/ref/NDSolve.html, Wolfram Research, Inc., Mathematica, Champaign, IL. [69] See https://mathworld.wolfram.com/HeavisideStepFunction.html and https://mathworld.wolfram.com/ DeltaFunction.html.

Federal University of Cear¨ı¿œ, Brazil Email address: [email protected]

Obninsk Institute for Nuclear Power Engineering, Obninsk, Kaluga reg., Russia; Rosatom Technical Academy , Obninsk, Kaluga reg., Russia Email address: [email protected]

Federal University of Rio Grande, Brazil Email address: [email protected]

Faculty of Mathematics, University of Vienna, Austria Email address: [email protected]