CN117539142A - Neutron generator control method and device, electronic equipment and storage medium - Google Patents

Neutron generator control method and device, electronic equipment and storage medium Download PDF

Info

Publication number
CN117539142A
CN117539142A CN202311423359.5A CN202311423359A CN117539142A CN 117539142 A CN117539142 A CN 117539142A CN 202311423359 A CN202311423359 A CN 202311423359A CN 117539142 A CN117539142 A CN 117539142A
Authority
CN
China
Prior art keywords
current
preset
difference value
parameter
ion source
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202311423359.5A
Other languages
Chinese (zh)
Inventor
请求不公布姓名
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Zhongke Shijin Anhui Neutron Technology Co ltd
Original Assignee
Zhongke Shijin Anhui Neutron Technology Co ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Zhongke Shijin Anhui Neutron Technology Co ltd filed Critical Zhongke Shijin Anhui Neutron Technology Co ltd
Priority to CN202311423359.5A priority Critical patent/CN117539142A/en
Publication of CN117539142A publication Critical patent/CN117539142A/en
Pending legal-status Critical Current

Links

Classifications

    • HELECTRICITY
    • H05ELECTRIC TECHNIQUES NOT OTHERWISE PROVIDED FOR
    • H05HPLASMA TECHNIQUE; PRODUCTION OF ACCELERATED ELECTRICALLY-CHARGED PARTICLES OR OF NEUTRONS; PRODUCTION OR ACCELERATION OF NEUTRAL MOLECULAR OR ATOMIC BEAMS
    • H05H3/00Production or acceleration of neutral particle beams, e.g. molecular or atomic beams
    • H05H3/06Generating neutron beams
    • GPHYSICS
    • G05CONTROLLING; REGULATING
    • G05BCONTROL OR REGULATING SYSTEMS IN GENERAL; FUNCTIONAL ELEMENTS OF SUCH SYSTEMS; MONITORING OR TESTING ARRANGEMENTS FOR SUCH SYSTEMS OR ELEMENTS
    • G05B11/00Automatic controllers
    • G05B11/01Automatic controllers electric
    • G05B11/36Automatic controllers electric with provision for obtaining particular characteristics, e.g. proportional, integral, differential
    • G05B11/42Automatic controllers electric with provision for obtaining particular characteristics, e.g. proportional, integral, differential for obtaining a characteristic which is both proportional and time-dependent, e.g. P.I., P.I.D.
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F17/00Digital computing or data processing equipment or methods, specially adapted for specific functions
    • G06F17/10Complex mathematical operations
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02EREDUCTION OF GREENHOUSE GAS [GHG] EMISSIONS, RELATED TO ENERGY GENERATION, TRANSMISSION OR DISTRIBUTION
    • Y02E30/00Energy generation of nuclear origin
    • Y02E30/30Nuclear fission reactors

Landscapes

  • Physics & Mathematics (AREA)
  • Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Data Mining & Analysis (AREA)
  • Theoretical Computer Science (AREA)
  • Spectroscopy & Molecular Physics (AREA)
  • Mathematical Physics (AREA)
  • Plasma & Fusion (AREA)
  • Computational Mathematics (AREA)
  • Mathematical Analysis (AREA)
  • Mathematical Optimization (AREA)
  • Algebra (AREA)
  • Pure & Applied Mathematics (AREA)
  • Databases & Information Systems (AREA)
  • Software Systems (AREA)
  • General Engineering & Computer Science (AREA)
  • High Energy & Nuclear Physics (AREA)
  • Automation & Control Theory (AREA)
  • Particle Accelerators (AREA)

Abstract

The application provides a neutron generator control method, a neutron generator control device, electronic equipment and a storage medium. The method comprises the following steps: acquiring an anode current of an ion source at the current moment and a first current difference value; when the first current difference value is larger than a first preset difference value, determining a first initial adjustment parameter according to the preset current, the ion source anode current, the first current difference value and a preset weight coefficient, and adjusting the current of the storage according to the first initial adjustment parameter; updating a preset weight coefficient according to the preset current, the anode current of the ion source at the next moment and the second current difference value; determining a first iteration adjusting parameter according to the preset current, the ion source anode current at the next moment, the second current difference value and the updated preset weight coefficient, and adjusting the current of the storage according to the first iteration adjusting parameter so as to adjust neutron yield; repeating the steps until the first current difference value is less than or equal to a first preset difference value. Therefore, the problems of high rule construction cost and poor universality of the traditional neutron generator control mode can be solved.

Description

Neutron generator control method and device, electronic equipment and storage medium
Technical Field
The invention relates to the technical field of intelligent control, in particular to a neutron generator control method, a neutron generator control device, electronic equipment and a storage medium.
Background
With the progress of the times, the requirements of the modern industrial technology on the production efficiency and the standard are more stringent.
In the technical field of neutron generation, the conventional neutron yield stability control system generally adopts a traditional PID or a PID control method based on fuzzy control. In the conventional PID control technology, determination of PID parameters (kp, ki and kd) depends on experiments, repeated attempts are needed, the process is tedious and time-consuming, and the experience requirements of the testers are very high. In this method, the PID parameter is given fixed number, so that the universality of the program is poor, and when the neutron tube performance parameter slightly changes greatly due to model difference, environmental condition, accumulated working time and the like, the program is not applicable any more. The PID control technology based on fuzzy control can realize self-tuning of PID parameters based on fuzzy rules, and is greatly improved compared with the traditional PID control technology, but still a rule base needs to be established on the basis of a large amount of experimental data and expert experience, and the simplicity of method implementation and universality of programs are still not ideal.
Disclosure of Invention
In view of the foregoing, an object of an embodiment of the present application is to provide a neutron generator control method, apparatus, electronic device and storage medium, which can solve the problems of high rule construction cost and poor universality of the conventional neutron generator control method.
In order to achieve the technical purpose, the technical scheme adopted by the application is as follows:
in a first aspect, an embodiment of the present application provides a neutron generator control method, applied to a PID controller in a neutron generator system, where the neutron generator system further includes a neutron generator, the method includes:
s1: acquiring the current of an ion source anode of the neutron generator at the current moment and a first current difference value between the current of the ion source anode and a preset current;
s2: when the first current difference value is larger than a first preset difference value, determining a first initial adjustment parameter according to the preset current, the ion source anode current, the first current difference value and a preset weight coefficient, and adjusting the accumulator current of the neutron generator according to the first initial adjustment parameter, wherein the preset weight coefficient comprises a bias vector, and preset weights respectively corresponding to the preset current, the ion source anode current and the first current difference value;
S3: acquiring the anode current of an ion source at the next moment at the current moment, and updating the preset weight coefficient through a first preset weight coefficient updating formula according to the preset current, the anode current of the ion source at the next moment and a second current difference value between the anode current of the ion source at the next moment and the preset current to obtain an updated preset weight coefficient;
s4: determining a first iteration adjustment parameter according to the preset current, the ion source anode current at the next moment, the second current difference value and the updated preset weight coefficient, and adjusting the accumulator current according to the first iteration adjustment parameter so as to adjust the neutron yield of the neutron generator;
s5: repeating the steps S1 to S4 until the first current difference value is smaller than or equal to the first preset difference value.
With reference to the first aspect, in some optional embodiments, step S2 includes:
determining a first control parameter of the PID controller according to the preset current, the ion source anode current, the first current difference value and the preset weight coefficient, wherein the first control parameter comprises a first proportional parameter, a first integral parameter and a first differential parameter:
y=f(Wx+b)
Wherein y represents an output vector formed by the first control parameter, f (·) represents an activation function, W represents the preset weight, x represents an input vector formed by the preset current, the ion source anode current and the first current difference, and b represents the bias vector;
determining the first initial adjustment parameter according to the first control parameter:
u(k)=u(k-1)+K p Δe k +K i e k +K d (Δe k -Δe k-1 )
Δe k =e k -e k-1 ,e k =r(k)-y(k)
wherein u (K) represents the first initial adjustment parameter, K represents the current sampling run, K p Represents the first proportional parameter, K i Representing the first integral parameter, K d Representing the first differential parameter, r (k) representing the preset current, y (k) representing the ion source anode current, e k Representing the first current difference;
and taking the first initial regulation parameter as a control quantity of the PID controller to regulate the accumulator current.
With reference to the first aspect, in some optional embodiments, the first preset weight coefficient updating formula is as follows:
in which W is new1 Representing the updated preset weight, b new1 Represents the updated bias vector, η represents the learning rate for controlling the update step of the weight coefficients, E represents the loss function,representing the partial derivative of the loss function with respect to a preset weight,/- >Representing the partial derivative of the loss function with respect to the bias vector, < >>Representing the partial derivative of the loss function with respect to the output vector, e k Representing the first current difference.
With reference to the first aspect, in some optional embodiments, step S4 includes:
determining an updated first control parameter according to the preset current, the ion source anode current at the next moment, the second current difference value and the updated preset weight coefficient, wherein the updated first control parameter comprises an updated first proportional parameter, an updated first integral parameter and an updated first differential parameter:
y new =f(W new1 x n +b new1 )
wherein y is new Representing an output vector composed of the updated first control parameter, f (·) representing an activation function, W new1 Representing the updated preset weight, x n Representing the difference between the preset current, the anode current of the ion source at the next moment and the second current, b new1 Representing the updated bias vector;
determining the first iteration adjusting parameter according to the updated first control parameter:
u(k+1)=u(k)+K pn Δe k+1 +K in+1 +K dn (Δe k+1 -Δe k )
Δe k+1 =e k+1 -e k ,e k+1 =r(k+1)-y(k+1)
where u (k+1) represents the first iterative adjustment parameter, u (K) represents the first initial adjustment parameter, k+1 represents the current sampling round, K pn Representing the updated first scale parameter, K in Representing the updated first integral parameter, K dn Representing the updated first differential parameter, r (k+1) represents the preset current, y (k+1) represents the ion source anode current at the next moment, e k+1 Representing the second current difference;
and taking the first iteration adjusting parameter as a control quantity of the PID controller to adjust the accumulator current.
With reference to the first aspect, in some optional embodiments, the method further includes:
s6: when the first current difference value is smaller than or equal to the first preset difference value, a first neutron yield is obtained, and when the first current difference value is smaller than or equal to the first preset difference value, the first neutron yield represents the neutron yield monitored by the neutron generator system at the same time;
s7: when the current difference value is smaller than or equal to the first preset difference value and the difference between the first neutron yield and the preset yield is larger than a second preset difference value, determining a second initial adjustment parameter according to the preset yield, the first neutron yield, the difference between the first neutron yield and the preset yield and a current weight, and adjusting the target pressure of the neutron generator according to the second initial adjustment parameter, wherein the current weight is obtained after the preset weight coefficient is updated for the last time in the step S3;
S8: acquiring a second neutron yield, updating the current weight through a second preset weight coefficient updating formula according to the preset yield, the second neutron yield and the difference between the second neutron yield and the preset yield to obtain an updated current weight, wherein the second neutron yield represents the neutron yield monitored by the neutron generator system at the next moment after the target pressure of the neutron generator is regulated according to the second initial regulating parameter;
s9: determining a second iteration adjustment parameter according to the preset yield, the second neutron yield, the difference between the second neutron yield and the preset yield and the updated current weight, and adjusting the target pressure according to the second iteration adjustment parameter so as to adjust the neutron yield of the neutron generator;
s10: and repeating the steps S1 to S9 until the neutron generator stops working.
With reference to the first aspect, in some optional embodiments, the second preset weight coefficient updating formula is as follows:
in which W is new2 Representing a preset weight value in the updated current weight, b new2 Representing the bias vector, W, in the updated current weight c Representing the preset weight value, b, obtained after the last update in step S3 c Represents the offset vector, x, obtained after the last update in step S3 c Representing an input vector composed of the preset yield, the second neutron yield, the difference between the second neutron yield and the preset yield, η representing a learning rate for controlling a weight coefficient update step size, E representing a loss function,representing the partial derivative of the loss function with respect to a preset weight,/->Representing the bias of the loss function to the bias vectorDerivative (F)>Representing the partial derivative of the loss function with respect to the output vector, e c Representing the difference between the first neutron yield and the preset yield.
With reference to the first aspect, in some optional embodiments, the method further includes:
and when the execution times of the step S10 exceeds the preset times and the difference between the neutron yield and the preset yield is larger than the second preset difference value each time in the execution process of the step S10, sending a prompt for indicating the damage of the neutron generator system.
In a second aspect, embodiments of the present application further provide a neutron generator control device, the device including:
the first acquisition unit is used for acquiring the anode current of the ion source of the neutron generator at the current moment and a first current difference value between the anode current of the ion source and a preset current;
The first determining unit is used for determining a first initial adjusting parameter according to the preset current, the ion source anode current, the first current difference value and a preset weight coefficient when the first current difference value is larger than a first preset difference value, and adjusting the accumulator current of the neutron generator according to the first initial adjusting parameter, wherein the preset weight coefficient comprises a bias vector and preset weights respectively corresponding to the preset current, the ion source anode current and the first current difference value;
the first updating unit is used for acquiring the ion source anode current at the next moment at the current moment, and updating the preset weight coefficient through a first preset weight coefficient updating formula according to the preset current, the ion source anode current at the next moment and a second current difference value between the ion source anode current at the next moment and the preset current to obtain an updated preset weight coefficient;
the second determining unit is used for determining a first iteration adjusting parameter according to the preset current, the ion source anode current at the next moment, the second current difference value and the updated preset weight coefficient, and adjusting the accumulator current according to the first iteration adjusting parameter so as to adjust the neutron yield of the neutron generator;
The first circulation unit is used for repeatedly obtaining the ion source anode current of the neutron generator at the current moment and the first current difference value, when the first current difference value is larger than a first preset difference value, determining a first initial adjustment parameter according to the preset current, the ion source anode current at the next moment, the first current difference value and the preset weight coefficient, adjusting the storage current of the neutron generator according to the first initial adjustment parameter, obtaining the ion source anode current at the next moment at the current moment, and updating the preset weight coefficient according to a first preset weight coefficient updating formula according to the preset current, the ion source anode current at the next moment, the second current difference value and the second current difference value of the preset current, obtaining an updated preset weight coefficient, determining a first adjustment parameter according to the preset current, the ion source anode current at the next moment, the second current difference value and the updated weight coefficient, and adjusting the storage according to the first iteration adjustment parameter until the first iteration adjustment parameter is smaller than the first difference value.
In a third aspect, an embodiment of the present application further provides an electronic device, where the electronic device includes a processor and a memory coupled to each other, where the memory stores a computer program, and when the computer program is executed by the processor, causes the electronic device to perform the method described above.
In a fourth aspect, embodiments of the present application further provide a computer readable storage medium, where a computer program is stored, which when run on a computer, causes the computer to perform the above-mentioned method.
The invention adopting the technical scheme has the following advantages:
in the technical scheme provided by the application, firstly, the anode current of an ion source at the current moment and a first current difference value are obtained; when the first current difference value is larger than a first preset difference value, determining a first initial adjustment parameter according to the preset current, the ion source anode current, the first current difference value and a preset weight coefficient, and adjusting the current of the storage according to the first initial adjustment parameter; then acquiring the anode current of the ion source at the next moment at the current moment, and updating the preset weight coefficient according to the preset current, the anode current of the ion source at the next moment and the second current difference value to obtain an updated preset weight coefficient; then determining a first iteration adjusting parameter according to the preset current, the anode current of the ion source at the next moment, the second current difference value and the updated preset weight coefficient, and adjusting the current of the storage according to the first iteration adjusting parameter so as to adjust the neutron yield of the neutron generator; and finally repeating the steps until the first current difference value is smaller than or equal to a first preset difference value. Therefore, the problems of high rule construction cost and poor universality of the traditional neutron generator control mode can be solved.
Drawings
The present application may be further illustrated by the non-limiting examples given in the accompanying drawings. It is to be understood that the following drawings illustrate only certain embodiments of the present application and are therefore not to be considered limiting of its scope, for the person of ordinary skill in the art may derive other relevant drawings from the drawings without inventive effort.
FIG. 1 is a block diagram of a neutron generator system provided in an embodiment of the present application.
Fig. 2 is a schematic diagram of a flow chart for stabilizing neutron yield according to an embodiment of the present application.
Fig. 3 is a block diagram of an electronic device provided in an embodiment of the present application.
Fig. 4 is a schematic flow chart of a neutron generator control method according to an embodiment of the present application.
Fig. 5 is a schematic diagram of a network structure of a BP neural network according to an embodiment of the present application.
Fig. 6 is one of alternative network structures of the BP neural network provided in the embodiments of the present application.
Fig. 7 is a second alternative network structure of the BP neural network according to the embodiment of the present application.
FIG. 8 is a logic block diagram of the stability control of neutron yield provided by an embodiment of the present application.
Fig. 9 is a schematic flow chart of operation logic of the first adjustment parameter according to the embodiment of the present application.
Fig. 10 is a block diagram of a neutron generator control device provided in an embodiment of the present application.
Icon: 100-an electronic device; a 101-processor; 102-memory; 200-neutron generator control device; 210-a first acquisition unit; 220-a first determination unit; 230-a first updating unit; 240-a second determination unit; 250-first circulation unit.
Detailed Description
The present application will be described in detail below with reference to the drawings and the specific embodiments, and it should be noted that in the drawings or the description of the specification, similar or identical parts use the same reference numerals, and implementations not shown or described in the drawings are in a form known to those of ordinary skill in the art. In the description of the present application, the terms "first," "second," and the like are used merely to distinguish between descriptions and are not to be construed as indicating or implying relative importance.
Referring to fig. 1, an embodiment of the present application provides a neutron generator system, which includes a control module (i.e. the PID controller described above) and a neutron generator, where the neutron generator includes a storage power supply, an ion source power supply, a target high-voltage power supply, and a neutron tube, and the neutron generator may further include a source intensity measurement module for neutron yield monitoring. In the neutron generator system, the control module is used for controlling the accumulator power supply, the ion source power supply and the target high-voltage power supply to supply power to the neutron tube, the neutron tube works to generate neutrons, the source intensity measuring module monitors neutron yield and feeds back the neutron yield to the control module, and meanwhile, the control module also has the function of monitoring working parameters of the accumulator power supply, the ion source power supply and the target high-voltage power supply, so that closed-loop control of the neutron generator is realized.
As can be appreciated, referring to fig. 2, a flow chart for stabilizing neutron yield is illustratedThe basic logic for stable control of neutron yield is: when the difference between the anode current of the ion source and the preset current exceeds the first preset difference (i.e., δI a ) When the accumulator current is regulated by the PID controller; when the current of the accumulator is increased, the pressure of the working gas of the neutron tube is increased, and the anode current of the ion source is increased; when the current of the accumulator is reduced, the pressure of working gas in the neutron tube is reduced, and the current of the anode of the ion source is reduced, so that the stable control of neutron yield is realized. Comparing the monitored real-time neutron yield with the preset yield when the difference between the anode current of the ion source and the preset current does not exceed the first preset difference, and comparing the monitored real-time neutron yield with the preset yield when the difference between the real-time neutron yield and the preset yield exceeds the second preset difference (namely delta I n ) When the target pressure is regulated; wherein, when the target pressure is increased, the neutron yield is increased, and when the target pressure is reduced, the neutron yield is reduced.
Referring to fig. 3, an electronic device 100 according to an embodiment of the present application may include a processor 101 and a memory 102. The memory 102 stores a computer program which, when executed by the processor 101, enables the electronic device 100 to perform the respective steps in the neutron generator control method described below.
In this embodiment, the electronic apparatus 100 may be the PID controller described above. The method comprises the steps of acquiring an ion source anode current at the current moment and a first current difference value, determining a first initial adjustment parameter according to a preset current, the ion source anode current, the first current difference value and a preset weight coefficient, and adjusting the current of a storage by taking the first adjustment parameter as a control quantity; then obtaining the anode current of the ion source at the next moment at the current moment, updating the preset weight coefficient according to the preset current, the anode current of the ion source at the next moment and the second current difference value to obtain an updated preset weight coefficient, determining a first iteration parameter based on the updated preset weight coefficient, and adjusting the current of the storage according to the first iteration parameter to adjust the neutron yield; and finally, repeating the steps until the first current difference value is smaller than or equal to the first preset difference value, and realizing stable control of neutron yield of the neutron generator.
Referring to fig. 4, the present application further provides a neutron generator control method, which can be applied to the above electronic device, and the electronic device executes or implements each step in the method. The neutron generator control method may include the steps of:
S1: acquiring the current of an ion source anode of the neutron generator at the current moment and a first current difference value between the current of the ion source anode and a preset current;
s2: when the first current difference value is larger than a first preset difference value, determining a first initial adjustment parameter according to the preset current, the ion source anode current, the first current difference value and a preset weight coefficient, and adjusting the accumulator current of the neutron generator according to the first initial adjustment parameter, wherein the preset weight coefficient comprises a bias vector, and preset weights respectively corresponding to the preset current, the ion source anode current and the first current difference value;
s3: acquiring the anode current of an ion source at the next moment at the current moment, and updating the preset weight coefficient through a first preset weight coefficient updating formula according to the preset current, the anode current of the ion source at the next moment and a second current difference value between the anode current of the ion source at the next moment and the preset current to obtain an updated preset weight coefficient;
s4: determining a first iteration adjustment parameter according to the preset current, the ion source anode current at the next moment, the second current difference value and the updated preset weight coefficient, and adjusting the accumulator current according to the first iteration adjustment parameter so as to adjust the neutron yield of the neutron generator;
S5: repeating the steps S1 to S4 until the first current difference value is smaller than or equal to the first preset difference value.
In the above embodiment, firstly, the anode current of the ion source at the current moment and the first current difference value are obtained; when the first current difference value is larger than a first preset difference value, determining a first initial adjustment parameter according to the preset current, the ion source anode current, the first current difference value and a preset weight coefficient, and adjusting the current of the storage according to the first initial adjustment parameter; then acquiring the anode current of the ion source at the next moment at the current moment, and updating the preset weight coefficient according to the preset current, the anode current of the ion source at the next moment and the second current difference value to obtain an updated preset weight coefficient; then determining a first iteration adjusting parameter according to the preset current, the anode current of the ion source at the next moment, the second current difference value and the updated preset weight coefficient, and adjusting the current of the storage according to the first iteration adjusting parameter so as to adjust the neutron yield of the neutron generator; and finally repeating the steps until the first current difference value is smaller than or equal to a first preset difference value. Therefore, the problems of high rule construction cost and poor universality of the traditional neutron generator control mode can be solved.
The following describes the steps of the control method of the generator in detail, as follows:
in step S1, the ion source anode current may be obtained by monitoring the data by the source intensity measurement module and then transmitting the data to the PID controller in real time, or may be obtained by monitoring the data of the ion source anode current by the source intensity measurement module and then transmitting the data to a memory carried by (or connected to) the PID controller for storing in advance, and then reading or calling the data from the memory 102 based on a subsequent instruction sent by the processor 101 of the PID controller, where the manner of obtaining the ion source anode current is not specifically limited.
In step S2, when the first current difference is greater than a first preset difference, determining a first initial adjustment parameter according to the preset current, the ion source anode current, the first current difference, and a preset weight coefficient, and adjusting the reservoir current of the neutron generator according to the first initial adjustment parameter, may include:
determining a first control parameter of the PID controller according to the preset current, the ion source anode current, the first current difference value and the preset weight coefficient, wherein the first control parameter comprises a first proportional parameter, a first integral parameter and a first differential parameter:
y=f(Wx+b) (1)
Wherein y represents an output vector formed by the first control parameter, f (·) represents an activation function, W represents the preset weight, x represents an input vector formed by the preset current, the ion source anode current and the first current difference, and b represents the bias vector;
determining the first initial adjustment parameter according to the first control parameter:
u(k)=u(k-1)+K p Δe k +K i e k +kd(Δe k -Δe k-1 ) (2)
Δe k =e k -e k-1 ,e k =r(k)-y(k) (3)
wherein u (K) represents the first initial adjustment parameter, K represents the current sampling run, K p Represents the first proportional parameter, K i Representing the first integral parameter, K d Representing the first differential parameter, r (k) representing the preset current, y (k) representing the ion source anode current, e k Representing the first current difference;
and taking the first initial regulation parameter as a control quantity of the PID controller to regulate the accumulator current.
In this embodiment, the determination of the first adjustment parameter may be implemented through a preset BP neural network, which may be integrated in the PID controller, or may be carried by other electronic devices (e.g., a personal computer, a notebook computer, a mobile phone, etc.) connected to the PID controller.
In this embodiment, the network structure of the BP neural network may be as shown in fig. 5, where in fig. 5, r (k) represents the preset current, y (k) represents the ion source anode current, e (k), i.e., e k Representing a first current difference, W i,j Represent implicit layer weights, q j,o Representing the weight of the output layer, the network structure further comprises an input value 1 (it is understood that the number of the input items also needs to be adaptively changed according to the structural complexity of the BP neural network, and in combination with the present application, only the first three inputs shown in the left side of the input layer in fig. 5 need to be provided, and the input value 1 is used as a placeholder adapting to the BP neural network structure and does not participate in realityInter-arithmetic).
Based on the BP neural network, first, according to an input vector, a preset weight and a bias vector, a first control parameter composed of a first proportional parameter, a first integral parameter and a first differential parameter is determined, then, according to the first control parameter, a first initial adjustment parameter of the anode current of the ion source is determined, and the current of the storage is adjusted according to the first initial adjustment parameter through a PID controller, so that the anode current of the ion source is adjusted.
In step S3, the first preset weight coefficient updating formula may be as follows:
in which W is new1 Representing the updated preset weight, b new1 Represents the updated bias vector, η represents the learning rate for controlling the update step of the weight coefficients, E represents the loss function,representing the partial derivative of the loss function with respect to a preset weight,/- >Representation ofPartial derivative of the loss function on the bias vector, +.>Representing the partial derivative of the loss function with respect to the output vector, e k Representing the first current difference.
In this embodiment, a loss function is set for the network based on the BP neural network, and the preset weight, the bias vector and the output vector are respectively calculated and derived based on the loss function, so as to iteratively update the preset weight coefficient (i.e., the preset weight and the bias vector) of the network, so that the preset weight coefficient is counter-propagated through the BP neural network, and the BP neural network can flexibly adapt to the performance change of the neutron generator in the parameter operation process, thereby realizing the stable control of the neutron yield of the neutron generator.
In step S4, determining a first iteration adjustment parameter according to the preset current, the ion source anode current at the next moment, the second current difference value, and the updated preset weight coefficient, and adjusting the reservoir current according to the first iteration adjustment parameter to adjust the neutron yield of the neutron generator may include:
determining an updated first control parameter according to the preset current, the ion source anode current at the next moment, the second current difference value and the updated preset weight coefficient, wherein the updated first control parameter comprises an updated first proportional parameter, an updated first integral parameter and an updated first differential parameter:
y new =f(W new1 x n +b new1 ) (9)
Wherein y is new Representing an output vector composed of the updated first control parameter, f (·) representing an activation function, W new1 Representing the updated preset weight, x n Representing the difference between the preset current, the anode current of the ion source at the next moment and the second current, b new1 Representing the updated bias vector;
determining the first iteration adjusting parameter according to the updated first control parameter:
u(k+1)=u(k)+K pn Δe k+1 +K in e k+1 +K dn (Δe k+1 -Δe k ) (10)
Δe k+1 =e k+1 -e k ,e k+1 =r(k+1)-y(k+1) (11)
where u (k+1) represents the first iterative adjustment parameter, u (K) represents the first initial adjustment parameter, k+1 represents the current sampling round, K pn Representing the updated first scale parameter, K in Representing the updated first integral parameter, K dn Representing the updated first differential parameter, r (k+1) represents the preset current, y (k+1) represents the ion source anode current at the next moment, e k+1 Representing the second current difference;
and taking the first iteration adjusting parameter as a control quantity of the PID controller to adjust the accumulator current.
In this embodiment, after the first round of adjustment of the current of the storage is completed through the first initial adjustment parameter, the input vector required by the BP neural network is collected again in step S3, and the weight coefficient is updated reversely through a preset weight coefficient updating formula according to the input vector collected in the new round, so as to obtain the updated weight coefficient. Then, based on the input vector acquired in the new round and the updated weight coefficient, the step S4 provided in the present embodiment may determine the first iteration adjustment parameter through the BP neural network, so as to perform the second round of adjustment on the current of the storage. Therefore, the PID controller corrects the preset weight coefficient under the action of the BP neural network so as to adapt to the change condition of the anode current of the ion source, and the universality of the PID controller on the performance change of the proton generator is enhanced; meanwhile, the preset weight parameters can be updated and corrected in the step execution process, so that a user can calibrate the initial values of the preset weight parameters without spending resources, and the parameter calibration cost of the PID controller is saved.
In step S5, steps S1 to S4 are cyclically performed until the first current difference value is less than or equal to the first preset difference value. Therefore, after the current of the storage is regulated by the first initial regulation parameter/the first iteration regulation parameter according to the PID controller, the performance of the neutron generator (namely the anode current of the ion source) is circularly corrected by the BP neural network, so that the control parameter (namely the first initial regulation parameter/the first iteration regulation parameter) of the PID controller is circularly updated and corrected, the PID controller can flexibly adapt to the performance change of the neutron generator in the process of controlling the neutron yield of the neutron generator, and the universality of the PID controller is enhanced. Meanwhile, the preset weight coefficient can be circularly corrected, so that a user can omit the calibration process of the preset weight coefficient in the practical application of the PID controller, and the construction cost of the control rule of the PID controller is saved.
It can be understood that, in practical application, the network structure of the BP neural network is only used as a tool for implementing calculation and iteration of the first initial adjustment parameter and the first iteration adjustment parameter, the network structure of the BP neural network is not particularly limited, and the function of obtaining the first initial adjustment parameter and the first iteration adjustment parameter by calculating the preset current r (k), the ion source anode current y (k) and the error value e (k) of the two may be implemented, and in some alternative embodiments, the network structure of the BP neural network may be as shown in fig. 6 and fig. 7.
As an alternative embodiment, the method may further comprise:
s6: when the first current difference value is smaller than or equal to the first preset difference value, a first neutron yield is obtained, and when the first current difference value is smaller than or equal to the first preset difference value, the first neutron yield represents the neutron yield monitored by the neutron generator system at the same time;
s7: when the current difference value is smaller than or equal to the first preset difference value and the difference between the first neutron yield and the preset yield is larger than a second preset difference value, determining a second initial adjustment parameter according to the preset yield, the first neutron yield, the difference between the first neutron yield and the preset yield and a current weight, and adjusting the target pressure of the neutron generator according to the second initial adjustment parameter, wherein the current weight is obtained after the preset weight coefficient is updated for the last time in the step S3;
s8: acquiring a second neutron yield, updating the current weight through a second preset weight coefficient updating formula according to the preset yield, the second neutron yield and the difference between the second neutron yield and the preset yield to obtain an updated current weight, wherein the second neutron yield represents the neutron yield monitored by the neutron generator system at the next moment after the target pressure of the neutron generator is regulated according to the second initial regulating parameter;
S9: determining a second iteration adjustment parameter according to the preset yield, the second neutron yield, the difference between the second neutron yield and the preset yield and the updated current weight, and adjusting the target pressure according to the second iteration adjustment parameter so as to adjust the neutron yield of the neutron generator;
s10: and repeating the steps S1 to S9 until the neutron generator stops working.
It can be understood that when the anode current of the ion source is in a stable state and the neutron yield of the neutron generator still does not meet the ideal condition (i.e., the first current difference is less than or equal to the first preset difference and the difference between the first neutron yield and the preset yield is greater than the second preset difference), the embodiment can further control the neutron yield by adjusting the target pressure of the neutron generator.
Specifically, in this embodiment, the preset yield, the first neutron yield, the difference between the first neutron yield and the preset yield, and the current weight are used as inputs of the BP neural network, the second initial adjustment parameter is obtained through calculation of the BP neural network, after the PID controller adjusts the target pressure according to the second initial adjustment parameter, the second neutron yield is collected through the source intensity measurement module, the current weight is updated through the BP neural network according to the collected second neutron yield, and then the second iterative adjustment parameter is determined according to the updated current weight, so that the PID controller continuously updates the parameters of the PID controller in the process of adjusting the target pressure according to the neutron yield and controlling the neutron yield through feedback of the target pressure, thereby enhancing the universality of the PID controller on the performance change of the neutron generator.
In this embodiment, the second preset weight coefficient updating formula may be as follows:
in which W is new2 Representing a preset weight value in the updated current weight, b new2 Representing the bias vector, W, in the updated current weight c Representing the preset weight value, b, obtained after the last update in step S3 c Represents the offset vector, x, obtained after the last update in step S3 c Representing an input vector composed of the preset yield, the second neutron yield, the difference between the second neutron yield and the preset yield, η representing a learning rate for controlling a weight coefficient update step size, E representing a loss function,representing the preset weight of the loss functionPartial derivative of value,/->Representing the partial derivative of the loss function with respect to the bias vector, < >>Representing the partial derivative of the loss function with respect to the output vector, e c Representing the difference between the first neutron yield and the preset yield.
In practical applications, the determination of the second initial adjustment parameter/the second iterative adjustment parameter is the same as the calculation logic of the first initial adjustment parameter/the first iterative adjustment parameter, the calculation of the second initial adjustment parameter is still realized by calling the formula (1), the formula (2) and the formula (3), the calculation of the second iterative adjustment parameter is still realized by calling the formula (9), the formula (10) and the formula (11), and the difference is only the replacement of data, for example, the replacement of the preset weight coefficient (i.e. the preset weight value and the bias vector) in the formula (1) with the current weight, and the replacement of the input vector consisting of the preset electric quantity, the ion source anode current and the first current difference with the first neutron yield, the preset yield and the difference between the first neutron yield and the preset yield. Therefore, the calculation process of the second initial adjustment parameter/the second iterative adjustment parameter is not described herein.
In the above embodiment, the preset current, the first preset difference, the preset weight coefficient, the preset yield, and the second preset difference may be flexibly set according to the user requirement, and the preset current, the first preset difference, the preset weight coefficient, the preset yield, and the second preset difference are not specifically limited in this embodiment.
As an alternative embodiment, the method may further comprise:
and when the execution times of the step S10 exceeds the preset times and the difference between the neutron yield and the preset yield is larger than the second preset difference value each time in the execution process of the step S10, sending a prompt for indicating the damage of the neutron generator system.
In this embodiment, when the number of times of execution of the step S10 exceeds the preset number of times, and the difference between the first neutron yield and the preset yield is greater than the second preset difference value each time in the execution process of the step S10, a prompt indicating that the neutron generator system is damaged is sent out by a prompt module (such as a buzzer, an LED display screen, etc.) integrated with the PID controller itself, or a prompt device (such as a speaker, an audible and visual alarm, etc.) electrically connected with the PID controller, so as to remind a user to repair the neutron generator system in time.
Referring to fig. 8 and 9, a manner of implementing a PID controller based on a BP neural network to control a neutron generator will be described based on fig. 8 and 9, as follows:
brief description of the drawings: in fig. 8, r_ia (t) represents a set value (i.e., a preset current) of the anode current of the ion source, and y_ia (t) represents an actual value of the anode current of the ion source collected by the source intensity measurement module; e_ia (t) =r_ia (t) -y_ia (t), representing the error (i.e., first current difference) between the ion source anode current setpoint and the actual value; de_ia (t)/dt represents the rate of change of the error, in this embodiment, the error between the set value and the actual value of the anode current of the ion source between every two data acquisitions; r_yn (t) represents a set value of neutron yield (i.e., a preset yield), and y_yn (t) represents an actual value of neutron yield collected by the source intensity measurement module; e_yn (t) =r_yn (t) -y_yn (t), representing the error between the neutron yield set value and the actual value; de_yn (t)/dt represents the change in error between the neutron yield set point and the actual value between every two data acquisitions over a fixed time. It will be understood that, in fig. 8, the variable t related to each parameter represents the current time, and the variable k related to each parameter in fig. 9 represents the current sampling round, k may be understood as a counter of t, and the two meanings are substantially the same in the parameter calculation process of the PID controller. For example, when the time interval between the time instants is 5 seconds and the natural time is 0:00, t=1 indicates that the current time instant is the first time instant, and at this time, the first time of collection of the anode current of the ion source and/or the heavy resource is performed, namely k=1; when the natural time is 0:05, t=2 represents that the current time is the second time, and the second time of collecting the anode current or/and the heavy resource yield of the ion source is performed at this time, namely k=2.
The control mode comprises the following steps: firstly, collecting the anode current of an ion source of a neutron generator at the current moment through a source intensity measuring module, circularly correcting a first initial adjusting parameter and a first iteration adjusting parameter through a BP neural network according to the difference value (namely a first current difference value) between the anode current of the ion source and a preset value, and adjusting the current of a storage based on the first initial adjusting parameter and the first iteration adjusting parameter, so that the anode current of the ion source is adjusted through the current phase change of the storage, and the neutron yield of the neutron generator is controlled, and specifically:
determining a first control parameter of the PID controller according to a preset current, an ion source anode current, a first current difference value and a preset weight coefficient, wherein the first control parameter comprises a first proportional parameter, a first integral parameter and a first differential parameter:
y=f(Wx+b)
wherein y represents an output vector formed by a first control parameter, f (·) represents an activation function, W represents a preset weight, x represents an input vector formed by a preset current, an ion source anode current and a first current difference value, and b represents a bias vector;
determining a first initial adjustment parameter according to the first control parameter:
u(k)=u(k-1)+K p Δe k +K i e k +K d (Δe k -Δe k-1 )
Δe k =e k -e k-1 ,e k =r(k)-y(k)
where u (K) represents the first initial adjustment parameter, K represents the current sampling run, K p Represents a first proportional parameter, K i Represents a first integral parameter, K d Represents a first differential parameter, r (k) represents a preset current, y (k) represents an ion source anode current, e k Representing a first current difference;
and taking the first initial regulation parameter as a control quantity of the PID controller to regulate the current of the storage.
After the current of the storage is regulated for the first time, the ion source anode current at the next moment is collected through the source intensity measuring module, and the preset weight coefficient is updated through the following first preset weight coefficient updating formula according to the preset current, the ion source anode current at the next moment, and the second current difference value between the ion source anode current at the next moment and the preset current:
in which W is new1 Representing the updated preset weight, b new1 Represents the updated bias vector, η represents the learning rate for controlling the update step of the weight coefficients, E represents the loss function,representing the partial derivative of the loss function with respect to a preset weight,/->Representing the partial derivative of the loss function with respect to the bias vector, < >>Representing the partial derivative of the loss function with respect to the output vector, e k Representing the first current difference.
Then determining updated first control parameters according to the preset current, the ion source anode current at the next moment, the second current difference value and the updated preset weight coefficient, wherein the updated first control parameters comprise updated first proportional parameters, updated first integral parameters and updated first differential parameters:
y new =f(W new1 x n +b new1 )
Wherein y is new Representing an output vector composed of updated first control parameters, f (·) representing an activation function, W new1 Representing the updated preset weight, x n Representing the difference between the anode current of the ion source at the next moment and the second current, b new1 Representing the updated bias vector;
according to the updated first control parameter, determining a first iteration adjusting parameter:
u(k+1)=u(k)+K pn Δe k+1 +K in e k+1 +K dn (Δe k+1 -Δe k )
Δe k+1 =e k+1 -e k ,e k+1 =r(k+1)-y(k+1)
where u (k+1) represents a first iterative adjustment parameter, u (K) represents the first initial adjustment parameter, k+1 represents the current sampling run, K pn Representing the updated first scale parameter, K in Representing the updated first integral parameter, K dn Representing the updated first differential parameter, r (k+1) represents the preset current, y (k+1) represents the ion source anode current at the next moment, e k+1 Representing a second current difference;
and taking the first iteration adjusting parameter as a control quantity of the PID controller, and adjusting the current of the storage.
And circulating the steps until the first current difference value is smaller than or equal to a first preset difference value.
When the first current difference value is smaller than or equal to a first preset difference value, acquiring a second neutron yield through a source intensity measuring module, and when the first current difference value is smaller than or equal to the first preset difference value and the difference between the second neutron yield and the preset yield is larger than the second preset difference value, determining a second initial adjusting parameter according to the preset yield, the first neutron yield, the difference between the first neutron yield and the preset yield and the current weight, and adjusting the target pressure of the neutron generator according to the second initial adjusting parameter;
And then, acquiring a second neutron yield, and updating the current weight according to the preset yield, the second neutron yield and the difference between the second neutron yield and the preset yield by using a second preset weight coefficient updating formula as follows to obtain the updated current weight:
in which W is new2 Representing a preset weight value in the updated current weight, b new2 Representing the bias vector, W, in the updated current weight c Representing the preset weight value, b, obtained after the last update in step S3 c Represents the offset vector, x, obtained after the last update in step S3 c Represents an input vector composed of a preset yield, a second neutron yield, a difference between the second neutron yield and the preset yield, η represents a learning rate for controlling a weight coefficient update step size, E represents a loss function,representing the partial derivative of the loss function with respect to a preset weight,/->Representing the partial derivative of the loss function with respect to the bias vector, < >>Representing the partial derivative of the loss function with respect to the output vector, e c Representing the difference between the first neutron yield and the preset yield.
Then determining a second iteration adjusting parameter according to the preset yield, the second neutron yield, the difference between the second neutron yield and the preset yield and the updated current weight, and adjusting the target pressure according to the second iteration adjusting parameter so as to adjust the neutron yield of the neutron generator;
And finally repeating the steps until the neutron generator stops working.
In this way, the anode current and the neutron yield of the ion source are collected in real time, and the first initial adjustment parameter/the first iteration adjustment parameter and the second initial adjustment parameter/the second iteration adjustment parameter of the PID controller can be continuously corrected through the BP neural network according to the difference between the anode current and a preset value (preset electric quantity) of the ion source and the difference between the neutron yield and the preset value (preset yield), so that the PID controller can stably control the neutron yield of the neutron generator according to the first initial adjustment parameter/the first iteration adjustment parameter and the second initial adjustment parameter/the second iteration adjustment parameter of the continuous iteration.
Based on the design, the PID controller can flexibly adjust control parameters according to the performance of the neutron generator which is continuously changed in the process of controlling the neutron generator, so that the universality of the PID controller is enhanced, and meanwhile, the preset weight coefficient is continuously corrected in the adjustment process, so that the data calibration in the early stage of industrial application is avoided, and a large amount of cost is saved.
Referring to fig. 10, the present application further provides a neutron generator control device 200, where the neutron generator control device 200 includes at least one software functional module that may be stored in the memory 102 in the form of software or Firmware (Firmware) or cured in an Operating System (OS) of the electronic device 100. The processor 101 is configured to execute executable modules stored in the memory 102, such as software functional modules and computer programs included in the neutron generator control device 200.
The neutron generator control device 200 includes a first acquisition unit 210, a first determination unit 220, a first update unit 230, a second determination unit 240, and a first circulation unit 250, each of which may have the following functions:
the first acquisition unit is used for acquiring the anode current of the ion source of the neutron generator at the current moment and a first current difference value between the anode current of the ion source and a preset current;
the first determining unit is used for determining a first initial adjusting parameter according to the preset current, the ion source anode current, the first current difference value and a preset weight coefficient when the first current difference value is larger than a first preset difference value, and adjusting the accumulator current of the neutron generator according to the first initial adjusting parameter, wherein the preset weight coefficient comprises a bias vector and preset weights respectively corresponding to the preset current, the ion source anode current and the first current difference value;
the first updating unit is used for acquiring the ion source anode current at the next moment at the current moment, and updating the preset weight coefficient through a first preset weight coefficient updating formula according to the preset current, the ion source anode current at the next moment and a second current difference value between the ion source anode current at the next moment and the preset current to obtain an updated preset weight coefficient;
The second determining unit is used for determining a first iteration adjusting parameter according to the preset current, the ion source anode current at the next moment, the second current difference value and the updated preset weight coefficient, and adjusting the accumulator current according to the first iteration adjusting parameter so as to adjust the neutron yield of the neutron generator;
the first circulation unit is used for repeatedly obtaining the ion source anode current of the neutron generator at the current moment and the first current difference value, when the first current difference value is larger than a first preset difference value, determining a first initial adjustment parameter according to the preset current, the ion source anode current at the next moment, the first current difference value and the preset weight coefficient, adjusting the storage current of the neutron generator according to the first initial adjustment parameter, obtaining the ion source anode current at the next moment at the current moment, and updating the preset weight coefficient according to a first preset weight coefficient updating formula according to the preset current, the ion source anode current at the next moment, the second current difference value and the second current difference value of the preset current, obtaining an updated preset weight coefficient, determining a first adjustment parameter according to the preset current, the ion source anode current at the next moment, the second current difference value and the updated weight coefficient, and adjusting the storage according to the first iteration adjustment parameter until the first iteration adjustment parameter is smaller than the first difference value.
Optionally, the first determining unit 220 is further configured to:
determining a first control parameter of the PID controller according to the preset current, the ion source anode current, the first current difference value and the preset weight coefficient, wherein the first control parameter comprises a first proportional parameter, a first integral parameter and a first differential parameter:
y=f(Wx+b)
wherein y represents an output vector formed by the first control parameter, f (·) represents an activation function, W represents the preset weight, x represents an input vector formed by the preset current, the ion source anode current and the first current difference, and b represents the bias vector;
determining the first initial adjustment parameter according to the first control parameter:
u(k)=u(k-1)+K p Δe k +K i e k +K d (Δe k -Δe k-1 )
Δe k =e k -e k-1 ,e k =r(k)-y(k)
in the middle ofU (K) represents the first initial adjustment parameter, K represents the current sampling run, K p Represents the first proportional parameter, K i Representing the first integral parameter, K d Representing the first differential parameter, r (k) representing the preset current, y (k) representing the ion source anode current, e k Representing the first current difference;
and taking the first initial regulation parameter as a control quantity of the PID controller to regulate the accumulator current.
Optionally, the updating formula of the first preset weight coefficient is as follows:
in which W is new1 Representing the updated preset weight, b new1 Represents the updated bias vector, η represents the learning rate for controlling the update step of the weight coefficients, E represents the loss function,representing the partial derivative of the loss function with respect to a preset weight,/->Representing the partial derivative of the loss function with respect to the bias vector, < >>Representing the partial derivative of the loss function with respect to the output vector, e k Representing the first current difference.
Optionally, the second determining unit 240 is further configured to:
determining an updated first control parameter according to the preset current, the ion source anode current at the next moment, the second current difference value and the updated preset weight coefficient, wherein the updated first control parameter comprises an updated first proportional parameter, an updated first integral parameter and an updated first differential parameter:
y new =f(W new1 x n +b new1 )
wherein y is new Representing an output vector composed of the updated first control parameter, f (·) representing an activation function, W new1 Representing the updated preset weight, x n Representing the difference between the preset current, the anode current of the ion source at the next moment and the second current, b new1 Representing the updated bias vector;
determining the first iteration adjusting parameter according to the updated first control parameter:
u(k+1)=u(k)+K pn Δe k+1 +K in e k+1 +K dn (Δe k+1 -Δe k )
Δe k+1 =e k+1 -e k ,e k+1 =r(k+1)-y(k+1)
where u (k+1) represents the first iterative adjustment parameter, u (K) represents the first initial adjustment parameter, k+1 represents the current sampling round, K pn Representing the updated first scale parameter, K in Representing the updated first integral parameter, K dn Representing the updated first differential parameter, r (k+1) represents the preset current, y (k+1) represents the ion source anode current at the next moment, e k+1 Representing the second current difference;
and taking the first iteration adjusting parameter as a control quantity of the PID controller to adjust the accumulator current.
Optionally, the neutron generator control device may further include:
the second obtaining unit is used for obtaining a first neutron yield when the first current difference value is smaller than or equal to the first preset difference value, and the first neutron yield represents the neutron yield monitored by the neutron generator system at the same time when the first current difference value is smaller than or equal to the first preset difference value;
a third determining unit, configured to determine a second initial adjustment parameter according to the preset yield, the first neutron yield, the difference between the first neutron yield and the preset yield, and a current weight when the current difference is less than or equal to the first preset difference and the difference between the first neutron yield and the preset yield is greater than a second preset difference, and adjust a target pressure of the neutron generator according to the second initial adjustment parameter, where the current weight is obtained after the preset weight coefficient is updated last time in step S3;
The second updating unit is used for acquiring a second neutron yield, updating the current weight through a second preset weight coefficient updating formula according to the preset yield, the second neutron yield and the difference between the second neutron yield and the preset yield to obtain an updated current weight, wherein the second neutron yield represents the neutron yield monitored by the neutron generator system at the next moment after the target pressure of the neutron generator is regulated according to the second initial regulating parameter;
a fourth determining unit, configured to determine a second iteration adjustment parameter according to the preset yield, the second neutron yield, a difference between the second neutron yield and the preset yield, and the updated current weight, and adjust the target pressure according to the second iteration adjustment parameter, so as to adjust the neutron yield of the neutron generator;
and the second circulation unit is used for repeating the steps S1 to S9 until the neutron generator stops working.
Optionally, the second preset weight coefficient updating formula is as follows:
/>
in which W is new2 Representing a preset weight value in the updated current weight, b new2 Representing the bias vector, W, in the updated current weight c Representing the preset weight value, b, obtained after the last update in step S3 c Represents the offset vector, x, obtained after the last update in step S3 c Representing an input vector composed of the preset yield, the second neutron yield, the difference between the second neutron yield and the preset yield, η representing a learning rate for controlling a weight coefficient update step size, E representing a loss function,representing the partial derivative of the loss function with respect to a preset weight,/->Representing the partial derivative of the loss function with respect to the bias vector, < >>Representing the loss function versus inputPartial derivative of the output vector e c Representing the difference between the first neutron yield and the preset yield.
Optionally, the neutron generator control device may further include:
and the prompting unit is used for sending a prompt for indicating that the neutron generator system is damaged when the execution times of the step S10 exceeds the preset times and the difference between the neutron yield and the preset yield is larger than the second preset difference value each time in the execution process of the step S10.
In this embodiment, the processor 101 may be an integrated circuit chip with signal processing capability. The processor 101 may be a general-purpose processor. For example, the processor 101 may be a central processing unit (Central Processing Unit, CPU), digital signal processor (Digital Signal Processing, DSP), application specific integrated circuit (Application Specific Integrated Circuit, ASIC), field programmable gate array (Field-Programmable Gate Array, FPGA) or other programmable logic device, discrete gate or transistor logic, discrete hardware components, or may implement or perform the methods, steps, and logic blocks disclosed in embodiments of the present application.
The memory 102 may be, but is not limited to, random access memory, read only memory, programmable read only memory, erasable programmable read only memory, electrically erasable programmable read only memory, and the like. In this embodiment, the memory 102 may be used to store a preset current, a first preset difference, a preset weight coefficient, a preset yield, a second preset difference, a BP neural network, and the like. Of course, the memory 102 may also be used to store a program that the processor 101 executes after receiving the execution instruction.
It is understood that the neutron generator system shown in fig. 1 and the electronic device 100 structure shown in fig. 3 are only one type of schematic structure, and that the neutron generator system and the electronic device 100 may also include more components than those shown in fig. 1/3. The components shown in fig. 1 and 3 may be implemented in hardware, software, or a combination thereof.
It should be noted that, for convenience and brevity of description, the detailed operation of the neutron generator system and the electronic device 100 described above may refer to the corresponding process of each step in the foregoing method, and will not be described in detail herein.
Embodiments of the present application also provide a computer-readable storage medium. The computer readable storage medium has stored therein a computer program which, when run on a computer, causes the computer to perform the neutron generator control method as described in the above embodiments.
From the foregoing description of the embodiments, it will be apparent to those skilled in the art that the present application may be implemented in hardware, or by means of software plus a necessary general hardware platform, and based on this understanding, the technical solution of the present application may be embodied in the form of a software product, which may be stored in a non-volatile storage medium (may be a CD-ROM, a U-disc, a mobile hard disk, etc.), and includes several instructions to cause a computer device (may be a personal computer, a server, or a network device, etc.) to perform the methods described in the respective implementation scenarios of the present application.
In summary, the embodiment of the application provides a neutron generator control method, a neutron generator control device, an electronic device and a storage medium, in the technical scheme, firstly, an ion source anode current at the current moment and a first current difference value are obtained; when the first current difference value is larger than a first preset difference value, determining a first initial adjustment parameter according to the preset current, the ion source anode current, the first current difference value and a preset weight coefficient, and adjusting the current of the storage according to the first initial adjustment parameter; then acquiring the anode current of the ion source at the next moment at the current moment, and updating the preset weight coefficient according to the preset current, the anode current of the ion source at the next moment and the second current difference value to obtain an updated preset weight coefficient; then determining a first iteration adjusting parameter according to the preset current, the anode current of the ion source at the next moment, the second current difference value and the updated preset weight coefficient, and adjusting the current of the storage according to the first iteration adjusting parameter so as to adjust the neutron yield of the neutron generator; and finally repeating the steps until the first current difference value is smaller than or equal to a first preset difference value. Therefore, the problems of high rule construction cost and poor universality of the traditional neutron generator control mode can be solved.
In the embodiments provided in the present application, it should be understood that the disclosed apparatus, system, and method may be implemented in other manners as well. The above-described apparatus, systems, and method embodiments are merely illustrative, for example, flow charts and block diagrams in the figures illustrate the architecture, functionality, and operation of possible implementations of systems, methods and computer program products according to various embodiments of the present application. In this regard, each block in the flowchart or block diagrams may represent a module, segment, or portion of code, which comprises one or more executable instructions for implementing the specified logical function(s). It will also be noted that each block of the block diagrams and/or flowchart illustration, and combinations of blocks in the block diagrams and/or flowchart illustration, can be implemented by special purpose hardware-based systems which perform the specified functions or acts, or combinations of special purpose hardware and computer instructions. In addition, the functional modules in the embodiments of the present application may be integrated together to form a single part, or each module may exist alone, or two or more modules may be integrated to form a single part.
The foregoing is merely exemplary embodiments of the present application and is not intended to limit the scope of the present application, and various modifications and variations may be suggested to one skilled in the art. Any modification, equivalent replacement, improvement, etc. made within the spirit and principles of the present application should be included in the protection scope of the present application.

Claims (10)

1. A neutron generator control method for use in a PID controller in a neutron generator system, the neutron generator system further comprising a neutron generator, the method comprising:
s1: acquiring the current of an ion source anode of the neutron generator at the current moment and a first current difference value between the current of the ion source anode and a preset current;
s2: when the first current difference value is larger than a first preset difference value, determining a first initial adjustment parameter according to the preset current, the ion source anode current, the first current difference value and a preset weight coefficient, and adjusting the accumulator current of the neutron generator according to the first initial adjustment parameter, wherein the preset weight coefficient comprises a bias vector, and preset weights respectively corresponding to the preset current, the ion source anode current and the first current difference value;
S3: acquiring the anode current of an ion source at the next moment at the current moment, and updating the preset weight coefficient through a first preset weight coefficient updating formula according to the preset current, the anode current of the ion source at the next moment and a second current difference value between the anode current of the ion source at the next moment and the preset current to obtain an updated preset weight coefficient;
s4: determining a first iteration adjustment parameter according to the preset current, the ion source anode current at the next moment, the second current difference value and the updated preset weight coefficient, and adjusting the accumulator current according to the first iteration adjustment parameter so as to adjust the neutron yield of the neutron generator;
s5: repeating the steps S1 to S4 until the first current difference value is smaller than or equal to the first preset difference value.
2. The method according to claim 1, wherein step S2 comprises:
determining a first control parameter of the PID controller according to the preset current, the ion source anode current, the first current difference value and the preset weight coefficient, wherein the first control parameter comprises a first proportional parameter, a first integral parameter and a first differential parameter:
y=f(Wx+b)
Wherein y represents an output vector formed by the first control parameter, f (·) represents an activation function, W represents the preset weight, x represents an input vector formed by the preset current, the ion source anode current and the first current difference, and b represents the bias vector;
determining the first initial adjustment parameter according to the first control parameter:
u(k)=u(k-1)+K p Δe k +K i e k +K d (Δe k -Δe k-1 )
Δe k =e k -e k-1 ,e k =r(k)-y(k)
wherein u (K) represents the first initial adjustment parameter, K represents the current sampling run, K p Represents the first proportional parameter, K i Representing the first integral parameter, K d Representing the first differential parameter, r (k) representing the preset current, y (k) representing the ion source anode current, e k Representing the first current difference;
and taking the first initial regulation parameter as a control quantity of the PID controller to regulate the accumulator current.
3. The method of claim 1, wherein the first preset weight coefficient update formula is as follows:
in which W is new1 Representing the updated preset weight, b new1 Represents the updated bias vector, η represents the learning rate for controlling the update step of the weight coefficients, E represents the loss function,representing the partial derivative of the loss function with respect to a preset weight,/- >Representing the partial derivative of the loss function with respect to the bias vector, < >>Representing the partial derivative of the loss function with respect to the output vector, e k Representing the first current difference.
4. The method according to claim 1, wherein step S4 comprises:
determining an updated first control parameter according to the preset current, the ion source anode current at the next moment, the second current difference value and the updated preset weight coefficient, wherein the updated first control parameter comprises an updated first proportional parameter, an updated first integral parameter and an updated first differential parameter:
y new =f(W new1 x n +b new1 )
wherein y is new Representing an output vector composed of the updated first control parameter, f (·) representing an activation function, W new1 Representing the updated preset weight, x n Representing the difference between the preset current, the anode current of the ion source at the next moment and the second current, b new1 Representing the updated bias vector;
Determining the first iteration adjusting parameter according to the updated first control parameter:
u(k+1)=u(k)+K pn Δe k+1 +K in e k+1 +K dn (Δe k+1 -Δe k )
Δe k+1 =e k+1 -e k ,e k+1 =r(k+1)-y(k+1)
where u (k+1) represents the first iterative adjustment parameter, u (K) represents the first initial adjustment parameter, k+1 represents the current sampling round, K pn Representing the updated first scale parameter, K in Representing the updated first integral parameter, K dn Representing the updated first differential parameter, r (k+1) represents the preset current, y (k+1) represents the ion source anode current at the next moment, e k+1 Representing the second current difference;
and taking the first iteration adjusting parameter as a control quantity of the PID controller to adjust the accumulator current.
5. The method according to claim 1, wherein the method further comprises:
s6: when the first current difference value is smaller than or equal to the first preset difference value, a first neutron yield is obtained, and when the first current difference value is smaller than or equal to the first preset difference value, the first neutron yield represents the neutron yield monitored by the neutron generator system at the same time;
s7: when the current difference value is smaller than or equal to the first preset difference value and the difference between the first neutron yield and the preset yield is larger than a second preset difference value, determining a second initial adjustment parameter according to the preset yield, the first neutron yield, the difference between the first neutron yield and the preset yield and a current weight, and adjusting the target pressure of the neutron generator according to the second initial adjustment parameter, wherein the current weight is obtained after the preset weight coefficient is updated for the last time in the step S3;
S8: acquiring a second neutron yield, updating the current weight through a second preset weight coefficient updating formula according to the preset yield, the second neutron yield and the difference between the second neutron yield and the preset yield to obtain an updated current weight, wherein the second neutron yield represents the neutron yield monitored by the neutron generator system at the next moment after the target pressure of the neutron generator is regulated according to the second initial regulating parameter;
s9: determining a second iteration adjustment parameter according to the preset yield, the second neutron yield, the difference between the second neutron yield and the preset yield and the updated current weight, and adjusting the target pressure according to the second iteration adjustment parameter so as to adjust the neutron yield of the neutron generator;
s10: and repeating the steps S1 to S9 until the neutron generator stops working.
6. The method of claim 5, wherein the second preset weight coefficient update formula is as follows:
in which W is new2 Representing a preset weight value in the updated current weight, b new2 Representing the updated current timeBias vector in front weight, W c Representing the preset weight value, b, obtained after the last update in step S3 c Represents the offset vector, x, obtained after the last update in step S3 c Representing an input vector composed of the preset yield, the second neutron yield, the difference between the second neutron yield and the preset yield, η representing a learning rate for controlling a weight coefficient update step size, E representing a loss function,representing the partial derivative of the loss function with respect to a preset weight,/->Representing the partial derivative of the loss function with respect to the bias vector, < >>Representing the partial derivative of the loss function with respect to the output vector, ec representing the difference between the first neutron yield and the predetermined yield.
7. The method of claim 5, wherein the method further comprises:
and when the execution times of the step S10 exceeds the preset times and the difference between the neutron yield and the preset yield is larger than the second preset difference value each time in the execution process of the step S10, sending a prompt for indicating the damage of the neutron generator system.
8. A neutron generator control device, the device comprising:
the first acquisition unit is used for acquiring the anode current of the ion source of the neutron generator at the current moment and a first current difference value between the anode current of the ion source and a preset current;
The first determining unit is used for determining a first initial adjusting parameter according to the preset current, the ion source anode current, the first current difference value and a preset weight coefficient when the first current difference value is larger than a first preset difference value, and adjusting the accumulator current of the neutron generator according to the first initial adjusting parameter, wherein the preset weight coefficient comprises a bias vector and preset weights respectively corresponding to the preset current, the ion source anode current and the first current difference value;
the first updating unit is used for acquiring the ion source anode current at the next moment at the current moment, and updating the preset weight coefficient through a first preset weight coefficient updating formula according to the preset current, the ion source anode current at the next moment and a second current difference value between the ion source anode current at the next moment and the preset current to obtain an updated preset weight coefficient;
the second determining unit is used for determining a first iteration adjusting parameter according to the preset current, the ion source anode current at the next moment, the second current difference value and the updated preset weight coefficient, and adjusting the accumulator current according to the first iteration adjusting parameter so as to adjust the neutron yield of the neutron generator;
The first circulation unit is used for repeatedly obtaining the ion source anode current of the neutron generator at the current moment and the first current difference value, when the first current difference value is larger than a first preset difference value, determining a first initial adjustment parameter according to the preset current, the ion source anode current at the next moment, the first current difference value and the preset weight coefficient, adjusting the storage current of the neutron generator according to the first initial adjustment parameter, obtaining the ion source anode current at the next moment at the current moment, and updating the preset weight coefficient according to a first preset weight coefficient updating formula according to the preset current, the ion source anode current at the next moment, the second current difference value and the second current difference value of the preset current, obtaining an updated preset weight coefficient, determining a first adjustment parameter according to the preset current, the ion source anode current at the next moment, the second current difference value and the updated weight coefficient, and adjusting the storage according to the first iteration adjustment parameter until the first iteration adjustment parameter is smaller than the first difference value.
9. An electronic device comprising a processor and a memory coupled to each other, the memory storing a computer program that, when executed by the processor, causes the electronic device to perform the method of any of claims 1-7.
10. A computer readable storage medium, characterized in that the computer readable storage medium has stored therein a computer program which, when run on a computer, causes the computer to perform the method according to any of claims 1-7.
CN202311423359.5A 2023-10-30 2023-10-30 Neutron generator control method and device, electronic equipment and storage medium Pending CN117539142A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202311423359.5A CN117539142A (en) 2023-10-30 2023-10-30 Neutron generator control method and device, electronic equipment and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202311423359.5A CN117539142A (en) 2023-10-30 2023-10-30 Neutron generator control method and device, electronic equipment and storage medium

Publications (1)

Publication Number Publication Date
CN117539142A true CN117539142A (en) 2024-02-09

Family

ID=89794923

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202311423359.5A Pending CN117539142A (en) 2023-10-30 2023-10-30 Neutron generator control method and device, electronic equipment and storage medium

Country Status (1)

Country Link
CN (1) CN117539142A (en)

Similar Documents

Publication Publication Date Title
CN104953814B (en) A kind of method and apparatus for controlling pfc circuit
US11316212B2 (en) Method, system and device for active balance control of battery pack
CN111596718B (en) Photovoltaic power generation control method and device, computer equipment and storage medium
KR20110128907A (en) Control concept for a digitally controlled magnetic supply device
US10073144B2 (en) Method of determining the state of charge of a battery of an electronic appliance
CN113315164A (en) Reactive voltage control method and device, medium and computing device
KR102382047B1 (en) Automatic learning tuning system of motor controller using PSO
CN109446720B (en) Parameter identification method for self-shunt excitation system of high-capacity phase modulator
CN110646518A (en) Output control method of ultrasonic transducer and related equipment
Abdullah et al. Alternative method for predictive functional control to handle an integrating process
CN117117992B (en) Output power adjusting method, device, computer equipment and storage medium
JPH0535309A (en) Model prediction control device
Spoljarić et al. Optimization of PID controller in AVR system by using ant lion optimizer algorithm
CN117539142A (en) Neutron generator control method and device, electronic equipment and storage medium
GB2597798A (en) Intelligent battery management system and method
JP2014191736A (en) Control parameter determination device, method, and program, and controller, and optimization control system
US9013073B2 (en) System and method for balancing input current with parallel power supplies
KR101762357B1 (en) Control device and method for voltage source inverter
JP6848710B2 (en) Plant control and adjustment equipment and methods
CN111146811A (en) Virtual synchronous generator secondary frequency modulation robust control method
CN116914777B (en) Small signal stability analysis method, device and system for wind power system and storage medium
Yu et al. Online Adversarial Stabilization of Unknown Linear Time-Varying Systems
Sokolov Problems of adaptive optimal control of discrete-time systems under bounded disturbance and linear performance indexes
CN117055354A (en) Power control optimization method and device based on closed-loop control algorithm
Tian et al. Variable gain iterative learning control with initial error correction

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination