1. Introduction
Optimization is a set of mathematical principles and methods used to solve quantitative problems in many disciplines, such as physics, biology, engineering, economics, and business. The theory and methods of solving optimization problems are considered in mathematical programming. The use of mathematical analysis in optimization is shown in an article by H. Eren [
1]. A brief overview of the optimization theory is contained in an article by G. R. Sinha [
2] and the book by M. Cavazzuti [
3]. Based on design variables, there are three types of structural optimization problems: size optimization, which changes the thickness and dimensions of the shape under study while maintaining its original appearance and topology; shape optimization, in which the topology is preserved, but the shape and contours change; and topological optimization, which ensures finding the optimal distribution of the material in a certain area, taking into account the loads and connections. This work is mainly devoted to the calculation of shape optimization. An introduction to shape optimization is briefly presented in the book by Haslinger, J. and Mäkinen, R. A. E [
4]. Recent developments in this type of optimization are presented in the article by Allaire and Henrot [
5].
When reviewing methods and software packages for shape optimization, the following studies were found on optimizing free-form shells in the program Rhino+Grasshopper, with the use of the Natural Force Density Method (NFDM) [
6] and evolutionary algorithm [
7]. Article [
8] mentions a variety of plug-ins for optimization in Rhino, which shows the versatility of the program. Article [
9] is devoted to shape optimization in the Ansys program using Fortran; article [
10] provides a study of the structural optimization of reinforced concrete spatial structures of different forms in Abaqus, while article [
11] is devoted to the structural analysis and optimization of spherical and groined shells in the Sofistic program.
Thus, we can conclude that there is not such a large number of studies on shape optimization in software packages. As for the optimization in the Comsol program, there are works devoted to the general optimization process of the program [
12,
13]. Additionally, a study on the optimization of piezoelectric cantilevers was found [
14]. However, no studies have yet been found that are dedicated to optimizing the shape in a special Shape Optimization module, which was added to the updated version of the program and represents a new step of research in this area of optimization. The basis of the Shape Optimization module consists of three gradient methods, MMA, SNOPT and IPOPT, which are widely used in mathematical programing. The MMA solver is described in the work of the creator of this method, Krister Svanberg [
15], and in the author’s subsequent works [
16,
17], where the globally convergent version of MMA–GCMMA is presented. Additionally, in an article by Fanni, M is shown as the topology optimization using MMA for different mesh sizes for cantilevers [
18], and in an article by Bruyneel M. et al. [
19], is proposed as a new first-order approximation scheme for the shape optimization of trusses and for complex design problems, which is based on apthe proximations of MMA and GCMMA. A brief summary of SNOPT and IPOPT solvers is presented in an article by Sven Leyffer and Ashutosh Mahajan [
20]. The article by Yin Yu et al. [
21] is devoted to the study of various optimization algorithms and six gradient-based methods, including SNOPT and IPOPT, and three gradient-free algorithms within the framework of the aerodynamic shape optimization problem. The aerodynamic twist optimization shows that the gradient methods converge faster than the gradient-free methods, thereby being the best choice for high-fidelity aerodynamic shape optimization. Therefore, it is of interest to us to use these gradient methods for the task of optimizing two common architectural shells. Article [
22] presents the theoretical and practical details about SNOPT for large-scale constrained optimization and article [
23] contains a short tutorial dedicated to IPOPT.
Since all of the above solvers are based on different methods, the approximation of convex functions (MMA), sequential quadratic programing method (SNOPT), and the method of internal points of the linear search filter (IPOPT), and are used in the study to calculate two different types of surfaces (the surface of revolution (spherical dome) and helical-ruled surface (right helicoid)), it can be assumed that the solutions obtained in the optimization process in a commercial program will be different, and the main goal is to compare the three methods and choose the most optimal method for the quality of the solution, which includes the processing speed of the results, the final values, and the resulting geometry itself.
Special attention is paid to the construction of a computational mesh in the program, since the quality of optimization calculations can significantly depend on its size. Comsol contains nine types of mesh sizes, ranging from extremely fine to extremely coarse. Therefore, the paper compares the results obtained for models constructed with two different mesh sizes: finer and fine.
In order to perform the optimizations, several tasks are necessary to be carried out:
- -
To present a brief overview of the types of optimization used in the program and list the methods used;
- -
To characterize the methods that form the basis of the Shape Optimization module;
- -
To define the design variables and objective functions;
- -
To perform the structural analysis before the optimization and to provide necessary optimization calculations;
- -
To compare the obtained results.
Before exploring the possibilities of the program, it is also necessary to analyze the overall optimization process, which is based on the selection of criteria, boundary conditions, and the search for a suitable method. Since each optimization task has the same structure in its core, the present article begins with a review of this process in general, and then the structure is applied to specific optimizations made with the Comsol program.
2. Materials and Methods
2.1. The Basic Process of Shape Optimization
The solution of any optimization problem first involves building a model of the object under study, and then conducting a computational experiment that makes it possible to effectively investigate the properties of the model itself in a certain range of setups dictated by the nature of the experiment. Before performing the calculation, it is necessary to determine what can be changed to find the optimal solution, since the entire design process is complex and involves various requirements. These requirements can be presented in the form of quality criteria (including, constructive, technological, economic, and functional) consisting of a subset of particular criteria. For example, the structural and technological criteria include strength, stability, rigidity, vibration activity, and durability [
5]. The most important criteria on the example of the surface revolution of the shell, such as the optimal distribution of thickness and minimum weight, are presented in the article by S. N. Krivoshapko [
24]. The definition of criteria leads to the formation of a certain set of design variables that determine the basic properties of the optimization problem.
After the optimization task has been formed, it is necessary to determine the problem, the goal to be pursued by changing the specified variables. This goal is a form of objective functions. The identification of the most stable (or the most lightweight) structure is a natural task in shape optimization [
25]. In the architectural and construction field, there are several limitations that need to be considered. The main idea is to vary a shape within a chosen class of domains, all satisfying certain industrial constraints (such as the quantity of material, spatial and dimensional restrictions, or some similarity to a fixed form), and to search for an optimal shape that minimizes a given target (energy) function [
25]. All this forms the constraint space, which must be kept in mind since it restricts the search space to valid solutions. Subsequently, a suitable optimization method is selected, which provides an optimization of the objective function by varying the input parameters. Optimization methods can be applied to some different building design problems, such as massing, orientation, facade design, thermal comfort, daylighting, life cycle analysis, structural design analysis, energy and cost [
8]. All the necessary optimization components are shown in
Figure 1.
2.2. The Process of Shape Optimization in Comsol Multiphysics
The Comsol Multiphysics is an advanced universal software system of finite element method (FEM) analysis that provides solutions to problems in various fields of engineering. The program contains various modules and solvers with which it is possible to simulate almost all physical processes that are described by partial differential equations. The interface makes it easy to set up complex problems without extensive knowledge about the underlying mathematics or physics [
26]. The Comsol Multiphysics program has extensive capabilities for single-criteria and multi-criteria optimizations. To carry out optimization calculations, the program has a special module called Optimization, which adds its basic functionality and allows users to solve parametric, geometric, and topological optimization problems, as well as some types of inverse problems.
The module includes three solvers, Optimization, Shape Optimization, and Topology Optimization, which are based on two methods of solving optimization problems: gradient free and gradient based. Gradient-free methods are used when objective functions and constraints may have discontinuities. This means that the function itself is not continuous and has no derivatives. The Optimization module includes 5 optimization gradient-free methods: the Bound Optimization by Quadratic Approximation (BOBYQA), the Constraint Optimization by Linear Approximation (COBYLA), the Nelder–Mead method, the coordinate search method, and the Monte Carlo method. All these methods are easy to implement since they do not require finding a differentiable objective function and the number of settings that need to be made is minimal.
The gradient-based method is used when you need to solve a problem with a large number of design variables. The Shape and Topology Optimizations include three gradient-based methods for calculating the analytical derivatives of the objective function and the constraint function: the Method of Moving Asymptotes or MMAs, Sparse Nonlinear OPTimizer or SNOPT, and Interior Point OPTimizer or IPOPT. Thus, an important advantage of the Optimization module in the Comsol program is the variety of choice of mathematical optimization methods.
The solver MMAs for non-linear programing and structural optimization was developed by Professor Krister Svanberg [
15]. This general and flexible optimization method [
18] is used to solve problems with a large number of variable variables with a slight increase in the number of calculations, for example, topological optimization problems. The method is based on the problem of approximation of convex functions and, at each iterative stage, a strictly convex approximating sub-problem is solved. Such sub-problems are controlled by «moving asymptotes» based on the values of the objective function and its sensitivity found using FEM [
27]. The MMA is based on solving the optimization problems of the following form, where the variables are
, and
:
where
are real numbers that satisfy
for all
j,
, …,
and
are real numbers that satisfy
and
for all
i, and also
for all
i with
[
15].
The SNOPT solver was developed by Philip E. Gill from the University of California San Diego, and Walter Murray and Michael A. Saunders from the Stanford University, and is based on the use of the sequential quadratic programing (SQP) method [
20]. This means that SNOPT solves a sequence of approximations to the original problem, where the objective function is quadratic with several variables under linear constraints on these variables. This solver is designed for problems with many thousands of constraints and variables, but is best suited for problems with a moderate number of degrees of freedom [
22]. The SNOPT is based on the solution of the following problem:
where
,
is a linear or nonlinear smooth objective function,
and
are constant lower and upper bounds,
is a set of nonlinear constraint functions,
is a sparse matrix, ∼ is a vector of relational operators (≤, ≥ or =), and
,
are right-hand side constants.
∼
are the nonlinear constraints of the model and
form the linear constraints [
19].
The IPOPT solver was created by Andreas Wächter as part of his dissertation research at the Chemical Engineering Department at Carnegie Mellon University. IPOPT is based on the interior-point algorithm with a filter line search method [
21]. The difference between this method and SNOPT is that IPOPT was released as an open-source code under the Eclipse Public License (EPL) and can be used for commercial purposes. In general, the computational effort during the optimization with IPOPT is typically concentrated in the solution of linear systems, or the computation of the problem functions and their derivatives, depending on the particular application. This algorithm is used to solve general nonlinear problems:
where
are the optimization variables with lower and upper bounds,
are the constraints. The constraints,
g(
x), have lower and upper bounds,
∈
and
[
23].
The optimization process in the Comsol program is shown in
Figure 2. After creating/importing the model, the process of its improvement takes place in 4 stages.
After the model is created or imported into the Comsol program, its parameters are determined, which include load data and geometric dimensions. Then, the next important stage is devoted to continuing working with the initial data of a model, specifying the materials, as well as building a mesh in the mesh section. Before creating a mesh, the type of finite elements is selected. In this study, a physics-controlled mesh was used, which is built from finite elements of different types and sizes. In this study, an automatic grid was used, taking into account physics, which is built from finite elements of different types and sizes. Next, the boundary loads are set and the model is calculated for the stress–strain state. Subsequently, there is a transition to the optimization process, which consists of choosing a suitable optimization module, method, and objective function. The most important stage is the determination of the objective function, which is a criterion indicating the quality of the system. The total strain energy is selected as an objective function to carry out the calculation in the work and the task is to minimize it. Optimization techniques, such as shape optimization by minimizing strain energy, may create new structural forms, which are more appropriate to the structural approach due to stresses and strains [
10]. After installing all these items, the optimization module is launched.
2.3. Initial Design of the Sphere Shell
As a test example for the calculation, the spherical dome is chosen, which is one of the effective forms of spatial structures. The dome region consists of the upper half of a spherical shell. A spherical surface (sphere) is a surface of revolution, which is generated by the rotation of a circle with a constant radius
® around its axis [
28].
Implicit equation of the half spherical dome:
Parametrical equations:
where
is the angle between the normal to the surface and Ox axis, and
is the angle of rotation for the plane of the meridian from the positive direction of the Ox axis.
The shell is built within the Comsol program itself with an arbitrary radius of 10 m. To begin with, the input parameters or criteria are defined, such as the dome radius, R = 10 m, and vertical load, F = 30,000 N/m
2. Finally, in the preparatory stage, a concrete material with a volume weight of 2300 kg/m
3 is set for calculating the constructed form. Next, a computational grid triangular mesh is created and, to begin with, the finer element size is selected. As a result of the automatic mesh construction, 1406 triangles are obtained. The maximum element size is 1.1 m and the minimum element size is 0.08 m. The thickness of the shell is set at 0.1 m. Subsequently, a fixed constraint is installed along the entire lower ring and two face loads are set: the vertical load and dead load (
Figure 3).
After setting all the necessary values, the shell is analyzed for the stress–strain state. On the
z-axis, the maximum displacement value is 2.22 mm. The values of the first principal stress are −8.3 × 10
−16 MPa (minimum) and 2.95 MPa (maximum). For the second principal stress, the minimum value is −1.88 MPa and the maximum value is 0.40 MPa. The values of the third principal stress are 4.7 × 10
−16 MPa (maximum) and −5.85 MPa (minimum). The total elastic strain energy is 9020.16 J.
Figure 4 represents a graphical diagram showing the maximum and minimum values.
Next, the fine mesh size is selected (
Figure 5) and the model is split into 662 triangles. The maximum element size is 1.6 m and the minimum element size is 0.2 m. Then, the calculation for the stress–strain state is repeated.
The maximum displacement value is 2.22 mm. The values of the first principal stress are −7.7 × 10
−16 MPa (minimum) and 2.95 MPa (maximum). For the second principal stress, the minimum value is −1.88 MPa and the maximum value is 0.40 MPa. The values of the third principal stress are 4.3 × 10
−10 MPa (maximum) and −5.8 × 10
−16 MPa (minimum). The total elastic strain energy is 9020.16 J.
Figure 6 represents a graphical diagram showing the maximum and minimum values.
Furthermore, an optimization calculation is performed using the Shape Optimization module, which includes only the gradient-based optimization methods MMA, SNOPT, and IPOPT. To compare the results, the shell calculation is carried out using these three methods. The objective function for optimization is the total elastic strain energy. The number of iterations for optimization for each method is set to 50. A Shell Shape Optimization module can be installed in Comsol for the optimization of an existing geometry to control the variable settings: the maximum displacement (dmax) and filter radius (Rmin). These parameters are set as follows: dmax = 2 m, Rmin = 0.5 m. The dmax parameter shows us how much the geometry maximally deviates from the existing one during the optimization process, and the radius is responsible for the value of the bending radius that is used in the calculation.
2.4. The Initial Design of the Helicoid Shell
To optimize the complex shape, a shell of a right helicoid is chosen. The right helicoid is a helical ruled surface, defined by a straight line that intersects the axis of the helicoid at a right angle and makes a helical motion along the same axis. A right helicoid is notable for being the only ruled minimal surface–surface with a zero mean curvature.
In general, the helicoid is given by the following equation:
In the study, one loop of the helicoid is calculated and the parametrical equation is:
Here,
c is the vertical displacement of the generatrix, which is the segment from
r1 to
r2 on the axis, Ox, upon its rotation by 1 radian and is related to the height of 1 loop of the helicoid
H (with the height of the surface, the generatrix of which has rotated 360°) by the following equation:
[
29].
Parameters r and v are the curvilinear coordinates of an arbitrary point of the helicoid; r is the distance from this point to the helicoid axis, Oz, and v is the angle from the Ox axis to the line connecting the origin and the projection of the desired point on the xOy plane.
The helicoid shell is also built via Comsol using the following geometrical parameters: an inner radius of 3.1 m, outer radius of 7.1 m, and the height of one loop (3 m). Additionally, the vertical load F = 10,000 N/m
2 and a dead load of the structure are set, and the concrete material has a volume weight of 2300 kg/m
3. As a result of building an automatic mesh, a total of 572 elements is created with the maximum element size of 0.786 m and the minimum element size of 0.0572 m. The thickness of the shell is set to 0.16 m. The fixed constraint is installed on the initial, final, and internal faces of the structure (
Figure 7).
Subsequently, the stress–strain analysis is also conducted. On the
z-axis, the maximum displacement value is 53.38 mm. The values of the first principal stress are −4.5 × 10
−15 MPa (minimum) and 6.9 MPa (maximum). For the second principal stress, the minimum value is −10 MPa and the maximum value is 0.22 MPa. The values of the third principal stress are −34.73 MPa (minimum) and −1.4 × 10
−17 MPa (maximum). The total elastic strain energy is 18,283.8 J.
Figure 8 represents a graphical diagram showing the maximum and minimum values.
Next, the mesh type is changed from «fine» to «finer» (
Figure 9) and the model is split into 264 triangles. The maximum element size is 1.14 m and the minimum element size is 0.143 m.
The maximum displacement value is 53.46 mm. The values of the first principal stress are −1.5 × 10
−15 MPa (minimum) and 7.11 MPa (maximum). For the second principal stress, the minimum value is −12.96 MPa and the maximum value is 0.42 MPa. The values of the third principal stress are 3.5 × 10
−16 MPa (maximum) and −33.60 MPa (minimum). The total elastic strain energy is 18,339.9 J. The graphical diagram showing the maximum and minimum values is presented in
Figure 10.
The shape optimization of the helicoid shell is also carried out using three methods in Comsol. Similar to the conducted research of the sphere as an objective function for optimization, the total elastic strain energy is chosen, and the two control variable settings have the following values: dmax –0.25 m, Rmin = 1 m.