An accelerator automatic beam tuning modeling method

By employing an automatic beam tuning modeling method for accelerators, combining coarse and fine tuning stages, and using differential evolution, Brownian motion, and Levy flight strategies to optimize power parameters, the problems of existing technologies such as beam tuning relying on experience, insufficient accuracy, and lack of globally optimal parameters are solved, achieving high-precision beam tuning with millisecond-level variations.

CN118981869BActive Publication Date: 2025-11-11CHINA INSTITUTE OF ATOMIC ENERGY
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202410973999.1
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-07-19
Publication Date
2025-11-11
Estimated Expiration
2044-07-19

AI Technical Summary

Technical Problem

Existing cyclotron beam tuning methods rely on experience, making it difficult to guarantee beam performance, impossible to observe millisecond-level changes, and fixed intervals and step sizes result in insufficient tuning precision and the inability to achieve globally optimal parameters.

Method used

An automatic beam-tuning modeling method for accelerators is adopted. By establishing an automatic beam-tuning initial value model and objective function, and combining coarse and fine tuning stages, differential evolution, Brownian motion, and Levy flight strategies are used to optimize power parameters, thereby achieving simultaneous adjustment and high-precision regulation of multiple subsystem parameters.

Benefits of technology

Simultaneous adjustment of parameters from multiple subsystems was achieved, improving adjustment accuracy. Millisecond-level changes could be observed and located, ensuring beam performance. This solved the shortcomings of manual beam tuning and achieved globally optimal parameters.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118981869B_ABST
    Figure CN118981869B_ABST
Patent Text Reader

Abstract

This invention proposes an automatic beam tuning modeling method for accelerators, comprising: establishing an automatic beam tuning initialization model D. ij And initialize the model D. ij Initialize the parameters to be adjusted, and set the total number of power supply parameter optimizations T and the initial number of power supply parameter optimizations t = 0; establish the objective function F, and set the objective value O. k 'and actual value O k Perform difference calculation; let t = t + 1 to coarsely adjust all alternative schemes for the beam parameters of all subsystems, and obtain the beam update scheme D for the coarse adjustment section. i_best The D i_best The optimal alternative scheme is selected from multiple options during the joint debugging of all subsystems. Based on the coarse adjustment, the alternative scheme is adjusted to obtain the optimal scheme for beam current update in the fine adjustment segment. The process is then determined: if t = t + 1, return to step three; otherwise, the process ends. This invention solves the problems of manual beam tuning, which relies on experience, cannot observe millisecond-level changes, has insufficient adjustment precision, and only achieves locally optimal parameters, by organically combining the automatic beam tuning model D, the objective function F, and the coarse and fine adjustment stages.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention belongs to the field of cyclotrons, specifically relating to an automatic beam-tuning modeling method for accelerators. Background Technology

[0002] Cyclotron systems are numerous and complex, including ion source systems, injection line systems, main accelerator systems, beam line systems, water cooling systems, vacuum systems, pneumatic systems, and so on. The coupling between these systems is strong, and the extraction of the beam requires coordination between the parameters of multiple systems. It takes a lot of time for professional commissioning personnel to adjust the target beam.

[0003] Existing commissioning methods primarily involve experienced operators making step-by-step adjustments to the accelerator's multi-stage systems. First, the ion source system is adjusted, repeatedly testing power parameters to induce filament arcing. Then, several key parameters are adjusted to continuously increase beam efficiency, requiring constant monitoring of the power supply status and parameter adjustments. After the beam is extracted, the process continues to the next system, again involving adjusting multiple parameters and observing the beam status of the previous system before repeated adjustments. This process is repeated until the extracted beam on the target of the final system equals the set target beam value. Some methods utilize automated programs, employing simple hill-climbing algorithms to linearly increase or decrease power parameters while simultaneously observing the beam status until the target beam value is achieved.

[0004] Problems with existing technology:

[0005] 1. Manual beam adjustment relies on experience and it is difficult to guarantee the beam effect. Cyclotrons require rapid and stable beam output in practical applications. However, manually adjusting beam parameters is not only time-consuming and labor-intensive, but the effect also depends on the operator's experience. There is no unified adjustment scheme, making it difficult to guarantee the beam effect. Furthermore, errors by operators lacking practical adjustment experience may cause irreparable damage to the accelerator.

[0006] 2. Manual beam tuning cannot detect millisecond-level changes. Accelerator system data changes at the millisecond level. Manual beam tuning can only adjust a few parameters of a single system, making it impossible to simultaneously observe parameters of multiple subsystems, thus preventing the observation of millisecond-level changes in multiple subsystems.

[0007] 3. Fixed-interval and fixed-step-size beam tuning methods result in insufficient tuning accuracy. Since existing tuning processes involve variations and adjustments within a fixed interval, the accuracy of this interval and the step size of each adjustment significantly impact the results. If the interval is too small, the optimal parameters may not be within it; if the interval is too large, system oscillations will increase, and the tuning time for individual parameters will be longer. A large step size for each adjustment will shorten the tuning time for a single parameter but reduce tuning accuracy; a small step size will improve accuracy but also lengthen the tuning time. Finding the optimal parameter combination quickly and effectively remains difficult.

[0008] 4. Only locally optimal parameters are achieved, not globally optimal parameters. There are strong coupling relationships between the various systems in the accelerator. Adjusting one parameter and then adjusting subsequent parameters will affect previously adjusted parameters. Current solutions lack unified adjustment of parameters across multiple systems, only achieving optimal beam parameters for one system without considering the influence of other systems. Therefore, parameter matching between multiple systems cannot be achieved, and the adjusted beam parameters may only be locally optimal, failing to achieve globally optimal parameters. Summary of the Invention

[0009] To address the problems existing in the prior art, this invention proposes an automatic beam tuning modeling method for accelerators. The first objective is to solve the problem that manual beam tuning relies on experience and it is difficult to guarantee the beam effect. The second objective is to solve the problem that manual beam tuning cannot observe millisecond-level changes. The third objective is to solve the problem that the existing beam tuning methods use fixed intervals and fixed step sizes, resulting in insufficient adjustment accuracy. The fourth objective is to solve the problem that existing beam tuning methods only achieve locally optimal parameters and cannot achieve globally optimal parameters.

[0010] To solve its technical problems, the present invention proposes the following technical solutions:

[0011] An automatic beam tuning modeling method for accelerators, characterized by the following steps:

[0012] Step 1: Establish the automatic beam adjustment initial value model D ij And initialize the model D. ij The parameters to be adjusted are assigned initial values, and the total number of power parameter optimizations T and the initial number of power parameter optimizations t = 0 are set.

[0013] Step 2: Establish the objective function F, and set the objective value O. k 'and actual value O k Perform difference calculation;

[0014] Step 3: Let t = t + 1; perform coarse adjustment on all alternative schemes D for the beam parameters of all subsystems to obtain the coarse adjustment segment beam update scheme D. i_best The Di_best The best alternative among multiple options in the joint debugging of all subsystems;

[0015] Step 4: Based on the coarse adjustment stage, adjust the alternative schemes from the coarse adjustment stage to obtain the optimal scheme D for beam current renewal in the fine adjustment stage. i_best ;

[0016] Step 5: Determine if t = T. If not, return to step 3; if yes, end.

[0017] Furthermore, the initial value model D for automatic beam tuning of the accelerator is established in step one. ij And initialize the model D. ij The initial values ​​are assigned to the parameters to be adjusted in the following process:

[0018] 1) Identify the subsystems to be tuned, including: ion source subsystem, injection line subsystem, main accelerator subsystem, and beamline subsystem;

[0019] 2) Establish the initial value model D ij The initial value model is as follows:

[0020] D ij =lb j +rand×(ub j -lb j ) i=1,2,…N; j=1,2,…Dim (1)

[0021] In formula (1), i on the left represents the i-th row of the matrix, j represents the j-th column of the matrix; i = 1, 2, ... N represents that there are N alternative schemes in the matrix; j = 1, 2, ... Dim represents that each row of the matrix has Dim parameters; lb on the right side of formula (1) j and ub j are the upper and lower bounds of the j-th tuned parameter, respectively, and rand represents a random value between 0 and 1.

[0022] Furthermore, in step 1, process 2), the initial value model D is established. ij The specific process is as follows:

[0023] i. Determine the individual subsystems in all alternative schemes D for all subsystem beam parameters;

[0024] D = [D IS D IL D MA D BL (2)

[0025] Where: D IS For the ion source parameter subsystem to be adjusted; D ILFor the subsystem of parameters to be adjusted in the injection line; D MA The main accelerator parameter tuning subsystem; D BL For the beamline parameter adjustment subsystem;

[0026] ii. Determine the set of parameters to be tuned for each subsystem D IS D IL D MA D BL ;

[0027] D IS = [D1 D2 D3 D4];

[0028] D IL =[D5 D6 … D 12 ];

[0029] D MA =[D 13 D 14 … D 18 ];

[0030] D BL =[D 19 D 20 … D 24 ];

[0031] Where: D IS The set of N rows and 4 columns of parameters to be adjusted for the ion source subsystem; D IL For the N rows and 8 columns of parameters to be adjusted in the injection line subsystem; D MA The set of N rows and 6 columns of adjustable parameters for the main accelerator subsystem; D BL The set of N rows and 6 columns of parameters to be adjusted for the beamline subsystem; where N represents N alternative schemes for each subsystem.

[0032] iii. Determine the adjustment parameters for each subsystem:

[0033] D IS The ion source system has four adjustable parameters: filament power supply current (A), arc voltage power supply current (A), absorber power supply voltage (kV), and plasma power supply voltage (kV).

[0034] D IL The injection line system has 8 adjustable parameters: 1X guide magnet power supply current (A), 1Y guide magnet power supply current (A), 2X guide magnet power supply current (A), 2Y guide magnet power supply current (A), injection line solenoid power supply voltage (V), injection line solenoid power supply current (A), injection line solenoid power supply voltage (V), and injection line solenoid power supply current (A).

[0035] D MAThe main accelerator system has six adjustable parameters: positive deflection plate power supply voltage (kV), positive deflection plate power supply current (mA), negative deflection plate power supply voltage (kV), negative deflection plate power supply current (mA), main magnet power supply voltage (V), and main magnet power supply current (A).

[0036] D BL The beamline system has six adjustment parameters: beamline X-guide power supply current (A), beamline Y-guide power supply current (A), beamline fourth-stage lens power supply current 1 (A), beamline fourth-stage lens power supply current 2 (A), rotating magnet power supply voltage (V), and rotating magnet power supply voltage (A).

[0037] iv. Determine the total adjustable parameter D for each subsystem. MA

[0038] There are a total of 24 adjustment parameters for all subsystems, i.e., Dim = 24.

[0039] Furthermore, by expanding each subsystem of the above formula (2), the following are all the alternative schemes D for the beam parameters of all subsystems arranged in N rows and Dim columns:

[0040]

[0041] Where, d i d represents the i-th alternative. i,j The value of the j-th beam parameter to be optimized represents the i-th alternative scheme.

[0042] Furthermore, in step two, the objective function F is established for the objective value O. k 'and actual value O k The difference is calculated as follows:

[0043]

[0044] In formula (4), F on the left represents the objective function, and D on the right represents the objective function. i Representing the i-th alternative solution of the four subsystems, O on the right side of equation (4) k O represents the current actual beam output value of the k-th subsystem of the i-th alternative scheme obtained according to formula (2). k 'Represents the ideal target beam current value of the k-th subsystem of the i-th alternative scheme, where k = 1, 2, 3, 4 represent the ion source beam current, internal target beam current, stripped target beam current, and beryllium target beam current, respectively; F i O represents the ideal beam current value of the i-th alternative. k 'and actual beam current value O k The difference;

[0045] In formula (4), only the ion source subsystem has ΔD.av Other subsystems do not have ΔD av .

[0046] Furthermore, the O in formula (4) k The calculation is as follows:

[0047] When k = 1, 2, 3, 4 in formula (4),

[0048] O4'=α1O1'=α2O2'=α3O3' (5)

[0049] Wherein, O4' is the known target beam, namely the beryllium target beam, and α1, α2, and α3 are the known engineering debugging experience of the accelerator and the transmission efficiency of each stage. Based on the known O4' and α1, α2, and α3, the magnitudes of other beam target values ​​O1', O2', and O3' are calculated; where O1' represents the target value of the ion source beam, O2' represents the target value of the internal target beam, and O3' represents the target value of the stripped target beam.

[0050] ΔD of formula (4) av The calculation is as follows:

[0051] ΔD av =(D av -D av ') (6)

[0052] D on the right side of formula (6) av D represents the actual voltage value of the current arc voltage power supply. av 'Target voltage value of the arc voltage power supply; set the target voltage value D of the arc voltage power supply based on engineering experience.' av =120;

[0053] The O in formula (4) k -O k The calculation is as follows:

[0054] ΔO k =O k -O k (7)

[0055] O on the right side of formula (7) k According to formula (5), O k To obtain the beam current value of a certain subsystem from actual measurement, the parameters of the four subsystems in formula (2) are adjusted simultaneously. If one of the subsystems does not improve, no update is performed; if ΔO k_new <ΔO k_old This indicates that the beam O k Improvements were achieved, approaching the set beam target value. The corresponding system parameters were updated. If ΔO k_new ≥ΔO k_oldThis indicates that the beam O k If no improvement is achieved, the original parameters should be kept unchanged; the state of the arc voltage should also be considered in the ion source system, therefore the update conditions for the ion source system are:

[0056] ΔO 1_new +ΔD av_new <ΔO 1_old +ΔD av_old (8)

[0057] Formula (8) takes the ion source subsystem as an example. On the left side of Formula (8), ΔO 1_new This is the difference between the actual beam current and the target value of the updated ion source system; ΔD av_new The difference between the actual value and the target value of the arc voltage of the updated ion source system; ΔO on the right side of formula (8) 1_old ΔD represents the difference between the actual and target beam current values ​​of the ion source system in the last update. av_old This is the difference between the actual value and the target value of the arc voltage of the ion source system in the previous test; Formula (8) only applies to the ion source subsystem. av_new Other subsystems do not have ΔD av_new .

[0058] Furthermore, in step three, all alternative schemes D for the beam parameters of all subsystems are coarsely adjusted to obtain the coarse adjustment segment beam update scheme D. i_best The specific process is as follows:

[0059] i. Judgment If yes, select to perform the initial stage of beam coarse adjustment; otherwise, determine... If yes, perform mid-stage beam coarse adjustment; otherwise, perform late-stage beam coarse adjustment.

[0060] ii. Obtain the coarse-tuning stage beam scheme D i The beam parameter set update conditions are shown in formula (9). The updated beam parameter scheme is compared with the previous scheme, and the scheme that is closer to the target beam is selected as the updated beam scheme. The beam scheme D in the coarse adjustment stage i The update conditions are as follows:

[0061]

[0062] Where P1 represents the coarse adjustment stage, and D... i For the updated i-th beam parameter scheme, For the i-th beam parameter update scheme using the coarse adjustment strategy, This is the beam parameter scheme updated last time. The i-th set of beam objective functions updated using the coarse-tuning strategy. This is the beam objective function set updated last time.

[0063] iii. By D i Select the optimal value D best where i = 1, 2, ..., N;

[0064] iv. Return to step four.

[0065] Furthermore, if the pre-beam coarse adjustment phase is selected, the specific process is as follows:

[0066] The early stage of beam coarse adjustment, i.e. At that time, a differential evolution strategy is used to update and iterate the beam parameters. The differential evolution strategy uses two random alternative schemes generated by formula (10) to update the beam parameters, calculates the difference value between the two sets of beam parameters to generate new beam parameters, and the update formula is as follows:

[0067]

[0068] in:

[0069] d random_1 =lb j +rand×(ub j -lb j )

[0070] d random_2 =lb j +rand×(ub j -lb j )

[0071] In formula (10), P1 on the left side represents the coarse adjustment stage. This represents the beam parameters in the coarse adjustment stage in row i and column j of formula (3); the right side of formula (10) (d random_1 -d random_2 The term )×R1 represents the differential movement strategy, where d i,j d represents the beam parameters in row i and column j of formula (3) in the previous time. random_1 and d random_2 All are generated within the beam parameter range according to formula (1), where R1 is the random factor of the current strategy, and is a random number between 0 and 1, lb j and ub j The upper and lower bounds of the j-th adjusted parameter are respectively, and rand represents a random value between 0 and 1;

[0072] If you choose to perform intermediate beam coarse adjustment, the specific process is as follows:

[0073] During the mid-stage of beam coarse adjustment, i.e. At that time, a Brownian motion strategy is used to update the beam parameters. This strategy involves iteratively updating the beam parameters by finding suitable beam parameters in the vicinity of the historical best parameter set, and incorporating the historical best beam parameter set:

[0074]

[0075] In formula (11), P1 on the left side represents the coarse adjustment stage. This represents the beam parameters in the coarse adjustment stage in row i and column j; the first term d on the right-hand side of the formula is... best This represents the optimal beam parameters in the coarse-tuning stage in row i and column j; the second term on the right-hand side of the formula is exp((t / T)∧4)×(RB-0.5)×(d best -d i,j ) represents the Brownian motion strategy, where d i,j represents the beam parameters in row i and column j of formula (3) in the previous time, t represents the current number of parameter optimizations, T represents the total number of parameter optimizations set by the algorithm, RB represents the Brownian motion factor, which is a number randomly generated according to a standard normal distribution with a mean of 0 and a standard deviation of 1, and exp represents the natural exponential function.

[0076] If you choose to perform the beam coarse adjustment post-process, the specific procedure is as follows:

[0077] The later stage of beam coarse adjustment, i.e. To reduce the probability of beam parameters getting trapped in local optima and improve the speed and accuracy of parameter optimization, a Levy flight strategy is introduced, adding a nonlinear factor to increase the beam convergence range. The revised formula is as follows:

[0078]

[0079] In formula (12), P1 on the left side represents the coarse adjustment stage. This represents the beam parameters in the coarse adjustment stage of row i and column j; the first term d on the right side of formula (12) best This represents the optimal beam parameters in the coarse adjustment stage of row i and column j; the second term on the right side of formula (12) is ((1-t / T)∧(2×t / T))×d i,j ×RL represents the Levy flight strategy, where (1-t / T)∧(2×t / T) represents the time range of the coarse-tuning phase; t represents the current number of parameter optimizations, and T represents the total number of parameter optimizations set for the algorithm; d i,j This represents the beam parameters in row i and column j of formula (3) in the previous iteration;

[0080] In formula (12), RL represents the flight strategy factor. The nonlinear factor determines the step size and increment / decrease of parameter optimization through the flight distribution function, which helps the beam parameters escape local optima and find the global optimal set of beam parameters.

[0081] RL=0.5×Levy (13)

[0082] Where Levy represents the flight distribution function, the weighting coefficient of 0.5 is used to improve the convergence interval of the beam parameters and avoid excessively large step sizes that could cause the beam parameters to exceed their limits. The Levy distribution function is calculated as follows:

[0083]

[0084] In the distribution function of formula (14), s is a fixed constant of 0.01, η is a fixed constant of 1.5, u and v are random numbers between 0 and 1, used to control the step size of beam parameter adjustment, and the calculation formula of σ is as follows:

[0085]

[0086] In formula (15), σ on the left is used to control the step size and direction of the beam parameters; Γ on the right represents the gamma function. This distribution increases the extreme variation conditions of the beam parameters, which helps to find a wider range of beam parameters; η is a fixed constant of 1.5.

[0087] Substituting σ from formula (15) into formula (14), then substituting Levy from formula (14) into formula (13), and then substituting RL from formula (13) into formula (12), we obtain the beam parameters in row i and column j of the coarse adjustment stage after coarse adjustment in the current coarse adjustment segment according to formula (12).

[0088] Furthermore, in step four, based on the coarse adjustment stage, adjustments are made to the alternative schemes from the coarse adjustment stage to obtain the optimal scheme D for beam current updating in the fine adjustment stage. best The fine adjustment segment beam update scheme is as follows:

[0089] 1) Determine rand i If the value is greater than 0.5, then update D using the C1 strategy of formula (16). i If not, update D using the C2 strategy of formula (16). i ;

[0090]

[0091] In formula (16), P2 on the left side represents the fine-tuning stage. This represents the beam parameters in row i and column j during the fine-tuning phase; C1 and C2 on the right side of formula (16) are the beam parameters updated by the strategy, d best This represents the optimal beam parameters in row i and column j during the fine-tuning stage, d i,j This represents the beam parameters in row i and column j from the previous fine-tuning stage, d randomIt is generated according to formula (1) within the beam parameter range, where t represents the current number of parameter optimizations and T represents the total number of parameter optimizations set by the algorithm; rand i Let R1 be a random number between 0 and 1, representing the probability of executing strategy C1 or C2 for the i-th alternative. R2 and R3 are randomly generated numbers between 0 and 1 that conform to a normal distribution. R1 is used to control the increase or decrease of the beam parameters, and R2 is used to control the step size of the beam parameters. K represents the random selection of an integer 1 or 2. The probabilities of C1 and C2 occurring are equal.

[0092] 2) Determine whether to use strategies C1 and C2 to update the beam parameters D. i Afterwards, check if the beam is close to the target value. If not, execute the adaptive controller to update the beam parameters during the coarse-tuning phase. If so, update Di.

[0093] 3) By D i Select the optimal value D best where i = 1, 2, ..., N;

[0094] 4) Return to step five.

[0095] Furthermore, in step four, process 2), the adaptive controller updates the beam parameters during the coarse-tuning stage. Taking the ion source system as an example, the updated parameter D... IS_new as follows:

[0096] 1)D IS_new =ΔD IS +D IS_best (17)

[0097] D on the left side of formula (17) IS_new The beam parameter set is updated by the ion source system through the proportional controller; ΔD on the right side of equation (17) IS It is obtained by multiplying e1 by the adaptive coefficient of the proportional controller. e1 is the sum of two differences, the first of which is the current optimal ion source beam O. 1_best and target ion source beam O 1_target The difference between them, the second difference is the current arc voltage power supply voltage value D. av_target With the optimal arc voltage power supply value D av_best Difference between; D IS_best It is the current optimal set of ion source beam parameters;

[0098] 2) The first term on the right side of formula (17) is calculated as follows:

[0099] ΔD IS = kp × (1 - t / T) 2 ×e1 (18)

[0100] Where kp=±0.05 adjusts the beam parameters of the ion source system from two directions, and takes the beam close to the target value as the updated parameters. t represents the current number of parameter optimizations, T represents the total number of parameter optimizations set by the algorithm, and the (1-t / T) item can control the step size of beam optimization in the later stages of the algorithm to gradually decrease.

[0101] 3) Formula (18)e1 is calculated as follows:

[0102] e1=((O 1_target -O 1_bset )+(D av_target -D av_best (19)

[0103] Among them O 1_target This is the target value of the ion source beam, O 1_bset The current optimal value of the ion source beam, D av_target It is the target value of the arc current power supply voltage, D. av_best This is the optimal value for the arc current power supply voltage;

[0104] 4) The ion source beam parameters have been updated as follows:

[0105]

[0106] D IS These are the beam parameters of the ion source system after the proportional control stage; P2 indicates the fine-tuning stage. This represents the proportionally adjusted ion source beam parameters, ΔO. 1_new It is the difference between the proportionally adjusted ion source beam and the target beam, ΔD. av_new It is the difference between the proportionally adjusted arc voltage and the target arc voltage, ΔO. 1_old It is the difference between the ion source beam and the target beam during the coarse adjustment stage, ΔD av_old It is the difference between the arc voltage supply voltage value during the coarse adjustment stage and the target arc voltage supply voltage value.

[0107] The process of updating the beam parameters of the other three systems is similar to that of the ion source system, and D is obtained accordingly. IL D MA D BL ;

[0108] 5)D best =[D IS D IL D MA D BL ].

[0109] Advantages and effects of the present invention

[0110] 1. By establishing an automatic beam-tuning model D, not only can all parameters of multiple subsystems be adjusted simultaneously, but also multiple alternative schemes i=1,2,…N of each subsystem can be adjusted simultaneously. This solves the problem that there is a strong coupling relationship between the various systems of the accelerator, and that adjusting subsequent parameters after adjusting one parameter will also affect the previously adjusted parameters.

[0111] 2. By establishing an objective function F, an adjustment target is provided for the coarse and fine adjustment stages. This invention sets the target value O of the objective function F. k 'and actual value O k Furthermore, the coarse-tuning and fine-tuning stages are cleverly combined, with each stage updating the actual value O of the objective function F. k Then, the objective function F undergoes a new difference calculation, and this process is repeated until the objective value O is reached. k 'and actual value O k The difference is reduced to 0.

[0112] 3. By organically combining coarse and fine adjustments, high-precision positioning of millisecond-level changes, rapid positioning of millisecond-level changes, and positioning of millisecond-level changes using optimization algorithms are achieved. This solves the problems of manual beam tuning relying on experience and making it difficult to guarantee beam current effectiveness, the inability to observe millisecond-level changes in manual beam tuning, and insufficient adjustment accuracy due to the use of fixed intervals and fixed step sizes in manual beam tuning. Specifically, the results of each coarse adjustment determine the range of optimal power parameters for each of the four subsystems. The fine adjustment stage further filters based on the coarse adjustment to find the optimal power parameters for each range. Attached Figure Description

[0113] Figure 1 This is a flowchart of an automatic beam tuning modeling method for accelerators according to the present invention;

[0114] Figure 2 The flowchart for optimizing power supply parameters using a coarse-tuning method in this invention is shown below.

[0115] Figure 3 The flowchart of the power supply parameter optimization method used in this invention is as follows;

[0116] Figure 4 This is a schematic diagram illustrating the update of beam parameters during the fine-tuning stage using an adaptive controller, as described in this invention. Detailed Implementation

[0117] Design principle of the invention

[0118] 1. Innovation of this invention: The innovation lies in the organic combination of the automatic beam tuning model D, the objective function F, and the coarse and fine tuning stages, which solves four problems of the prior art. First, by establishing the automatic beam tuning model D, the goal of simultaneously adjusting the power parameters of the four subsystems is achieved, solving the problem that there is a strong coupling relationship between the various systems of the accelerator, and that adjusting subsequent parameters after adjusting one parameter will also affect the previously adjusted parameters. The simultaneous adjustment means that in the coarse tuning stage of formulas (9) to (15) and the fine tuning stage of formulas (16) to (20), the parameters representing the j=1,2,…Dim columns of the four subsystems in formula (3) are adjusted simultaneously. Second, by establishing the automatic beam tuning model D, not only can all parameters of multiple subsystems be adjusted simultaneously, but also multiple alternative schemes i=1,2,…N of each subsystem can be adjusted simultaneously, further solving the problem of the strong coupling relationship between the various systems of the accelerator. Thirdly, by establishing an objective function F, an adjustment target is provided for the coarse and fine adjustment stages. This invention sets the target value O of the objective function F. k 'and actual value O k Furthermore, the coarse-tuning and fine-tuning stages are cleverly combined, with each stage updating the actual value O of the objective function F. k Then, the objective function F undergoes a new difference calculation, and this process is repeated until the objective value O is reached. k 'and actual value O k The difference is kept until it reaches 0. Fourth, coarse and fine adjustments are organically combined. Each coarse adjustment only determines the range of optimal power parameters for each of the four subsystems, but not the specific values. The fine adjustment stage further filters based on the coarse adjustment to find the optimal power parameters for each range. The optimal power parameters are those that allow the actual beam current value to be 0. k Closer to the target value O k The parameter of '.

[0119] 2. Initial value model D ij Design principle: The first thing this invention does is to establish an automatic beam-tuning initial value model D in step one. ij Initial value model D ij Expanded, it takes the form of formula (3). Formula (3) has two functions. First, it is used to assign initial values ​​to all power parameters in the matrix of formula (3). Only after assigning initial values ​​can the coarse and fine adjustments in steps three and four be performed. The method for assigning initial values ​​is formula (1). Second, formula (3) is used to further optimize the parameters in formula (3) that have already been assigned initial values ​​in the coarse and fine adjustment stages. The purpose of optimization is to make the actual output beam current O k The value is close to the target value O k Here, the power supply parameters and the actual output beam current Ok There is a correspondence, due to the beam O k There's no way to debug it directly; you can only adjust the power supply parameters. Since the beam current is controlled by the power supply parameters, adjusting these parameters indirectly regulates the actual output beam current. k The purpose.

[0120] 3. Design Principle of Objective Function F: The objective function of this invention plays a bridging role. "Bridging" refers to introducing the preceding model D, while "bridging" refers to providing adjustment targets for the subsequent coarse and fine-tuning stages. The 0 in the objective function F... k It cannot function without model D, nor without the algorithms used in the coarse-tuning and fine-tuning stages.

[0121] The objective function F is used to provide the adjustment target for the coarse and fine adjustment stages; the target is to make O k -O k The difference is close to 0: making the difference close to 0 means that the actual beam current value O k Approaching the target value O k The actual beam current value O k Approaching the target value O k 'It's not about directly adjusting the beam; the beam O' k There's no way to debug it, but the power supply parameters and the actual output beam current are... k There is a corresponding relationship, so the actual output beam current O in the objective function F can be indirectly adjusted by adjusting the power supply parameters during the coarse and fine adjustment stages. k The purpose.

[0122] Based on the above principles, this invention designs an automatic beam tuning modeling method for accelerators, such as... Figure 1-4 As shown, its characteristics include the following steps:

[0123] An automatic beam tuning modeling method for accelerators, characterized by the following steps:

[0124] Step 1: Establish the automatic beam adjustment initial value model D ij And initialize the model D. ij The parameters to be adjusted are assigned initial values, and the total number of power parameter optimizations T and the initial number of power parameter optimizations t = 0 are set.

[0125] Step 2: Establish the objective function F, and set the objective value O. k 'and actual value O k Perform difference calculation;

[0126] Step 3: Let t = t + 1; perform coarse adjustment on all alternative schemes D for the beam parameters of all subsystems to obtain the coarse adjustment segment beam update scheme D. i_bestThe D i_best The best alternative among multiple options in the joint debugging of all subsystems;

[0127] Step 4: Based on the coarse adjustment stage, adjust the alternative schemes from the coarse adjustment stage to obtain the optimal scheme D for beam current renewal in the fine adjustment stage. i_best ;

[0128] Step 5: Determine if t = T. If not, return to step 3; if yes, end.

[0129] Furthermore, the initial value model D for automatic beam tuning of the accelerator is established in step one. ij And initialize the model D. ij The initial values ​​are assigned to the parameters to be adjusted in the following process:

[0130] 1) Identify the subsystems to be tuned, including: ion source subsystem, injection line subsystem, main accelerator subsystem, and beamline subsystem;

[0131] 2) Establish the initial value model D ij The initial value model is as follows:

[0132] D ij =lb j +rand×(ub j -lb j ) i=1,2,…N; j=1,2,…Dim (1)

[0133] In formula (1), i on the left represents the i-th row of the matrix, j represents the j-th column of the matrix; i = 1, 2, ... N represents that there are N alternative schemes in the matrix; j = 1, 2, ... Dim represents that each row of the matrix has Dim parameters; lb on the right side of formula (1) j and ub j are the upper and lower bounds of the j-th tuned parameter, respectively, and rand represents a random value between 0 and 1.

[0134] Furthermore, in step 1, process 2), the initial value model D is established. ij The specific process is as follows:

[0135] i. Determine the individual subsystems in all alternative schemes D for all subsystem beam parameters;

[0136] D = [D IS D IL D MA D BL (2)

[0137] Where: D IS For the ion source parameter subsystem to be adjusted; D ILFor the subsystem of parameters to be adjusted in the injection line; D MA The main accelerator parameter tuning subsystem; D BL For the beamline parameter adjustment subsystem;

[0138] ii. Determine the set of parameters to be tuned for each subsystem D IS D IL D MA D BL ;

[0139] D IS = [D1 D2 D3 D4];

[0140] D IL =[D5 D6…D 12 ];

[0141] D MA =[D 13 D 14 …D 18 ];

[0142] D BL =[D 19 D 20 …D 24 ];

[0143] Where: D IS The set of N rows and 4 columns of parameters to be adjusted for the ion source subsystem; D IL For the N rows and 8 columns of parameters to be adjusted in the injection line subsystem; D MA The set of N rows and 6 columns of adjustable parameters for the main accelerator subsystem; D BL The set of N rows and 6 columns of parameters to be adjusted for the beamline subsystem; where N represents N alternative schemes for each subsystem.

[0144] iii. Determine the adjustment parameters for each subsystem:

[0145] D IS The ion source system has four adjustable parameters: filament power supply current (A), arc voltage power supply current (A), absorber power supply voltage (kV), and plasma power supply voltage (kV).

[0146] D IL The injection line system has 8 adjustable parameters: 1X guide magnet power supply current (A), 1Y guide magnet power supply current (A), 2X guide magnet power supply current (A), 2Y guide magnet power supply current (A), injection line solenoid power supply voltage (V), injection line solenoid power supply current (A), injection line solenoid power supply voltage (V), and injection line solenoid power supply current (A).

[0147] D MAThe main accelerator system has six adjustable parameters: positive deflection plate power supply voltage (kV), positive deflection plate power supply current (mA), negative deflection plate power supply voltage (kV), negative deflection plate power supply current (mA), main magnet power supply voltage (V), and main magnet power supply current (A).

[0148] D BL The beamline system has six adjustment parameters: beamline X-guide power supply current (A), beamline Y-guide power supply current (A), beamline fourth-stage lens power supply current 1 (A), beamline fourth-stage lens power supply current 2 (A), rotating magnet power supply voltage (V), and rotating magnet power supply voltage (A).

[0149] iv. Determine the total adjustable parameter D for each subsystem. MA

[0150] There are a total of 24 adjustment parameters for all subsystems, i.e., Dim = 24.

[0151] Furthermore, by expanding each subsystem of the above formula (2), the following are all the alternative schemes D for the beam parameters of all subsystems arranged in N rows and Dim columns:

[0152]

[0153] Where, d i d represents the i-th alternative. i,j The value of the j-th beam parameter to be optimized represents the i-th alternative scheme.

[0154] Furthermore, in step two, the objective function F is established for the objective value O. k 'and actual value O k The difference is calculated as follows:

[0155]

[0156] In formula (4), F on the left represents the objective function, and D on the right represents the objective function. i Representing the i-th alternative scheme of the four subsystems, O on the right side of formula (4) k O represents the current actual beam output value of the k-th subsystem of the i-th alternative scheme obtained according to formula (2). k 'Represents the ideal target beam current value of the k-th subsystem of the i-th alternative scheme, where k = 1, 2, 3, 4 represent the ion source beam current, internal target beam current, stripped target beam current, and beryllium target beam current, respectively; F i O represents the ideal beam current value of the i-th alternative. k 'and actual beam current value O k The difference;

[0157] In formula (4), only the ion source subsystem has ΔD.av Other subsystems do not have ΔD av .

[0158] Furthermore, the O in formula (4) k The calculation is as follows:

[0159] When k = 1, 2, 3, 4 in formula (4),

[0160] O4'=α1O1'=α2O2'=α3O3' (5)

[0161] Wherein, O4' is the known target beam, namely the beryllium target beam, and α1, α2, and α3 are the known engineering debugging experience of the accelerator and the transmission efficiency of each stage. Based on the known O4' and α1, α2, and α3, the magnitudes of other beam target values ​​O1', O2', and O3' are calculated; where O1' represents the target value of the ion source beam, O2' represents the target value of the internal target beam, and O3' represents the target value of the stripped target beam.

[0162] ΔD of formula (4) av The calculation is as follows:

[0163] ΔD av =(D av -D av ') (6)

[0164] D on the right side of formula (6) av D represents the actual voltage value of the current arc voltage power supply. av 'Target voltage value of the arc voltage power supply; set the target voltage value D of the arc voltage power supply based on engineering experience.' av =120;

[0165] The O in formula (4) k -O k The calculation is as follows:

[0166] ΔO k =O k -O k (7)

[0167] O on the right side of formula (7) k According to formula (5), O k To obtain the beam current value of a certain subsystem from actual measurement, the parameters of the four subsystems in formula (2) are adjusted simultaneously. If one of the subsystems does not improve, no update is performed; if ΔO k_new <ΔO k_old This indicates that the beam O k Improvements were achieved, approaching the set beam target value. The corresponding system parameters were updated. If ΔO k_new ≥ΔO k_oldThis indicates that the beam O k If no improvement is achieved, the original parameters should be kept unchanged; the state of the arc voltage should also be considered in the ion source system, therefore the update conditions for the ion source system are:

[0168] ΔO 1_new +ΔD av_new <ΔO 1_old +ΔD av_old (8)

[0169] Formula (8) takes the ion source subsystem as an example. On the left side of Formula (8), ΔO 1_new This is the difference between the actual beam current and the target value of the updated ion source system; ΔD av_new The difference between the actual value and the target value of the arc voltage of the updated ion source system; ΔO on the right side of formula (8) 1_old ΔD represents the difference between the actual and target beam current values ​​of the ion source system in the last update. av_old This is the difference between the actual value and the target value of the arc voltage of the ion source system in the previous test; Formula (8) only applies to the ion source subsystem. av_new Other subsystems do not have ΔD av_new .

[0170] Furthermore, in step three, all alternative schemes D for the beam parameters of all subsystems are coarsely adjusted to obtain the coarse adjustment segment beam update scheme D. i_best The specific process is as follows:

[0171] i. Judgment If yes, select to perform the initial stage of beam coarse adjustment; otherwise, determine... If yes, perform mid-stage beam coarse adjustment; otherwise, perform late-stage beam coarse adjustment.

[0172] ii. Obtain the coarse-tuning stage beam scheme D i The beam parameter set update conditions are shown in formula (9). The updated beam parameter scheme is compared with the previous scheme, and the scheme that is closer to the target beam is selected as the updated beam scheme. The beam scheme D in the coarse adjustment stage i The update conditions are as follows:

[0173]

[0174] Where P1 represents the coarse adjustment stage, and D... i For the updated i-th beam parameter scheme, For the i-th beam parameter update scheme using the coarse adjustment strategy, This is the beam parameter scheme updated last time. The i-th set of beam objective functions updated using the coarse-tuning strategy. This is the beam objective function set updated last time.

[0175] iii. By D i Select the optimal value D best where i = 1, 2, ..., N;

[0176] iv. Return to step four.

[0177] Furthermore, if the pre-beam coarse adjustment phase is selected, the specific process is as follows:

[0178] The early stage of beam coarse adjustment, i.e. At that time, a differential evolution strategy is used to update and iterate the beam parameters. The differential evolution strategy uses two random alternative schemes generated by formula (10) to update the beam parameters, calculates the difference value between the two sets of beam parameters to generate new beam parameters, and the update formula is as follows:

[0179]

[0180] in:

[0181] d random_1 =lb j +rand×(ub j -lb j )

[0182] d random_2 =lb j +rand×(ub j -lb j )

[0183] In formula (10), P1 on the left side represents the coarse adjustment stage. This represents the beam parameters in the coarse adjustment stage in row i and column j of formula (3); the right side of formula (10) (d random_1 -d random_2 The term )×R1 represents the differential movement strategy, where d i,j d represents the beam parameters in row i and column j of formula (3) in the previous time. random_1 and d random_2 All are generated within the beam parameter range according to formula (1), where R1 is the random factor of the current strategy, and is a random number between 0 and 1, lb j and ub j The upper and lower bounds of the j-th adjusted parameter are respectively, and rand represents a random value between 0 and 1;

[0184] If you choose to perform intermediate beam coarse adjustment, the specific process is as follows:

[0185] During the mid-stage of beam coarse adjustment, i.e. At that time, a Brownian motion strategy is used to update the beam parameters. This strategy involves iteratively updating the beam parameters by finding suitable beam parameters in the vicinity of the historical best parameter set, and incorporating the historical best beam parameter set:

[0186]

[0187] In formula (11), P1 on the left side represents the coarse adjustment stage. This represents the beam parameters in the coarse adjustment stage in row i and column j; the first term d on the right-hand side of the formula is... best This represents the optimal beam parameters in the coarse-tuning stage in row i and column j; the second term on the right-hand side of the formula is exp((t / T)∧4)×(RB-0.5)×(d best -d i,j ) represents the Brownian motion strategy, where d i,j represents the beam parameters in row i and column j of formula (3) in the previous time, t represents the current number of parameter optimizations, T represents the total number of parameter optimizations set by the algorithm, RB represents the Brownian motion factor, which is a number randomly generated according to a standard normal distribution with a mean of 0 and a standard deviation of 1, and exp represents the natural exponential function.

[0188] If you choose to perform the beam coarse adjustment post-process, the specific procedure is as follows:

[0189] The later stage of beam coarse adjustment, i.e. To reduce the probability of beam parameters getting trapped in local optima and improve the speed and accuracy of parameter optimization, a Levy flight strategy is introduced, adding a nonlinear factor to increase the beam convergence range. The revised formula is as follows:

[0190]

[0191] In formula (12), P1 on the left side represents the coarse adjustment stage. This represents the beam parameters in the coarse adjustment stage of row i and column j; the first term d on the right side of formula (12) best This represents the optimal beam parameters in the coarse adjustment stage of row i and column j; the second term on the right side of formula (12) is ((1-t / T)∧(2×t / T))×d i,j ×RL indicates Flight strategy, where (1-t / T)∧(2×t / T) represents the time range of the coarse-tuning phase; t represents the current number of parameter optimizations, and T represents the total number of parameter optimizations set for the algorithm; d i,j This represents the beam parameters in row i and column j of formula (3) in the previous iteration;

[0192] In formula (12), RL represents the flight strategy factor. The nonlinear factor determines the step size and increment / decrease of parameter optimization through the flight distribution function, which helps the beam parameters escape local optima and find the global optimal set of beam parameters.

[0193] RL=0.5×Levy (13)

[0194] Where Levy represents the flight distribution function, the weighting coefficient of 0.5 is used to improve the convergence interval of the beam parameters and avoid excessively large step sizes that could cause the beam parameters to exceed their limits. The Levy distribution function is calculated as follows:

[0195]

[0196] In the distribution function of formula (14), s is a fixed constant of 0.01, η is a fixed constant of 1.5, u and v are random numbers between 0 and 1, used to control the step size of beam parameter adjustment, and the calculation formula of σ is as follows:

[0197]

[0198] In formula (15), σ on the left is used to control the step size and direction of the beam parameters; Γ on the right represents the gamma function. This distribution increases the extreme variation conditions of the beam parameters, which helps to find a wider range of beam parameters; η is a fixed constant of 1.5.

[0199] Substituting σ from formula (15) into formula (14), then substituting Levy from formula (14) into formula (13), and then substituting RL from formula (13) into formula (12), we obtain the beam parameters in row i and column j of the coarse adjustment stage after coarse adjustment in the current coarse adjustment segment according to formula (12).

[0200] Furthermore, in step four, based on the coarse adjustment stage, adjustments are made to the alternative schemes from the coarse adjustment stage to obtain the optimal scheme D for beam current updating in the fine adjustment stage. best The fine adjustment segment beam update scheme is as follows:

[0201] 1) Determine rand i If the value is greater than 0.5, then update D using the C1 strategy of formula (16). i If not, update D using the C2 strategy of formula (16). i ;

[0202]

[0203] In formula (16), P2 on the left side represents the fine-tuning stage. This represents the beam parameters in row i and column j during the fine-tuning phase; C1 and C2 on the right side of formula (16) are the beam parameters updated by the strategy, d best This represents the optimal beam parameters in row i and column j during the fine-tuning stage, d i,j This represents the beam parameters in row i and column j from the previous fine-tuning stage, drandom It is generated according to formula (1) within the beam parameter range, where t represents the current number of parameter optimizations and T represents the total number of parameter optimizations set by the algorithm; rand i Let R1 be a random number between 0 and 1, representing the probability of executing strategy C1 or C2 for the i-th alternative. R2 and R3 are randomly generated numbers between 0 and 1 that conform to a normal distribution. R1 is used to control the increase or decrease of the beam parameters, and R2 is used to control the step size of the beam parameters. K represents the random selection of an integer 1 or 2. The probabilities of C1 and C2 occurring are equal.

[0204] 2) Determine whether to use strategies C1 and C2 to update the beam parameters D. i Afterwards, check if the beam is close to the target value. If not, execute the adaptive controller to update the beam parameters during the coarse-tuning phase. If so, update Di.

[0205] 3) By D i Select the optimal value D best where i = 1, 2, ..., N;

[0206] 4) Return to step five.

[0207] Furthermore, in step four, process 2), the adaptive controller updates the beam parameters during the coarse-tuning stage. Taking the ion source system as an example, the updated parameter D... IS_new as follows:

[0208] 1)D IS_new =ΔD IS +D IS_best (17)

[0209] D on the left side of formula (17) IS_new The beam parameter set is updated by the ion source system through the proportional controller; ΔD on the right side of equation (17) IS It is obtained by multiplying e1 by the adaptive coefficient of the proportional controller. e1 is the sum of two differences, the first of which is the current optimal ion source beam O. 1_best and target ion source beam O 1_target The difference between them, the second difference is the current arc voltage power supply voltage value D. av_target With the optimal arc voltage power supply value D av_best Difference between; D IS_best It is the current optimal set of ion source beam parameters;

[0210] 2) The first term on the right side of formula (17) is calculated as follows:

[0211] ΔD IS = kp × (1 - t / T) 2 ×e1 (18)

[0212] Where kp=±0.05 adjusts the beam parameters of the ion source system from two directions, and takes the beam close to the target value as the updated parameters. t represents the current number of parameter optimizations, T represents the total number of parameter optimizations set by the algorithm, and the (1-t / T) item can control the step size of beam optimization in the later stages of the algorithm to gradually decrease.

[0213] 3) Formula (18)e1 is calculated as follows:

[0214] e1=((O 1_target -O 1_bset )+(D av_target -D av_best (19)

[0215] Among them O 1_target This is the target value of the ion source beam, O 1_bset The current optimal value of the ion source beam, D av_target It is the target value of the arc current power supply voltage, D. av_best This is the optimal value for the arc current power supply voltage;

[0216] 4) The ion source beam parameters have been updated as follows:

[0217]

[0218] D IS These are the beam parameters of the ion source system after the proportional control stage; P2 indicates the fine-tuning stage. This represents the proportionally adjusted ion source beam parameters, ΔO. 1_new It is the difference between the proportionally adjusted ion source beam and the target beam, ΔD. av_new It is the difference between the proportionally adjusted arc voltage and the target arc voltage, ΔO. 1_old It is the difference between the ion source beam and the target beam during the coarse adjustment stage, ΔD av_old It is the difference between the arc voltage supply voltage value during the coarse adjustment stage and the target arc voltage supply voltage value.

[0219] The process of updating the beam parameters of the other three systems is similar to that of the ion source system, and D is obtained accordingly. IL D MA D BL ;

[0220] 5)D best =[D IS D IL D MA D BL ].

[0221] The above description is merely an example and illustration of the concept of the present invention. Those skilled in the art can make various modifications or additions to the specific embodiments described or use similar methods to replace them, as long as they do not deviate from the concept of the invention or exceed the scope defined in the claims, they should all fall within the protection scope of the present invention.

Claims

1. An automatic beam tuning modeling method for accelerators, characterized in that: Includes the following steps: Step 1: Establish the automatic beam adjustment initial value model D ij And initialize the model D. ij The parameters to be adjusted are assigned initial values, and the total number of power parameter optimizations T and the initial number of power parameter optimizations t = 0 are set. Step 2: Establish the objective function F, and set the objective value O. k 'and actual value O k Perform difference calculation; Step 3: Let t = t + 1; perform coarse adjustment on all alternative schemes D for the beam parameters of all subsystems to obtain the coarse adjustment segment beam update scheme D. i_best The D i_best The best alternative among multiple options in the joint debugging of all subsystems; Step 4: Based on the coarse adjustment stage, adjust the alternative schemes from the coarse adjustment stage to obtain the optimal scheme D for beam current renewal in the fine adjustment stage. i_best ; Step 5: Determine if t = T. If not, return to step 3; if yes, end. The first step involves establishing the accelerator automatic beam tuning initialization model D. ij And initialize the model D. ij The initial values ​​are assigned to the parameters to be adjusted in the following process: 1) Identify the subsystems to be tuned, including: ion source subsystem, injection line subsystem, main accelerator subsystem, and beamline subsystem; 2) Establish the initial value model D ij The initial value model is as follows: D ij =lb j +rand×(ub j -lb j ) i=1,2,…N;j=1,2,…Dim (1) In formula (1), i on the left represents the i-th row of the matrix, j represents the j-th column of the matrix; i = 1, 2, ... N represents that there are N alternative schemes in the matrix; j = 1, 2, ... Dim represents that each row of the matrix has Dim parameters; lb on the right side of formula (1) j and ub j These are the upper and lower bounds of the j-th adjusted parameter, respectively, and rand represents a random value between 0 and 1; The second step involves establishing the objective function F, with respect to the objective value O. k 'and actual value O k The difference is calculated as follows: In formula (4), F on the left represents the objective function, and D on the right represents the objective function. i Representing the i-th alternative scheme of the four subsystems, O on the right side of formula (4) k O represents the current actual beam output value of the k-th subsystem of the i-th alternative scheme obtained according to formula (2). k 'Represents the ideal target beam current value of the k-th subsystem of the i-th alternative scheme, where k = 1, 2, 3, 4 represent the ion source beam current, internal target beam current, stripped target beam current, and beryllium target beam current, respectively; F i O represents the ideal beam current value of the i-th alternative. k 'and actual beam current value O k The difference; Step three involves coarsely adjusting all alternative schemes D for the beam parameters of all subsystems to obtain the coarse adjustment segment beam update scheme D. i_best The specific process is as follows: i. Judgment If yes, select to perform the initial stage of beam coarse adjustment; otherwise, determine... If yes, perform mid-stage beam coarse adjustment; otherwise, perform late-stage beam coarse adjustment. ii. Obtain the coarse-tuning stage beam scheme D i The beam parameter set update conditions are shown in formula (9). The updated beam parameter scheme is compared with the previous scheme, and the scheme that is closer to the target beam is selected as the updated beam scheme. The beam scheme D in the coarse adjustment stage i The update conditions are as follows: Where P1 represents the coarse adjustment stage, and D... i For the updated i-th beam parameter scheme, For the i-th beam parameter update scheme using the coarse adjustment strategy, For the previously updated beam parameter scheme, F i new,p1 The i-th beam objective function set updated using the coarse-tuning strategy, F i old This is the beam objective function set updated last time; iii. By D i Select the optimal value D best where i = 1, 2, ..., N; iv. Return to step four; Step four involves adjusting the alternative schemes from the coarse adjustment stage to obtain the optimal scheme D for beam current updating in the fine adjustment stage. best The fine adjustment segment beam update scheme is as follows: 1) Determine rand i If the value is greater than 0.5, then update D using the C1 strategy of formula (16). i If not, update D using the C2 strategy of formula (16). i ; In formula (16), P2 on the left side represents the fine-tuning stage. This represents the beam parameters in row i and column j during the fine-tuning phase; C1 and C2 on the right side of formula (16) are the beam parameters updated by the strategy, d best This represents the optimal beam parameters in row i and column j during the fine-tuning stage, d i,j This represents the beam parameters in row i and column j from the previous fine-tuning stage, d random It is generated according to formula (1) within the beam parameter range, where t represents the current number of parameter optimizations and T represents the total number of parameter optimizations set by the algorithm; rand i Let R1 be a random number between 0 and 1, representing the probability of executing strategy C1 or C2 for the i-th alternative. R2 and R3 are randomly generated numbers between 0 and 1 that conform to a normal distribution. R1 is used to control the increase or decrease of the beam parameters, and R2 is used to control the step size of the beam parameters. K represents the random selection of an integer 1 or 2. The probabilities of C1 and C2 occurring are equal. 2) Determine whether to use strategies C1 and C2 to update the beam parameters D. i Afterwards, check if the beam is close to the target value. If not, execute the adaptive controller to update the beam parameters during the coarse-tuning phase. If so, update Di. 3) By D i Select the optimal value D best where i = 1, 2, ..., N; 4) Return to step five.

2. The automatic beam tuning modeling method for accelerators according to claim 1, characterized in that: Step 1, process 2), establishes the initial value model D. ij The specific process is as follows: i. Determine the individual subsystems in all alternative schemes D for all subsystem beam parameters; D=[D IS D IL D MA D BL ] (2) Where: D IS For the ion source parameter subsystem to be adjusted; D IL For the subsystem of parameters to be adjusted in the injection line; D MA The main accelerator parameter tuning subsystem; D BL For the beamline parameter adjustment subsystem; ii. Determine the set of parameters to be tuned for each subsystem D IS D IL D MA D BL ; D IS [D1 D2 D3 D4]: D IL =[D5 D6…D 12 ]; D MA =[D 13 D 14 …D 18 ]; D BL =[D 19 D 20 …D 24 ]; Where: D IS The set of N rows and 4 columns of parameters to be adjusted for the ion source subsystem; D IL For the N rows and 8 columns of parameters to be adjusted in the injection line subsystem; D MA The set of N rows and 6 columns of adjustable parameters for the main accelerator subsystem; D BL The set of N rows and 6 columns of parameters to be adjusted for the beamline subsystem; where N represents N alternative schemes for each subsystem. iii. Determine the adjustment parameters for each subsystem: D IS The ion source system has four adjustable parameters: filament power supply current (A), arc voltage power supply current (A), absorber power supply voltage (kV), and plasma power supply voltage (kV). D IL The injection line system has 8 adjustable parameters: 1X guide magnet power supply current (A), 1Y guide magnet power supply current (A), 2X guide magnet power supply current (A), 2Y guide magnet power supply current (A), injection line solenoid power supply voltage (V), injection line solenoid power supply current (A), injection line solenoid power supply voltage (V), and injection line solenoid power supply current (A). D MA The main accelerator system has six adjustable parameters: positive deflection plate power supply voltage (kV), positive deflection plate power supply current (mA), negative deflection plate power supply voltage (kV), negative deflection plate power supply current (mA), main magnet power supply voltage (V), and main magnet power supply current (A). D BL The beamline system has six adjustment parameters: beamline X-guide power supply current (A), beamline Y-guide power supply current (A), beamline fourth-stage lens power supply current 1 (A), beamline fourth-stage lens power supply current 2 (A), rotating magnet power supply voltage (V), and rotating magnet power supply voltage (A). iv. Determine the total adjustable parameter D for each subsystem. MA There are a total of 24 adjustment parameters for all subsystems, i.e., Dim = 24.

3. The automatic beam tuning modeling method for accelerators according to claim 2, characterized in that: Expanding each subsystem of formula (2), the following are all the alternative schemes D for the beam parameters of all subsystems in N rows and Dim columns: Where, d i d represents the i-th alternative. i,j The value of the j-th beam parameter to be optimized represents the i-th alternative scheme; In formula (4), only the ion source subsystem has ΔD. av Other subsystems do not have ΔD av .

4. The automatic beam tuning modeling method for accelerators according to claim 3, characterized in that: The O in formula (4) k The calculation is as follows: When k = 1, 2, 3, 4 in formula (4), O4'=α1O1'=α2O2'=α3O3' (5) Wherein, O4' is the known target beam, namely the beryllium target beam, and α1, α2, and α3 are the known engineering debugging experience of the accelerator and the transmission efficiency of each stage. Based on the known O4' and α1, α2, and α3, the magnitudes of other beam target values ​​O1', O2', and O3' are calculated; where O1' represents the target value of the ion source beam, O2' represents the target value of the internal target beam, and O3' represents the target value of the stripped target beam. ΔD of formula (4) av The calculation is as follows: ΔD av =(D av -D av ') (6) D on the right side of formula (6) av D represents the actual voltage value of the current arc voltage power supply. av 'Target voltage value of the arc voltage power supply; set the target voltage value D of the arc voltage power supply based on engineering experience.' av =120; The O in formula (4) k -O k The calculation is as follows: ΔO k =O k -Oh k ' (7) O on the right side of formula (7) k According to formula (5), O k To obtain the beam current value of a certain subsystem from actual measurement, the parameters of the four subsystems in formula (2) are adjusted simultaneously. If one of the subsystems does not improve, no update is performed; if ΔO k_new <ΔO k_old This indicates that the beam O k Improvements were achieved, approaching the set beam target value. The corresponding system parameters were updated. If ΔO k_new ≥ΔO k_old This indicates that the beam O k If no improvement is achieved, the original parameters should be kept unchanged; the state of the arc voltage should also be considered in the ion source system, therefore the update conditions for the ion source system are: ΔO 1_new +ΔD av_new <ΔO 1_old +ΔD av_old (8) Formula (8) takes the ion source subsystem as an example. On the left side of Formula (8), ΔO 1_new This is the difference between the actual beam current and the target value of the updated ion source system; ΔD av_new The difference between the actual value and the target value of the arc voltage of the updated ion source system; ΔO on the right side of formula (8) 1_old ΔD represents the difference between the actual and target beam current values ​​of the ion source system in the last update. av_old This is the difference between the actual value and the target value of the arc voltage of the ion source system in the previous test; Formula (8) only applies to the ion source subsystem. av_new Other subsystems do not have ΔD av_new .

5. The automatic beam tuning modeling method for accelerators according to claim 1, characterized in that, If you choose to perform the initial stage of beam coarse adjustment, the specific process is as follows: The early stage of beam coarse adjustment, i.e. At that time, a differential evolution strategy is used to update and iterate the beam parameters. The differential evolution strategy uses two random alternative schemes generated by formula (10) to update the beam parameters, calculates the difference value between the two sets of beam parameters to generate new beam parameters, and the update formula is as follows: in: d random_1 =lb j +rand×(ub j -lb j ) d random_2 =lb j +rand×(ub j -lb j ) In formula (10), P1 on the left side represents the coarse adjustment stage. This represents the beam parameters in the coarse adjustment stage in row i and column j of formula (3); the right side of formula (10) (d random_1 -d random_2 The term )×R1 represents the differential movement strategy, where d i,j d represents the beam parameters in row i and column j of formula (3) in the previous time. random_1 and d random_2 All are generated within the beam parameter range according to formula (1), where R1 is the random factor of the current strategy, and is a random number between 0 and 1, lb j and ub j The upper and lower bounds of the j-th adjusted parameter are respectively, and rand represents a random value between 0 and 1; If you choose to perform intermediate beam coarse adjustment, the specific process is as follows: During the mid-stage of beam coarse adjustment, i.e. At that time, a Brownian motion strategy is used to update the beam parameters. This strategy involves iteratively updating the beam parameters by finding suitable beam parameters in the vicinity of the historical best parameter set, and incorporating the historical best beam parameter set: In formula (11), P1 on the left side represents the coarse adjustment stage. This represents the beam parameters in the coarse adjustment stage in row i and column j; the first term d on the right-hand side of the formula is... best This represents the optimal beam parameters in the coarse-tuning stage in row i and column j; the second term on the right-hand side of the formula is exp((t / T)∧4)×(RB-0.5)×(d best -d i,j ) represents the Brownian motion strategy, where d i,j represents the beam parameters in row i and column j of formula (3) in the previous time, t represents the current number of parameter optimizations, T represents the total number of parameter optimizations set by the algorithm, RB represents the Brownian motion factor, which is a number randomly generated according to a standard normal distribution with a mean of 0 and a standard deviation of 1, and exp represents the natural exponential function. If you choose to perform the beam coarse adjustment post-process, the specific procedure is as follows: The later stage of beam coarse adjustment, i.e. To reduce the probability of beam parameters getting trapped in local optima and improve the speed and accuracy of parameter optimization, a Levy flight strategy is introduced, adding a nonlinear factor to increase the beam convergence range. The revised formula is as follows: In formula (12), P1 on the left side represents the coarse adjustment stage. This represents the beam parameters in the coarse adjustment stage of row i and column j; the first term d on the right side of formula (12) best This represents the optimal beam parameters in the coarse adjustment stage of row i and column j; the second term on the right side of formula (12) is ((1-t T / ∧)×(t2T / ×d) i, ) j )×RL represents the Lev flight strategy, where (1-t / T)∧(2×t / T) represents the time range of the mid-stage coarse-tuning; t represents the current number of parameter optimizations, and T represents the total number of parameter optimizations set for the algorithm; d i,j This represents the beam parameters in row i and column j of formula (3) in the previous iteration; In formula (12), RL represents the flight strategy factor. The nonlinear factor determines the step size and increment / decrease of parameter optimization through the flight distribution function, which helps the beam parameters escape local optima and find the global optimal set of beam parameters. RL=0.5×Levy (13) Where Levy represents the flight distribution function, the weighting coefficient of 0.5 is used to improve the convergence interval of the beam parameters and avoid excessively large step sizes that could cause the beam parameters to exceed their limits. The Levy distribution function is calculated as follows: In the distribution function of formula (14), s is a fixed constant of 0.01, η is a fixed constant of 1.5, u and v are random numbers between 0 and 1, used to control the step size of beam parameter adjustment, and the calculation formula of σ is as follows: In formula (15), σ on the left is used to control the step size and direction of the beam parameters; Γ on the right represents the gamma function. This distribution increases the extreme variation conditions of the beam parameters, which helps to find a wider range of beam parameters; η is a fixed constant of 1.

5. Substituting σ from formula (15) into formula (14), then substituting Levy from formula (14) into formula (13), and then substituting RL from formula (13) into formula (12), we obtain the beam parameters in row i and column j of the coarse adjustment stage after coarse adjustment in the current coarse adjustment segment according to formula (12).

6. The automatic beam tuning modeling method for accelerators according to claim 1, characterized in that: In step four, process 2), the adaptive controller updates the beam parameters during the coarse-tuning stage. Taking the ion source system as an example, the updated parameter D... IS_new as follows: 1)D IS_new =ΔD IS +D IS_best (17) D on the left side of formula (17) IS_new The beam parameter set is updated by the ion source system through the proportional controller; ΔD on the right side of equation (17) IS It is obtained by multiplying e1 by the adaptive coefficient of the proportional controller. e1 is the sum of two differences, the first of which is the current optimal ion source beam current O. 1_best and target ion source beam O 1_target The difference between them, the second difference is the current arc voltage power supply voltage value D. av_target With the optimal arc voltage power supply value D av_best Difference between; D IS_best It is the current optimal set of ion source beam parameters; 2) The first term on the right side of formula (17) is calculated as follows: ΔD IS =kp×(1-t / T) 2 ×e1 (18) Where kp=±0.05 adjusts the beam parameters of the ion source system from two directions, takes the beam close to the target value as the updated parameters, t represents the current number of parameter optimizations, T represents the total number of parameter optimizations set by the algorithm, and the (1-t / T) item can control the step size of beam optimization in the later stage of the algorithm to gradually decrease; 3) Formula (18)e1 is calculated as follows: e1=((O 1_target -Oh 1_bset )+(D av_target -D av_best )) (19) Among them O 1_target This is the target value of the ion source beam, O 1_bset The current optimal value of the ion source beam, D av_target It is the target value of the arc current power supply voltage, D av_best This is the optimal value for the arc current power supply voltage; 4) The ion source beam parameters have been updated as follows: D IS These are the beam parameters of the ion source system after the proportional control stage; P2 indicates the fine-tuning stage. This represents the proportionally adjusted ion source beam parameters, ΔO. 1_new It is the difference between the proportionally adjusted ion source beam and the target beam, ΔD. av_new It is the difference between the proportionally adjusted arc voltage and the target arc voltage, ΔO. 1_old It is the difference between the ion source beam and the target beam during the coarse adjustment stage, ΔD av_old It is the difference between the arc voltage supply voltage value during the coarse adjustment stage and the target arc voltage supply voltage value. The process of updating the beam parameters of the other three systems is similar to that of the ion source system, and D is obtained accordingly. IL D MA D BL ; 5)D best =[D IS D IL D MA D BL ]。

Citation Information

Patent Citations

  • Radial target beam intensity and position synchronization system and method for cyclotron

    CN109413834A

  • Optimization method and optimization device for beam shaping device

    CN115130322A