Design of a New 1D Halbach Magnet Array with Good Sinusoidal Magnetic Field by Analyzing the Curved Surface

In the linear and planar motors, the 1D Halbach magnet array is extensively used. The sinusoidal property of the magnetic field deteriorates by analyzing the magnetic field at a small air gap. Therefore, a new 1D Halbach magnet array is proposed, in which the permanent magnet with a curved surface is applied. Based on the superposition of principle and Fourier series, the magnetic flux density distribution is derived. The optimized curved surface is obtained and fitted by a polynomial. The sinusoidal magnetic field is verified by comparing it with the magnetic flux density of the finite element model. Through the analysis of different dimensions of the permanent magnet array, the optimization result has good applicability. The force ripple can be significantly reduced by the new magnet array. The effect on the mass and air gap is investigated compared with a conventional magnet array with rectangular permanent magnets. In conclusion, the new magnet array design has the scalability to be extended to various sizes of motor and is especially suitable for small air gap applications.


Introduction
Linear and planar motors can directly convert electric energy into linear motion mechanical energy without any transmission device of intermediate conversion mechanism [1,2]. They have the advantages of compact structure, high transmission stiffness, fast dynamic response, and high positioning accuracy due to the absence of mechanical conversion parts, and are extensively used in various fields, such as logistics delivery systems, computer numerical control (CNC) machine systems, lithography, and magnetically levitated train systems. The magnetic field on one side of the 1D Halbach permanent magnet array is significantly enhanced due to the arrangement of permanent magnets and has good sinusoidal characteristics. Therefore, the 1D Halbach magnet array is widely applied in linear, planar, and other motors [3][4][5][6][7][8].
Many other researchers have studied linear or planar motors by applying the 1D Halbach magnet array. Won-Jong Kim et al. [9,10] proposed the planar magnetic levitation device, which is composed of four permanent magnet linear motors. The 1D Halbach magnet array with rectangular magnets is used and the magnetic field is represented by Fourier series expansion and the complex theory. M Lee et al. [11] replaced the rectangular magnets with trapezoidal magnets in the double-sided linear motor to produce more force. The magnetic flux density distribution was obtained by adding the magnetic flux density of each permanent magnet. Chen Jun-Wei et al. [12] proposed a new Halbach magnetic array by applying the permanent magnet with a sinusoidal edge. The larger flux density and smaller harmonic distortion can be obtained by the magnet array in a linear motor. The magnetic flux density was derived by generalized blending function mapping and superposition. Irfan-Ur-Rab Usman et al. [13] developed a 6 degree of freedom (DOF) planar levitating synchronous motor. It consists of four linear motors with 1D magnet and superposition. Irfan-Ur-Rab Usman et al. [13] developed a 6 degree of freedom (DOF) planar levitating synchronous motor. It consists of four linear motors with 1D magnet arrays. The coil is made into a printed circuit board. The force fluctuation can be reduced by designing proper separation and spacing magnet arrays. Rui Chen [14] analyzed the M-Magnet array with a magnetization axis in a 45° direction relative to its side surfaces, instead of 0° or 90° magnetization pieces used in a conventional Halbach array. Then, a novel hybrid array based on the M-Magnet array is presented which can attenuate the 6th force ripple. A. Boduroglu et al. [15] proposed a new, skewed magnet arrangement for the linear motor. By comparing the conventional magnet arrangement, the permanent magnet with asymmetric V shape arrangement can reduce the force ripple and has little effect on the average force.
According to the above analysis, in order to improve the performance of the permanent magnet array, a variety of studies have been carried out, such as high force, small harmonic distortion, and low force ripple. In the linear and planar motor, the air gap is very small between the permanent magnets and coils in order to get higher thrust. However, the sinusoidal property of the magnetic field deteriorates when the air gap is small. This can be seen in Figure 1, obtained by the conventional 1D Halbach magnet array with rectangular magnets when the air gap is 1 mm. In the real-time control, the first harmonic of the magnetic flux density is usually used to calculate the force, which will cause the force ripple due to the error with the actual magnetic flux density. It is found that the magnetic flux density has poor sinusoidal property and relatively large error compared with the first harmonic. As we know, one permanent magnet can be regarded as a superposition of countless small pieces according to the superposition principle, so does the magnetic flux density of the permanent magnet. Therefore, the main cause of poor waveform is that the rectangular permanent magnet is used, such as in [1][2][3][4][5][6][7][8][9][10]13,14]. Though the trapezoidal magnet [11], the sinusoidal-edged magnet [12], and the skewed magnet [15] are applied in the motors, the top and bottom surfaces of permanent magnets are flat and the sinusoidal property of the magnetic field also deteriorates in the small air gap. Therefore, the paper is analyzed from a new perspective. The surface shape of the permanent magnet is designed to be curved instead of flat so that the waveform of magnetic flux density can be improved.
In order to obtain the magnetic flux density with good sinusoidal characteristics, the permanent magnet is divided into small pieces and the heights of the small pieces are It is found that the magnetic flux density has poor sinusoidal property and relatively large error compared with the first harmonic. As we know, one permanent magnet can be regarded as a superposition of countless small pieces according to the superposition principle, so does the magnetic flux density of the permanent magnet. Therefore, the main cause of poor waveform is that the rectangular permanent magnet is used, such as in [1][2][3][4][5][6][7][8][9][10]13,14]. Though the trapezoidal magnet [11], the sinusoidal-edged magnet [12], and the skewed magnet [15] are applied in the motors, the top and bottom surfaces of permanent magnets are flat and the sinusoidal property of the magnetic field also deteriorates in the small air gap. Therefore, the paper is analyzed from a new perspective. The surface shape of the permanent magnet is designed to be curved instead of flat so that the waveform of magnetic flux density can be improved.
In order to obtain the magnetic flux density with good sinusoidal characteristics, the permanent magnet is divided into small pieces and the heights of the small pieces are designed. The design of a permanent magnet is a constrained nonlinear multivariable optimization problem. The appropriate optimization algorithm [16][17][18][19][20] should be chosen to realize the design of the new magnet array. In terms of numerical effect and stability, the sequential quadratic programming (SQP) algorithm is considered to be one of the most effective methods to solve nonlinear constrained optimization. Therefore, the heights of the small pieces are optimized by SQP. The shape of the curved surface is obtained by optimization results and is fitted by a least squares method [21,22]. Consequently, a new 1D Halbach magnet array with a curved surface is proposed.

Modeling of the New Magnet Array
The magnetic flux density is modeled in this section. The new magnet array is proposed based on the conventional magnet array with rectangular magnets. The permanent magnet is designed to obtain a good sinusoidal magnetic field. Therefore, the analysis steps are as follows. Firstly, the permanent magnet is divided into small pieces. Then the height of each small piece is independently set. Finally, the magnetic flux density is derived based on the Fourier series. Figure 2 shows the cross-section of the magnet array and the M x projection distribution for small pieces of permanent magnets in the x magnetization direction. The magnetization direction is denoted by the arrow. The direction of the arrow is from the S pole to the N pole. Each small piece of permanent magnet can be seen as one rectangular magnet and is indicated by the blue bar. designed. The design of a permanent magnet is a constrained nonlinear multivariable optimization problem. The appropriate optimization algorithm [16][17][18][19][20] should be chosen to realize the design of the new magnet array. In terms of numerical effect and stability, the sequential quadratic programming (SQP) algorithm is considered to be one of the most effective methods to solve nonlinear constrained optimization. Therefore, the heights of the small pieces are optimized by SQP. The shape of the curved surface is obtained by optimization results and is fitted by a least squares method [21,22]. Consequently, a new 1D Halbach magnet array with a curved surface is proposed.

Modeling of the New Magnet Array
The magnetic flux density is modeled in this section. The new magnet array is proposed based on the conventional magnet array with rectangular magnets. The permanent magnet is designed to obtain a good sinusoidal magnetic field. Therefore, the analysis steps are as follows. Firstly, the permanent magnet is divided into small pieces. Then the height of each small piece is independently set. Finally, the magnetic flux density is derived based on the Fourier series. Figure 2 shows the cross-section of the magnet array and the Mx projection distribution for small pieces of permanent magnets in the x magnetization direction. The magnetization direction is denoted by the arrow. The direction of the arrow is from the S pole to the N pole. Each small piece of permanent magnet can be seen as one rectangular magnet and is indicated by the blue bar. On the basis of the periodic and symmetry characteristics of the magnet array, all the permanent magnets are divided into the same number of small pieces. The side length of each piece is the same. For each permanent magnet, the axis of symmetry is in the middle and both sides have a symmetrical distribution. Therefore, there are four small pieces with the same heights in one period, and these pieces can be regarded as one group shown in Figure 2. If the number of all small pieces of one permanent magnet is 2n, where n is an integer, the number of the small pieces of half of one permanent magnet is n. From this, the permanent magnets magnetized in the x-direction of the magnet array are composed of n groups of pieces, and so are the permanent magnets magnetized in the z-direction.
The Mx of magnet array is modeled based on the Fourier series and expressed as On the basis of the periodic and symmetry characteristics of the magnet array, all the permanent magnets are divided into the same number of small pieces. The side length of each piece is the same. For each permanent magnet, the axis of symmetry is in the middle and both sides have a symmetrical distribution. Therefore, there are four small pieces with the same heights in one period, and these pieces can be regarded as one group shown in Figure 2. If the number of all small pieces of one permanent magnet is 2n, where n is an integer, the number of the small pieces of half of one permanent magnet is n. From this, the permanent magnets magnetized in the x-direction of the magnet array are composed of n groups of pieces, and so are the permanent magnets magnetized in the z-direction.
The M x of magnet array is modeled based on the Fourier series and expressed as where M = B r /µ 0 , ω = π/t, µ 0 is the permeability of vacuum, t is the pole pitch, k is the harmonic numbers, a(i,k) is projection distribution coefficient, B r is the remanence of the permanent magnet, a(i, k) = 8 /kπ sin(kωd/2) sin(kπ/2) sin(kω(p + (2i where d is the side length of the small piece, and p is the side length of the permanent magnet. The magnetization vector of the magnet array consists of M x and M z components. The M z component also can be modeled by using the Fourier series. Figure 3 shows the M z projection distribution of the permanent magnets in the z magnetization direction. monic numbers, a(i,k) is projection distribution coefficient, Br is the remanence of the permanent magnet, where d is the side length of the small piece, and p is the side length of the permanent magnet.
The magnetization vector of the magnet array consists of Mx and Mz components. The Mz component also can be modeled by using the Fourier series. Figure 3 shows the Mz projection distribution of the permanent magnets in the z magnetization direction.
where b(i,k) is the projection distribution coefficient, The magnetization vector of the magnet array is obtained and expressed as There are three regions of the magnetic field in space. From top to bottom, they are air, permanent magnet array, and air. The magnetic scalar potential method is applied to solve the magnetic flux density because there is no conduction current.
The boundary conditions of the interface can be derived from Maxwell's equations. So the magnetic field problem comes down to solve the Poisson equation of magnetic scalar potential [9]. The magnetic flux density is obtained by using the variable separation method. For the region below the magnet array, it is expressed as The expression of M z is The magnetization vector of the magnet array is obtained and expressed as There are three regions of the magnetic field in space. From top to bottom, they are air, permanent magnet array, and air. The magnetic scalar potential method is applied to solve the magnetic flux density because there is no conduction current.
The boundary conditions of the interface can be derived from Maxwell's equations. So the magnetic field problem comes down to solve the Poisson equation of magnetic scalar potential [9]. The magnetic flux density is obtained by using the variable separation method. For the region below the magnet array, it is expressed as where h t (i) and h b (i) are the position of the top and bottom surfaces of each piece of the permanent magnet, respectively, The relative permeability for permanent magnet µ r is assumed as 1.0. Because highquality sintered NdFeB permanent magnets (µ r = 1.03~1.05) will be used, the error due to this assumption can be neglected.

Optimization
The main purpose is to obtain a good sinusoidal magnetic field, which is to make the actual magnetic flux density consistent with the first harmonic of the magnetic flux density. As a result, the actual magnetic field has good sinusoidal characteristics, and the expression can be simplified as that of the first harmonic.
In the real-time control of electrical machines, the first harmonic of the magnetic flux density is usually used to calculate the force. The new magnet array is designed based on the conventional magnet array, and the shape of the surface is optimized. Therefore, the first harmonic of magnetic flux density of the conventional magnet array is chosen in the optimization.
The optimization is realized by reducing the higher harmonics. The shape of the curved surface is obtained by optimizing the height of small pieces. Generally, the main performance of the motors is reflected by the horizontal thrust. It is produced by the z component of the magnetic flux density. So the minimization of the higher harmonics of the z component is chosen to be the objective.
For the conventional magnet array, the first harmonic of the magnetic flux density can be obtained when n takes 1 and expressed as where B x1 and B z1 are the first harmonic of x and z component of magnetic flux density, respectively, K 1 is the coefficient, m h is the height of the permanent magnet, m t and m b are the position of the top and bottom surfaces of the rectangular permanent magnet, respectively, In order to determine the harmonic numbers for optimizing, we take the B r , t, p, and m h parameters of the permanent magnet as 1.2 T, 20 mm, 10 mm, and 10 mm for analysis, respectively. The maximum of the magnetic flux density at 2 mm below the x-axis is about 1.677 × 10 −5 T when k = 25, which is much less than the geomagnetic field (about 6 × 10 −5 T). The harmonic components can be ignored in optimization if the harmonic numbers, k, are more than 25.
Therefore, the approximate expression of the magnetic flux density can be represented by a certain number of harmonics. The z component is given by where m = 25. The higher harmonic components of the new magnet array can be evaluated by According to the periodicity of the magnetic field, the region of half period is chosen. The region is placed 2 mm below the x-axis and divided into 41 points. The objective function is given according to Equations (10) and (14) where x l = 0.025(m − 1)t and z l = −0.002 are the coordinate values.
From the objective function, Equation (15), the reduction of higher harmonics is a constrained nonlinear multivariable optimization problem. The sequential quadratic programming (SQP) algorithm has the advantages of good convergence, high computational efficiency, and strong boundary searchability, which is chosen to realize the optimization. In order to avoid the singular points and obtain better optimization results, the number of pieces of half of one permanent magnet is set to five after analysis. For the whole permanent magnet, the total number of small pieces is 10. It is enough to exhibit well the shape of the curved surface of the permanent magnet.
The optimization parameters and variables are shown in Tables 1 and 2, respectively. Considering the assembly of the permanent magnets, the positions of the top surface of each piece (h t (1), h t (2), . . . , h t (5)) remain the same, and the optimization variables are the positions of the bottom surface of each piece of half of one permanent magnet (h p (1), h p (2), . . . , h p (5)). The 'constraints' in Table 2

Optimization variables Constraints Unit
The results can be seen in Figure 4, the minimization of the objective function is obtained. In Figure 4, the 'current point' denotes the value of the optimization variables and is the best point the solver found in its run. The 'current function value' is the value of the objective function at the current point.   The small pieces of one permanent magnet based on the optimization variables are shown in Figure 5. In the new magnet array, the optimized curved surfaces of permanent magnets in the x and z magnetization directions are the same. The symmetry axis of the curved surface is in the middle and both sides have a symmetrical distribution. h p (1)~h p (5) are the optimization variables and also the positions of bottom surfaces of small pieces of half of one permanent magnet. So the small pieces of one permanent magnet can be obtained according to symmetry. The small pieces of one permanent magnet based on the optimization variables are shown in Figure 5. In the new magnet array, the optimized curved surfaces of permanent magnets in the x and z magnetization directions are the same. The symmetry axis of the curved surface is in the middle and both sides have a symmetrical distribution. hp(1)~hp (5) are the optimization variables and also the positions of bottom surfaces of small pieces of half of one permanent magnet. So the small pieces of one permanent magnet can be We take the permanent magnet whose x coordinate of the center is at zero as an example. The shape of the optimized curved surface of the permanent magnet is shown in Figure 6. The data used to construct the curved surface shape are obtained according to the optimization results. It can be seen that the shape is similar to a sine or power function. The least squares polynomial fitting is used to fit the data. By comparing the results of a polynomial of degrees 2, 3, and 4, the fitting of the polynomial of degree 4 is more accurate. The polynomial of degree 4 is chosen. For better expression and without affecting the accuracy, the first-and third-order terms with very small coefficients are removed, and the sum of squares due to error (SSE) is 1.376×10 −10 m 2 . The computed data of the polynomial is also shown in Figure 6 and the expression is as follows ( ) where a1=3.763×10 5 , a2=34.28, and a3=-3.699×10 -4 are the coefficients, and the value range of hp (1) hp (2) Symmetry axis hp (3) hp (4) hp (5) x Figure 5. The small magnet pieces, based on the optimization variables of one permanent magnet.
We take the permanent magnet whose x coordinate of the center is at zero as an example. The shape of the optimized curved surface of the permanent magnet is shown in Figure 6. The data used to construct the curved surface shape are obtained according to the optimization results. It can be seen that the shape is similar to a sine or power function. The least squares polynomial fitting is used to fit the data. By comparing the results of a polynomial of degrees 2, 3, and 4, the fitting of the polynomial of degree 4 is more accurate. The polynomial of degree 4 is chosen. For better expression and without affecting the accuracy, the first-and third-order terms with very small coefficients are removed, and the sum of squares due to error (SSE) is 1.376 × 10 −10 m 2 . The computed data of the polynomial is also shown in Figure 6 and the expression is as follows According to the optimization and polynomial fitting, the analytical model of the magnetic flux density is simple and expressed as Equation (10). According to the optimization and polynomial fitting, the analytical model of the magnetic flux density is simple and expressed as Equation (10).

Verification with FEM
The new magnet array with a curved surface is obtained by applying the optimization results, and the axonometric drawing is shown in Figure 7. In order to verify the optimization, the magnetic flux density with different z coordinates are compared with the finite element model (FEM). The FEM is built and analyzed by the Ansoft Maxwell. With precision-driven adaptive subdivision technology and a powerful post-processor, Ansoft Maxwell is an excellent high-performance electromagnetic design software in the industry. According to the optimization and polynomial fitting, the analytical model of the magnetic flux density is simple and expressed as Equation (10).

Verification with FEM
The new magnet array with a curved surface is obtained by applying the optimization results, and the axonometric drawing is shown in Figure 7. In order to verify the optimization, the magnetic flux density with different z coordinates are compared with the finite element model (FEM). The FEM is built and analyzed by the Ansoft Maxwell. With precision-driven adaptive subdivision technology and a powerful post-processor, Ansoft Maxwell is an excellent high-performance electromagnetic design software in the industry. The magnetic flux density is obtained by the FEM and analytical model. The x and z components are shown in Figure 8. It is found that the magnetic flux density has a good sinusoidal waveform. The analytical model results fit very well with the FEM results. The total harmonic distortion (THD) [23] is introduced to evaluate the magnetic flux density. The root mean square (RMS) values of the error between the analytical model and FEM and THD of magnetic flux density are shown in Table 3. The magnetic flux density is obtained by the FEM and analytical model. The x and z components are shown in Figure 8. It is found that the magnetic flux density has a good sinusoidal waveform. The analytical model results fit very well with the FEM results. The total harmonic distortion (THD) [23] is introduced to evaluate the magnetic flux density. The root mean square (RMS) values of the error between the analytical model and FEM and THD of magnetic flux density are shown in Table 3.    The RMS(∆B x ), RMS(∆B z ), THD(B x ) and THD(B z ) values for different z coordinates are very small. The maximum RMS(∆B x ) and RMS(∆B z ) values occurred when z is −1 mm, which are 2.19% and 2.14% of the peak value of B x and B z of FEM, respectively. The THD(B x ) and THD(B z ) values are the same according to Equation (7). The maximum THD(B x ) and THD(B z ) values occurred when z is −1 mm, which are both 2.69%. As a result, a new permanent magnet array with a good sinusoidal magnetic field and a simple analytical model of magnetic flux density is obtained.

Different Lengths of Permanent Magnet
In this section, the applicability of optimization results will be discussed when the dimensions of the permanent magnet have changed. The optimization results are obtained with the specific parameters of the permanent magnet array. The fit expression must be improved for different dimensions of the permanent magnet, and the new expression is described as where p 1 is the side length of new permanent magnets which are magnetized in z and x directions, x 1 is the new x coordinate, and the value range is [−p 1 /2, p 1 /2], We take p 1 as 5 mm, 20 mm, 30 mm, and 40 mm, respectively, as an example to verify the new fit expression. Figure 9 shows the results of optimization and the computed data of the new fit expression. It can be seen that the new fit expression has good consistency with the optimization results. Therefore, the new fit expression has good applicability to the permanent magnet with different side lengths. with the optimization results. Therefore, the new fit expression has good applicability to the permanent magnet with different side lengths.

Different Heights of Permanent Magnet
The applicability of optimization results is also analyzed when the height of the permanent magnet is changed. The magnetic flux density of the analytical model and FEM are compared when ht(i) (i=1,2,…,5) takes 5 mm and 15 mm, respectively, which are shown in Figure 10 and Figure 11.

Different Heights of Permanent Magnet
The applicability of optimization results is also analyzed when the height of the permanent magnet is changed. The magnetic flux density of the analytical model and FEM are compared when h t (i) (i = 1, 2, . . . , 5) takes 5 mm and 15 mm, respectively, which are shown in Figures 10 and 11. mum RMS(ΔBx) and RMS(ΔBz) values are 0.0183 T and 0.0168 T, and 2.22% and 2.06% of the peak value of Bx and Bz of FEM when ht(i) (i=1,2,…,5) takes 15 mm, respectively. The maximum THD(Bx) and THD(Bz) values also occur when z takes -1 mm, which are 3.53% and 2.37% of the peak value when ht(i) (i=1,2,…,5) takes 5 mm and 15 mm respectively. Therefore, the new fit expression has good applicability to the permanent magnet with different heights. The applicability of optimization results is verified by analyzing the new magnet arrays with different lengths and heights of permanent magnets. Therefore, the new magnet array can be flexibly designed according to the feature. As long as the shape of the bottom curved surface is consistent with the optimization results, the desired magnetic field strength can be obtained by simply changing the size of the permanent magnet and the magnetic field will still have good sinusoidal characteristics.

The Effect on the Mass
In the new magnet array, the cross-section of the permanent magnet is no longer a rectangle when the curved surface is applied. It is necessary to analyze the effect on the mass. The total mass can be obtained by summing up the mass of all permanent magnets. It is assumed that there is no difference between permanent magnets, so the effect on the mass can be indicated by analyzing one permanent magnet. By analyzing the cross-section of the permanent magnet, the change of mass can be obtained by integrating equation The area ratio of the cross-section between the new permanent magnet and the rec- From Figures 10 and 11, the magnetic flux density also shows a good sinusoidal waveform. The analytical model results fit very well with the FEM results. The maximum RMS(∆B x ) and RMS(∆B z ) values are 0.0151 T and 0.0139 T, and 3.03% and 2.78% of the peak value of B x and B z of FEM when h t (i) (i = 1, 2, . . . , 5) takes 5 mm, respectively. The maximum RMS(∆B x ) and RMS(∆B z ) values are 0.0183 T and 0.0168 T, and 2.22% and 2.06% of the peak value of B x and B z of FEM when h t (i) (i = 1, 2, . . . , 5) takes 15 mm, respectively. The maximum THD(B x ) and THD(B z ) values also occur when z takes −1 mm, which are 3.53% and 2.37% of the peak value when h t (i) (i = 1, 2, . . . , 5) takes 5 mm and 15 mm respectively. Therefore, the new fit expression has good applicability to the permanent magnet with different heights.
The applicability of optimization results is verified by analyzing the new magnet arrays with different lengths and heights of permanent magnets. Therefore, the new magnet array can be flexibly designed according to the feature. As long as the shape of the bottom curved surface is consistent with the optimization results, the desired magnetic field strength can be obtained by simply changing the size of the permanent magnet and the magnetic field will still have good sinusoidal characteristics.

The Effect on the Mass
In the new magnet array, the cross-section of the permanent magnet is no longer a rectangle when the curved surface is applied. It is necessary to analyze the effect on the mass. The total mass can be obtained by summing up the mass of all permanent magnets. It is assumed that there is no difference between permanent magnets, so the effect on the mass can be indicated by analyzing one permanent magnet. By analyzing the cross-section of the permanent magnet, the change of mass can be obtained by integrating equation f 0 (x 0 ). The mass decreases when the result is positive, otherwise, it increases. The integral is expressed as The area ratio of the cross-section between the new permanent magnet and the rectangular permanent magnet is analyzed. The area of the cross-section of the rectangular permanent magnet can be described as where k h × p 1 is the height of the cross-section and k h is the coefficient. The ratio is obtained by It is found that the ratio is independent of the parameter p 1 . The parameter p is set to 10 mm in the design of the surface. The ratio is a fixed value when k h is given. Taking k h = 1 as an example, the ratio value is −0.372%. The increase is very little and has almost no effect on the mass.

The Effect on the Air Gap
Due to the curved surface of permanent magnets, the bottom of the new magnet array is not flat. A part of the bottom curved surface is below the x-axis, according to the optimization results. Compared with the conventional magnet array, the actual air gap between the magnet and the coil is a little smaller. The magnetic field strength will be changed when the air gap remains the same as the conventional magnet array. The influence of the curved surface on the air gap is investigated further.
The lowest point of the curved surface is obtained when x 0 is 0 mm in f 0 (x 0 ). To keep the same air gap, the new z coordinate value, at which the magnetic flux density is calculated, is where z 0 is the original coordinate value, such as −1 mm, or −2 mm, and so on. The magnetic flux density is proportional to the expression of e ωz according to Equation (10). The ratio of the magnetic flux density calculated at the new z coordinate value to the original one is expressed as where ω 1 is redefined for different side lengths of the permanent magnet, The ratio is also a fixed value and independent of the parameter p 1 , which equals e π/2/p×a 3 . The value of the ratio is 94.36% for different lengths of the permanent magnet.
Considering the air gap, the magnetic flux density is slightly decreased. In other words, the new magnet array has a good sinusoidal magnetic field in a very small air gap, sacrificing very little magnetic flux density, which is especially suitable for precision positioning apparatus with strict requirements for a small air gap.

The Effect on the Force
In order to investigate the effect on the force of the new magnet array, the force and force ripple of the new magnet array and the conventional magnet array are compared. In the analytical model for real-time control, the expressions of the magnetic flux density of the two magnet arrays are the same and obtained by Equation (10).
We take the linear motor with a moving magnet array as an example. Figure 12 shows the axonometric diagram of the motor with the new magnet array and coils. The motor with the conventional magnet array is similar and the diagram is not given.
where ω1 is redefined for different side lengths of the permanent magnet, The ratio is also a fixed value and independent of the parameter p1, which equals e π/2/p×a 3. The value of the ratio is 94.36% for different lengths of the permanent magnet. Considering the air gap, the magnetic flux density is slightly decreased. In other words, the new magnet array has a good sinusoidal magnetic field in a very small air gap, sacrificing very little magnetic flux density, which is especially suitable for precision positioning apparatus with strict requirements for a small air gap.

The Effect on the Force
In order to investigate the effect on the force of the new magnet array, the force and force ripple of the new magnet array and the conventional magnet array are compared. In the analytical model for real-time control, the expressions of the magnetic flux density of the two magnet arrays are the same and obtained by Equation (10).
We take the linear motor with a moving magnet array as an example. Figure 12 shows the axonometric diagram of the motor with the new magnet array and coils. The motor with the conventional magnet array is similar and the diagram is not given.  For the convenience of analysis, Figure 13 shows the cross-section of the motor with the new magnet array and the conventional magnet array. In order to remove the position dependency and generate the position-independent force on the array, the dq0 transformation and the three-phase coil are applied. For the convenience of analysis, Figure 13 shows the cross-section of the motor with the new magnet array and the conventional magnet array. In order to remove the position dependency and generate the position-independent force on the array, the dq0 transformation and the three-phase coil are applied. By using the magnetic flux density of Equation (10), the Lorentz force on the magnet array, generated by one coil, is calculated by solving the volume integral and expressed as  By using the magnetic flux density of Equation (10), the Lorentz force on the magnet array, generated by one coil, is calculated by solving the volume integral and expressed as where where N is the number of coil turns, I is the current in the coil, K F is the coefficient, c t and c b are the position of the top and bottom surfaces of the coil, respectively. x co is the coordinate of the coil center in the x-direction, m l is the length of the magnet array in the y-direction, c d is the width of the air core of the coil, c w is the width of the coil, and c h is the height of the coil. For the three-phase coil group, the force can be expressed as where T F is the matrix, x a , x b, and x c are the coordinates of the coil center of the three-phase coil in the x-direction, and d c is the distance between two coil centers. The dq0 transformation matrix is used to remove the position dependency and expressed as By applying the dq0 transformation matrix, the force of the three-phase coil group is replaced as So the current of the coil is expressed as From Equation (34), the levitation force and horizontal thrust are produced by the d axis and q axis current, respectively. Therefore, the position-independent force on the array generated by the three-phase coil is obtained.
The force and force ripple of the two magnet arrays are analyzed and compared. The dimensions of the magnet array shown in Table 1 are used, and the other dimensions of the motor are given in Table 4. The force of the analytical model can be directly calculated by Equation (34) when i d and i q are given. In order to better analyze the effect on the force of the two magnet arrays, the forces of the two magnet arrays calculated by the FEM and analytical model are shown in Figure 14 when the magnet array moves in one period. The i d and i q take −5 A and 0 A respectively. in Figure 14 when the magnet array moves in one period. The id and iq take -5 A and 0 A respectively. It is found that the Fx ripple and Fz ripple of the new magnet array are much smaller than the conventional magnet array. The disturbing force, Fy, is produced by the end of the coil due to the end effect of magnetic flux density according to the Lorentz force formula. The Fy ripple for both magnet arrays is small and essentially zero. The Fx of the new magnet array is slightly smaller than the force of the conventional magnet array which can be inferred from the above analysis of the effect on the air gap.
The new magnet array is built based on the fitting curve, and the magnetic flux density of the new magnet array is expressed in Equation (10), based on the analysis in Section 3. It can be seen from Figure 7 that the magnetic flux density in different z coordinates has a very small error between the analytical model and FEM, but the accumulative error will be produced in the force calculation due to the volume integral by using the analytical model. Therefore, the correction coefficient, Kc, is introduced to establish the analytical model of force for the new magnet array. The force of the new magnet array is modified as follows ( ) It is found that the F x ripple and F z ripple of the new magnet array are much smaller than the conventional magnet array. The disturbing force, F y , is produced by the end of the coil due to the end effect of magnetic flux density according to the Lorentz force formula. The F y ripple for both magnet arrays is small and essentially zero. The F x of the new magnet array is slightly smaller than the force of the conventional magnet array which can be inferred from the above analysis of the effect on the air gap.
The new magnet array is built based on the fitting curve, and the magnetic flux density of the new magnet array is expressed in Equation (10), based on the analysis in Section 3. It can be seen from Figure 7 that the magnetic flux density in different z coordinates has a very small error between the analytical model and FEM, but the accumulative error will be produced in the force calculation due to the volume integral by using the analytical model. Therefore, the correction coefficient, K c , is introduced to establish the analytical model of force for the new magnet array. The force of the new magnet array is modified as follows where F x is the x component of the force obtained by Equation (34), F xFEM is the average value of the x component of the force obtained by the FEM in one period. The force of the analytical model and RMS values of the error between the analytical model and FEM for the two magnet arrays are shown in Table 5.  Table 5, the F x value of the new magnet array is 95.47% of the conventional magnet array. The RMS(∆F y ) for the two magnet arrays are all very small. The RMS(∆F x ) and RMS(∆F z ) values of the new magnet array are reduced a lot, which are 16.01% and 31.75% of the conventional magnet array. Therefore, the new magnet array can significantly reduce the force ripple without sacrificing too much force in comparison to the conventional magnet array.
In order to better observe the advantages of the new magnet array in the small air gap and verify the applicability of the correction coefficient, the air gap, a p , is changed from 1 mm to 0.5 mm. The force of the new magnet array calculated by the FEM and analytical model based on the new air gap is shown in Figure 15. The force of the analytical model and RMS values of the error between the analytical model and FEM for the new magnet array based on the new air gap is shown in Table 6. In order to better observe the advantages of the new magnet array in the small air gap and verify the applicability of the correction coefficient, the air gap, ap, is changed from 1 mm to 0.5 mm. The force of the new magnet array calculated by the FEM and analytical model based on the new air gap is shown in Figure 15. The force of the analytical model and RMS values of the error between the analytical model and FEM for the new magnet array based on the new air gap is shown in Table 6. It is found that the new magnet array still has a small force ripple with the small air gap from Figure 15. The correction coefficient is verified by analyzing the RMS values of the error between the analytical model and FEM from Table 6. The RMS(∆Fy) of the new magnet array is also very small. Compared with the conventional magnet array, with the It is found that the new magnet array still has a small force ripple with the small air gap from Figure 15. The correction coefficient is verified by analyzing the RMS values of the error between the analytical model and FEM from Table 6. The RMS(∆F y ) of the new magnet array is also very small. Compared with the conventional magnet array, with the air gap of 1 mm, the force of the new magnet array is higher and the RMS(∆F x ) and RMS(∆F z ) values are also relatively low, which are 23.11% and 32.82% of the conventional magnet array.
To sum up, through the analysis of the above discussion, the new magnet array with a sinusoidal magnetic field is obtained. The curved surface based on the optimization results has good applicability to different dimensions of the permanent magnet. The new magnet array can be designed flexibly according to the feature. In contrast to the conventional magnet array, the new magnet array has little influence on the mass and air gap and can significantly reduce the force ripple. The new magnet array still maintains the small force ripple in the small air gap.

Conclusions
A new 1D Halbach magnet array with a curved surface of the permanent magnet is proposed in this paper. The curved surface design method of the permanent magnet is realized based on the superposition principle. The shape of the optimized curved surface is similar to a sine or power function and fitted by a polynomial. The expression of magnetic flux density is simple and the same as the first harmonic of the conventional magnet array with rectangular permanent magnets. A good sinusoidal magnetic field is obtained in a very small air gap. The optimization results have good applicability to different dimensions of the permanent magnet. The effect on the mass of the permanent magnet array is very small. The magnetic flux density is slightly decreased when the air gap remains the same as the conventional magnet array. The new magnet array can significantly reduce the force ripple in comparison to the conventional magnet array. The new magnet array is especially suitable for precision positioning apparatus with strict requirements for a small air gap. The method of surface design of permanent magnet can be used for similar 2D permanent magnet arrays.
In future work, a combined global-local optimization method will be further investigated to improve the optimization and identify the exact solution. Furthermore, the model structural design methodology will be studied to determine the fitted terms automatically.