1 Introduction

Sonar transducers are the primary device to generate signals inside the water for different purposes. Their applications range from object detection to communication [1,2,3]. Tonpilz is a term used for most of the underwater sonar transducers. A Tonpilz includes a head mass and tail mass connected by a long rod with threads at its ends. The rod is passed through the stacks of piezoelectric actuator disk. These stacks form an annular cylinder compressed between two masses by tightening the rod to the end masses. Therefore, the rod, which is also called tie rod, will be under pretension and the stacks are under precompression at their rest state. By applying a harmonic voltage to the stacks, they exert force, and consequently cause motion, to the end masses. This motion generates sonar waves that are propagated in the aquatic environment. The transducer design for sonar applications primarily consists of the determination of the component materials and dimensions that yield the desired transducer response, such as center frequency, bandwidth, and sensitivity. Piezoelectric stacks, mechanical parts, and surrounding medium are the main domains that have to be considered in the Tonpilz modeling. Figure 1 shows the schematic of the Tonpilz and its constituents [4, 5]. Piezoelectric Transducers (PTs) have been used in many engineering applications requiring force or motion control. Their applications include vibration systems, sensors, and actuators [6].

Fig. 1
figure 1

The schematic of Tonpilz and its parts

The modeling and design of piezoelectric transducers are challenging tasks due to many parameters affecting its mechanical and electrical characteristics. Hence, the design includes try and error which could be a tedious process. Also, the nonlinear and distributed parameters of the transducer model make it difficult to devise a systematic design approach [1, 5, 7, 8], or required significant amount of experiments [9].

Optimization is another way to shorten the design process by inspecting all the design variables space for the best set that optimizes a given cost function. Using this method, many problems arising from the nonlinearity and high dimensionality of the design space can be avoided. However, finding the optimal answer is another challenge. Naïve method, which includes searching all the design space, is tried for this purpose [10]. However, the large number of variables and the continuous nature of them leave any blunt search method in disadvantage. Gradient-based methods are suitable for finding local minima when the variables are all continuous [3, 11, 12]. The problem with these methods is that they miss the global extrema if they converge to a local one. The highly nonlinear nature of the problem makes the aforementioned problem a significant challenge. To overcome this challenge, researchers used numerical optimization methods that are not dependent on the gradient of the cost function. Stochastic optimization methods, such as evolutionary algorithms, initially select random parameter combinations over the whole parameter space [13,14,15,16,17].

The optimization process of TPT has usually been based on single-objective optimization algorithms [18, 19]. The multiobjective optimization is also tried for problems with small number of design variables [11]. Executing the multiobjective optimization for a larger number of design variables is another challenge. The design variable space includes both continuous and integer variables. Variables like the number of the stacks can not be expressed by real numbers. Also, the standard parts are provided in standard sizes which are apart by steps. The categorical variables, such as the material types, are another example of variables in integer form. In the literature, there is a gap for the optimization of sonar transducer having integer values in the objective function.

In this work, based on the above discussion, a new design methodology for TPTs is proposed to improve the current design methods. First, the mathematical model is formulated to capture the frequency response of the system, to be used as the objective function of the optimization algorithm. Next, an optimization problem with two objective functions, i.e. the flatness and the maximum value of the pressure level, is formulated. Due to the high performance of the evolutionary optimization algorithms, such as genetic algorithm, we chose to use them for our cause. A suitable structure for the augmented objective function is proposed through Pareto-front analysis. Also, a method of mixed-integer optimization is used in order to incorporate the integer-valued structural and material design variables, such as the number of the piezoelectric stacks and the type of the piezoelectric materials, into the optimization problem. The effect of the design parameters is then analyzed and the optimal values are proposed using the genetic algorithm.

The design of sonar transducers is thoroughly investigated. The effect of all the design variables in the performance is studied. Comparing to the previously presented methods, this method gives the best possible optimized result with respect to finding the global optima Opposing to the case of gradient-based optimization. Secondly, the problem of mixed-integer and real design variables of the TPTs are addressed for the first time. This gives the designer a valuable tool to better explore the design space. Furthermore, including the categorical variables, such as the material type, accelerates the optimization process by binding several physical values together and decreasing unnecessary search in the design space. Thirdly, including several design variables in the optimization gives a design variable set which is satisfactory in different practical aspects. The outcome of this algorithm can be fine-tuned through topological optimization for improving the acoustic properties, such as beam shape and lateral emissions, in a more focused manner in a smaller design space.

2 Mathematical model

Tonpilz works by the harmonic excitation of its head mass by the piezoelectric stacks. Hence, its behavior is studied as the steady-state frequency response of the system, also called the harmonic response. Regarding its structure, Tonpilz is a system consisting of both electrical and mechanical components. In order to address the interaction between these parts, we chose an approach of combining them by using the analogy between the electrical circuit and mechanical spring–mass–damper system. An equivalent mass–spring is considered in the modeling as listed in Table 1. A complete description of the analogy can be found in the literature [4]. The validity of this approach is investigated and found to be satisfactory when the dissipative terms of the system are taken into account [5].

Table 1 Electro-mechanical analogous parameters

We established our model by incorporating the electromechanical elements of the system, as well as the effect of the surrounding environment. Initially, the impedance of the system is calculated by combining the equivalent capacitance, inductance, and resistance of the system. It can be presented as in Eq. (1).

$$ Z = \frac{1}{{j\omega C_{e} }} + j\omega M_{e} + R_{e} $$
(1)

where ω is the excitation frequency, Ce is the equivalent capacitance, Me is the equivalent mass, and Re is the equivalent resistance of the system. The equivalent values are calculated by the electric-mechanical analogy. This system includes the piezoelectric stacks, which consist of the electrical domain and mechanical domain, the mechanical parts, and the aquatic environment which takes part both as an extra mass and also damper. It absorbs radiative energy of the transducer. The following equation yields the capacitance term (Ce) which includes the stiffness of the piezoelectric stacks (km), tie rod stiffness (ks), and the stiffness of the other mechanical part (kr). This term presents the energy storing elements of the system.

$$ C_{e} = \frac{1}{{k_{m} }} + \frac{1}{{k_{s} }} + \frac{1}{{k_{r} }} $$
(2)

where the ks and kr terms are calculated as follows:

$$ \begin{aligned} k_{s} = \frac{{A_{s} }}{{nt_{s} s_{33}^{E} }} \hfill \\ k_{r} = \frac{{A_{r} E_{r} }}{{l_{r} }} \hfill \\ \end{aligned} $$
(3)

where As is the piezoelectric stacks area, n is the number of stacks, ts is the thickness of the stacks, \( s_{33}^{E} \) is the elastic compliance coefficient of the stacks, Ar is the cross-section area of the tie rod, Er is the elastic modulus of the rod, and lr is the effective length of the rod. The magnitude of the km depends on the geometry of the parts and varies from a system to another.

The inductance term includes the inertial elements of the system. They are system elements mass and the radiation mass which takes into account the mass of the water in front of the transducer. There are several methods proposed for modeling the mass. Here we chose the method developed in [5]. Hence, the following equation calculates the equivalent mass.

$$ \begin{aligned} & M_{e} = \frac{{M_{1} }}{{1 + M_{1} /M_{2} }} - \frac{{M_{s} }}{6} \\ & where\quad M_{1} { = }M_{r} + M_{h} + 0.5M_{s} \\ & \quad M_{2} = M_{t} + 0.5M_{s} \\ \end{aligned} $$
(4)

where Mh and Mt are the mass of head and tail, respectively. Ms is the stack mass, and Mr is the radiation mass and is explained later in Eq. (11). The equivalent resistance, which represents the dissipative elements of the system, is formulated as follows.

$$ R_{e} = \frac{{R_{r} }}{{\left( {1 + M1/M2} \right)^{2} }} $$
(5)

where Rr is the radiation damping which is formulated later in Eq. (11). As the velocity of the transducer head is analogous to the current in the equivalent circuit, it is calculated by dividing the applied voltage to the system impedance of Eq. (1).

$$ u_{h/t} = \frac{{V\,d_{33} \,A_{s} /\,t\,s_{33}^{E} }}{Z} $$
(6)

where V is the applied voltage, and d33 is the piezoelectric charge constant. To find the head absolute velocity one could use the momentum law.

$$ u_{h} = \frac{{u_{h/t} }}{{1 + M_{h} /M_{t} }} $$
(7)

We chose the sound pressure level (SPL) as the index of performance and optimized it. It is defined as a logarithmic function of the generated pressure at a 1-m distance to the reference pressure (1 μPa).

$$ \begin{aligned} & SPL = 20\,\log \left( {\left| p \right|/p_{ref} } \right) \\ & where\quad p = \frac{{\rho a^{2} u_{h} j\omega }}{2} \\ \end{aligned} $$
(8)

where p is the pressure, ρ is the density of the water, and a is the radius of the radiating surface. The surrounding environment has a crucial effect, in the form of the additional mass and damping effect, on the behavior of sonar transducers. The following is the equivalent impedance of the surrounding water which is added to the transducer internal impedance.

$$ Z_{r} = \rho cA\left[ {\left( {1 - \frac{{J_{1} \left( {2ka} \right)}}{ka}} \right) + j\frac{{H_{1} \left( {2ka} \right)}}{ka}} \right] $$
(9)

where J1 is typed 1 Bessel function, A is the area of the vibrating surface, and H1 is defined as follows.

$$ H_{1} \approx \frac{2}{\pi } - J_{0} \left( {ka} \right) + \left( {\frac{16}{\pi } - 5} \right)\frac{{\sin \left( {ka} \right)}}{ka} + \left( {12 - \frac{36}{\pi }} \right)\frac{{1 - \cos \left( {ka} \right)}}{{\left( {ka} \right)^{2} }} $$
(10)

In which, a is the radius of the emitter surface and k is the wavenumber. The radiation mass and damping of the environment estimated as follows.

$$ \begin{aligned} M_{r} &= \frac{{imag\left( {Z_{r} } \right)}}{\omega } \hfill \\ R_{r} &= real\left( {Z_{r} } \right) \hfill \\ \end{aligned} $$
(11)

The other indicator of the transducer performance is the directivity of the transducer. It shows how focused is the energy of the transducer is emitted. The following equation yields this value.

$$ p\left( {r,\theta } \right) = j\rho cku_{0} a^{2} \frac{{e^{ - jkr} }}{r}\frac{{J_{1} \left( {ka\sin \theta } \right)}}{ka\sin \theta } $$
(12)

3 Problem statement and optimization

The aim of this optimization problem is to find the values for the transducer dimensions, mass properties, and material type in order to have the desired behavior in frequency response. The complex nature of the system and also the relatively high number of design variables, as well as the nonlinear relationships, make the optimization problem a nontrivial and challenging one. According to the system description, the design variable space is introduced in Table 2. The variables all contribute to the harmonic response of the transducer, as it is shown in the modeling section.

Table 2 design variable bounds

This optimization problem is subjected to several constraints that should be taken into account in any algorithm. By inspecting the design variables, constraint equations should be defined in order to have a geometrically feasible solution. For instance, the diameter of the stress bolt cannot exceed the internal diameter of the piezoelectric stack. The other restrictions are bonds on the design variables that come from the outer physical and functional restrictions on the transducer. The list of the constraints and design variable bonds are shown in Table 3.

Table 3 Design variable Bounds and constraints

The four piezoelectric types chosen for the optimization are listed in Table 4 [20]. Due to the presence of design variables with strictly integer values, an optimization method able to solve the mixed-integer problems should be implemented. The genetic algorithm method is one of the most efficient methods to solve such problems [21]. MATLAB genetic algorithm package is able to perform such optimization with some limitations [22]. In this study, we use this toolbox as it offers a wide range of options and high capabilities in global optimization.

Table 4 Piezoelectric materials

The desirable behavior for an ideal transducer is to have a high generated pressure level at all frequencies in the working band. It means that the transducer will be able to send the detection signals in a wide enough range for different situations. To transform the latter statement into the mathematical language, one should consider a frequency response function with as much as possible flat shape over the operational frequency range. Besides that, one should consider that the frequency response should have its maximum amplitude at the working range as we desire strong sonar emission which would result in stronger reflective waves and object detectability. The following is the above statements in a mathematical presentation:

$$ \begin{aligned} & \mathop {\hbox{min} }\limits_{x} \quad f_{1} = \mathop {\hbox{max} }\limits_{\omega } \left( {SPL\left( {\omega ,x} \right)} \right) - \mathop {\hbox{min} }\limits_{\omega } \left( {SPL\left( {\omega ,x} \right)} \right) \\ & \mathop {\hbox{max} }\limits_{x} \quad f_{2} = \mathop {\hbox{max} }\limits_{\omega } \left( {SPL\left( {\omega ,x} \right)} \right) \\ \end{aligned} $$
(13)

Therefore, a multi-objective problem should be solved. With a closer look into the relationship between the objective functions, through the Pareto front analysis, an augmented objective function is defined. The Pareto frontier for the normalized objective functions, f1, and f2 in Eq. (13), is presented in Fig. 2. The Pareto optimal front is found at the proximity of the blue curve, shown in Fig. 2. It is clear that a linear relationship does not exist between the two functions and a higher-order augmented function is required. Therefore, based on the results, the function shown in Eq. (14) is chosen as the fitness function for the genetic algorithm. The optimization target space is defined as the subspace that both f1 and f2 are reasonably low. It is shown in blue to make it distinguished from the rest of the curve defining the f1f2 relationship. This part of the curve is estimated by a second-degree function, shown in Eq. (14). This function can estimate the target region well and also avoid numerical solution difficulties of rational functions.

Fig. 2
figure 2

Pareto frontier for the objective functions of Eq. (13)

The sign of the two coefficients is determined by the type of optimization problem, i.e. maximizing or minimizing problems. Their magnitude is also a control parameter for specifying the importance of each objective value. In this study, we chose them to be 1.

$$ \mathop {\hbox{min} }\limits_{x} \,\,\,\,\,\,F = \alpha f_{1} \left( x \right)^{2} + \beta f_{2} \left( x \right)^{2} $$
(14)

4 Results

The optimization is performed over the frequency range between 10 and 40 kHz and the initial point of the algorithm is set to be the arithmetic mean point of the upper and lower bonds presented in Table 3. The optimization is conducted by using the default setting and values of the Genetic Algorithm toolbox in MATLAB except for the generation number which is set at 30. The reason was that the default value of 800 is too high for this problem and resulted in a long unnecessary computational time. Figure 3 shows the convergence rate of the algorithm, i.e. the fitness function value. The black points show the best penalty value, which means the value among all the generated population, versus the algorithm generation number. The blue points represent the mean penalty value for objective function among all the generated design variable sets in the correspondent generation.

Fig. 3
figure 3

Convergence of the objective function vs. generation number in the genetic algorithm

The optimum design variables from the optimization algorithm are listed in Table 5. The frequency response of the system corresponding to the design variable sets is shown next to each other in Fig. 4. In this figure, to show the improvement of the performance due to the proposed method, a set of comparisons are conducted between the design point with the higher bounds of the variables, lower bounds of the variables, and the obtained optimum values. As it is shown, the maximum value of the frequency response spectrum is close to 1.6 kHz, a slight shift from the response of the design with upper bond variables. Regarding the flatness of the frequency response, i.e. the first objective function, the results did not improve noticeably but the performance is enhanced by an increased magnitude at the resonant frequency. The results are a significant improvement with respect to the lower bond design variables. In this case, the resonance frequency is out of the operation frequency interval. The proposed formulation suggests a tool for having a fast tradeoff between the competing objectives. By changing α and β values in Eq. (14), one can adjust the final outcome to the desired design.

Table 5 Design variable optimum values
Fig. 4
figure 4

The frequency response with the optimized, upper bound, and lower bound design values

The simulated distribution of the pressure for the initial and optimum design of the Tonpilz is compared in Fig. 5. It is the pressure magnitude from the transducer surface up to 1 m apart. The result shows an improvement in the overall pressure level after the optimization with respect to the design variable point consisting of the points in the middle of the variable range.

Fig. 5
figure 5

The distribution of pressure across the surrounding environment for the initial (top) and the optimized (bottom) designs. The horizontal and vertical axes are the X and Y coordinates of the points up to 1 m away from the head of the Tonpilz

The other indicator of the merit of a transducer is its directivity. Directivity shows how the generated energy is focused on the desired direction and it can be improved as the harmonic response is enhanced. Figure 6 shows the directivity of the Tonpilz. The figure signifies the improvement in the directivity in the optimized design.

Fig. 6
figure 6

Directivity of the Tonpilz for the initial (top) and the optimized (bottom) designs. The optimization led to a narrower beam which means a more focused emitted energy

5 Conclusion

In this study, an electromechanical model is developed to capture the harmonic response of an underwater sonar transducer (Tonpilz). The analogy between the mechanical mass–spring–damper system with electrical self-capacitor-resistant is used to combine and models the electrical and the mechanical parts of the Tonpilz and the surrounding environment. Next, the properties of a superior transducer are defined in form of a multiobjective cost function and the appropriate design variables are identified. One novelty of this work is to incorporating the discrete variables, both in form of integer values of physical quantities and indicator of the categorical variables, into the optimization problem, along with the real valued variables. The highly nonlinear and mixed variable type problem made genetic algorithm a good option to consider. To find the best design variable set and solve the optimization problem, a novel approach to the genetic algorithm is proposed. Based on the geometrical and functional limits of the transducer, a series of constraints were introduced in the optimization problem. The optimized Tonpilz showed a significant improvement in terms of the harmonic response and the directivity of the emitted acoustic waves. By using the Pareto front analysis, a design variable set, which results in satisfactory performance in terms of the maximum power output and also wideband sonar emission, is found. A comparison of the performance shows that the proposed method improved the vibration magnitude at the resonant frequency by 37% in dB. Also, the optimized response emits more energy in the working frequencies range. As result of the optimized design variables, the energy output of the transducer is more focused in the desired direction, which means less wasted energy.

Moreover, the outcome of this study is a method of design based on a mixed-integer genetic algorithm which gives a powerful tool to the designers to rapidly change the design variables and observe the effect in the output. The presented modeling and optimization technique could handle nonlinear and linear constraints arising from the design and operational concerns.

In future studies, other important objective functions such as directivity can be investigated. Moreover, novel machine/deep learning models are suggested to be trained to speed up the optimization process.