Palladium-nickel oil hydrogen rapid response control method and system based on variable temperature fitting

By using a variable-temperature fitting control method to dynamically adjust the temperature of the Pd-Ni sensor, the response delay problem during oil sample switching was solved, enabling rapid and accurate hydrogen concentration detection and improving detection accuracy and sensor stability.

CN122016953BActive Publication Date: 2026-07-07WUHAN HAOMAI OPTOELECTRONICS TECH CO LTD

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
WUHAN HAOMAI OPTOELECTRONICS TECH CO LTD
Filing Date
2026-04-07
Publication Date
2026-07-07

AI Technical Summary

Technical Problem

Existing Pd-Ni-based sensors have slow response speeds when switching oil samples, which cannot meet the requirements for rapid diagnosis and real-time control. Furthermore, the constant temperature mode cannot adapt to changes in oil sample characteristics, resulting in decreased detection accuracy and stability.

Method used

The variable temperature fitting control method is adopted. By monitoring the oil sample characteristics and resistance value in real time, the temperature is dynamically adjusted, including transient heating, dynamic temperature adjustment and steady-state isothermal stages. Combined with the resistance-temperature-time fitting model, it can achieve rapid response and accurate detection.

Benefits of technology

It effectively shortens the response time, improves detection accuracy and stability, adapts to the characteristics of different oil samples, and extends the service life of the sensor.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122016953B_ABST
    Figure CN122016953B_ABST
Patent Text Reader

Abstract

The present application belongs to the field of automatic control, and discloses a palladium-nickel oil hydrogen rapid response control method and system based on variable temperature fitting, which comprises the following steps: collecting oil sample characteristics and resistance values of Pd-Ni sensitive elements, and judging whether oil sample switching occurs; if no oil sample switching occurs, a corrected resistance change amount is calculated through a fitting algorithm, and the corrected resistance change amount is converted into a hydrogen concentration value; if oil sample switching occurs, variable temperature control of the Pd-Ni sensitive element is performed, and a transient temperature rising stage, a dynamic temperature adjusting stage and a steady state constant temperature stage are executed in sequence; a resistance-temperature-time fitting model is constructed in the variable temperature control process, and whether the resistance value reaches a steady state after the steady state constant temperature stage is completed is analyzed and determined based on the resistance-temperature-time fitting model, and if the resistance value reaches the steady state, it is corrected and converted into a hydrogen concentration value. The present application solves the adaptation problem of different viscosity and temperature new oil samples, and effectively eliminates temperature drift and variable temperature residual interference.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of automatic control, and more specifically, to a method and system for rapid response control of hydrogen in palladium-nickel oil based on variable temperature fitting. Background Technology

[0002] Hydrogen is one of the key characteristic gases in early faults (such as partial discharge and corona discharge) of oil-immersed electrical equipment. Rapid and accurate online monitoring of its concentration is crucial for equipment condition assessment and fault early warning. Palladium-nickel (Pd-Ni) alloys are widely used as sensitive materials for dissolving hydrogen in oil due to their excellent selective adsorption of hydrogen and resistance change characteristics.

[0003] However, in practical online monitoring applications, especially in scenarios where oil samples are changed in the laboratory or oil circuits of field equipment are circulated and updated, existing Pd-Ni-based sensors face a prominent problem: when the sensor switches from one oil sample environment to another (or from air into oil), the high viscosity of the oil medium, the mass transfer resistance of hydrogen molecules at the oil-solid interface, and the possible adsorption of oil film on the sensor surface cause the sensor's response speed to slow down significantly, resulting in a long "tailing" or "delay" phenomenon, which cannot meet the needs of rapid diagnosis and real-time control.

[0004] Traditional improvement schemes often focus on optimizing the microstructure of palladium-nickel materials (such as porosification and nanostructuring) or employing a single isothermal heating mode. While isothermal heating can accelerate hydrogen desorption and mass transfer processes to some extent, its improvement effect is limited. More importantly, the isothermal operating mode is passive and fixed when facing the dynamic and transient process of oil sample switching. Its fixed temperature setpoint makes it difficult to simultaneously optimize response speed, measurement sensitivity, and long-term sensor stability. When a new oil sample with different physical properties such as temperature and viscosity suddenly comes into contact with the isothermal sensor, the entire system (including the sensor chip, surrounding oil film, and solid-liquid interface) needs a considerable amount of time to re-establish thermal and mass exchange equilibrium. This thermal relaxation and mass transfer relaxation process itself is the main source of response delay. A single isothermal mode not only fails to actively accelerate this process, but its fixed temperature parameters may not even be the optimal solution for the specific characteristics of the current oil sample, thus limiting further improvements in response speed. Summary of the Invention

[0005] To overcome the aforementioned deficiencies of the prior art and achieve the above objectives, the present invention provides the following technical solution:

[0006] This invention provides a rapid response control method for hydrogen in palladium-nickel oil based on variable temperature fitting, the method comprising:

[0007] S1. Real-time monitoring and acquisition of oil sample characteristics and resistance value of Pd-Ni sensing element; determination of whether oil sample switching occurs based on oil sample characteristics and resistance value; the oil sample characteristics include oil sample temperature and oil sample viscosity; the Pd-Ni sensing element is located in the oil sample.

[0008] S2. If no oil sample switching occurs, the actual working temperature of the Pd-Ni sensing element surface is collected in real time, and the corrected resistance change is calculated by the fitting algorithm. The corrected resistance change is then converted into a hydrogen concentration value.

[0009] S3. If an oil sample switch occurs, record the initial temperature and initial viscosity of the new oil sample, and trigger the temperature control of the Pd-Ni sensitive element, sequentially executing the transient heating stage, dynamic temperature adjustment stage, and steady-state isothermal stage.

[0010] S4. During the temperature control process, the resistance value and the actual working temperature are collected synchronously. A resistance-temperature-time fitting model is constructed based on the resistance value and the actual working temperature. The resistance value after the steady-state constant temperature stage is analyzed and determined based on the resistance-temperature-time fitting model. If the resistance value reaches the steady state, it is corrected and converted into a hydrogen concentration value and output.

[0011] Further, step S1 includes:

[0012] Real-time monitoring of oil sample characteristics and resistance values ​​of Pd-Ni sensing elements; calculation of resistance change based on the resistance values.

[0013] The oil sample temperature change rate, oil sample viscosity change rate, and resistance value abrupt change amplitude are calculated based on the oil sample characteristics and resistance value over a continuously preset time period. When any one of the following parameters meets one of the following conditions, an initial warning for oil sample switching is triggered: the absolute value of the oil sample temperature change rate exceeds a preset temperature change threshold, the absolute value of the oil sample viscosity change rate exceeds a preset viscosity change threshold, or the resistance value abrupt change amplitude exceeds a preset resistance amplitude threshold.

[0014] After triggering the initial warning for oil sample switching, the actual changes in oil sample temperature and viscosity within a preset time period before and after triggering the initial warning are calculated. If both the actual changes in oil sample temperature and viscosity meet the preset change rules and the resistance value shows an upward or downward trend for a duration of 3 seconds, then an oil sample switching is confirmed to have occurred; otherwise, it is confirmed that no oil sample switching has occurred. The preset change rules refer to calculating the ratio of the actual change in oil sample temperature to the corresponding temperature change threshold and the ratio of the actual change in oil sample viscosity to the corresponding viscosity change threshold, respectively. Both ratios must be greater than or equal to 80%, and the two parameters must change synchronously with no significant time difference, with a time difference ≤ 1 second.

[0015] Further, step S2 includes:

[0016] If no oil sample switching occurs, the actual operating temperature T on the surface of the Pd-Ni sensing element is collected in real time. w The actual operating temperature T w The actual operating temperature is compared with the steady-state temperature to ensure that the deviation between the actual operating temperature and the steady-state temperature is within the preset deviation range. The preset deviation range is within ±0.1℃. If it exceeds ±0.1℃, fine-tuning heating is performed to ensure that the deviation between the actual operating temperature and the steady-state temperature is within the preset deviation range. The steady-state temperature is obtained by the following method: based on the current steady-state oil sample when no oil sample switching occurs, its oil sample characteristics, such as oil sample temperature and oil sample viscosity, are extracted and substituted into the preset oil sample characteristic model. The oil sample characteristic model outputs the steady-state temperature that is adapted to the oil sample characteristics.

[0017] Based on the resistance value and the actual operating temperature, a fitting algorithm is used to dynamically correct the resistance change to obtain the corrected resistance change.

[0018] The corrected resistance change is converted into a hydrogen concentration value using a preset concentration calibration formula.

[0019] Furthermore, methods for obtaining steady-state temperature include:

[0020] Based on the current steady-state oil sample without any oil sample switching, its oil sample characteristics are extracted and substituted into a preset oil sample characteristic model. Based on the oil sample characteristic model, a steady-state temperature adapted to the oil sample is output. At the same time, the steady-state temperature is fine-tuned every Z minutes according to the currently collected oil sample temperature, with a fine-tuning range of ±0.2℃, where Z is a positive integer.

[0021] Further, step S3 includes:

[0022] After an oil sample switch occurs, the oil sample temperature and viscosity at the moment of switch are immediately extracted as the initial temperature and initial viscosity of the new oil sample.

[0023] Based on the initial temperature and initial viscosity, the initial hydrogen molecule mass transfer rate of the new oil sample is output through a preset oil sample characteristic prediction model.

[0024] The mass transfer rate range of the initial hydrogen molecule mass transfer rate is determined according to the initial hydrogen molecule mass transfer rate and the preset mass transfer rate range division criteria, and marked as the current mass transfer range; the current mass transfer range includes a low-speed mass transfer range, a medium-speed mass transfer range and a high-speed mass transfer range.

[0025] The target temperature for the transient heating stage is determined based on the initial temperature, initial viscosity, initial hydrogen molecule mass transfer rate, and current mass transfer range, and is marked as the first target temperature. The heating rate for the transient heating stage is determined based on the current mass transfer range. The holding time is determined based on the initial viscosity and current mass transfer range, and is marked as the first holding time. Temperature control for the transient heating stage is completed based on the first target temperature, heating rate, and first holding time.

[0026] Furthermore, step S3 also includes:

[0027] After the transient heating phase ends, the resistance change is calculated based on the resistance value at the end of the phase; the target temperature of the dynamic temperature control phase is adjusted based on the resistance change rate and the current mass transfer range, and marked as the second target temperature; the duration, adjustment frequency, and adjustment amplitude of the dynamic temperature control phase are determined according to the current mass transfer range; and the temperature control of the dynamic temperature control phase is completed based on the second target temperature, duration, adjustment frequency, and adjustment amplitude.

[0028] After the dynamic temperature adjustment phase ends, the predicted resistance change rate of the resistance value is calculated using a variable temperature fitting algorithm. Based on the predicted resistance change rate, it is determined whether the resistance value has reached a steady state. If the resistance value has reached a steady state, the steady-state constant temperature phase begins. If the resistance value has not reached a steady state, the dynamic temperature adjustment phase is restarted until the resistance value reaches a steady state.

[0029] Calculate the average value of the second target temperature in the dynamic temperature regulation stage, and calculate the target temperature of the steady-state isothermal stage based on the average value of the second target temperature, the first target temperature, and the current mass transfer range. Mark this as the optimal steady-state temperature. Perform temperature control in the steady-state isothermal stage based on the optimal steady-state temperature. The duration of the steady-state isothermal stage is not less than 10 seconds.

[0030] Furthermore, step S3 also includes:

[0031] Throughout the transient heating phase, dynamic temperature adjustment phase, and steady-state isothermal phase, the real-time resistance change rate is calculated based on the synchronously acquired resistance value of the Pd-Ni sensing element. The current hydrogen molecule mass transfer rate is then calculated using the real-time resistance change rate and a preset correlation model. The current hydrogen molecule mass transfer rate is compared with the initial hydrogen molecule mass transfer rate to obtain the deviation result, which includes the absolute value and direction of the deviation. The target temperature for the corresponding phase is then dynamically adjusted based on the deviation result.

[0032] Furthermore, the step of dynamically correcting the target temperature for the corresponding stage based on the deviation result includes:

[0033] When the absolute value of the deviation exceeds the preset deviation, the target temperature for the corresponding stage is dynamically corrected according to the direction of the deviation.

[0034] The deviation direction is such that when the current hydrogen molecule mass transfer rate decreases relative to the initial hydrogen molecule mass transfer rate, the target temperature for the corresponding stage will be increased by 2-3%.

[0035] The deviation direction is such that when the current hydrogen molecule mass transfer rate increases relative to the initial hydrogen molecule mass transfer rate, the target temperature for the corresponding stage will be reduced by 2-3%.

[0036] When the absolute value of the deviation does not exceed the preset deviation, there is no need to correct the target temperature.

[0037] Further, step S4 includes:

[0038] During the temperature control process, the resistance value and the actual operating temperature are collected synchronously to ensure the temporal consistency of the resistance value and the actual operating temperature, and to construct a three-dimensional dataset consisting of the resistance value, the actual operating temperature and time.

[0039] Based on the aforementioned three-dimensional dataset, a resistance-temperature-time fitting model is constructed using a dynamic quadratic polynomial fitting algorithm based on the least squares method. Based on the resistance-temperature-time fitting model, a set of predicted resistance values ​​is calculated.

[0040] The first derivative of the resistance-temperature-time fitting model at time t is obtained to get the future resistance change rate; the resistance fluctuation amplitude is calculated based on the resistance value; the deviation between the predicted resistance value and the actual resistance value is calculated and marked as the resistance deviation; based on the future resistance change rate, resistance fluctuation amplitude and resistance deviation, it is determined whether the resistance value has reached a steady state. If a steady state is reached, the current resistance value is locked as the steady-state resistance value.

[0041] The steady-state resistance change is calculated based on the steady-state resistance value, and the steady-state resistance change is corrected to obtain the corrected steady-state resistance change; the corrected steady-state resistance change is then converted into a hydrogen concentration value.

[0042] Another object of the present invention is to provide a fast response control system for hydrogen in palladium-nickel oil based on variable temperature fitting, the system comprising:

[0043] The oil sample switching determination module is used to monitor and collect the characteristics of the oil sample and the resistance value of the Pd-Ni sensing element in real time, and to determine whether an oil sample switching has occurred based on the oil sample characteristics and resistance value. The oil sample characteristics include oil sample temperature and oil sample viscosity; the Pd-Ni sensing element is located in the oil sample.

[0044] The first concentration calculation module is used to collect the actual operating temperature T on the surface of the Pd-Ni sensing element in real time if no oil sample switching occurs. w The corrected resistance change is calculated using a fitting algorithm, and then converted into a hydrogen concentration value.

[0045] The variable temperature control module is used to record the initial temperature and initial viscosity of the new oil sample if an oil sample switch occurs, and to trigger the variable temperature control of the Pd-Ni sensitive element, sequentially executing the transient heating stage, the dynamic temperature adjustment stage, and the steady-state isothermal stage.

[0046] The second concentration calculation module is used to simultaneously collect the resistance value and the actual working temperature during the temperature change control process, construct a resistance-temperature-time fitting model based on the resistance value and the actual working temperature, analyze and determine whether the resistance value has reached a steady state after the completion of the steady-state isothermal stage based on the resistance-temperature-time fitting model, and if the resistance value has reached a steady state, it is corrected and converted into a hydrogen concentration value and output.

[0047] The technical effects and advantages of this invention, based on a rapid response control method and system for hydrogen in palladium-nickel oil using variable temperature fitting, are as follows:

[0048] This invention integrates three parameters—oil sample temperature, viscosity, and resistance—to clearly define synchronization requirements and the proportion of changes. Combined with dynamic threshold adaptive adjustment, this effectively improves the accuracy of oil sample switching detection, avoiding missed or false detections. Furthermore, by quantifying the calculation standards for change rate and abrupt change amplitude, this invention can trigger an initial warning at the moment of oil sample switching, quickly complete fusion verification, accurately capture switching transients, and ensure timely initiation of subsequent temperature control, avoiding detection deviations caused by switching delays.

[0049] This invention ensures that the Pd-Ni sensing element is always at its optimal operating temperature. Existing technologies use a fixed steady-state temperature, which cannot adapt to dynamic changes in oil sample temperature and viscosity, leading to decreased hydrogen adsorption sensitivity and detection accuracy. This invention, through an oil sample characteristic model, can output the optimal steady-state temperature adapted to the current oil sample. Combined with fine-tuning every 5 minutes (±0.2℃), the deviation between the actual operating temperature of the sensing element and the optimal steady-state temperature is ≤±0.1℃, maximizing hydrogen adsorption sensitivity. Furthermore, this invention, through the model's built-in steady-state temperature adaptation range and dynamic fine-tuning of oil sample characteristics, effectively eliminates the influence of oil sample characteristic changes on temperature control, providing a stable temperature basis for subsequent resistance calibration and improving the accuracy of hydrogen concentration detection in steady-state scenarios.

[0050] This invention effectively addresses the pain point of response delay after oil sample switching. Its three-stage variable temperature control strategy allows for differentiated adjustment based on the current mass transfer range, effectively shortening response time and improving response efficiency. The invention rapidly breaks the oil film adsorption equilibrium during the transient heating stage, precisely adapts the mass transfer rate during the dynamic temperature adjustment stage, and maintains the optimal temperature during the steady-state isothermal stage. This avoids both slow mass transfer and insufficient sensitivity caused by excessively low temperatures, and performance degradation of sensitive elements caused by excessively high temperatures, thus extending the lifespan of sensitive elements. Furthermore, this invention rapidly obtains the initial hydrogen molecule mass transfer rate through an oil sample characteristic prediction model and designs differentiated variable temperature parameters based on the current mass transfer range, adapting to low-speed, medium-speed, and high-speed mass transfer scenarios. This solves the adaptation problem for new oil samples with different viscosities and temperatures, improving the method's versatility.

[0051] This invention provides a full-process fitting and correction system that accurately quantifies the magnitude of temperature interference, eliminates residual errors caused by temperature variations, improves the accuracy of resistance correction, and effectively eliminates temperature drift and residual interference caused by temperature variations. In addition, this invention dynamically corrects the target temperature by back-calculating the current hydrogen molecule mass transfer rate and judging the deviation results, ensuring that the temperature control is always adapted to the current mass transfer state, further improving the response speed and detection accuracy, and realizing dynamic adaptive optimization of temperature variation control.

[0052] Existing technologies often determine steady state by relying on a single resistance data point or short-term rate of change, which can easily misjudge instantaneous fluctuations as steady state, leading to concentration output deviations. In contrast, this invention integrates three conditions—future resistance change rate, resistance fluctuation amplitude, and resistance deviation—and combines them with continuous data point verification, effectively improving the accuracy of steady state determination and avoiding steady state errors caused by single data point determinations. Attached Figure Description

[0053] Figure 1 The flowchart is a fast response control method for hydrogen in palladium-nickel oil based on variable temperature fitting provided by the present invention.

[0054] Figure 2 The structural block diagram of the rapid response control system for hydrogen in palladium-nickel oil based on variable temperature fitting provided by the present invention is shown. Detailed Implementation

[0055] The technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.

[0056] Please see Figure 1 As shown, this embodiment of the invention provides a fast response control method for hydrogen in palladium-nickel oil based on variable temperature fitting, the method comprising:

[0057] S1. Real-time monitoring and acquisition of oil sample characteristics and the resistance value of the Pd-Ni sensitive element, determining whether an oil sample switch has occurred based on the oil sample characteristics and resistance value. The oil sample characteristics include oil sample temperature and viscosity; the Pd-Ni sensitive element is located within the oil sample; in this embodiment, the oil sample temperature is acquired in real-time using a PT100 platinum resistance sensor at a frequency of 5Hz; the oil sample viscosity is acquired in real-time using a capillary viscosity sensor at a frequency of 2Hz; and the resistance value R of the Pd-Ni sensitive element is acquired in real-time using a Wheatstone bridge circuit at a frequency of 10Hz. The Pd-Ni sensitive element, also known as a palladium-nickel alloy sensitive element, is the core element used in this invention to detect the hydrogen concentration in oil. Its core characteristic is that its resistance value changes with the amount of hydrogen molecules adsorbed; the faster the hydrogen molecule mass transfer rate, the more drastic the resistance change. The core purpose of this step is to accurately capture the transient state of oil sample switching.

[0058] S2. If no oil sample switching occurs, the actual operating temperature T on the surface of the Pd-Ni sensing element is collected in real time. w The corrected resistance change is calculated using a fitting algorithm and then converted into a hydrogen concentration value. The core objective of this step is to ensure that the deviation between the actual operating temperature and the steady-state temperature of the Pd-Ni sensing element is within a preset range under steady-state conditions without oil sample switching, thus placing the Pd-Ni sensing element at its optimal temperature. A variable-temperature fitting algorithm is then used to dynamically correct the resistance change, achieving accurate hydrogen concentration detection. This overcomes the limitations of traditional constant-temperature monitoring that only collects data without correction, balancing the accuracy and long-term stability of steady-state detection.

[0059] S3. If an oil sample switch occurs, record the initial temperature and viscosity of the new oil sample, and trigger temperature control of the Pd-Ni sensing element, sequentially executing the transient heating stage, dynamic temperature adjustment stage, and steady-state isothermal stage. This step breaks through the passivity of the traditional isothermal mode, adopting a three-stage active temperature control strategy of transient heating → dynamic temperature adjustment → steady-state isothermal. It combines the hydrogen molecule mass transfer rate of the new oil sample for adaptive temperature adjustment, specifically accelerating thermal relaxation and hydrogen molecule mass transfer processes, eliminating the response delay caused by oil sample switching, and balancing detection sensitivity and the long-term stability of the Pd-Ni sensing element.

[0060] S4. During the temperature control process, the resistance value and the actual operating temperature are collected synchronously. A resistance-temperature-time fitting model is constructed based on the resistance value and the actual operating temperature. The resistance value after the steady-state isothermal stage is analyzed and determined based on the resistance-temperature-time fitting model to determine whether it has reached a steady state. If the resistance value has reached a steady state, it is corrected and converted into a hydrogen concentration value, which is then output. The core purpose of this step is to accurately determine the steady state of the resistance value, perform final correction through a temperature-variable fitting algorithm, and achieve accurate conversion and output of the hydrogen concentration. A steady-state determination logic based on fitting prediction and multi-condition verification is adopted to avoid errors in the determination of a single data point, ensuring the accuracy and reliability of the hydrogen concentration value output.

[0061] In this embodiment, step S1 includes:

[0062] S1.1 Real-time monitoring and acquisition of oil sample characteristics and the resistance value R of the Pd-Ni sensing element. s Calculate the resistance change ΔR / R0 based on the resistance value, where ΔR = R s -R0; R s R0 represents the smoothed resistance value. The Pd-Ni sensing element was placed in a hydrogen-free standard oil sample, and the ambient temperature was kept constant at 25℃ (standard reference temperature). After standing at this temperature for 30 minutes, the initial resistance value of the sensing element was acquired using a high-precision Wheatstone bridge circuit. The smoothed resistance value was obtained by using a moving average filtering algorithm during the resistance value acquisition process. The filtering window size was set to 5 data points to remove random noise caused by circuit interference and oil sample flow fluctuations.

[0063] S1.2 Calculate the oil sample temperature change rate ΔT / Δt, oil sample viscosity change rate Δμ / Δt, and resistance value change amplitude |(Rs(t)-Rs(t-10s)) / Rs(t-10s)| within a continuous preset time period based on the oil sample characteristics and resistance value; if any one of the parameters of oil sample temperature change rate, oil sample viscosity change rate, and resistance value change amplitude meets one of the following conditions, a preliminary warning for oil sample switching is triggered: the absolute value of the oil sample temperature change rate exceeds the preset temperature change threshold, the absolute value of the oil sample viscosity change rate exceeds the preset viscosity change threshold, or the resistance value change amplitude exceeds the preset resistance amplitude threshold. The preset duration is usually 10 seconds. ΔT refers to the maximum difference in oil sample temperature within 10 consecutive seconds. The specific calculation method is as follows: extract the maximum value Tmax and minimum value Tmin of oil sample temperature within 10 consecutive seconds, ΔT=|Tmax-Tmin|; Δt refers to the time interval used to calculate the rate of change, which is fixed at 10 seconds in this embodiment; Δμ refers to the maximum difference in oil sample viscosity within 10 consecutive seconds. The specific calculation method is as follows: extract the maximum value μmax and minimum value μmin of oil sample viscosity within 10 consecutive seconds, Δμ=|μmax-μmin|; Rs(t) refers to the resistance value of the Pd-Ni sensing element collected at the current time (denoted as time t) and filtered by the moving average; Rs(t-10s) refers to the resistance value collected 10 seconds before the current time and processed by the same filtering. The temperature change threshold refers to the critical value for judging abnormal fluctuations in oil sample temperature, with an initial value of 0.5℃ / min (unit:℃ / min); the viscosity change threshold refers to the critical value for judging abnormal fluctuations in oil sample viscosity, with an initial value of 5% / min (unit:% / min); the resistance amplitude threshold refers to the critical value for judging sudden abnormalities in the resistance value of the Pd-Ni sensing element, with an initial value of 10%. The above thresholds can be adaptively adjusted according to actual working conditions.

[0064] S1.3 After triggering the initial warning for oil sample switching, calculate the actual changes in oil sample temperature and viscosity within a preset time period before and after the warning. If both the actual changes in oil sample temperature and viscosity simultaneously meet the preset change rules, and the resistance value shows an upward or downward trend for a duration of 3 seconds, then an oil sample switching is confirmed to have occurred; otherwise, it is confirmed that no oil sample switching has occurred. The preset change rules refer to calculating the ratio of the actual change in oil sample temperature to the corresponding temperature change threshold and the ratio of the actual change in oil sample viscosity to the corresponding viscosity change threshold, respectively. Both ratios must be greater than or equal to 80% and must change synchronously without a significant time difference (≤1 second). The calculation method for the actual change in oil sample temperature is as follows: extract the maximum and minimum values ​​of oil sample temperature within 10 seconds before and after the initial warning is triggered, calculate the absolute value of the difference between the two, and obtain the actual change in oil sample temperature. The calculation method for the actual change in oil sample viscosity is the same as that for the actual change in oil sample temperature.

[0065] In this embodiment, step S2 includes:

[0066] S2.1 If no oil sample switching occurs, the actual operating temperature T on the surface of the Pd-Ni sensing element is collected in real time. w The actual operating temperature T w The actual operating temperature is compared with the steady-state temperature to ensure that the deviation between the actual operating temperature and the steady-state temperature is within the preset deviation range. The preset deviation range is within ±0.1℃. If it exceeds ±0.1℃, fine-tuning heating is performed to ensure that the deviation between the actual operating temperature and the steady-state temperature is within the preset deviation range.

[0067] The steady-state temperature is obtained by the following method: Based on the current steady-state oil sample without sample switching, its oil sample characteristics, such as oil sample temperature and oil sample viscosity, are extracted. These characteristics are then substituted into a preset oil sample characteristic model. Based on the oil sample characteristic model, a steady-state temperature adapted to the oil sample is output. On this basis, the steady-state temperature is fine-tuned every Z minutes according to the currently collected oil sample temperature. The fine-tuning range is ±0.2℃ to ensure that the steady-state temperature always adapts to the characteristics of the current oil sample and maintains the detection accuracy. Z is a positive integer, and in this embodiment, Z is 5.

[0068] The oil sample characteristic model is essentially a four-dimensional correlation model of oil sample temperature, oil sample viscosity, hydrogen molecule mass transfer rate, and steady-state temperature. Its core function is to quickly map the steady-state temperature of the Pd-Ni sensing element adapted to the current steady-state oil sample based on its fundamental characteristics, namely initial temperature and initial viscosity, providing a reliable benchmark for subsequent dynamic fine-tuning. The model includes an input layer, two hidden layers, and an output layer, employing a hybrid architecture of a fully connected layer, a feature correlation layer, and a mapping output layer. The specific structure and parameters are as follows:

[0069] The input layer of the oil sample characteristic model receives two input parameters (initial temperature and initial viscosity) to form a two-dimensional input feature vector. The feature association layer is used to capture the correlation between the initial temperature, initial viscosity, hydrogen molecule mass transfer rate, and steady-state temperature, strengthening the representation of the adaptation law between parameters. The fully connected layer is used to integrate the intermediate features output by the feature association layer, remove redundant information, and enhance the feature fusion effect. Each hidden layer contains 1024 neurons, and the neurons use the ReLU nonlinear activation function to ensure that the model can learn and express the complex mapping relationship between input features and steady-state temperature. The output layer contains one core output node (steady-state temperature) and one auxiliary output node (hydrogen molecule mass transfer rate), which uses a linear activation function to directly output quantized values ​​without additional conversion calculations.

[0070] The input layer of the oil sample characteristic model is connected to the first hidden layer, the feature association layer is connected to the fully connected layer, and each fully connected layer is connected in a fully connected manner. Each connection corresponds to an adjustable weight parameter (the initial weight value is obtained by fitting experimental data, and the value range is 0.01-0.15). This weight determines the degree of influence of the output value of the previous layer neuron on the input value of the next layer neuron. The weight coefficient corresponding to the initial temperature (0.08-0.15) is higher than the weight coefficient corresponding to the initial viscosity (0.01-0.07), which is consistent with the experimental law that the initial temperature has a more significant influence on the steady-state temperature.

[0071] The experimental data for this model, along with the oil sample characteristic prediction model and fitting model described below, are from the same source. Both models were trained and optimized using a large amount of experimental data on oil samples of different types, covering temperatures from 0 to 80°C and viscosities from 1 to 100 mm² / s, ensuring parameter consistency. The model incorporates the correlation between hydrogen molecule mass transfer rate and initial temperature and initial viscosity, i.e., hydrogen molecule mass transfer rate is positively correlated with initial temperature and negatively correlated with initial viscosity. It also incorporates the adaptation law between hydrogen molecule mass transfer rate and steady-state temperature. Different mass transfer rates correspond to different optimal operating temperatures / steady-state temperatures for Pd-Ni sensing elements. The model can directly output the steady-state temperature from the initial parameters of the oil sample without additional complex calculations, thus meeting the high-efficiency requirements of steady-state monitoring.

[0072] Using oil sample experimental data under different working conditions as training samples, a total of 1200 training samples were collected, of which 80% were used as the training set, 10% as the validation set, and 10% as the test set. The initial temperature, initial viscosity, hydrogen molecule mass transfer rate, and steady-state temperature correspondence in the samples were labeled, and the training model learned the mapping law between input features and output parameters. After training, the validation set accuracy was ≥95% and the error was ≤±0.2℃, ensuring the accuracy of the model output.

[0073] The output of the steady-state temperature adapted to the oil sample based on the oil sample characteristic model includes: substituting the collected oil sample temperature and viscosity into the preset oil sample characteristic model; the model automatically calculates the hydrogen molecule mass transfer rate corresponding to the current steady-state oil sample based on the built-in correlation between hydrogen molecule mass transfer rate and steady-state temperature and initial viscosity; the calculation logic is consistent with the initial hydrogen molecule mass transfer rate in S3; this hydrogen molecule mass transfer rate is used as an intermediate parameter to match the corresponding steady-state temperature adaptation range; specifically, when the hydrogen molecule mass transfer rate is less than 0.001 mol / (m²·s), the steady-state temperature is - oil sample temperature + 8~10℃; when 0.001 mol / (m²·s) ≤ hydrogen molecule mass transfer rate ≤ 0.005 mol / (m²·s), the steady-state temperature is - oil sample temperature + 3~5℃; when the hydrogen molecule mass transfer rate is > 0.005 mol / (m²·s), the steady-state temperature is - oil sample temperature ± 1℃.

[0074] Based on the currently collected oil sample temperature, the fine-tuning of the steady-state temperature includes:

[0075] The deviation between the current real-time temperature and the steady-state temperature of the previous fine-tuning cycle is calculated, i.e., the current real-time temperature is subtracted from the steady-state temperature of the previous fine-tuning cycle. Based on this deviation, a new steady-state temperature is obtained through fine-tuning. If the deviation is > 0.2℃, the steady-state temperature is lowered by 0.1-0.2℃; if the deviation is < -0.2℃, the steady-state temperature is raised by 0.1-0.2℃; if -0.2℃ ≤ the deviation ≤ 0.2℃, only a 0.1℃ fine-tuning is performed, with the heating or cooling direction consistent with the oil sample temperature change trend, or no fine-tuning is performed. After fine-tuning, the new steady-state temperature is verified. If the verification passes, the new steady-state temperature is used as the steady-state temperature for the current cycle and as a reference for fine-tuning in the next cycle. If the verification fails, the fine-tuning range is reduced to 0.1℃, readjusted, and verified again until it passes, ensuring that the fine-tuned steady-state temperature is both suitable for the current oil sample temperature and meets the requirements for hydrogen molecule mass transfer rate. The verification of the new steady-state temperature includes: inputting the fine-tuned new steady-state temperature, the current oil sample temperature, and the current oil sample viscosity into the oil sample characteristic model; recalculating the hydrogen molecule mass transfer rate corresponding to the current oil sample; and determining whether the fine-tuned new steady-state temperature is within the suitable range of the steady-state temperature corresponding to the hydrogen molecule mass transfer rate based on the current oil sample's hydrogen molecule mass transfer rate. If it is not within the range, the verification fails; if it is within the range, the verification passes.

[0076] S2.2, Based on the resistance value R s and actual operating temperature T w A fitting algorithm is used to dynamically correct the resistance change, resulting in the corrected resistance change (ΔR / R0)cal. The calculation formula is: (ΔR / R0)cal = A × T w 2 +B×T w +C, where A, B, and C are preset fitting coefficients, which are obtained by fitting a large amount of experimental data of oil samples with different temperatures and viscosities. Through this fitting correction, the systematic error caused by temperature drift is effectively eliminated.

[0077] S2.3. The corrected resistance change is converted into a hydrogen concentration value using a preset concentration calibration formula. The concentration calibration formula is set as: H=k×(ΔR / R0)cal+b, where H is the hydrogen concentration value, k is the calibration coefficient, b is the calibration constant, and (ΔR / R0)cal is the corrected resistance change. To ensure the accuracy of the concentration conversion, the calibration coefficient k and the calibration constant b are calibrated every 3 months using a standard hydrogen oil sample to ensure that the concentration conversion accuracy is not less than ±1μL / L.

[0078] In this embodiment, step S3 includes:

[0079] S3.1 After an oil sample switch occurs, immediately extract the oil sample temperature and viscosity at the moment of switch as the initial temperature and initial viscosity of the new oil sample.

[0080] S3.2 Based on the initial temperature and initial viscosity, the initial hydrogen molecule mass transfer rate of the new oil sample is output through a preset oil sample characteristic prediction model. Specifically, the initial temperature and initial viscosity of the new oil sample are input into the oil sample characteristic prediction model. The model combines the correlation characteristics of the two and automatically outputs the corresponding initial hydrogen molecule mass transfer rate v. The initial hydrogen molecule mass transfer rate v serves as the core basis for temperature adjustment in subsequent temperature change stages.

[0081] The preset oil sample characteristic prediction model is essentially a three-dimensional correlation fitting model of initial temperature, initial viscosity, and initial hydrogen molecule mass transfer rate. Its core function is to quickly and accurately output the corresponding initial hydrogen molecule mass transfer rate based on the initial temperature and initial viscosity of the new oil sample after sample switching. This model shares the same origin and architecture as the aforementioned oil sample characteristic model, containing an input layer, one hidden layer, and an output layer. It adopts a fully connected layer + feature enhancement layer architecture, with the specific structure and parameters as follows:

[0082] The input layer of the oil sample characteristic prediction model receives two core input parameters (initial temperature and initial viscosity of the new oil sample) to form a two-dimensional input feature vector. The feature enhancement layer is used to capture the correlation between the initial temperature, initial viscosity and initial hydrogen molecule mass transfer rate of the new oil sample. The fully connected layer is used to integrate the intermediate features output by the feature enhancement layer and remove redundant information of parameter fluctuations at the moment of oil sample switching. The hidden layer contains 512 neurons, which is simplified compared to the oil sample characteristic model and adapts to the needs of rapid prediction. The neurons use the ReLU nonlinear activation function to ensure that the model can quickly learn and express the complex mapping relationship between the input features and the initial hydrogen molecule mass transfer rate. The output layer contains one core output node (initial hydrogen molecule mass transfer rate), which uses a linear activation function to directly output the quantified value (unit: mol / (m²·s)) without additional conversion calculations.

[0083] The input layer and hidden layer, as well as the hidden layer and output layer of the oil sample characteristic prediction model, are all connected in a fully connected manner. Each connection corresponds to an adjustable weight parameter (the initial weight value is obtained by fitting experimental data, and the value range is 0.02-0.18). This weight determines the degree of influence of the output value of the previous layer neuron on the input value of the next layer neuron. Among them, the weight coefficient corresponding to the initial temperature (0.10-0.18) is higher than the weight coefficient corresponding to the initial viscosity (0.02-0.08).

[0084] The experimental data for the oil sample characteristic prediction model and the oil sample characteristic model are from the same source, both obtained through training and optimization using a large amount of oil sample experimental data, ensuring parameter consistency. The model has a built-in core correlation logic (obtained by linear regression fitting) between initial temperature, initial viscosity, and initial hydrogen molecule mass transfer rate, clearly defining the quantitative law that the initial hydrogen molecule mass transfer rate is positively correlated with the initial temperature and negatively correlated with the initial viscosity. At the same time, it has a built-in adaptation table of initial temperature-initial viscosity-initial hydrogen molecule mass transfer rate, which can directly and quickly output v based on the initial temperature and initial viscosity of the new oil sample without additional complex calculations. The model is adapted to transient scenarios after oil sample switching, and can quickly respond to the input of new oil sample parameters with an output delay of ≤0.5s, ensuring timely activation of the three-stage temperature change control and further solving the response delay problem after oil sample switching.

[0085] Using oil sample experimental data under different working conditions as training samples, the initial temperature, initial viscosity, and v correspondence in the samples are labeled. The training model learns the mapping law between input features (initial temperature, initial viscosity) and output parameters (v). After training, the validation set accuracy is ≥94% and the error is ≤±0.0002mol / (m²·s) to ensure accurate model output and avoid unreasonable subsequent temperature parameter settings due to mass transfer rate prediction deviation.

[0086] S3.3 Determine the mass transfer rate range of the initial hydrogen molecule mass transfer rate according to the initial hydrogen molecule mass transfer rate and the preset mass transfer rate range division criteria, and mark it as the current mass transfer range; the current mass transfer range includes a low-speed mass transfer range, a medium-speed mass transfer range and a high-speed mass transfer range.

[0087] The preset criteria for dividing the mass transfer rate range include:

[0088] Low-speed mass transfer range: v < 0.001 mol / (m²·s), corresponding to new oil samples with high initial viscosity and low initial temperature. In this range, the resistance to hydrogen molecule mass transfer is extremely high, oil film adsorption is obvious, and thermal relaxation is slow.

[0089] Medium-speed mass transfer range: 0.001 mol / (m²·s) ≤ v ≤ 0.005 mol / (m²·s), corresponding to new oil samples with moderate initial viscosity and initial temperature. In this range, the mass transfer resistance of hydrogen molecules is moderate, and the oil film adsorption and thermal relaxation delay are relatively mild.

[0090] High-speed mass transfer range: v > 0.005 mol / (m²·s), corresponding to new oil samples with low initial viscosity and high initial temperature. In this range, the mass transfer resistance of hydrogen molecules is small, the oil film adsorption is slight, and the thermal relaxation is fast.

[0091] S3.4. Determine the target temperature for the transient heating stage based on the initial temperature T0, initial viscosity μ0, initial hydrogen molecule mass transfer rate v, and the current mass transfer range, and mark it as the first target temperature T1. The calculation formula is: T1=T0+a×ln(μ0)+b×(1 / v); where a and b are preset fitting coefficients, and the values ​​of a and b are determined based on the current mass transfer range; determine the heating rate for the transient heating stage based on the current mass transfer range; determine the holding time t1 based on the initial viscosity and the current mass transfer range, and mark it as the first holding time; complete the temperature control of the transient heating stage based on the first target temperature, heating rate, and first holding time.

[0092] The determination of the values ​​of a and b based on the current mass transfer interval includes:

[0093] Low-speed mass transfer range: a∈[4,5], b∈[6,8], T1 is increased by 5-8℃ compared to the medium-speed mass transfer range, ensuring rapid breakthrough of mass transfer resistance and oil film adsorption;

[0094] Medium-speed mass transfer interval: a∈[2,3], b∈[3,5], T1 is calculated normally, taking into account both mass transfer efficiency and sensitive element performance;

[0095] High-speed mass transfer range: a∈[2,3], b∈[3,5], T1 is 3-5℃ lower than that of medium-speed mass transfer range to avoid excessive temperature attenuation of sensitive component performance.

[0096] The content of determining the heating rate during the transient heating stage based on the current mass transfer range includes:

[0097] Low-speed mass transfer range: The entire process adopts a high-speed heating rate of 4-5℃ / s, without distinguishing between heating stages, quickly raising the temperature of the Pd-Ni sensing element to T1 and shortening the thermal relaxation time.

[0098] Medium-speed mass transfer range: A stepped heating strategy is adopted, with a high-speed heating of 4-5℃ / s in the initial stage and a medium-speed heating of 2-3℃ / s in the later stage to avoid temperature overshoot; the initial stage of heating refers to the range from the current temperature to T0+10℃; the later stage of heating refers to the range from T0+10℃ to T1.

[0099] High-speed mass transfer range: The entire process adopts a medium-speed heating rate of 2-3℃ / s to slowly heat up to T1, reducing the impact of temperature fluctuations on sensitive elements;

[0100] In this embodiment, the temperature feedback frequency is 10Hz, and the temperature control actuator adjusts the heating power in real time to ensure that the temperature rises accurately to T1, with a temperature control accuracy of not less than ±0.1℃.

[0101] Determining the holding time based on the initial viscosity and the current mass transfer range includes:

[0102] Low-speed mass transfer range: t1∈[25,30]s, using the longest heat preservation time to ensure that the oil film adsorption equilibrium is fully broken;

[0103] Medium-speed mass transfer range: when μ0≤20mm² / s, t1∈[10,15]s; when 20mm² / s<μ0≤50mm² / s, t1∈[15,25]s; when μ0>50mm² / s, t1∈[25,30]s;

[0104] High-speed mass transfer range: when μ0≤20mm² / s, t1=10s; when 20mm² / s<μ0≤50mm² / s, t1=15s; when μ0>50mm² / s, t1=25s.

[0105] In this embodiment, step S3 further includes:

[0106] S3.5 After the transient heating stage ends, calculate the rate of change of resistance V based on the resistance value at the end of this stage. R Based on the resistance change rate and the current mass transfer range, adjust the target temperature T2 of the dynamic temperature adjustment stage and mark it as the second target temperature; determine the duration, adjustment frequency and adjustment amplitude of the dynamic temperature adjustment stage according to the current mass transfer range; complete the variable temperature control of the dynamic temperature adjustment stage based on the second target temperature, duration, adjustment frequency and adjustment amplitude.

[0107] Among them, the resistance change rate V is calculated based on the resistance value at the end of this stage. R The content includes: resistance change rate V R The calculation formula is: V R =|(ΔR / R0)(t)-(ΔR / R0)(t-5s)| / 5s; where, in this embodiment, the end of this stage refers to the last 5 seconds of the transient heating stage, (ΔR / R0)(t) refers to the real-time resistance change of the Pd-Ni sensing element calculated at the current time t, and (ΔR / R0)(t-5s) refers to the resistance change of the sensing element calculated at the 5 seconds before the current time t;

[0108] The content of adjusting the target temperature T2 of the dynamic temperature control stage based on the resistance change rate and the current mass transfer range includes:

[0109] V R ≥2% / s, the target temperature drops from T1 to T2. At this time, T2=T0+c, where c is a preset coefficient, c∈[1,3]; where c∈[1,2] for high-speed mass transfer interval, c∈[1,3] for medium-speed mass transfer interval, and c∈[2,3] for low-speed mass transfer interval, which rarely occurs in this scenario; if it does occur, c∈[2,3]; the cooling rate is uniformly set to -2℃ / s;

[0110] V R<2% / s, the target temperature rises from T1 to T2. At this time, T2=T0+d×ln(μ0)+e, where d and e are preset coefficients, d∈[3,6], e∈[5,10]; in the low-speed mass transfer range d∈[5,6], e∈[8,10], T3 is 3-5℃ higher than the medium-speed mass transfer range; in the medium-speed mass transfer range d∈[3,4], e∈[5,7]; in the high-speed mass transfer range d∈[3,4], e∈[5,6], T2 is 2-3℃ lower than the medium-speed mass transfer range; the heating rate is uniformly set to 2-3℃ / s to accelerate hydrogen molecule mass transfer.

[0111] The determination of the duration, adjustment frequency, and adjustment amplitude of the dynamic temperature control phase based on the current mass transfer range includes:

[0112] The duration of the dynamic temperature adjustment phase is ∈ [30, 60] s, where the duration of the high-speed mass transfer zone is ∈ [30, 45] s, and the duration of the medium-speed and low-speed mass transfer zones is ∈ [30, 60] s. During this period, the adjustment frequency and adjustment range are set according to the current mass transfer zone: the low-speed mass transfer zone is fine-tuned every 3 s with an adjustment range of ±0.8℃; the medium-speed and high-speed mass transfer zones are fine-tuned every 5 s with an adjustment range of ±0.5℃. After each fine-tuning, V is recalculated. R until V R To achieve the optimal range of 1-2% / s, ensuring that the resistance value quickly stabilizes.

[0113] S3.6 After the dynamic temperature adjustment stage ends, the predicted resistance change rate of the resistance value is calculated by the variable temperature fitting algorithm; the resistance value is judged to determine whether it has reached a steady state based on the predicted resistance change rate. If the resistance value has reached a steady state, the steady-state constant temperature stage is entered; if the resistance value has not reached a steady state, the dynamic temperature adjustment stage is re-entered until the resistance value reaches a steady state.

[0114] The step of calculating the predicted resistance change rate using a temperature-fitting algorithm and determining whether the resistance value has reached a steady state based on the predicted resistance change rate includes:

[0115] Ten seconds before the end of the dynamic temperature adjustment phase, the resistance value and actual operating temperature of the Pd-Ni sensing element are collected synchronously to obtain a temporary dataset. The temporary dataset consists of the resistance value, actual operating temperature and time within 10 seconds before the end of the dynamic temperature adjustment phase. The resistance value and actual operating temperature are collected synchronously to ensure that there is no timing misalignment and to avoid prediction errors caused by the mismatch between the resistance value and the actual operating temperature. The collection frequency is 10Hz.

[0116] Based on the temporary dataset, a variable-temperature fitting algorithm is used to calculate the predicted resistance value. The calculation formula is: R = A1×t² + B1×t + C1×T, where A1, B1, and C1 are temporary fitting coefficients, t is time, T is temperature, and R is the predicted resistance value. The temporary fitting coefficients are calculated using the least squares method. Specifically, the time, actual operating temperature, and resistance value in the temporary dataset are substituted into t, T, and R in the above calculation formula, respectively. A linear regression algorithm is used to fit the data and quickly solve for the specific values ​​of A1, B1, and C1. The solution process is existing technology and will not be elaborated on here. Only the data from the last 10 seconds of the dynamic temperature adjustment stage is used here to ensure that it is adapted to the current near-stable mass transfer state and to avoid interference from large temperature fluctuations in the early stage.

[0117] The predicted resistance value within the next 1-3 seconds is predicted based on the calculation formula R=A1×t²+B1×t+C1×T. Specifically, the three time nodes of 1S, 2S, and 3S are substituted respectively, i.e., t1=1S, t2=1S, and t3=1S; combined with the temperature at the end of the dynamic temperature adjustment stage, the predicted resistance values ​​R1, R2, and R3 at the corresponding future times are calculated. Among them, the temperature at the end of the dynamic temperature adjustment stage is the average of the last five actual working temperatures in the temporary data set. Since the temperature tends to be constant at the end of the dynamic temperature adjustment stage, it can be regarded as a constant value.

[0118] The predicted resistance change rate is calculated based on the predicted resistance values. Specifically, the calculation method is as follows: Based on the predicted resistance values ​​R1, R2, and R3, the resistance changes ΔR1 and ΔR2 of adjacent predicted nodes are calculated: ΔR1 = |R2 - R1|, ΔR2 = |R3 - R2|; the instantaneous change rates v1 and v2 for the corresponding time intervals are calculated: v1 = ΔR1 / 1s, v2 = ΔR2 / 1s, with a time interval of 1s; the average of the two instantaneous change rates is calculated to obtain the predicted resistance change rate, calculated as: predicted resistance change rate = (v1 + v2) / 2; finally, the predicted resistance change rate is converted to a percentage (% / s) and compared with a threshold of 0.1% / s to complete the steady-state prediction.

[0119] If the predicted resistance change rate is ≤0.1% / s, the resistance value is expected to reach a steady state, and the system enters the steady-state constant temperature stage; if the predicted resistance change rate is >0.1% / s, the resistance value is expected to not reach a steady state, and the system returns to the dynamic temperature adjustment stage until the resistance value reaches a steady state.

[0120] S3.7 Calculate the average value of the second target temperature in the dynamic temperature regulation stage, and calculate the target temperature of the steady-state isothermal stage based on the average value of the second target temperature, the first target temperature and the current mass transfer range, and mark it as the optimal steady-state temperature; perform temperature control of the steady-state isothermal stage based on the optimal steady-state temperature; the isothermal duration of the steady-state isothermal stage shall not be less than 10s.

[0121] The formula for calculating the optimal steady-state temperature is: Optimal steady-state temperature = (T1 + T) / ( ... S ) / 2;T S This represents the average value of the second target temperature during the dynamic temperature regulation phase, where T is the high-speed mass transfer interval. S Based on the calculation results, the temperature was reduced by 1-2℃ to further improve the long-term stability of the sensitive element; the low-speed and medium-speed mass transfer ranges were calculated normally according to the formula to ensure that they were adapted to the characteristics of the new oil sample.

[0122] In this embodiment, step S3 further includes:

[0123] S3.8. Throughout the transient heating phase, dynamic temperature adjustment phase, and steady-state isothermal phase, the real-time resistance change rate is calculated based on the synchronously acquired resistance value of the Pd-Ni sensing element; the current hydrogen molecule mass transfer rate v is then calculated based on the real-time resistance change rate and a preset correlation model. t The current hydrogen molecule mass transfer rate is compared with the initial hydrogen molecule mass transfer rate to obtain the deviation result; the deviation result includes the absolute value of the deviation and the direction of the deviation; the target temperature of the corresponding stage is dynamically corrected based on the deviation result. The current hydrogen molecule mass transfer rate is the core parameter for realizing three-stage temperature variation. Compared with the resistivity change rate, it has strong anti-interference ability and no adjustment lag, and can adapt to the entire stage of transient heating, dynamic temperature adjustment, and steady-state isothermal control. It can dynamically correct the target temperature of each stage by judging the deviation from the initial hydrogen molecule mass transfer rate, accurately match the mass transfer characteristics of the new oil sample, and take into account the response speed, detection accuracy, and stability of the sensitive element. This is the key to the breakthrough of the traditional passive isothermal mode in this invention.

[0124] The calculation method for the real-time resistance change rate in this embodiment is the same as the calculation method for the resistance change rate in step S3.5, and will not be elaborated further here. The experimental data for the preset correlation model and the oil sample characteristic prediction model are from the same source, both obtained through training and optimization using experimental data from a large number of oil samples of different types, temperatures, and viscosities. The preset correlation model is essentially a three-dimensional linear fitting model, which achieves a precise mapping from the resistance change rate to the hydrogen molecule mass transfer rate, eliminating temperature fluctuation interference. Its expression is: v t =k1×v Rc +k2×T w +k3, where v t v represents the current hydrogen molecule mass transfer rate output by the model. Rc This is the real-time rate of change of resistance after temperature compensation; this parameter is a model input parameter. w The actual operating temperature of the Pd-Ni sensing element is the model input parameter; k1, k2, and k3 are preset fitting coefficients obtained by fitting experimental data, where k1 is the core proportional coefficient, k2 is the temperature compensation coefficient, and k3 is the correction constant.

[0125] The calculation method for the real-time resistance change rate after temperature compensation includes: taking the calculated real-time resistance change rate and combining it with the actual operating temperature T of the currently acquired Pd-Ni sensing element. w Substituting into the temperature compensation formula, we obtain the real-time resistance change rate after temperature compensation. The temperature compensation formula is: v Rc =Real-time resistance change rate - (k2'×T) w +k3'), which is from the same source as the correlation model and uses the same parameter standard; where k2' is the temperature interference coefficient, which is a fitting coefficient and is from the same source as k2 in the correlation model but adapts to the compensation scenario. Its value range is 0.015-0.025% / (s·℃), which is obtained by fitting a large amount of experimental data. The experiment covers oil temperature conditions of 0-80℃ and viscosity range of 1-100mm² / s. Through linear regression algorithm, the interference amplitude of different actual working temperatures on the real-time resistance change rate is quantified, and the value range of this coefficient is finally determined; k3' is the temperature compensation correction constant, which is used to offset the basic temperature interference at room temperature. Its value range is 0.03-0.05% / s, which is also obtained by synchronously fitting the experimental data when the correlation model was built, to ensure that the temperature compensation formula and the parameters of the correlation model are consistent and without logical deviation;

[0126] The content of dynamically correcting the target temperature for the corresponding stage based on the deviation results includes:

[0127] If the absolute value of the deviation between the current hydrogen molecule mass transfer rate and the initial hydrogen molecule mass transfer rate does not exceed 10% of the preset deviation, no correction of the target temperature is required. If the absolute value of the deviation between the current hydrogen molecule mass transfer rate and the initial hydrogen molecule mass transfer rate exceeds 10%, it is determined that the mass transfer rate has significantly shifted. If the deviation direction is a decrease in the current hydrogen molecule mass transfer rate relative to the initial hydrogen molecule mass transfer rate, the target temperature for the corresponding stage will be increased by 2-3%; if the deviation direction is an increase in the current hydrogen molecule mass transfer rate relative to the initial hydrogen molecule mass transfer rate, the target temperature for the corresponding stage will be decreased by 2-3%. After each temperature correction, the system automatically records the correction parameters and mass transfer rate change data, including the initial hydrogen molecule mass transfer rate, the current hydrogen molecule mass transfer rate, the temperature before and after correction, and the correction time. This data is used to subsequently optimize the oil sample characteristic prediction model and temperature adjustment strategy, forming a closed-loop control of mass transfer rate back-calculation, deviation judgment, temperature correction, and model optimization. This further improves the temperature control accuracy and detection reliability of this invention in oil sample switching scenarios.

[0128] In this embodiment, step S4 includes:

[0129] S4.1 During the temperature control process, the resistance value and the actual operating temperature are collected synchronously to ensure the temporal consistency of the resistance value and the actual operating temperature, and a three-dimensional dataset consisting of the resistance value, the actual operating temperature and time is constructed.

[0130] S4.2. Based on the aforementioned three-dimensional dataset, a resistance-temperature-time fitting model is constructed using a dynamic quadratic polynomial fitting algorithm based on the least squares method. The set of predicted resistance values ​​is then calculated based on this model, which is expressed as: Rp = D×t² + E×t + F×T w ²+G×T w +I×t×T w +M, where D, E, F, G, I, and M are preset fitting coefficients, which are obtained by fitting experimental data from a large number of oil samples with different temperatures and viscosities, and t is time, T w Rp represents the actual operating temperature, and Rp represents the set of predicted resistance values, also known as the resistance trend. A resistance-temperature-time fitting model is used to predict the resistance trend within the next 1-5 seconds. When calculating the set of predicted resistance values ​​based on the resistance-temperature-time fitting model, five time nodes (1s, 2s, 3s, 4s, and 5s) or more closely spaced time nodes are substituted into the predicted temperature at the corresponding time. Since the system has entered a steady-state isothermal phase, the predicted temperature is determined to be consistent with the current actual operating temperature. The predicted resistance value corresponding to each future time node is then calculated, forming a continuous set of predicted data, which constitutes the set of predicted resistance values.

[0131] S4.3. Calculate the first derivative of the resistance-temperature-time fitting model at time t to obtain the future resistance change rate; calculate the resistance fluctuation amplitude based on the resistance value; calculate the deviation between the predicted resistance value and the actual resistance value, and mark it as the resistance deviation; determine whether the resistance value has reached a steady state based on the future resistance change rate, resistance fluctuation amplitude, and resistance deviation. If a steady state has been reached, lock the current resistance value as the steady-state resistance value R. sta ;

[0132] The criteria for determining whether the resistance value has reached a steady state based on the future resistance change rate, resistance fluctuation amplitude, and resistance deviation include:

[0133] The determination of the future resistance change rate, resistance fluctuation amplitude, and resistance deviation determines whether the resistance value simultaneously meets three steady-state determination conditions. The steady-state determination conditions include: the average value of five consecutive future resistance change rates ≤ 0.1% / s, the resistance fluctuation amplitude of five consecutive data points ≤ 0.05%, and the resistance deviation ≤ 0.2%. Specifically, the resistance fluctuation amplitude of five consecutive data points refers to: extracting five resistance values ​​consecutively according to the acquisition sequence, calculating the average value of the five resistance values, and then calculating the absolute value of the deviation between each of the five resistance values ​​and the average value. The maximum value among these absolute deviations is taken as the resistance fluctuation amplitude of the five data points.

[0134] If all three steady-state conditions are met simultaneously, the system continuously collects 3-5 resistance values. If the 3-5 resistance values ​​do not fluctuate significantly, the system officially determines that the resistance value has reached a steady state and locks the current resistance value as the steady-state resistance value. If any one of the conditions is not met, the system returns to the dynamic temperature adjustment stage, continues to adjust the target temperature, and repeats the dynamic temperature adjustment and steady-state prediction process until all steady-state conditions are met.

[0135] S4.4 Calculate the steady-state resistance change (ΔR / R0)sta based on the aforementioned steady-state resistance value. The calculation formula is: (ΔR / R0)sta = (R sta -R0) / R0 is used to correct the steady-state resistance change to obtain the corrected steady-state resistance change; the corrected steady-state resistance change is then converted into a hydrogen concentration value.

[0136] When correcting the steady-state resistance change, a suitable fitting model is invoked. The expression of the fitting model used here is the same as that of the resistance-temperature-time fitting model in S4.2 above, that is, it is the same in form. In this step, the preset fitting coefficients of the fitting model are obtained by fitting a large number of experimental data of oil samples with different temperatures and viscosities. The fitting model is used to quantify the residual interference of temperature fluctuations on the steady-state resistance change during the temperature change process, so as to accurately remove the residual error. The ideal steady-state resistance value without residual temperature change error can be calculated by the expression of the fitting model. The ideal steady-state resistance change is calculated based on the ideal steady-state resistance value and R0. The calculation formula is: ideal steady-state resistance change = (ideal steady-state resistance value - R0) / R0. The ideal steady-state resistance change is used as the corrected steady-state resistance change. Substituting the corrected steady-state resistance change into the preset concentration calibration formula yields the hydrogen concentration value. The concentration calibration formula here is the same as the concentration calibration formula in S2.3. Simultaneously, the present invention continuously detects whether the oil sample is switched. If the oil sample switch is detected again, steps S3-S4 of the present invention are repeated to achieve cyclic detection.

[0137] The foregoing described the fast-response control method for hydrogen in palladium-nickel oil based on variable-temperature fitting in the embodiments of this application. The following describes the fast-response control system for hydrogen in palladium-nickel oil based on variable-temperature fitting in the embodiments of this application, which is used to implement the fast-response control method for hydrogen in palladium-nickel oil based on variable-temperature fitting; please refer to... Figure 2 A rapid response control system for hydrogen in palladium-nickel oil based on temperature-variable fitting, the system comprising:

[0138] The oil sample switching determination module is used to monitor and collect the characteristics of the oil sample and the resistance value of the Pd-Ni sensing element in real time, and to determine whether an oil sample switching has occurred based on the oil sample characteristics and resistance value. The oil sample characteristics include oil sample temperature and oil sample viscosity; the Pd-Ni sensing element is located in the oil sample.

[0139] The first concentration calculation module is used to collect the actual operating temperature T on the surface of the Pd-Ni sensing element in real time if no oil sample switching occurs. w The corrected resistance change is calculated using a fitting algorithm, and then converted into a hydrogen concentration value.

[0140] The variable temperature control module is used to record the initial temperature and initial viscosity of the new oil sample if an oil sample switch occurs, and to trigger the variable temperature control of the Pd-Ni sensitive element, sequentially executing the transient heating stage, the dynamic temperature adjustment stage, and the steady-state isothermal stage.

[0141] The second concentration calculation module is used to synchronously collect the resistance value and the actual operating temperature during the temperature change control process. Based on the resistance value and the actual operating temperature, a resistance-temperature-time fitting model is constructed. Based on the resistance-temperature-time fitting model, it is analyzed and determined whether the resistance value has reached a steady state after the completion of the steady-state isothermal stage. If the resistance value has reached a steady state, it is corrected and converted into a hydrogen concentration value and output. The modules are connected to each other through wired and / or wireless means to realize data transmission between modules.

[0142] The above description is merely a preferred embodiment of the present invention and is not intended to limit the present invention. Although the present invention has been described in detail with reference to the foregoing embodiments, those skilled in the art can still modify the technical solutions described in the foregoing embodiments or make equivalent substitutions for some of the technical features. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of the present invention should be included within the protection scope of the present invention.

[0143] All formulas in this manual are dimensionless and calculated numerically. The formulas are derived from software simulations based on a large amount of collected data to obtain the most recent real-world results. The preset parameters and thresholds in the formulas are set by those skilled in the art according to the actual situation.

[0144] Although embodiments of the invention have been shown and described, those skilled in the art will understand that various changes, modifications, substitutions and alterations can be made to these embodiments without departing from the principles and spirit of the invention, the scope of which is defined by the claims and their equivalents.

Claims

1. A rapid response control method for hydrogen in palladium-nickel oil based on variable temperature fitting, characterized in that, The method includes: S1. Real-time monitoring and acquisition of oil sample characteristics and resistance value of Pd-Ni sensing element; determination of whether oil sample switching occurs based on oil sample characteristics and resistance value; the oil sample characteristics include oil sample temperature and oil sample viscosity; the Pd-Ni sensing element is located in the oil sample. S2. If no oil sample switching occurs, the actual operating temperature T on the surface of the Pd-Ni sensing element is collected in real time. w The corrected resistance change is calculated using a fitting algorithm, and then converted into a hydrogen concentration value. S3. If an oil sample switch occurs, record the initial temperature and initial viscosity of the new oil sample, and trigger the temperature control of the Pd-Ni sensitive element, sequentially executing the transient heating stage, dynamic temperature adjustment stage, and steady-state isothermal stage. S4. During the temperature control process, the resistance value and the actual working temperature are collected synchronously. A resistance-temperature-time fitting model is constructed based on the resistance value and the actual working temperature. The resistance value after the steady-state constant temperature stage is analyzed and determined based on the resistance-temperature-time fitting model. If the resistance value reaches the steady state, it is corrected and converted into a hydrogen concentration value and output. Step S1 includes: Real-time monitoring of oil sample characteristics and resistance values ​​of Pd-Ni sensing elements; calculation of resistance change based on the resistance values. Calculate the rate of change of oil sample temperature, the rate of change of oil sample viscosity, and the magnitude of sudden change in resistance value within a continuously preset time period based on the oil sample characteristics and resistance value; determine whether to trigger an initial warning for oil sample switching based on the rate of change of oil sample temperature, the rate of change of oil sample viscosity, and the magnitude of sudden change in resistance value; After triggering the initial warning for oil sample switching, the actual change in oil sample temperature and the actual change in oil sample viscosity within a preset time period before and after triggering the initial warning for oil sample switching are calculated. When the actual change in oil sample temperature and the actual change in oil sample viscosity both meet the preset change rules, the oil sample switching is confirmed to have occurred. Step S3 includes: After an oil sample switch occurs, the oil sample temperature and viscosity at the moment of switch are immediately extracted as the initial temperature and initial viscosity of the new oil sample. Based on the initial temperature and initial viscosity, the initial hydrogen molecule mass transfer rate of the new oil sample is output through a preset oil sample characteristic prediction model. The mass transfer rate range of the initial hydrogen molecule mass transfer rate is determined according to the initial hydrogen molecule mass transfer rate and the preset mass transfer rate range division criteria, and marked as the current mass transfer range; the current mass transfer range includes a low-speed mass transfer range, a medium-speed mass transfer range and a high-speed mass transfer range. The target temperature for the transient heating stage is determined based on the initial temperature, initial viscosity, initial hydrogen molecule mass transfer rate, and current mass transfer range, and is marked as the first target temperature. The heating rate for the transient heating stage is determined based on the current mass transfer range. The holding time is determined based on the initial viscosity and current mass transfer range, and is marked as the first holding time. Temperature control for the transient heating stage is completed based on the first target temperature, heating rate, and first holding time.

2. The rapid response control method for hydrogen in palladium-nickel oil based on variable temperature fitting according to claim 1, characterized in that, Step S2 includes: If no oil sample switching occurs, the actual operating temperature of the Pd-Ni sensing element surface is collected in real time, and the actual operating temperature is compared with the steady-state temperature to ensure that the deviation between the actual operating temperature and the steady-state temperature is within the preset deviation range. Based on the resistance value and the actual operating temperature, a fitting algorithm is used to dynamically correct the resistance change to obtain the corrected resistance change. The corrected resistance change is converted into a hydrogen concentration value using a preset concentration calibration formula.

3. The rapid response control method for hydrogen in palladium-nickel oil based on variable temperature fitting according to claim 2, characterized in that, Methods for obtaining steady-state temperature include: Based on the current steady-state oil sample without any oil sample switching, its oil sample characteristics are extracted and substituted into a preset oil sample characteristic model. Based on the oil sample characteristic model, a steady-state temperature adapted to the oil sample is output. At the same time, the steady-state temperature is fine-tuned every Z minutes according to the currently collected oil sample temperature, with a fine-tuning range of ±0.2℃, where Z is a positive integer.

4. The method for rapid response control of hydrogen in palladium-nickel oil based on variable temperature fitting according to claim 1, characterized in that, Step S3 also includes: After the transient heating phase ends, the resistance change rate is calculated based on the resistance value at the end of the phase; the target temperature of the dynamic temperature control phase is adjusted based on the resistance change rate and the current mass transfer range, and marked as the second target temperature; the duration, adjustment frequency, and adjustment amplitude of the dynamic temperature control phase are determined according to the current mass transfer range; the temperature control of the dynamic temperature control phase is completed based on the second target temperature, duration, adjustment frequency, and adjustment amplitude. After the dynamic temperature adjustment phase ends, the predicted resistance change rate of the resistance value is calculated using a variable temperature fitting algorithm. Based on the predicted resistance change rate, it is determined whether the resistance value has reached a steady state. If the resistance value has reached a steady state, the steady-state constant temperature phase begins. If the resistance value has not reached a steady state, the dynamic temperature adjustment phase is restarted until the resistance value reaches a steady state. Calculate the average value of the second target temperature in the dynamic temperature regulation stage, and calculate the target temperature of the steady-state isothermal stage based on the average value of the second target temperature, the first target temperature, and the current mass transfer range. Mark this as the optimal steady-state temperature. Perform temperature control in the steady-state isothermal stage based on the optimal steady-state temperature.

5. The method for rapid response control of hydrogen in palladium-nickel oil based on variable temperature fitting according to claim 1, characterized in that, Step S3 also includes: Throughout the transient heating phase, dynamic temperature adjustment phase, and steady-state isothermal phase, the real-time resistance change rate is calculated based on the synchronously acquired resistance value of the Pd-Ni sensing element. The current hydrogen molecule mass transfer rate is then calculated using the real-time resistance change rate and a preset correlation model. The current hydrogen molecule mass transfer rate is compared with the initial hydrogen molecule mass transfer rate to obtain the deviation result, which includes the absolute value and direction of the deviation. The target temperature for the corresponding phase is then dynamically adjusted based on the deviation result.

6. The rapid response control method for hydrogen in palladium-nickel oil based on variable temperature fitting according to claim 5, characterized in that, The content of dynamically correcting the target temperature for the corresponding stage based on the deviation result includes: When the absolute value of the deviation exceeds the preset deviation, the target temperature for the corresponding stage is dynamically corrected according to the direction of the deviation. The deviation direction is such that when the current hydrogen molecule mass transfer rate decreases relative to the initial hydrogen molecule mass transfer rate, the target temperature for the corresponding stage will be increased by 2-3%. The deviation direction is such that when the current hydrogen molecule mass transfer rate increases relative to the initial hydrogen molecule mass transfer rate, the target temperature for the corresponding stage will be reduced by 2-3%. When the absolute value of the deviation does not exceed the preset deviation, there is no need to correct the target temperature.

7. The method for rapid response control of hydrogen in palladium-nickel oil based on variable temperature fitting according to claim 1, characterized in that, Step S4 includes: During the temperature control process, the resistance value and the actual operating temperature are collected simultaneously to construct a three-dimensional dataset consisting of the resistance value, the actual operating temperature, and time. A resistance-temperature-time fitting model is constructed based on the aforementioned three-dimensional dataset, and a set of predicted resistance values ​​is calculated based on the resistance-temperature-time fitting model. The first derivative of the resistance-temperature-time fitting model at time t is obtained to get the future resistance change rate; the resistance fluctuation amplitude is calculated based on the resistance value; the deviation between the predicted resistance value and the actual resistance value is calculated and marked as the resistance deviation; based on the future resistance change rate, resistance fluctuation amplitude and resistance deviation, it is determined whether the resistance value has reached a steady state. If a steady state is reached, the current resistance value is locked as the steady-state resistance value. The steady-state resistance change is calculated based on the steady-state resistance value, and the steady-state resistance change is corrected to obtain the corrected steady-state resistance change; the corrected steady-state resistance change is then converted into a hydrogen concentration value.

8. A fast response control system for hydrogen in palladium-nickel oil based on variable temperature fitting, characterized in that, The system includes: The oil sample switching determination module is used to monitor and collect the characteristics of the oil sample and the resistance value of the Pd-Ni sensing element in real time, and to determine whether an oil sample switching has occurred based on the oil sample characteristics and resistance value. The oil sample characteristics include oil sample temperature and oil sample viscosity; the Pd-Ni sensing element is located in the oil sample. The first concentration calculation module is used to collect the actual operating temperature T on the surface of the Pd-Ni sensing element in real time if no oil sample switching occurs. w The corrected resistance change is calculated using a fitting algorithm, and then converted into a hydrogen concentration value. The variable temperature control module is used to record the initial temperature and initial viscosity of the new oil sample if an oil sample switch occurs, and to trigger the variable temperature control of the Pd-Ni sensitive element, sequentially executing the transient heating stage, the dynamic temperature adjustment stage, and the steady-state isothermal stage. The second concentration calculation module is used to simultaneously collect the resistance value and the actual working temperature during the temperature change control process, construct a resistance-temperature-time fitting model based on the resistance value and the actual working temperature, analyze and determine whether the resistance value has reached a steady state after the completion of the steady-state isothermal stage based on the resistance-temperature-time fitting model, and if the resistance value has reached a steady state, then it is corrected and converted into a hydrogen concentration value and output. The real-time monitoring and acquisition of oil sample characteristics and the resistance value of the Pd-Ni sensing element, and the determination of whether an oil sample switch has occurred based on the oil sample characteristics and resistance value, include: Real-time monitoring of oil sample characteristics and resistance values ​​of Pd-Ni sensing elements; calculation of resistance change based on the resistance values. Calculate the rate of change of oil sample temperature, the rate of change of oil sample viscosity, and the magnitude of sudden change in resistance value within a continuously preset time period based on the oil sample characteristics and resistance value; determine whether to trigger an initial warning for oil sample switching based on the rate of change of oil sample temperature, the rate of change of oil sample viscosity, and the magnitude of sudden change in resistance value; After triggering the initial warning for oil sample switching, the actual change in oil sample temperature and the actual change in oil sample viscosity within a preset time period before and after triggering the initial warning for oil sample switching are calculated. When the actual change in oil sample temperature and the actual change in oil sample viscosity both meet the preset change rules, the oil sample switching is confirmed to have occurred. If an oil sample switch occurs, the initial temperature and initial viscosity of the new oil sample are recorded, and the temperature control of the Pd-Ni sensing element is triggered. The transient heating stage, dynamic temperature adjustment stage, and steady-state isothermal stage are executed sequentially, including: After an oil sample switch occurs, the oil sample temperature and viscosity at the moment of switch are immediately extracted as the initial temperature and initial viscosity of the new oil sample. Based on the initial temperature and initial viscosity, the initial hydrogen molecule mass transfer rate of the new oil sample is output through a preset oil sample characteristic prediction model. The mass transfer rate range of the initial hydrogen molecule mass transfer rate is determined according to the initial hydrogen molecule mass transfer rate and the preset mass transfer rate range division criteria, and marked as the current mass transfer range; the current mass transfer range includes a low-speed mass transfer range, a medium-speed mass transfer range and a high-speed mass transfer range. The target temperature for the transient heating stage is determined based on the initial temperature, initial viscosity, initial hydrogen molecule mass transfer rate, and current mass transfer range, and is marked as the first target temperature. The heating rate for the transient heating stage is determined based on the current mass transfer range. The holding time is determined based on the initial viscosity and current mass transfer range, and is marked as the first holding time. Temperature control for the transient heating stage is completed based on the first target temperature, heating rate, and first holding time.