Abstract
This presentation deals with four case studies in environmental and industrial mathematics developed by the mathematical engineering research group (mat+i) from the University of Santiago de Compostela and the Technological Institute for Industrial Mathematics (ITMATI). The first case involves environmental fluid mechanics: optimizing the location of submarine outfalls on the coast. This work, related to shallow water equations with variable depth, led us to develop a theory for numerical treatment of source terms in nonlinear first order hyperbolic balance laws. More recently, these techniques have been applied to solve Euler equations with source terms arising from numerical simulation of gas transportation networks when topography via gravity force is considered in the model. The last two problems concerns electromagnetism. One of them is related to nondestructive testing of car parts by using magnetic nanoparticles (the socalled magnetic particle inspection, MPI): mathematical modelling of magnetic hysteresis to simulate demagnetization. Finally, we present a mathematical procedure to reduce the computing time needed to achieve the stationary state of an induction electric machine when using transient numerical simulation.
Keywords
 Industrial mathematics
 Gas networks
 Environmental flows
 Electromagnetic hysteresis
 Nondestructive testing
 Fast simulation of electric machines
Download conference paper PDF
1 Introduction
Four case studies developed by the Research Group in Mathematical Engineering from the University of Santiago de Compostela (USC) and the Technological Institute for Industrial Mathematics (ITMATI) are considered. Two of them are related to fluid mechanics. The first one was developed in the framework of a contract with the Ministry of Public Works of Galicia and concerns shallow water flows in a domain with variable depth. The second one deals with gas flow in transport networks and has been done for the Reganosa company. From the mathematical point of view both are modelled with systems of nonlinear hyperbolic partial differential equations with source terms and the goal is to set up suitable finite volume discretization of the source terms.
The other two case studies concern electromagnetism. The goal of the first one, that has been financed by CIE Automotive company, is numerical simulation of magnetization and demagnetization processes in magnetic particle inspection procedures. Finally, the last case study is related to numerical solution of electric machines with optimal design in view. The underlying mathematical problems are, respectively, mathematical and numerical analysis of models for electromagnetic hysteresis, and methods to determine appropriate initial conditions for transient electromagnetic simulations, in order to attain the steady state as soon as possible.
2 Environmental Flows. The Shallow Water Equations
The technical goal of this work, commissioned by the Galician government to our research team in the eighties, was to determine the optimal location of submarine outfalls along the coast of the Galician rias. For this purpose several steps were done involving modelling, simulation and optimal control:

To compute the velocity field due to tidal currents and wind which was done by using the shallow water equations

To solve a mathematical model giving the evolution and dispersion of some pollution indicators as fecal coliforms or biochemical oxygen demand (BOD)

To formulate and solve some constrained optimal control problems related to outfall position and management of wastewater treatment systems.
Regarding the first step, as the shallow water equation is a nonlinear system of hyperbolic partial differential equations, numerical methods developed in the eighties of the last century for Euler equations can be applied to its numerical solution. We mean finite volume methods combined with approximate Riemann solvers. The unexpected problem we found was related to the discretization of the source term which is present in the shallow water equations when the bottom is not flat. In order to give some insight we refer to Fig. 1: we have solved the shallow water equations by using a finite volume scheme with the Van Leer Qscheme as approximate Riemann solver for flux term upwinding, and a centred scheme to discretize the source term arising from nonflat bottom. We have considered a static configuration in a closed channel, more precisely, the initial condition (and then the solution along the time) corresponds to water at rest. In the left plot one can see the computed water level which is a quite good approximation. However, the right plot shows the computed velocity which varies between around \(60\) and 80 m/s while the exact velocity is null.
Motivated by this problem, in the old paper [10] we developed a general methodology to discretize source terms in nonlinear systems of first order hyperbolic partial differential equations. In particular, our methods solve exactly the previous static problem. This paper is considered a seminal work in the theory of wellbalanced schemes for numerical solution of conservation laws with source terms, an active field of research during the last years. Moreover, thirty years later, this methodology was applied by our research group to a different problem: Euler equations with gravity, more specifically, to numerical simulation of gas transportation networks on nonflat topography.
3 Gas Network Simulation
This industrial demand from the Reganosa company consisted in writing a software code for transient numerical simulation of a gas transport network. In Fig. 2 the highpressure Spanish gas network is shown. Besides the great number of pipes, it includes entry (emission) and exit (consumption) points, underground storages and, more importantly, compression stations. The latter are needed to compensate the pressure drop along the network due to viscous friction of the gas on the pipe walls.
3.1 Mathematical Modelling: Homogeneous Gas Flow in a Pipe
The mathematical model for gas flow in a pipe consists of NavierStokes equations for compressible flows. More precisely, it involves the mass, momentum and energy conservation laws and some additional equations: the state equations for real gases and the DarcyWeisbach law for turbulent friction between gas and pipe walls combined with Colebrook equation to compute the friction factor. As the pipe length is much larger than the area of its crosssection we can use a 1D model:

\(\theta \) is absolute temperature (K)

p is pressure (Pa)

\(Z(\theta , p)\) is the compressibility factor (dimensionless)

E is the specific total energy (J/kg)

e is the specific internal energy (J/kg)

\(\theta _0\) is a reference temperature (K)

\(c_v(\theta )\) is the specific heat at constant volume (J/(kg K)).
3.2 Numerical Solution: One Single Pipe with Homogeneous Gas
Numerical methodology for solving the compressible Euler equations for homogeneous mixtures of perfect gases without sources has been well established since the eighties of the last century. For instance, one can use a simple firstorder method consisting of Euler explicit for time discretization, finite volume method for space discretization, and approximate Riemann solvers (e.g., van Leer’s QScheme) for upwind discretization of the flux term (see, for instance, [24]). However, when source terms are present (e.g., the gravity term with variable heigth), numerics is more difficult and similar to the shallow water equations the use of wellbalanced schemes is mandatory. This means that the discretization of source terms also needs some upwinding. In the last years many papers devoted to numerical solution of Euler equations with gravity have been written. Let us mention, for instance, [13,14,15, 23, 25, 27].
In order to highlight the need of using an upwind discretization of the source terms, we consider the following very simple test problem: h(x) in the gravity source term is an arbitrary function and we look for a static isothermal solution, i.e., satisfying \( v(x)=0,\quad \theta (x)=\theta _{ext},\quad \forall x\in (0,L). \) It is easy to see that the exact solution is given by \(v(x)=0\), \( \rho (x) =\rho _0 \exp \left( \displaystyle \frac{g}{R \theta _{ext} } \big (h(x)h_0\big )\right) , \) and \( p(x) =R \theta _{ext} \rho _0 \exp \big (\displaystyle \frac{g}{R \theta _{ext} } \big (h(x)h_0\big )\big ). \) For the data given in Table 1, the computed mass flow rate is shown in Fig. 3 as well as the exact solution which is null. One can see that the former is very bad, oscillating between around −10 and 10.
By using the general methodology developed in [10], we have proposed a discretization of the gravity term in [7] leading to a wellbalanced scheme that reproduces the null solution exactly.
3.3 Network with Heterogeneous Gas
Simulation of heterogeneous gas flowing in a network is more difficult. New problems arise: junction modelling, gas quality simulation. These issues have been addressed in papers [8, 9].
3.4 Experimental Validation in a Real Small Network
The code has been used for a small gas network and the results have been compared to real measurements. The network can be seen in Fig. 4.
Topography is quite irregular as can be seen in Fig. 5. Results and measurements corresponding to mass flow rate and pressure for some particular nodes are shown in Figs. 6 and 7, respectively.
4 Nondestructive Testing: Magnetic Particle Inspection (MPI)
MPI is a nondestructive testing technique to detect nearsurface defects in ferromagnetic pieces. The process is as follows: firstly, the workpiece is magnetized. Then, the presence of a surface discontinuity in the material allows the magnetic flux to leak, since air cannot support as much magnetic field per unit volume as metals. In order to identify a leak, ferrous particles, either dry or in a wet suspension, are applied to the workpiece. Then they are attracted to an area of flux leakage and form what is called an indication which is evaluated to determine its nature. Since cracks are more easily detected when they are perpendicular to the induced field, two magnetizations are made: circular and longitudinal. After inspection, a final demagnetization step is required for subsequent processing of the workpiece. In the next subsection we introduce an axisymmetric model for circular magnetization and present some numerical results (Figs. 8 and 9). Further details can be found in Refs. [2, 4,5,6].
4.1 Circular Magnetization. Axisymmetric Model
Let us introduce a mathematical model for circular magnetization. Thanks to axisymmetry, it can be written on a meridional section (see Fig. 10).
Given I(t), the magnetizing or demagnetizing current, and an initial condition \(H_0\), find \(H_{\theta }\) in \(\varOmega \times (t_0,T]\) such that
and
where \(\mathcal {B}\) is a scalar hysteresis operator to be defined later.
4.2 Hysteresis Modelling
Mathematical modelling of hysteresis is now a well established subject (see, for instance, the reference books [11, 12, 17,18,19, 26]). Let us summarize the main issues of the theory. We consider a system whose state is characterized by two scalar variables, u and w, which are assumed to depend continuously on time t. In our case \(u=H_\theta \) and \(w=B_\theta \). The value of w(t) is determined by u(t) and by the values of \(u(\tau )\) for \(\tau < t\). Let us introduce some basic definitions and notations (Fig. 11).
At any instant t, w(t) depends on the previous evolution of u, and on an initial state of the system to be called \(\xi \). We can formalize this as follows:
Here \(\mathcal {F}(\cdot ,\xi )\) represents an operator between suitable spaces of timedependent functions. Notice that \(\mathcal {F}\) is nonlocal in time. A particular example of hysteresis operator is the Preisach operator:
where \(\mathcal {T}\) is the Preisach triangle, \(0<p\in L^1(\mathcal {T})\) is the Preisach function which is determined by physical experiments for each material (see Fig. 12), \(h_\rho \) is the relay function (see Fig. 13) and \(\xi :\mathcal {T} \rightarrow \{1, 1\}\) is a Borel measure representing the initial magnetic state.
The classical Preisach model is built with the socalled rateindependent relay: let us fix any pair \(\rho := (\rho _1, \rho _2) \in \mathbb {R}^2,\, \rho _1 < \rho _2\). For any continuous function \(u : [0,T] \rightarrow \mathbb {R}\) and any \(\xi \in \{1, 1\}\), we define \(h_\rho (u,\xi )\) as follows.
Let \(t_1<\ldots<t_N<t\) be such that \(u(t_i)\in \{\rho _1,\rho _2\}\). If \(\{t_i\}=\emptyset \) or \(t=0\), then
else
If we split \(\mathcal {T}=S_u^{+}(t)\cup S_u^{}(t)\), where
then
We present some results obtained by solving the above model for a real crankshaft (see Fig. 14 for input data). Figure 15 shows the remanent magnetization after the circular magnetization process. In its turn, Fig. 16 shows the applied demagnetization current and the remanent magnetization after demagnetizing.
5 Accelerated Simulation of Electric Machines
In the design of electric machines (see Fig. 17), numerical simulation is an important tool. The engineer needs to know the behaviour of the machine in steady regime. In particular, he/she wants to know the torque. In order to get this steady state, finite element methods are used to solve a transient nonlinear system of PDEs derived from Maxwell equations, coupled with electrical circuit equations, starting from an (arbitrary) initial condition until the steady state is achieved. The time for this transient model to attain the steady state highly depends on the choice of the initial condition. When an unappropriate value is prescribed (for instance, when it is set to zero), a very long CPU time is needed to reach the steady state solution. Therefore, techniques leading to a suitable initial condition are in high demand and in the literature we can find several approaches to the problem. Let us mention, for instance, time periodic finite element methods [21], time periodicexplicit error correction methods [16], time differential correction [20], parareal algorithms [22]. A common drawback for these methods is the need of choosing a suitable time interval in which the solution is assumed to be periodic: the socalled effective period. Indeed, magnetic fields in rotor and stator oscillate at different frequencies and the common time at which both are periodic is generally quite large. However, the periodicity condition has to be defined in a short time interval for the method to be useful. Our methodology aims to compute a suitable initial condition and has the advantage of making use of periodicity property only in the rotor bars, so the above limitation does not apply. Moreover, the computational cost of our approach does not depend on the size of this period, and the number of unknowns is very small in comparison with the previously mentioned methods.
This work has been developed under contract with the company Robert Bosch GmbH from Stuggart (Stefan Kurz, Marcus Alexander). It has given rise to a Spanish patent. A detailed description of the methodology has been published in papers [1] and [3].
5.1 Description of the New Methodology
The main lines of the developed methodology can be described for a toy model. Let us consider a simple series circuit with an inductor and a resistor,
with the electromotive force
The general solution is
where \(\mathcal {Z}(\omega )=\mathrm R+\omega \mathrm {L}i\in \mathbb {C}\) is the impedance of the circuit and \(\varphi (\omega )\) its argument. We have two opposite extreme situations:

If \(\frac{\mathrm RT}{\mathrm {L}}\gg 1\), then the exponential vanishes quickly independently of the initial condition

If \(\frac{\mathrm RT}{\mathrm {L}}\ll 1\) then the transient part strongly depends on the initial condition. Moreover, in this case
$$ \varphi (\omega ) \approx \frac{\pi }{2} \text{ and } \mathcal {Z}(\omega )\approx \omega \mathrm {L}$$and hence
$$ \mathrm {I}(t) \approx A \mathrm e^{\frac{\mathrm R}{\mathrm {L}} t} +\frac{\mathbb {E}}{\omega \mathrm {L}} \cos (\omega t ). $$
If the equation is solved for \(\mathrm {I}(0) = 0\), then the solution is approximately given by
so it includes a transient part. However, if the equation is solved for
then \(A=0\) and the transient part is close to zero from the beginning. The important remark is that, if \(\frac{\mathrm RT}{\mathrm {L}}\ll 1\) then the above initial condition can be obtained without solving the ODE, as follows:

Firstly, the term involving the resistor can be neglected

Then, we integrate the equation twice: first between 0 and t and then between 0 and T. We get
$$ \mathrm {L}\int \limits _0^T\mathrm {I}(t)\,dt\mathrm {L}T\mathrm {I}(0)=\mathbb {E}\int \limits _0^T(Ts)\sin \omega s\,ds=\frac{\mathbb {E}T}{\omega } $$ 
Moreover, since the steady solution is harmonic then \(\int \nolimits _0^T\mathrm {I}(t)\,dt=0\) and from the above equation we deduce
$$ \mathrm {I}(0)=\frac{1}{\mathrm {L}T}\frac{\mathbb {E}T}{\omega }=\frac{\mathbb {E}}{\omega \mathrm {L}} $$
which is the suitable initial condition previously obtained. The interesting feature of this method is that it can be used in more general settings; in particular, to the model of induction machines with squirrel cage. In this case, the problem to be solved is the following:
Given currents along the coil sides \(I_n(t)\), \(n=N_b+1,\ldots ,N_c\), and initial currents along the bars \(y^0_n\), \(n=1,\ldots ,N_b\), find, for every \(t\in [0,T]\), currents \(y_n(t)\), \(n=1,\ldots ,N_b\), along the bars such that \(y_n(0)=y^0_n\), \(n=1,\ldots ,N_b\), and
where \(\mathbf {\mathcal {F}}:[0,T]\times \mathbb {R}^{N_b}\longrightarrow \mathbb {R}^{N_b}\) is the nonlinear operator defined as
for \(\quad t\in [0,T],\mathbf {w}\in \mathbb {R}^{N_b},\) with A(x, y, t) the solution to the following nonlinear magnetostatic problem:
Given a fixed \(t\in [0,T]\), currents along the coil sides \(I_n(t)\), \(n=N_b+1,\ldots ,N_c\), and \(\mathbf {w}\in \mathbb {R}^{N_b}\), find a field A(x, y, t) such that
with suitable transmission and boundary conditions.
5.2 Numerical Experiments with Real Electric Machines
We present the numerical results obtained for a particular induction machine with squirrel cage rotor. Firstly, we use our method to get a suitable initial condition. Next, we solve the transient model with this initial condition and compare the time needed to reach the steadystate with the one needed by taking null initial condition. The electric machine we have used for numerical experiments can be seen in Figs. 18 and 19. For confidentially issues it is a modification of a picture provided by Robert Bosch GmbH. Red, yellow and blue colors correspond to the three different phases. It is composed by 36 slots in the rotor and 48 slots in the stator. It is a threephase machine having 2 pole pairs with 12 slots per pole. The source currents are characterized by an electrical frequency \(f_c\) and a RMS current \(I_c\) through each slot. The currents corresponding to each phase of the stator are defined as
We have considered four operating points corresponding to different electrical sources in the stator and different rotor velocities. They are described in Table 2. The physical time to reach the steady state for the different operating points can be seen in Table 3. Finally, in Fig. 20, the computed torque and current along the transient simulation are shown for operation point # 4.
Notes and Comments.

We have presented four case studies in industrial mathematics, all related with numerical simulation by partial differential equations

In addition to the industrial outcome, in all cases scientific papers related to the developed methods have been published

This shows that industrial problems usually lead to new mathematical developments

Industrial mathematics is a nice area with good opportunities for young mathematicians willing also to learn other scientific disciplines

Postgraduate studies mixing applied mathematics and areas of application as physics, chemistry, biology, medicine, economy, etc. are a good initial step to develop a career in this promising area of increasing interest for companies and research institutions.
References
Bermúdez, A., Domínguez, O., Gómez, D., Salgado, P.: Finite element approximation of nonlinear transient magnetic problems involving periodic potential drop excitations. Comput. Math. Appl. 65, 1200–1219 (2013)
Bermúdez, A., Dupré, L., Gómez, D., Venegas, P.: Electromagnetic computations with Preisach hysteresis model. Finite Elem. Anal. Des. 126, 65–749 (2017)
Bermúdez, A., Gómez, D., Piñeiro, M., Salgado, P.: A novel numerical method for accelerating the computation of the steadystate in induction machines. Comput. Math. Appl. (2019)
Bermúdez, A., Gómez, D., Piñeiro, M., Salgado, P., Venegas, P.: Numerical simulation of magnetization and demagnetization processes. IEEE Trans. Magn. 53(12) (2017)
Bermúdez, A., Gómez, D., Rodríguez, R., Venegas, P.: Mathematical analysis and numerical solution of axisymmetric eddycurrent problems with Preisach hysteresis model. Rend. Semin. Mat. Univ. Politec. Torino 72(1–2), 73–117 (2014)
Bermúdez, A., Gómez, D., Venegas, P.: Mathematical analysis and numerical solution of models with dynamic Preisach hysteresis. J. Comput. Appl. Math. 367 (2020). https://doi.org/10.1016/j.cam.2019.112452
Bermúdez, A., López, X., VázquezCendón, M.E.: Numerical solution of nonisothermal nonadiabatic flow of real gases in pipelines. J. Comput. Phys. 323, 126–148 (2016)
Bermúdez, A., López, X., VázquezCendón, M.E.: Treating network junctions in finite volume solution of transient gas flow models. J. Comput. Phys. 344, 187–209 (2017)
Bermúdez, A., López, X., VázquezCendón, M.E.: Finite volume methods for multicomponent Euler equations with source terms. Comput. Fluids 156, 113–134 (2017)
Bermúdez, A., VázquezCendón, M.E.: Upwind methods for hyperbolic conservation laws with source terms. Comput. Fluids 23(8), 1049–1071 (1994)
Bertotti, G.: Hysteresis in Magnetism. Academic Press, New York (1998)
Brokate, M., Sprekels, J.: Hysteresis and Phase Transitions. Springer, Berlin (1996)
Chalons, C., Coquel, F., Godlewski, E., Raviart, P.A., Seguin, N.: Godunovtype schemes for hyperbolic systems with parameterdependent source: the case of Euler system with friction. Math. Models Methods Appl. Sci. 20, 2109–2166 (2010)
Chandrashekar, P., Klingenberg, C.: A second order wellbalanced finite volume scheme for Euler equations with gravity. SIAM J. Sci. Comput. 37(3), 382–402 (2015)
Käppeli, R., Mishra, S.: Wellbalanced schemes for the Euler equations with gravitation. J. Comput. Phys. 259, 199–219 (2014)
Katagiri, H., Kawase, Y., Yamaguchi, T., Tsuji, T., Shibayama, Y.: Improvement of convergence characteristics for steadystate analysis of motors with simplified singularity decompositionexplicit error correction method. IEEE Trans. Magn. 47(6), 1786–1789 (2011)
Krejčí, P.: Hysteresis, Convexity and Dissipation in Hyperbolic Equations. Gakkōtosho Co. Ltd., Tokyo (1996)
Krasnosel’skiĭ, M.A., Pokrovskiĭ, A.V.: Systems with Hysteresis. Springer, Berlin (1989)
Mayergoyz, I.D.: Mathematical Models of Hysteresis. Springer, New York (1991)
Miyata, K.: Fast analysis method of timeperiodic nonlinear fields. J. Math. Ind. 3, 131–140 (2011)
Nakata, T., Takahashi, N., Fujiwara, K., Muramatsu, K., Ohashi, H., Zhu, H.L.: Practical analysis of 3D dynamic nonlinear magnetic field using timeperiodic finite element method. IEEE Trans. Magn. 31(3), 1416–1419 (1995)
Schöps, S., Niyonzima, I., Clemens, M.: Parallelintime simulation of eddy current problems using parareal. IEEE Trans. Magn. 54(3), 1–4 (2018)
Thomann, A., Zenk, M., Klingenberg, C.: A second order wellbalanced finite volume scheme for Euler equations with gravity for arbitrary hydrostatic equilibria. Int. J. Numer. Methods Fluids 89, 465–482 (2019)
Toro, E.: Riemann Solvers and Numerical Methods for Fluid Dynamics. Springer, New York (2009)
Varma, D., Chandrashekar, P.: A secondorder, discretely wellbalanced finite volume scheme for Euler equations with gravity. Comput. Fluids 181, 292–313 (2019)
Visintin, A.: Differential Models of Hysteresis. Springer, Berlin (1994)
Xing, Y., Shu, C.W.: High order wellbalanced WENO scheme for the gas dynamics equations under gravitational fields. J. Sci. Comput. 54, 645–662 (2013)
Acknowledgements
This work has been partially supported by Robert Bosch GmbH under contract ITMATIC312015, by FEDER and Xunta de Galicia (Spain) under grant GI1563 ED431C 2017/60, by FEDER/Ministerio de Ciencia, Innovación y UniversidadesAgencia Estatal de Investigación under the research project MTM201786459R.
Author information
Authors and Affiliations
Corresponding author
Editor information
Editors and Affiliations
Rights and permissions
Open Access This chapter is licensed under the terms of the Creative Commons Attribution 4.0 International License (http://creativecommons.org/licenses/by/4.0/), which permits use, sharing, adaptation, distribution and reproduction in any medium or format, as long as you give appropriate credit to the original author(s) and the source, provide a link to the Creative Commons license and indicate if changes were made.
The images or other third party material in this chapter are included in the chapter's Creative Commons license, unless indicated otherwise in a credit line to the material. If material is not included in the chapter's Creative Commons license and your intended use is not permitted by statutory regulation or exceeds the permitted use, you will need to obtain permission directly from the copyright holder.
Copyright information
© 2022 The Author(s)
About this paper
Cite this paper
Bermúdez, A. (2022). Some Case Studies in Environmental and Industrial Mathematics. In: Chacón Rebollo, T., Donat, R., Higueras, I. (eds) Recent Advances in Industrial and Applied Mathematics. SEMA SIMAI Springer Series(), vol 1. Springer, Cham. https://doi.org/10.1007/9783030862367_2
Download citation
DOI: https://doi.org/10.1007/9783030862367_2
Published:
Publisher Name: Springer, Cham
Print ISBN: 9783030862350
Online ISBN: 9783030862367
eBook Packages: Mathematics and StatisticsMathematics and Statistics (R0)