Topological optimization method based on chimpanzee algorithm

Through the topological optimization method that simulates the hunting behavior of chimpanzees, the problems of traditional topological optimization methods that are large incomprehensible, slow in convergence and easy to fall into local optimal solutions in complex engineering structures are solved, and fast and accurate topological optimization is achieved, which is suitable for efficient optimization of a variety of materials and structures.

CN120449539APending Publication Date: 2025-08-08UNIV OF SHANGHAI FOR SCI & TECH
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202510322641.7
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-03-18
Publication Date
2025-08-08

AI Technical Summary

Technical Problem

When facing complex engineering structures, traditional topology optimization methods have large calculations, slow convergence speed, and are prone to fall into local optimal solutions, making it difficult to meet the optimization needs of high precision and high efficiency.

Method used

The topological optimization method based on chimpanzee algorithm is adopted to simulate chimpanzee hunting behavior, combine the exploration and development stages, and use random vectors and role division strategies to optimize the material structure, avoid local optimal solutions, and improve global search capabilities.

Benefits of technology

It realizes rapid and precise solution to complex topological optimization problems, avoids local optimal solutions, adapts to the optimization needs of different materials and structures, and has good scalability.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120449539A_ABST
    Figure CN120449539A_ABST
Patent Text Reader

Abstract

The invention discloses a topological optimization method based on a chimpanzee algorithm. The method comprises the following steps: establishing a finite element model; setting specific parameters in the algorithm and generating an initial chimpanzee population position; evaluating each chimpanzee individual; in the exploration stage, each chimpanzee individual changes the position according to a random vector; performing role division on individuals in a development stage to cooperatively update positions; continuously optimizing and iterating according to the fitness value of each chimpanzee individual to obtain an optimal solution; and when a preset number of iterations is reached, the algorithm is terminated, so that an optimal topological optimization result of a certain material is obtained. The chimpanzee algorithm is utilized to improve the topological optimization result, by simulating hunting behaviors of chimpanzee, the optimal solution can be quickly converged, the optimization effect is good, the checkerboard phenomenon is avoided, the method can be flexibly applied to different materials and structures, meanwhile, good expansibility is achieved, and the method is suitable for popularization and application. And more complex and diversified optimization requirements in the future can be met.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to a topology optimization method, in particular to a topology optimization method based on a chimpanzee algorithm. Background Art

[0002] Topology optimization is a key technique in structural design and materials science. It aims to maximize structural performance, such as strength, stiffness, or mass efficiency, by optimizing the distribution of materials and the layout of structures. In complex engineering applications, topology optimization problems often exhibit highly nonlinear and multimodal characteristics, making traditional optimization methods difficult to effectively solve.

[0003] Currently, topology optimization methods primarily rely on various numerical algorithms, such as finite element analysis, genetic algorithms, and particle swarm optimization. However, these methods often suffer from high computational complexity, slow convergence, and a tendency to fall into local optimal solutions when faced with complex and ever-changing topology optimization problems. In particular, with the increasing complexity of engineering structures, the requirements for topology optimization accuracy and efficiency are becoming increasingly stringent, and traditional optimization methods are no longer able to meet these demands.

[0004] As a novel optimization technique, the chimpanzee algorithm-based topology optimization method rapidly solves complex topology optimization problems by simulating chimpanzee hunting behavior. This method combines exploration and exploitation phases, gradually approaching the optimal solution by continuously adjusting the positions and roles of chimpanzee populations. However, while the chimpanzee algorithm theoretically boasts rapid convergence and high accuracy, practical applications still require further research and improvement, including how to appropriately set algorithm parameters for specific topology optimization problems and how to effectively avoid local optimal solutions.

[0005] Therefore, the present invention proposes a topology optimization method based on the chimpanzee algorithm, which aims to achieve a fast and accurate solution to complex topology optimization problems by simulating the hunting behavior of chimpanzees and combining it with specific engineering practical problems, so as to meet the future demand for high-precision and high-efficiency topology optimization methods in the fields of engineering structure design and materials science. Summary of the Invention

[0006] Purpose of the Invention: This invention aims to overcome the shortcomings of existing technologies by providing a topology optimization method based on the Chimpanzee algorithm. This method overcomes the limitations of traditional topology optimization techniques, not only determining the optimal design solution for complex material distributions and structural layouts, but also achieving excellent optimization results without the "checkerboard" phenomenon.

[0007] This invention proposes a seven-step topological optimization method for material structures, including: establishing a finite element model; setting specific algorithm parameters and generating initial chimpanzee population positions; evaluating each individual chimpanzee; changing the position of each individual chimpanzee according to a random vector during the exploration phase; assigning roles to the individuals and collaboratively updating their positions during the development phase; continuously optimizing and iterating based on the flexibility of each individual chimpanzee to obtain the optimal solution; and terminating the algorithm when a preset number of iterations is reached, thereby achieving the optimal result for the topological optimization of a particular material. By leveraging the chimpanzee algorithm to optimize the topological optimization results for complex materials, this invention addresses the demand for high-precision, high-efficiency topological optimization methods in future engineering structure design and materials science.

[0008] Technical solution: The present invention provides a topology optimization method based on the chimpanzee algorithm, comprising the following steps:

[0009] S1: Select the corresponding element type to discretize the initial design area into a grid;

[0010] S2: Set the parameters in the algorithm and generate the initial chimpanzee population positions. According to the specific correspondence, each position represents a possible structural layout or material distribution. These positions constitute the initial solution set of the problem, that is, the density set.

[0011] S3: Evaluate each chimpanzee and calculate its flexibility;

[0012] S4: During the exploration phase, each chimpanzee changes its position according to a random vector;

[0013] S5: During the development phase, chimpanzees are divided into roles, each representing a different solution in the population. Chimpanzees with different roles collaborate to update their positions to approach the optimal solution.

[0014] S6: Based on the fitness value of the current chimpanzee position, some poor solutions are eliminated and the excellent solutions are retained. Then a new generation of chimpanzee positions is generated and the iterative optimization process continues;

[0015] S7: When the preset number of iterations is reached, the algorithm terminates.

[0016] Furthermore, in S1, when discretizing the initial design area into grids, the specific steps include:

[0017] Define the geometric region, element type, material properties, geometric properties, element division, boundary conditions, and loads; mesh the material, that is, divide the simplified geometric region into a certain number of elements; establish the stiffness matrix and load vector based on the algorithm parameters to solve the displacement, and finally calculate the compliance value based on the displacement;

[0018] Furthermore, in S2, when generating the initial chimpanzee population location, the specific calculation is:

[0019] The algorithm is initialized as follows: in the multidimensional optimization problem, each chimpanzee is a row vector; each column matrix represents a solution to a problem; each variable of the chimpanzee row vector is a density value of a unit, and the variable represented by the initial density value obtained by the algorithm (X 1,1 , X 1,2 ,…,X 1,dim ), each variable must be between the upper bound 1 and the lower bound 0. The initialization of CA is shown in the following formula:

[0020]

[0021] Where X is the initial population position, N is the population size, dim is the population dimension, X i,j is the position of individual i in dimension j, X i,j The value of is obtained by the following formula:

[0022]

[0023] in represents the lower bound of the j-th dimension, represents the upper bound of the j-th dimension;

[0024] Furthermore, in S2, the parameters set include:

[0025] Determine the population size N, that is, the number of chimpanzee individuals; set the maximum number of iterations t_max as the termination condition for the algorithm; initialize other necessary parameters, such as the convergence factor f (usually linearly or decreasing from 2.5 to 0 with the increase of the number of iterations), influence coefficient, chaos factor, etc.

[0026] Furthermore, in S2, the specific formula for generating the initial population is:

[0027] In ChOA, the initialization chimpanzee population position update formula is shown as follows:

[0028] X j =rand×(ub-lb)+lb

[0029] Where, X j is the position of the j-th individual, lb and ub are the lower and upper bounds of the search space, and rand is a random number between 0 and 1.

[0030] Furthermore, in S3, regarding the calculation of flexibility:

[0031] C(ρ)=F T U

[0032] Where C is the flexibility value, F is the load vector, and U is the displacement vector.

[0033] Furthermore, in S4, during the exploration phase, each chimpanzee individual changes its position according to the random vector, where the position update formula is:

[0034] X chimp (t+1)=X prey (t)-a·d

[0035] Where, X chimp is the current position vector of the chimpanzee, X prey is the position vector of the current prey, t represents the current iteration number; a is a random vector that determines the distance between the chimpanzee and the prey. When |a|>1, it means that the chimpanzee disperses to search for prey, that is, enters the exploration phase; when |a|<1, it means that the chimpanzee performs an aggressive behavior, which accelerates the convergence of the algorithm.

[0036] The calculation formula is:

[0037] a=2·f·r1-f

[0038] Where f is the convergence factor, which decreases nonlinearly from 2.5 to 0 with the number of iterations, and r1 is a random number in the range [0, 1]. Therefore, the range of a is [-f, f].

[0039] d is the distance between the chimpanzee and the prey, which is expressed as:

[0040] d=|c·X prey (t)-m·X chimp (t)|

[0041] Where c represents the impact factor of obstacles on chimpanzee hunting during the hunting process, and its calculation formula is:

[0042] C=2·r2

[0043] Here, r2 is a random number with a value of [0, 1].

[0044] m is a chaotic mapping vector, which has certain ergodicity and orderliness. Its calculation formula is:

[0045] m=Chaotic.value

[0046] Furthermore, in S5, the specific formula for collaboratively updating the position is:

[0047]

[0048] Where X(t+1) is the updated position vector of the current chimpanzee individual, and X1, X2, X3, and X4 are the updated position vectors of the attacker, surrounder, driver, and pursuer. The mathematical model of their attack on prey is:

[0049] X1=X Attacker -a1·d Attacker

[0050] X2=X Barrier -a2·d Barrier

[0051] X3=X Chaser -a3·d Chaser

[0052] X4=X Driver -a4·d Driver

[0053] Among them, X Attacker 、X Barrier 、X Chaser 、X Driver Denote the position vectors of the attacker, besieger, chaser and pursuer respectively; d Attacker d Barrier d Chaser d Driver It represents the distance between the attacker, besieger, chaser and pursuer and the prey respectively, and its mathematical model is:

[0054] d Attacker =|c1X Attacker -m1X|

[0055] d Barrier =|c2X Barrier -m2X|

[0056] d Chaser =|c3X Chaser -m3X|

[0057] d Driver =|c4X Driver -m4X|

[0058] Among them, c1, c2, c3 and c4 represent the factors affecting the chimpanzees’ hunting caused by obstacles during the hunting process, and m1, m2, m3 and m4 are chaotic mapping vectors.

[0059] When the chimpanzee's position changes, the corresponding unit density value is also updated to the density value represented by the new position, so as to adjust the unit density value in the exploration phase, making it possible for the algorithm to find a better solution space area.

[0060] Furthermore, in S7, the termination condition of the judgment algorithm is:

[0061] Check whether the maximum number of iterations t_max or other preset stopping conditions (such as the fitness value reaches a certain threshold) is reached:

[0062] If the termination condition is met, the optimal solution (i.e., the chimpanzee position with the highest fitness value) and its corresponding flexibility are output; if the termination condition is not met, the process returns to the exploration phase to continue iterative optimization.

[0063] In this process, the cell density values corresponding to the excellent solutions are retained and enter the next round of iteration, while the cell density values of the eliminated solutions are discarded. The cell density values corresponding to the newly generated chimpanzee positions become the basis for the next round of iteration. In this way, the cell density values are continuously optimized until the termination conditions are met, and finally the cell density values corresponding to the optimal solution are output.

[0064] Compared with the prior art, the present invention has the following beneficial effects:

[0065] 1. Rapid convergence and high-precision solutions for complex topology optimization problems:

[0066] This paper proposes using the chimpanzee algorithm to improve topology optimization results. By simulating chimpanzee hunting behavior, it achieves rapid solutions to complex topology optimization problems. This method combines two phases: exploration and exploitation. The exploration phase uses random vectors to guide individual chimpanzees in a dispersed search for optimal solutions. The exploitation phase accelerates convergence through role partitioning and a collaborative update strategy. This combined approach enables more accurate solutions to complex material distributions and structural layouts, meeting high-precision requirements.

[0067] 2. Flexible parameter settings and wide applicability:

[0068] The Chimpanzee algorithm-based topology optimization method presented in this paper allows users to flexibly configure parameters, including population size, maximum number of iterations, and convergence factor, based on the specific problem. Properly configuring these parameters helps the algorithm better adapt to different materials and structures, enabling a wide range of applications. Furthermore, the method possesses excellent scalability, enabling it to meet more complex and diverse optimization needs in the future.

[0069] 3. Avoiding local optimal solutions and improving global search capabilities:

[0070] Traditional topology optimization methods often struggle with local optimal solutions when faced with complex and ever-changing topology optimization problems. This invention enhances the algorithm's global search capabilities by introducing mechanisms such as the chaotic mapping vector and obstacle impact factor from the chimpanzee algorithm. The chaotic mapping vector possesses certain ergodic and ordered properties, helping the algorithm escape local optimal solutions during the search process. The obstacle impact factor simulates the obstacles encountered during actual hunting, further increasing the diversity and complexity of the search. These mechanisms work together to enable the method of this invention to more effectively avoid local optimal solutions and enhance global search capabilities.

[0071] 4. This technical method can be applied to different materials and structures, and can adapt to more complex and diverse optimization needs in the future. BRIEF DESCRIPTION OF THE DRAWINGS

[0072] Figure 1 Flow chart of the steps of the topology optimization method based on the chimpanzee algorithm in the present invention;

[0073] Figure 2 This is the initial material structure in Example 1 of the present invention;

[0074] Figure 3 This is the optimized material structure in Example 1 of the present invention. DETAILED DESCRIPTION

[0075] In order to make the purpose, technical solution and advantages of the present invention clearer, the technical solution of the present invention will be further described below.

[0076] Example 1

[0077] Combine Figure 2 and 3 , this embodiment adopts the following technical solution, including the following steps:

[0078] Step 1: Discretize the initial design area into a grid. Mesh the current material, dividing the simplified geometric area into a certain number of finite elements. Next, define the material's geometric area, element type, material properties, geometric properties, element division, boundary conditions, and loads. Establish a stiffness matrix and load vector to solve for displacement, and finally calculate the compliance value from the displacement.

[0079] Step 2: Generate the initial chimpanzee population location. The specific calculation is:

[0080] The algorithm is initialized as follows: in the multidimensional optimization problem, each chimpanzee is a row vector; each column matrix represents a solution to a problem; each variable of the chimpanzee row vector is a density value of a unit, and the variable represented by the initial density value obtained by the algorithm (X 1,1 , X1,2 ,…,X 1,dim ), each variable must be between the upper bound 1 and the lower bound 0. The initialization of CA is shown in the following formula:

[0081]

[0082] Where X is the initial population position, N is the population size, dim is the population dimension, X i,j is the position of individual i in dimension j, X i,j The value of is obtained by the following formula:

[0083]

[0084] in represents the lower bound of the j-th dimension, represents the upper bound of the j-th dimension;

[0085] Step 3: Set the specific parameters in the algorithm and generate the initial chimpanzee population location. The parameters to be set include: determining the population size N, that is, the number of chimpanzee individuals; setting the maximum number of iterations t_max as the termination condition for the algorithm; initializing other necessary parameters, such as the convergence factor f (usually linearly increasing or decreasing from 2.5 to 0 with the increase in the number of iterations), the influence coefficient, the chaos factor, etc. In generating the initial population, the formula is:

[0086] X j =rand×(ub-lb)+lb

[0087] Where, X j is the position of the jth individual, lb and ub are the lower and upper bounds of the search space, and rand is a random number between 0 and 1.

[0088] Step 4: Evaluate each chimpanzee and calculate its flexibility

[0089] About the calculation of flexibility:

[0090] C(ρ)=F T U

[0091] Where C is the flexibility value, F is the load vector, and U is the displacement vector.

[0092] Step 5: Exploration phase. In the exploration phase, each chimpanzee changes its position according to the random vector. The position update formula is:

[0093] X chimp (t+1)=X prey (t)-a·d

[0094] Where, X chimpis the current position vector of the chimpanzee, X prey is the position vector of the current prey, t represents the current iteration number; a is a random vector that determines the distance between the chimpanzee and the prey. When |a|>1, it means that the chimpanzee disperses to search for prey, that is, enters the exploration phase; when |a|<1, it means that the chimpanzee performs an aggressive behavior, which accelerates the convergence of the algorithm.

[0095] The calculation formula is:

[0096] a=2·f·r1-f

[0097] Where f is the convergence factor, which decreases nonlinearly from 2.5 to 0 with the number of iterations, and r1 is a random number in the range [0, 1]. Therefore, the range of a is [-f, f].

[0098] d is the distance between the chimpanzee and the prey, which is expressed as:

[0099] d=|c·X prey (t)-m·X chimp (t)|

[0100] Where c represents the impact factor of obstacles on chimpanzee hunting during the hunting process, and its calculation formula is:

[0101] c=2·r2

[0102] Here, r2 is a random number with a value of [0, 1].

[0103] m is a chaotic mapping vector, which has certain ergodicity and orderliness. Its calculation formula is:

[0104] m=Chaotic.value

[0105] Step 6: Development phase. In the development phase, the chimpanzees are divided into roles, each representing a different solution in the population. The chimpanzees with different roles collaboratively update their positions to approach the optimal solution. The specific formula for collaborative position update is:

[0106]

[0107] Where X(t+1) is the updated position vector of the current chimpanzee individual, and X1, X2, X3, and X4 are the updated position vectors of the attacker, surrounder, driver, and pursuer. The mathematical model of their attack on prey is:

[0108] X1=X Attacker -a1·d Attacker

[0109] X2=X Barrier -a2·d Barrier

[0110] X3=X Chaser -a3·d Chaser

[0111] X4=X Driver -a4·d Driver

[0112] Among them, X Attacker 、X Barrier 、X Chaser 、X Driver Denote the position vectors of the attacker, besieger, chaser and pursuer respectively; d Attacker d Barrier d Chaser d Driver It represents the distance between the attacker, besieger, chaser and pursuer and the prey respectively, and its mathematical model is:

[0113] d Attacker =|c1X Attacker -m1X|

[0114] d Barrier =|c2X Barrier -m2X|

[0115] d Chaser =|c3X Chaser -m3X|

[0116] d Driver =|c4X Driver -m4X|

[0117] Among them, c1, c2, c3 and c4 represent the factors affecting the chimpanzees’ hunting caused by obstacles during the hunting process, and m1, m2, m3 and m4 are chaotic mapping vectors.

[0118] When the chimpanzee's position changes, the corresponding unit density value is also updated to the density value represented by the new position, so as to adjust the unit density value in the exploration phase, making it possible for the algorithm to find a better solution space area.

[0119] Step 7: Iterative optimization. Based on the flexibility value of the current chimpanzee position, some poor solutions are eliminated and the excellent solutions are retained. Then, a new generation of chimpanzee positions is generated and the iterative optimization process continues.

[0120] Step 8. Algorithm termination. When the preset number of iterations is reached, check whether the maximum number of iterations t_max or other preset stopping conditions (such as the flexibility value reaching a certain threshold) has been reached:

[0121] If the termination condition is met, the optimal solution (i.e., the chimpanzee position with the highest flexibility value) and its corresponding flexibility value are output; if the termination condition is not met, the process returns to the exploration phase to continue iterative optimization.

[0122] In this process, the cell density values corresponding to the excellent solutions are retained and enter the next round of iteration, while the cell density values of the eliminated solutions are discarded. The cell density values corresponding to the newly generated chimpanzee positions become the basis for the next round of iteration. In this way, the cell density values are continuously optimized until the termination conditions are met, and finally the cell density values corresponding to the optimal solution are output.

[0123] Specific example: Optimizing cantilever structures

[0124] The optimization goal of this engineering problem is to find a cantilever beam with the lightest mass and meeting the strength requirements under certain constraints.

[0125] Step 1: First, divide the entire structure into 80 × 40 = 3200 elements, with the density of each element serving as a design variable. Next, based on the finite element model, a mathematical model for the topology optimization problem of minimizing structural flexibility under volume constraints was established. The volume fraction was set to 0.5, and the external force application point and the external force F were given as known conditions.

[0126] Step 2: Select the population size N = 50 and the maximum number of iterations to 100. The convergence factor is linearly reduced from 2.5 to 0, and the influence coefficient and chaos factor are empirically set to 0.5 and 0.2. Then, the initial chimpanzee population positions are generated according to the formula. Each position represents a possible structural layout or material distribution. These positions constitute the initial solution set of the problem, that is, the density set. In generating the initial population, the formula is:

[0127] X j =rand×(ub-lb)+lb

[0128] Where, X j is the position of the j-th individual, lb and ub are the lower and upper bounds of the search space, and rand is a random number between 0 and 1.

[0129] Among them, when generating the initial chimpanzee population position, the specific calculation is:

[0130] The algorithm is initialized as follows: in the multidimensional optimization problem, each chimpanzee is a row vector; each column matrix represents a solution to a problem; each variable of the chimpanzee row vector is a density value of a unit, and the variable represented by the initial density value obtained by the algorithm (X 1,1 , X 1,2 ,…,X 1,dim ), each variable must be between the upper bound 1 and the lower bound 0. The initialization of CA is shown in the following formula:

[0131]

[0132] Where X is the initial population position, N is the population size, dim is the population dimension, X i,j is the position of individual i in dimension j, X i,j The value of is obtained by the following formula:

[0133]

[0134] in represents the lower bound of the j-th dimension, represents the upper bound of the j-th dimension;

[0135] Step 3: Set the algorithm parameters and generate the initial chimpanzee population locations. These parameters include: determining the population size N = (the number of chimpanzees); setting the maximum number of iterations t_max as the algorithm's termination condition; and initializing other necessary parameters, such as the convergence factor f (which typically increases linearly from 2.5 to 0 with increasing iterations), the influence coefficient, and the chaos factor.

[0136] Step 3: Evaluate each individual chimpanzee and calculate the flexibility of the structure. The smaller the flexibility, the stiffer the structure, and the more it meets the optimization goal.

[0137] Among them, the calculation of flexibility is:

[0138] C(ρ)=F T U

[0139] Where C is the flexibility value, F is the load vector, and U is the displacement vector.

[0140] Step 4: Exploration phase: Each chimpanzee changes its position according to the random vector. The position update formula is:

[0141] X j (t+1)=X j (t)+α·(P best -X j (t))·rand()

[0142] Among them, X j (t) is the current position of the chimpanzee individual, P best is the position of the best chimp in the current iteration, α is a random vector, and rand() is a random number between 0 and 1.

[0143] Step 5: During the development phase, the chimpanzees were divided into four roles, representing different solutions within the population. These roles were divided into attackers, besiegers, chasers, and pursuers, representing the best, average, poor, and potentially best solutions within the population, respectively.

[0144] Chimpanzees of different roles collaboratively update their positions to approach the optimal solution. The formula for collaborative position update is:

[0145] X chimp (t+1)=X prey (t)-a·d

[0146] Where, X chimp is the current position vector of the chimpanzee, X prey is the position vector of the current prey, t represents the current iteration number; a is a random vector that determines the distance between the chimpanzee and the prey. When |a|>1, it means that the chimpanzee disperses to search for prey, that is, enters the exploration phase; when |a|<1, it means that the chimpanzee performs an aggressive behavior, which accelerates the convergence of the algorithm.

[0147] The calculation formula is:

[0148] a=2·f·r1-f

[0149] Where f is the convergence factor, which decreases nonlinearly from 2.5 to 0 with the number of iterations, and r1 is a random number in the range [0, 1]. Therefore, the range of a is [-f, f].

[0150] d is the distance between the chimpanzee and the prey, which is expressed as:

[0151] d=|c·X prey (t)-m·X chimp (t)|

[0152] Where c represents the impact factor of obstacles on chimpanzee hunting during the hunting process, and its calculation formula is:

[0153] c=2·r2

[0154] Here, r2 is a random number with a value of [0, 1].

[0155] m is a chaotic mapping vector, which has certain ergodicity and orderliness. Its calculation formula is:

[0156] m=Chaotic.value

[0157] Furthermore, in S5, the specific formula for collaboratively updating the position is:

[0158]

[0159] Where X(t+1) is the updated position vector of the current chimpanzee individual, and X1, X2, X3, and X4 are the updated position vectors of the attacker, surrounder, driver, and pursuer. The mathematical model of their attack on prey is:

[0160] X1=X Attacker -a1·d Attacker

[0161] X2=X Barrier -a2·d Barrier

[0162] X3=X Chaser -a3·d Chaser

[0163] X4=X Driver -a4·d Driver

[0164] Among them, X Attacker 、X Barrier 、X Chaser 、X Driver Denote the position vectors of the attacker, besieger, chaser and pursuer respectively; d Attacker d Barrier d Chaser d Driver It represents the distance between the attacker, besieger, chaser and pursuer and the prey respectively, and its mathematical model is:

[0165] d Attacker =|c1X Attacker -m1X|

[0166] d Barrier =|c2X Barrier -m2X|

[0167] d Chaser =|c3X Chaser -m3X|

[0168] d Driver =|c4X Driver -m4X|

[0169] Among them, c1, c2, c3 and c4 represent the factors affecting the chimpanzees’ hunting caused by obstacles during the hunting process, and m1, m2, m3 and m4 are chaotic mapping vectors.

[0170] During the updating process, we also need to consider the impact of obstacles on chimpanzee hunting. By introducing obstacle impact factors and chaos mapping vectors, we can enhance the algorithm's global search capability and avoid falling into local optimal solutions.

[0171] Step 6: Based on the flexibility of the current chimpanzee position, some poor solutions are eliminated and the excellent solutions are retained. Then, a new generation of chimpanzee positions is generated and the iterative optimization process continues.

[0172] When the chimpanzee's position changes, the corresponding unit density value is also updated to the density value represented by the new position, so as to adjust the unit density value in the exploration phase, making it possible for the algorithm to find a better solution space area.

[0173] Step 7: When the preset number of iterations is reached, the algorithm terminates. Check whether the maximum number of iterations (100) or other preset stopping conditions are reached. If the termination conditions are met, the optimal solution (i.e., the chimpanzee position with the highest fitness value) and its corresponding flexibility value are output; if the termination conditions are not met, return to the exploration stage to continue iterative optimization.

[0174] The above description is merely a preferred embodiment of the present invention and does not limit the present invention in any way. Any person skilled in the art who, without departing from the scope of the present invention, makes any equivalent substitution, modification, or other changes to the technical solution and technical content disclosed in the present invention shall be deemed to be within the scope of the present invention and still fall within the scope of protection of the present invention.

Claims

1. A topology optimization method based on the chimpanzee algorithm, characterized in that: The following steps are involved: S1: Select the corresponding element type to discretize the initial design area into a grid; S2: Set the parameters in the algorithm and generate the initial chimpanzee population positions. According to the specific correspondence, each position represents a possible structural layout or material distribution. These positions constitute the initial solution set of the problem, that is, the density set. S3: Evaluate each chimpanzee and calculate its flexibility; S4: During the exploration phase, each chimpanzee changes its position according to a random vector; S5: During the development phase, chimpanzees are divided into roles, each representing a different solution in the population. Chimpanzees with different roles collaborate to update their positions to approach the optimal solution. S6: Based on the fitness value of the current chimpanzee position, some poor solutions are eliminated and the excellent solutions are retained. Then a new generation of chimpanzee positions is generated and the iterative optimization process continues; S7: When the preset number of iterations is reached, the algorithm terminates.

2. The topology optimization method based on the chimpanzee algorithm according to claim 1, characterized in that: In S1, the initial design area is discretized into a grid. The specific steps include: (1): Define geometric regions, element types, material properties, geometric properties, element partitioning, boundary conditions, and loads; (2): Meshing the material, that is, dividing the geometric area after material simplification into a certain number of units; (3): According to the algorithm parameter settings in S2, the stiffness matrix and load vector are established to solve the displacement and flexibility values.

3. The topology optimization method based on the chimpanzee algorithm according to claim 2, characterized in that: In S2, when generating the initial chimpanzee population position, the specific calculation is: The algorithm is initialized as follows: in the multidimensional optimization problem, each chimpanzee is a row vector; each column matrix represents a solution to a problem; each variable of the chimpanzee row vector is a density value of a unit, and the variable represented by the initial density value obtained by the algorithm (X 1,1 , X 1,2 ,…,X 1,dim ), each variable must be between the upper bound 1 and the lower bound 0, and CA is initialized as shown below: Where X is the initial population position, N is the population size, dim is the population dimension, and x i,j is the position of individual i in dimension j, x i,j The value of is obtained by the following formula: in represents the lower bound of the j-th dimension, represents the upper bound of the j-th dimension.

4. The topology optimization method based on the chimpanzee algorithm according to claim 3, characterized in that: In S2, the parameters to be set include: (1) Determine the population size N, that is, the number of chimpanzees; (2) Set the maximum number of iterations t_max as the termination condition of the algorithm; (3) Initialize other necessary parameters, including the convergence factor f, which usually increases linearly from 2.5 to 0 or decreases with the increase of the number of iterations, the influence coefficient, and the chaos factor.

5. The topology optimization method based on the chimpanzee algorithm according to claim 4, characterized in that: In S2, the specific formula for generating the initial population is: In ChOA, the initialization of the chimpanzee population position update formula is shown as follows: X j =rand×(ub-lb)+lb Where, X j is the position of the jth individual, lb and ub are the lower and upper bounds of the search space, and rand is a random number between 0 and 1.

6. The topology optimization method based on the chimpanzee algorithm according to claim 5, characterized in that: In S3, the calculation of flexibility is: C(ρ)=F T U Where C is the flexibility value, F is the load vector, and U is the displacement vector.

7. The topology optimization method based on the chimpanzee algorithm according to claim 6, characterized in that: In S4, during the exploration phase, each chimpanzee changes its position according to the random vector, where the position update formula is: X chimp (t+1)=X prey (t)-a·d Where, X chimp is the current position vector of the chimpanzee, X prey is the current prey position vector, t represents the current iteration number; a is a random vector that determines the distance between the chimpanzee and the prey. When |a|>1, it means that the chimpanzee disperses to search for prey, that is, enters the exploration phase; when |a|<1, it means that the chimpanzee performs an aggressive behavior, which speeds up the convergence of the algorithm. The calculation formula is: a=2·f·r1-f Where f is the convergence factor, which decreases nonlinearly from 2.5 to 0 with the number of iterations, r1 is a random number with a value of [0, 1], so the value range of a is [-f, f]. d is the distance between the chimpanzee and the prey, which is expressed as: d=|c·X prey (t)-m·X chimp (t)| Where c represents the impact factor of obstacles on chimpanzee hunting during the hunting process, and its calculation formula is: c=2·r2 Among them, r2 is a random number with a value of [0, 1]. m is a chaotic mapping vector, which has certain ergodicity and orderliness. Its calculation formula is: m=Chaotic.value.

8. The topology optimization method based on the chimpanzee algorithm according to claim 7, characterized in that: In S5, the specific formula for collaborative position update is: Where X(t+1) is the updated position vector of the current chimpanzee individual, and X1, X2, X3, and X4 are the updated position vectors of the attacker, surrounder, driver, and pursuer. The mathematical model of their attack on prey is: X1=X Attacker -a1·d Attacker X2=X Barrier -a2·d Barrier X3=X Chaser -a3·d Chaser X4=X Driver -a4·d Driver Among them, X Attacker 、X Barrier 、X Chaser 、X Driver Denote the position vectors of the attacker, besieger, chaser and pursuer respectively; d Attacker d Barrier d Chaser d Driver It represents the distance between the attacker, besieger, chaser and pursuer and the prey respectively, and its mathematical model is: d Attacker =|c1 X Attacker -m1 X| d Barrier =|c2 X Barrier -m2 X| d Chaser =|c3 X Chaser -m3 X| d Driver =|c4X Driver -m4 X| Among them, c1, c2, c3 and c4 are the factors that affect the chimpanzees’ hunting caused by obstacles during the hunting process, m1, m2, m3 and m4 are the chaotic mapping vectors, When the chimpanzee's position changes, the corresponding unit density value is also updated to the density value represented by the new position, so as to adjust the unit density value in the exploration phase, making it possible for the algorithm to find a better solution space area.

9. The topology optimization method based on the chimpanzee algorithm according to claim 8, characterized in that: In S7, the termination condition of the algorithm is determined as follows: checking whether the maximum number of iterations t_max or other preset stopping conditions are reached, such as the fitness value reaching a certain threshold: if the termination condition is met, the optimal solution and its corresponding fitness value are output; if the termination condition is not met, the algorithm returns to the exploration stage to continue iterative optimization.