Dynamic weighing method and system with self-calibration and temperature compensation functions
By building a closed-loop control system and utilizing a temperature sensor array and a temperature-drift database to monitor and compensate for temperature changes in the weighing system in real time, the problem of accuracy degradation in traditional weighing systems in complex environments is solved, and high-precision and adaptive weighing control is achieved.
Patent Information
- Application Number
- CN202510915327.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-07-03
- Publication Date
- 2025-09-23
AI Technical Summary
Traditional weighing systems have difficulty compensating for real-time temperature gradient changes in complex environments, resulting in reduced accuracy. They also lack adaptive capabilities and are unable to meet the high-precision control requirements in highly dynamic thermal cycle scenarios.
A closed-loop control system is constructed by coordinating the compensation decision controller and the parameter self-update controller. The temperature changes are monitored in real time through the temperature sensor array, the temperature difference and temperature change rate are calculated, the compensation mode is selected, and corrections are made based on the temperature-drift relationship database. When the cumulative temperature shock value reaches the threshold, the parameter self-update is triggered, and the weighing data with temperature credibility rating is output.
It effectively reduces system errors caused by temperature changes, eliminates parameter drift during long-term operation, improves system reliability and weighing accuracy, and realizes intelligent and adaptive control in complex thermal environments.
Smart Images

Figure CN120685185A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of weighing measurement and metering, and belongs to the application of automatic control systems in dynamic weighing, and in particular to a dynamic weighing method and system with self-calibration and temperature compensation functions. Background Art
[0002] Dynamic weighing technology is widely used in industrial automation, logistics and transportation, and intelligent manufacturing. Its core challenge lies in how to ensure weighing accuracy and stability under complex environmental conditions (such as temperature fluctuations, mechanical deformation, etc.). Traditional weighing systems mostly rely on static calibration or fixed compensation models, lack a closed-loop feedback mechanism, and are unable to track sensor drift and structural deformation caused by temperature gradient changes in real time, resulting in compensation lag; there are limitations in open-loop control. The modeling of the temperature-drift relationship in existing technologies is mostly based on linear assumptions, and it fails to build a closed-loop control loop of temperature disturbance-compensation correction-parameter update, making it difficult to adapt to nonlinear thermal effects; in addition, traditional compensation methods rely on manual regular calibration, lack adaptive capabilities, and are unable to offset the cumulative effects of environmental disturbances through self-adjustment of control strategies, resulting in long-term accuracy degradation. Especially in highly dynamic thermal cycle scenarios, existing technologies fail to achieve closed-loop coordination of compensation decisions and calibration triggers, making it difficult to meet the control requirements of high-precision weighing. Summary of the Invention
[0003] The main purpose of the present invention is to provide a dynamic weighing method and system with self-calibration and temperature compensation functions, by constructing a closed-loop control system that cooperates with a compensation decision controller and a parameter self-update controller to solve the problems of error accumulation and dependence on manual intervention caused by temperature fluctuations in traditional solutions.
[0004] To achieve the above object, the present invention provides a dynamic weighing method with self-calibration and temperature compensation functions, comprising the following steps:
[0005] The surface temperature of the load-bearing structure and the ambient temperature data are synchronously acquired through a preset temperature sensor array;
[0006] Calculating a current temperature difference between the surface temperature and the ambient temperature, generating a control signal when the current temperature difference exceeds a material thermal deformation threshold, and calculating a surface temperature change rate;
[0007] The compensation mode is selected according to the compensation control signal and the surface temperature change rate, the compensation process is started based on the closed-loop verification mechanism, the original weighing value is corrected based on the temperature-drift relationship database, and preliminary compensation data is generated;
[0008] By accumulating the duration of each temperature difference exceeding the threshold value and the corresponding temperature difference amplitude, a cumulative temperature shock value is obtained. When the cumulative temperature shock value reaches the set threshold, the parameter self-update operation is triggered to obtain the final weighing data;
[0009] Output the final weighing data with temperature confidence rating to the interactive interface.
[0010] Furthermore, the step of synchronously acquiring the surface temperature of the load-bearing structure and the ambient temperature data through a preset temperature sensor array includes:
[0011] Arranging a first temperature sensor array in advance at a first preset interval in a stress-sensitive area of the load-bearing structure;
[0012] Arrange a second temperature sensor array between the device base and the peripheral space at a second preset interval;
[0013] The surface temperature of the weighing structure and the ambient temperature data are collected through dual array sensors.
[0014] Furthermore, after the step of collecting the surface temperature of the weighing structure and the ambient temperature data by the dual array sensor, the method includes:
[0015] Mark the temperature data whose mutation amount exceeds the temperature mutation threshold as an abnormal point;
[0016] Use linear interpolation of the two valid sampling points before and after to replace the outliers;
[0017] Using the timestamp of the reference sensor as a reference, align the sampling timing of all sensors;
[0018] Resample and fit the data segments whose delay exceeds the time delay threshold.
[0019] Furthermore, the steps of calculating the current temperature difference between the surface temperature and the ambient temperature, generating a control signal when the current temperature difference exceeds a material thermal deformation threshold, and calculating the surface temperature change rate include:
[0020] Taking the first time window as a period, synchronously obtain the maximum surface temperature and the minimum ambient temperature;
[0021] Calculate the difference between the maximum surface temperature and the minimum ambient temperature during the window period as the current temperature difference;
[0022] When the current temperature difference exceeds the material thermal deformation threshold, a compensation control signal is generated. The material thermal deformation threshold is determined by a test piece temperature rise experiment. When the axial deformation reaches the deformation threshold, the corresponding temperature value is the material thermal deformation threshold.
[0023] Extract the continuous sampling data sequence of surface temperature within the window period;
[0024] Performing linear regression analysis on the data series to calculate the slope of temperature change over time;
[0025] The slope value was converted into the temperature change rate per minute as the surface temperature change rate.
[0026] Furthermore, the steps of selecting a compensation mode according to the compensation control signal and the surface temperature change rate, starting a compensation process based on a closed-loop verification mechanism, correcting the original weighing value according to the temperature-drift relationship database, and generating preliminary compensation data include:
[0027] When the compensation control signal exists and the generation time is within the preset validity period, the compensation process is started after the temperature validity is confirmed through the closed-loop verification mechanism;
[0028] When the surface temperature change rate does not exceed the rate threshold, basic compensation is performed. Based on the current temperature difference, the corresponding linear correction coefficient is obtained through the temperature-drift relationship database to correct the weighing value;
[0029] When the surface temperature change rate exceeds the rate threshold, enhanced compensation is performed, and the principal component factors are extracted through a pre-built temperature data matrix including a preset number of sensors and preset sampling time points, and the weighing value is dynamically corrected through the L2 regularization compensation model;
[0030] The corrected weighing value is stored as preliminary compensation data.
[0031] Furthermore, the steps of constructing the temperature-drift relationship database include:
[0032] Adjust the temperature difference environment in the temperature-controlled experimental chamber with a preset temperature difference step length;
[0033] Apply standard load at each temperature difference point and record the output drift of the load cell;
[0034] The temperature difference-drift relationship curve is established through piecewise linear regression;
[0035] The cubic spline interpolation is performed on the inflection point area of the curve to encrypt the data points.
[0036] Furthermore, the step of enhancing compensation includes:
[0037] Construct a state space model of temperature change rate and compensation amount;
[0038] The compensation amount is dynamically smoothed by using a Kalman filter;
[0039] When the temperature changes suddenly, the sliding window variance detection is enabled to automatically adjust the filter parameters.
[0040] Furthermore, the step of triggering the parameter self-update operation and obtaining the final weighing data includes:
[0041] When the cumulative temperature shock value calculated by accumulating the duration of each temperature difference exceeding the threshold and the corresponding temperature difference amplitude reaches the set threshold, the parameter self-update operation is triggered;
[0042] Load standard weights to perform zero point calibration and generate reference compensation parameters;
[0043] Calculating the deviation rate between the current compensation parameter and the reference compensation parameter;
[0044] If the deviation rate exceeds the calibration threshold, the temperature-drift relationship database is updated;
[0045] The preliminary compensation data is corrected secondary based on the updated temperature-drift relationship database, and the final weighing data is output.
[0046] Furthermore, the step of outputting the final weighing data with the temperature credibility rating to the interactive interface includes:
[0047] Calculate the current temperature difference ratio based on the current temperature difference value and the material thermal deformation threshold;
[0048] Calculate the average absolute deviation of the last three calibrations;
[0049] Generate risk rating results based on the current temperature difference ratio and absolute deviation mean;
[0050] The risk rating results are bound to the final weighing data and displayed in real time on the interactive interface.
[0051] The present invention also provides a dynamic weighing system with self-calibration and temperature compensation functions, comprising:
[0052] The temperature monitoring module is used to synchronously obtain the surface temperature of the load-bearing structure and the ambient temperature data through a preset temperature sensor array;
[0053] a compensation decision control module, configured to calculate a current temperature difference between the surface temperature and the ambient temperature, generate a control signal when the current temperature difference exceeds a material thermal deformation threshold, and calculate a surface temperature change rate;
[0054] The compensation execution module is used to select the compensation mode according to the compensation control signal and the surface temperature change rate, start the compensation process based on the closed-loop verification mechanism, correct the original weighing value based on the temperature-drift relationship database, and generate preliminary compensation data;
[0055] The parameter self-update control module is used to obtain a cumulative temperature shock value by accumulating the duration of each temperature difference exceeding the threshold value and the corresponding temperature difference amplitude. When the cumulative temperature shock value reaches a set threshold, the parameter self-update operation is triggered to obtain the final weighing data;
[0056] The data output module is used to output the final weighing data with temperature credibility rating to the interactive interface.
[0057] The dynamic weighing method and system with self-calibration and temperature compensation functions provided by the present invention have the following beneficial effects: Based on nonlinear modeling of material thermal deformation characteristics and a temperature-drift database, the present invention dynamically switches between basic compensation and enhanced compensation, reducing system errors caused by temperature changes. It also triggers intelligent calibration by accumulating temperature shock values, eliminating parameter drift during long-term operation, avoiding manual intervention, and improving system reliability. Furthermore, by introducing a temperature credibility rating mechanism, combined with real-time risk assessment and data binding, the interpretability of weighing results and the credibility of decision-making are enhanced. This invention effectively solves the problem of precision loss in dynamic weighing systems in complex thermal environments, promoting the development of weighing technology towards intelligent and adaptive directions. BRIEF DESCRIPTION OF THE DRAWINGS
[0058] Figure 1 1 is a flow chart of a dynamic weighing method with self-calibration and temperature compensation functions according to an embodiment of the present invention;
[0059] Figure 2 This is a structural block diagram of a dynamic weighing system with self-calibration and temperature compensation functions in one embodiment of the present invention;
[0060] The purpose, features and advantages of the present invention will be further described with reference to the accompanying drawings and in conjunction with the embodiments. DETAILED DESCRIPTION
[0061] In order to make the purpose, technical solutions and advantages of the present invention more clearly understood, the present invention will be further described in detail below with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present invention and are not intended to limit the present invention.
[0062] Reference Figure 1 , which is a flow chart of a dynamic weighing method with self-calibration and temperature compensation functions proposed by the present invention, comprising the following steps:
[0063] S1, synchronously obtain the surface temperature of the load-bearing structure and the ambient temperature data through a preset temperature sensor array;
[0064] S2, calculating the current temperature difference between the surface temperature and the ambient temperature, generating a control signal when the current temperature difference exceeds the material thermal deformation threshold, and calculating the surface temperature change rate;
[0065] S3, selects the compensation mode according to the compensation control signal and the surface temperature change rate, starts the compensation process based on the closed-loop verification mechanism, corrects the original weighing value based on the temperature-drift relationship database, and generates preliminary compensation data;
[0066] S4, when the cumulative temperature shock value is obtained by accumulating the duration of each temperature difference exceeding the threshold value and the corresponding temperature difference amplitude, when the cumulative temperature shock value reaches the set threshold, the parameter self-update operation is triggered to obtain the final weighing data;
[0067] S5, output the final weighing data with temperature credibility rating to the interactive interface.
[0068] In one embodiment, for step S1,
[0069] The steps of synchronously acquiring the surface temperature of the load-bearing structure and the ambient temperature data through a preset temperature sensor array include:
[0070] Arranging a first temperature sensor array in advance at a first preset interval in a stress-sensitive area of the load-bearing structure;
[0071] Arrange a second temperature sensor array between the device base and the peripheral space at a second preset interval;
[0072] The surface temperature of the weighing structure and the ambient temperature data are collected through dual array sensors.
[0073] In the process of specific implementation,
[0074] A dual-array sensor layout is used to monitor temperature, and the first temperature sensor array is arranged at a spacing of 5-10 cm in the stress concentration area of the load-bearing structure (such as the connection between the support beams). The method for determining the first preset spacing includes monitoring the local temperature mutation response time at different spacings in the heat conduction experiment; selecting the spacing range with a response time ≤ 2 seconds and a gradient error < 2°C / m as the first preset spacing (such as 5-10 cm). Specifically, when local friction heating occurs on the steel surface (typical rate 5°C / s), a 5cm spacing can ensure that the temperature mutation detection delay is ≤ 1.5 seconds, and the error of the 10cm spacing is still controlled within 2 seconds. As shown in Table 1 below:
[0075] Table 1:
[0076] Spacing (cm) Detection delay (s) Temperature gradient error (℃ / m) 5 1.2 0.8 10 2.1 1.8
[0077] At the same time, a second temperature sensor array is deployed between the device base and the surrounding space, with an interlayer spacing of 2-5 cm. The second preset spacing is determined by measuring the vertical temperature gradient distribution around the device; interlayer spacing is selected to be ≤ 5 cm to ensure a vertical resolution of < 0.3°C / layer. Ambient temperature stratification can result in vertical temperature gradients of up to 0.1-0.3°C per centimeter. With 2 cm interlayer spacing, multiple sensors are deployed within a 1 m height range to achieve millimeter-level resolution monitoring of the vertical temperature field. The raw data collected by the dual arrays undergoes preprocessing with outlier cleaning, time alignment, and resampling. Data points with a temperature jump greater than 5°C / s are marked as outliers. For example, if a sensor jumps from 25°C to 35°C within 1 second, it is replaced by a linear interpolation of the preceding and following valid points. All data timestamps are aligned using the reference sensor as the clock source. For data segments with delays greater than 100 ms, Lagrange interpolation is used for resampling to ensure a time error less than 1 ms.
[0078] In one embodiment, after the step of collecting the surface temperature of the weighing structure and the ambient temperature data using the dual array sensor, the method includes:
[0079] Mark the temperature data whose mutation amount exceeds the temperature mutation threshold as an abnormal point;
[0080] Use linear interpolation of the two valid sampling points before and after to replace the outliers;
[0081] Using the timestamp of the reference sensor as a reference, align the sampling timing of all sensors;
[0082] Resample and fit the data segments whose delay exceeds the time delay threshold.
[0083] Specifically, based on theoretical calculations and measured data, data with a temperature mutation of >5°C / s are used as the criterion for determining abnormal points and are marked as abnormal points. The physical properties of the weighing structure (such as a steel load-bearing platform) determine that there is a limit rate of change in its surface temperature. According to the thermodynamic formula dT / dtmax=Q / (ρ·c·V), where Q is the heat source power, ρ is the material density, c is the specific heat capacity, and V is the heated volume. For typical steel (ρ=7850kg / m 3 , c=460J / kg·K, V=0.01m 3 ), when the heat source power Q = 500W, the theoretical maximum temperature rise rate is 4.3°C / s. Therefore, setting a threshold of 5°C / s can effectively distinguish between normal operating conditions and sensor failures (such as jumps caused by short circuits). During 30 consecutive days of field testing, the distribution of temperature jumps was statistically analyzed, as shown in Table 2:
[0084] Table 2:
[0085] Relationship between temperature mutation amount and temperature mutation threshold Occurrences Failure ratio Not exceeding the threshold 2874 98.6% Exceeding the threshold 41 1.4%
[0086] Among them, 95.1% of the mutations ≥5℃ / s are sensor failures, and 2 are real temperature anomalies (such as local overload friction). The threshold of ≥5℃ / s can cover more than 95% of abnormal scenarios.
[0087] After detecting an anomaly, the outlier is replaced by linear interpolation of the two valid sampling points before and after. Multi-sensor timing alignment precision control technology is used to ensure data consistency. The selection of the reference sensor strictly follows the hardware and layout requirements. The sampling frequency must be stable (fluctuation < ±0.1%), the clock accuracy must be high (±1ppm), and it must be placed in the area with the minimum temperature gradient. The timestamp alignment uses the IEEE 1588 precision time protocol, with the reference sensor as the GPTP clock, to ensure that the clock synchronization accuracy of each sensor is ≤100μs, and the alignment is completed through a three-step algorithm of calculating the time offset, fitting the clock drift curve, and dynamically adjusting the counter. Determine the time delay threshold and test the data alignment error under different delay times, see Table 3:
[0088] Table 3:
[0089] Delay time (ms) Alignment error (ms) Temperature error (℃) 50 0.5 0.1 100 1.2 0.3 150 2.8 0.7
[0090] The delay time (100 ms) with alignment error < 1.5 ms and temperature error < 0.5° C. was selected as the time delay threshold. For data segments with delays exceeding 100 ms, Lagrange interpolation was used for resampling.
[0091] In one embodiment, for step S2,
[0092] The steps of calculating the current temperature difference between the surface temperature and the ambient temperature, generating a control signal when the current temperature difference exceeds a material thermal deformation threshold, and calculating the surface temperature change rate include:
[0093] Taking the first time window as a period, synchronously obtain the maximum surface temperature and the minimum ambient temperature;
[0094] Calculate the difference between the maximum surface temperature and the minimum ambient temperature during the window period as the current temperature difference;
[0095] When the current temperature difference exceeds the material thermal deformation threshold, a compensation control signal is generated. The material thermal deformation threshold is determined by a test piece temperature rise experiment. When the axial deformation reaches the deformation threshold, the corresponding temperature value is the material thermal deformation threshold.
[0096] Extract the continuous sampling data sequence of surface temperature within the window period;
[0097] Performing linear regression analysis on the data series to calculate the slope of temperature change over time;
[0098] The slope value was converted into the temperature change rate per minute as the surface temperature change rate.
[0099] In the process of specific implementation,
[0100] Based on the heat conduction equation of the surface temperature change of the load-bearing structure α is the thermal diffusion coefficient (typical value for steel is 1.2×10-5m 2 The first time window is determined through heat conduction simulation and measured data, with a preferred value of 3 minutes to balance noise suppression and response speed, effectively capturing more than 80% of the steady-state temperature distribution characteristics. Engineering verification data shows that a 3-minute window achieves the optimal balance between temperature gradient error (<0.5°C) and response speed (<40 seconds). Table 4 compares the temperature difference detection accuracy of different window lengths:
[0101] Table 4:
[0102] Window duration (min) Temperature gradient error (℃) Response delay (s) 1 0.9 18 3 0.3 32 5 0.2 51
[0103] The extreme temperature difference is calculated by taking the difference between the maximum surface temperature and the minimum ambient temperature during the window period. This can ensure the safety of the structure and avoid instantaneous fluctuations. For example, the temperature difference calculated between a certain temperature sequence and the ambient temperature sequence can effectively characterize the maximum thermal stress risk. The determination of the thermal deformation threshold of the material is completed through standardized experiments. Prepare a standard specimen of the same material as the load-bearing structure, heat the load-bearing structure specimen at a rate of 0.5°C / min in a constant temperature chamber, and simultaneously measure the axial strain ε (accuracy 0.001%). When ε = 0.05%, record the temperature difference ΔT between the current specimen surface and the environment. threshold . For ΔT threshold A 20% safety margin is applied as the actual decision threshold ΔT allowable =0.8ΔT threshold For example, the allowable temperature difference of Q235 steel is 12°C, and compensation is triggered when ΔT ≥ 12°C.
[0104] Experimentally measured ΔT of common materials threshold Values, see Table 5:
[0105] Table 5:
[0106] Material <![CDATA[ΔT threshold (℃)]]> <![CDATA[Coefficient of thermal expansion (10 -6 / °C)]]> Q235 steel 15 11.7 6061 aluminum alloy 22 23.6 304 stainless steel 18 16.0
[0107] The compensation control signal generation follows a strict technical closed-loop logic. allowable ,1.2ΔT allowable ), linear interpolation compensation is used; when ΔT>1.2ΔT allowable When the historical trend prediction algorithm is activated for compensation, the surface temperature data of the load-bearing structure is collected once per second with a 3-minute time window, and a total of 180 continuous sampling points are obtained. The temperature-time linear relationship equation T(t) = a*t+b is established, and the slope a is calculated using the least squares method. The formula is:
[0108]
[0109] n=180,t i is the timestamp, T i To correspond to the temperature value, the slope a was converted into the temperature change rate per minute (°C / min) as the surface temperature change rate.
[0110] In one embodiment, for step S3,
[0111] The steps of selecting a compensation mode according to the compensation control signal and the surface temperature change rate, starting a compensation process based on a closed-loop verification mechanism, correcting the original weighing value according to a temperature-drift relationship database, and generating preliminary compensation data include:
[0112] When the compensation control signal exists and the generation time is within the preset validity period, the compensation process is started after the temperature validity is confirmed through the closed-loop verification mechanism;
[0113] When the surface temperature change rate does not exceed the rate threshold, basic compensation is performed. Based on the current temperature difference, the corresponding linear correction coefficient is obtained through the temperature-drift relationship database to correct the weighing value;
[0114] When the surface temperature change rate exceeds the rate threshold, enhanced compensation is performed, and the principal component factors are extracted through a pre-built temperature data matrix including a preset number of sensors and preset sampling time points, and the weighing value is dynamically corrected through the L2 regularization compensation model;
[0115] The corrected weighing value is stored as preliminary compensation data.
[0116] In the specific implementation process, when the compensation control signal is detected, a closed-loop verification mechanism is executed. The closed-loop verification mechanism includes two-channel verification: timeliness verification (confirming that the signal generation time is within the last 5 minutes) and state consistency verification (real-time detection of the current temperature difference value > material thermal deformation threshold). If either verification fails, the signal is discarded and an error log is generated. The first rate threshold is set according to the material yield strength experiment. The specimen is heated at different temperature change rates in a temperature-controlled environment to monitor the thermal stress σ: E is the elastic modulus, α is the thermal expansion coefficient, and v is the Poisson's ratio. When the temperature change rate is greater than 2°C / min, the thermal stress σ exceeds the material yield strength σ. y 5% (safety margin), with σ=1.05σ y The corresponding temperature change rate (2°C / min) is used as the first rate threshold to enable the dynamic compensation model. Error comparison data shows that the enhanced compensation error at 2°C / min is reduced by more than 65% compared to the basic compensation, as shown in Table 6:
[0117] Table 6:
[0118]
[0119]
[0120] The basic compensation mode is implemented through the temperature-drift relationship database and the linear correction formula. The database uses the temperature difference ΔT as the index and stores the linear correction coefficient α corresponding to different materials. The compensation calculation formula is W 补偿 =W 原始 *(1+α*ΔT), for example, when ΔT=15℃, we can find α=0.028 by looking up the table, then the correction amount=15×0.028=0.42%. If the original value W 原始 =100kg, after compensation W 补偿 =100.42kg. The enhanced compensation mode utilizes a multi-step core algorithm with a preset number of sensors and sampling time points. Principal component analysis (PCA) contribution analysis confirms that at least eight sensors can cover 95% of the temperature field (cumulative contribution ≥ 95%). The sampling frequency is 0.33Hz (one point every three seconds), with 10 consecutive sampling points covering a 30-second window, ensuring complete capture of temperature trends. Missing data is interpolated using cubic spline interpolation, and outliers are removed using the 3σ criterion.
[0121] Perform singular value decomposition on the temperature data matrix X, formula X=U∑V T . After decomposition, select the first k principal components (k=3) to ensure that the cumulative variance contribution rate is ≥95%, so as to achieve dimensionality reduction of the data and extract key information. In the dynamic temperature compensation scenario, the temperature data matrix may have multicollinearity (such as high correlation between adjacent sensor data) and noise interference. In order to improve the generalization ability of the compensation model, it is necessary to solve the problem that the temperature change trends between sensors are similar, resulting in instability in model parameter estimation, and direct fitting under high-dimensional data is susceptible to noise, which reduces the robustness of compensation. Based on this, the L2 regularization compensation model (ridge regression) is introduced. By adding the L2 penalty term, the size of the model coefficient is constrained and the influence of multicollinearity is suppressed; the goodness of fit and model complexity are balanced to avoid overfitting of noisy data. Define the objective function:
[0122]
[0123] Where W 实测,i is the actual output value of the i-th weighing; PC1 i ,PC2 i ,PC3 i The first three principal components extracted by principal component analysis; β 0, β 1, β 2,β3 is the compensation coefficient to be determined; λ is the regularization strength parameter, which controls the weight of the penalty term. The regularization parameter λ is optimally determined using 10-fold cross-validation, dividing the dataset into 10 subsets. Candidate λ values (e.g., 0.001, 0.01, 0.1, 1) are iterated over. For each λ, the mean squared error (MSE) of the validation set is calculated, and the λ = 0.01 with the smallest MSE is selected as the final parameter. The optimal compensation coefficient is calculated using the closed-form formula: X is the principal component matrix, and I is the identity matrix. Compensation data is stored in the quaternary format of {timestamp, original value, compensation coefficient, compensated value}. Table 7 compares the compensation effects of the L2 regularization model and the ordinary least squares (OLS) method.
[0124] Table 7:
[0125] Temperature change rate (℃ / min) OLS error (%FS) L2 regularization error (%FS) Improvement 1.5 0.07 0.04 42.9% 2.5 0.21 0.06 71.4% 3.0 0.28 0.07 75.0%
[0126] In one embodiment, the step of constructing a temperature-drift relationship database includes:
[0127] Adjust the temperature difference environment in the temperature-controlled experimental chamber with a preset temperature difference step length;
[0128] Apply standard load at each temperature difference point and record the output drift of the load cell;
[0129] The temperature difference-drift relationship curve is established through piecewise linear regression;
[0130] The cubic spline interpolation is performed on the inflection point area of the curve to encrypt the data points.
[0131] Specifically, based on the nonlinear characteristics of the material's thermal expansion properties, a step size of 1°C was selected. Calibration experiments in a temperature-controlled experimental chamber showed that when the step size was greater than 2°C, the linear interpolation error was greater than 0.05% FS; when the step size was ≤ 1°C, the error was less than 0.02% FS, as shown in Table 8 below:
[0132] Table 8:
[0133] Step length (℃) Calibration error (% FS) Experimental time (h) 0.5 0.01 48 1.0 0.02 24 2.0 0.05 12
[0134] In the standard load loading link, each temperature difference point needs to be loaded with 20%, 50%, and 80% standard weights of the range. Taking the 200kg range as an example, 40kg, 100kg, and 160kg weights are loaded, and the output drift of the weighing sensor is recorded. For example, when the temperature difference ΔT = 10°C, the 40kg load corresponds to a drift of +12g, 100kg corresponds to +28g, and 160kg corresponds to +45g. After calibration, the piecewise linear regression model is used to further process the data. The inflection point of the curve is identified by the second-order derivative extreme value method, and the temperature difference-drift data is calculated. The formula is: d 2 (ΔW) / dT 2=[ΔW(T+1)-2ΔW(T)+ΔW(T-1) / (ΔT) 2 , when d 2 (ΔW) / dT 2 When the value is greater than the threshold, it is marked as an inflection point, which is used to divide different temperature ranges. For example, the slope of the low temperature range (-20 to 0°C) is k1 = 0.05% FS / °C, the slope of the normal temperature range (0 to 30°C) is k2 = 0.03% FS / °C, and the slope of the high temperature range (30 to 50°C) is k3 = 0.08% FS / °C. The cubic spline interpolation method is used within the inflection point ±2°C interval to encrypt the data points to a resolution of 0.1°C. The interpolation formula is S(T) = a i (TT i ) 3 +bi(TT i ) 2 +c i (TT i )+d i , where the coefficient a i ~d i Determined by the continuity conditions of adjacent points.
[0135] In one embodiment, the step of enhancing compensation comprises:
[0136] Construct a state space model of temperature change rate and compensation amount;
[0137] The compensation amount is dynamically smoothed by using a Kalman filter;
[0138] When the temperature changes suddenly, the sliding window variance detection is enabled to automatically adjust the filter parameters.
[0139] Specifically, the dynamic optimization mechanism of enhanced compensation achieves accurate compensation by constructing a state space model, applying Kalman filtering, temperature mutation detection and parameter adaptation. In the construction of the state space model, the state variables are defined as follows:
[0140] Where C is the compensation amount, C' is the rate of change of the compensation amount, and the input variable reflects the temperature change rate T' of the environment's dynamic disturbance to the system. The state equation (process model) formula is:
[0141] x k =Ax k-1 +BT' k +w k
[0142] Δt is the sampling interval (such as 1 second), and γ is the coefficient of influence of temperature change rate on compensation change (calibrated by experiment, typical value is 0.05). k is the process noise, which obeys the Gaussian distribution N(0,Q). The observation equation is zk=Hxk +v k , where H =
[10] , only the compensation amount is observed; v k The observation noise is N(0, R), which describes the relationship between the system dynamic process and the observation. The optimal compensation amount is estimated in real time through recursive calculations such as Kalman filter prediction and update steps. The sliding window variance detection method is used to detect temperature mutations. The variance is calculated by selecting the most recent N = 10 temperature sampling points (time span 10 seconds):
[0143] where μ T is the average temperature in the window. It is determined to be a temperature mutation ( is the historical average variance). After a mutation is detected, the process noise covariance is switched from normal mode to mutation mode to speed up the filter response. The normal mode and mutation mode are:
[0144] Taking the scenario where rapid temperature rise causes compensation lag as an example, the ambient temperature initially rises slowly and the filter is in normal mode. When the temperature rises suddenly by 5°C / s, the sliding window detects that the variance exceeds the limit. Historical baseline ), the parameters are switched immediately, the filter converges quickly, the compensation amount tracks to the target value within 0.5 seconds, and the error is reduced from 0.25% FS to 0.06% FS.
[0145] In one embodiment, for step S4,
[0146] The steps for triggering the parameter self-update operation and obtaining the final weighing data include:
[0147] When the cumulative temperature shock value calculated by accumulating the duration of each temperature difference exceeding the threshold and the corresponding temperature difference amplitude reaches the set threshold, the parameter self-update operation is triggered;
[0148] Load standard weights to perform zero point calibration and generate reference compensation parameters;
[0149] Calculating the deviation rate between the current compensation parameter and the reference compensation parameter;
[0150] If the deviation rate exceeds the calibration threshold, the temperature-drift relationship database is updated;
[0151] The preliminary compensation data is corrected secondary based on the updated temperature-drift relationship database, and the final weighing data is output.
[0152] In the specific implementation process, the technical basis of the parameter self-update operation is based on the calculation of the cumulative temperature shock value and the determination of the material fatigue limit. After the parameter update is completed, the new parameter value is fed back to the compensation decision control module, forming a closed-loop control loop of temperature monitoring-compensation decision-execution correction-parameter self-update-feedback optimization. The cumulative temperature shock value S total The calculation formula is:
[0153]
[0154] ΔT i is the i-th exceeding threshold temperature difference, t i The corresponding duration, for example, if there are three threshold-exceeding events on a certain day, the cumulative value reaches 336℃·min. The material fatigue limit S limit The load-bearing structure specimens were subjected to cyclic temperature load tests using a fatigue testing machine, and the cumulative impact value that caused the material to yield (strain ≥ 0.1%) was recorded. The actual trigger threshold for the safety threshold was set to S trigger =0.8*S limit , 80% safety margin can cover material performance fluctuations (±10%) and environmental uncertainties (±5%). Zero point calibration and reference parameter generation follow the standard weight loading specifications, using OIML R111 certified weights (error ≤ 0.01% FS), loading in 10% steps of the range, and generating a zero drift curve. Through the linear regression model W raw =a*W 实际 +b, where a is the sensitivity coefficient, b is the zero drift, and the reference parameter after calibration is K 标准 ={a 新 , b 新 The compensation parameter deviation analysis is evaluated by the deviation rate formula. The current parameter is the compensation parameter K generated in step S3. 当前 ={a 旧 , b 旧}, the deviation rate calculation formula is:
[0155]
[0156] The calibration threshold is set according to international measurement standards (such as OIML R76) to ensure that the compensation accuracy meets the requirements of commercial weighing equipment. When the deviation rate is greater than the calibration threshold of 0.05% FS (such as when the range is 200kg, the allowable deviation is ≤0.1kg), K 新 Write the database entries corresponding to the temperature range and perform cubic spline interpolation on adjacent temperature difference points to ensure a smooth transition of the curve. The secondary correction process performs the final calibration on the preliminary compensation data. The input data is the preliminary compensation data W generated in step S3. 初步 , calculate the final output value, which is the final weighing data, through the formula:
[0157]
[0158] When the error exceeds 0.02% FS, an alarm is triggered and a log containing the cumulative impact value, deviation rate, and data before and after compensation is recorded, ensuring full process traceability. The final weighing data output by the parameter self-update operation is fed back in real time to the temperature difference calculation unit of the compensation decision control module to optimize the accuracy of the compensation control signal generation for the next cycle.
[0159] In one embodiment, for step S5,
[0160] The steps of outputting the final weighing data with temperature confidence rating to the interactive interface include:
[0161] Calculate the current temperature difference ratio based on the current temperature difference value and the material thermal deformation threshold;
[0162] Calculate the average absolute deviation of the last three calibrations;
[0163] Generate risk rating results based on the current temperature difference ratio and absolute deviation mean;
[0164] The risk rating results are bound to the final weighing data and displayed in real time on the interactive interface.
[0165] (Record compensation logs, including timestamp, temperature difference, rating, and compensation amount.)
[0166] In the specific implementation process, the temperature credibility rating generation mechanism provides data support for risk rating through the calculation of the current temperature difference ratio and calibration deviation statistics. The current temperature difference ratio calculation formula is:
[0167]
[0168] ΔT current is the current temperature difference, ΔT threshold is the material thermal deformation threshold. The calibration deviation statistics record the deviation rate of the last three calibrations (calculated results in step S4) and calculate the mean:
[0169]
[0170] δi is the deviation rate for the i-th calibration. Risk rating rules are set based on a rating decision matrix and grading threshold technology. The 120% temperature difference threshold is derived from material yield testing; exceeding this value results in a 15% excess thermal stress safety margin. The 0.1% FS calibration deviation complies with the OIML R76 industry standard; exceeding this value triggers maintenance. Data binding and real-time display utilize JSON format to encapsulate weighing and rating information, including timestamps, weight, temperature data, and rating details (such as risk level and recommended actions).
[0171] In the multi-level control architecture of the present invention, the temperature sensing layer uses a dual-array temperature sensor to collect the surface temperature of the load-bearing structure and the ambient temperature in real time; the compensation decision layer generates a compensation control signal based on the temperature difference threshold and the temperature change rate, and dynamically selects the basic or enhanced compensation mode; the parameter update layer triggers the self-calibration operation according to the accumulated temperature shock value, forming a closed-loop update loop for the compensation parameters. In terms of closed-loop control logic, a complete closed-loop control chain is formed through the verification of the validity of the compensation control signal, the execution of the compensation strategy, the generation of preliminary data, the calibration trigger, the parameter update to the final output, and the temperature credibility rating is fed back to the compensation decision control module to achieve adaptive optimization of the control strategy. The closed-loop control system of "temperature disturbance-compensation correction-parameter calibration" constructed by the present invention effectively improves the anti-interference ability of the system, and realizes adaptive stable control of the weighing process through the coordinated operation of the compensation decision controller and the parameter self-update controller.
[0172] Reference Figure 2 , is a structural block diagram of a dynamic weighing system with self-calibration and temperature compensation functions in one embodiment of the present invention, comprising:
[0173] The temperature monitoring module is used to synchronously obtain the surface temperature of the load-bearing structure and the ambient temperature data through a preset temperature sensor array;
[0174] a compensation decision control module, configured to calculate a current temperature difference between the surface temperature and the ambient temperature, generate a control signal when the current temperature difference exceeds a material thermal deformation threshold, and calculate a surface temperature change rate;
[0175] The compensation execution module is used to select the compensation mode according to the compensation control signal and the surface temperature change rate, start the compensation process based on the closed-loop verification mechanism, correct the original weighing value based on the temperature-drift relationship database, and generate preliminary compensation data;
[0176] The parameter self-update control module is used to obtain a cumulative temperature shock value by accumulating the duration of each temperature difference exceeding the threshold value and the corresponding temperature difference amplitude. When the cumulative temperature shock value reaches a set threshold, the parameter self-update operation is triggered to obtain the final weighing data;
[0177] The data output module is used to output the final weighing data with temperature credibility rating to the interactive interface.
[0178] For the specific implementation of each module in the above device example, please refer to the above method embodiment, which will not be repeated here.
[0179] In summary, the present invention synchronously obtains the surface temperature and ambient temperature data of the load-bearing structure through a preset temperature sensor array; calculates the current temperature difference between the surface temperature and the ambient temperature, generates a control signal when the current temperature difference exceeds the material thermal deformation threshold, and calculates the surface temperature change rate; selects a compensation mode according to the compensation control signal and the surface temperature change rate, starts the compensation process based on the closed-loop verification mechanism, corrects the original weighing value according to the temperature-drift relationship database, and generates preliminary compensation data; when the cumulative temperature shock value is obtained by accumulating the duration of each temperature difference exceeding the threshold and the corresponding temperature difference amplitude, when the cumulative temperature shock value reaches the set threshold, the parameter self-update operation is triggered to obtain the final weighing data; outputs the final weighing data with temperature credibility rating to the interactive interface to solve the error accumulation and manual intervention dependence problems caused by temperature fluctuations in traditional solutions.
[0180] Those skilled in the art will appreciate that all or part of the processes in the above-described method embodiments can be implemented by instructing the relevant hardware through a computer program. The computer program can be stored in a non-volatile computer-readable storage medium. When executed, the computer program can include the processes of the above-described method embodiments. Among them, any reference to memory, storage, database, or other media provided by the present invention and used in the embodiments can include non-volatile and / or volatile memory. Non-volatile memory can include read-only memory (ROM), programmable ROM (PROM), electrically programmable ROM (EPROM), electrically erasable programmable ROM (EEPROM), or flash memory. Volatile memory can include random access memory (RAM) or external cache memory. By way of illustration and not limitation, RAM is available in various forms, such as static RAM (SRAM), dynamic RAM (DRAM), synchronous DRAM (SDRAM), double-speed SDRAM (SSRSDRAM), enhanced SDRAM (ESDRAM), synchronous link DRAM (SLDRAM), RAMbus direct RAM (RDRAM), direct RAM bus dynamic RAM (DRDRAM), and RAMbus dynamic RAM.
[0181] It should be noted that, in this document, the terms "comprises," "includes," or any other variations thereof are intended to encompass non-exclusive inclusion, such that a process, apparatus, article, or method comprising a series of elements includes not only those elements but also other elements not explicitly listed, or elements inherent to such process, apparatus, article, or method. In the absence of further limitations, an element defined by the phrase "comprising a ..." does not exclude the presence of other identical elements in the process, apparatus, article, or method comprising the element.
[0182] The above description is only a preferred embodiment of the present invention and does not limit the patent scope of the present invention. Any equivalent structure or equivalent process transformation made by using the contents of the present invention description and drawings, or directly or indirectly applied in other related technical fields, are also included in the patent protection scope of the present invention.
Claims
1. A dynamic weighing method with self-calibration and temperature compensation functions, characterized in that: The following steps are involved: The surface temperature of the load-bearing structure and the ambient temperature data are synchronously acquired through a preset temperature sensor array; Calculating a current temperature difference between the surface temperature and the ambient temperature, generating a compensation control signal when the current temperature difference exceeds a material thermal deformation threshold, and calculating a surface temperature change rate; Selecting a compensation mode according to the compensation control signal and the surface temperature change rate, starting a compensation process based on a closed-loop verification mechanism, correcting the original weighing value according to a temperature-drift relationship database, and generating preliminary compensation data; By accumulating the duration of each temperature difference exceeding the threshold value and the corresponding temperature difference amplitude, a cumulative temperature shock value is obtained. When the cumulative temperature shock value reaches the set threshold, the parameter self-update operation is triggered to obtain the final weighing data; Output the final weighing data with temperature confidence rating to the interactive interface.
2. The dynamic weighing method with self-calibration and temperature compensation functions according to claim 1, characterized in that: The step of synchronously acquiring the surface temperature of the load-bearing structure and the ambient temperature data through a preset temperature sensor array comprises: Arranging a first temperature sensor array in advance at a first preset interval in a stress-sensitive area of the load-bearing structure; Arrange a second temperature sensor array between the device base and the peripheral space at a second preset interval; The surface temperature of the weighing structure and the ambient temperature data are collected through dual array sensors.
3. The dynamic weighing method with self-calibration and temperature compensation functions according to claim 2, characterized in that: After the step of collecting the weighing structure surface temperature and ambient temperature data by the dual array sensor, the method includes: Mark the temperature data whose mutation amount exceeds the temperature mutation threshold as an abnormal point; Use linear interpolation of the two valid sampling points before and after to replace the outliers; Using the timestamp of the reference sensor as a reference, align the sampling timing of all sensors; Resample and fit the data segments whose delay exceeds the time delay threshold.
4. The dynamic weighing method with self-calibration and temperature compensation functions according to claim 1, characterized in that: The step of calculating the current temperature difference between the surface temperature and the ambient temperature, generating a control signal when the current temperature difference exceeds a material thermal deformation threshold, and calculating the surface temperature change rate includes: Taking the first time window as a period, synchronously obtain the maximum surface temperature and the minimum ambient temperature; Calculate the difference between the maximum surface temperature and the minimum ambient temperature during the window period as the current temperature difference; When the current temperature difference exceeds the material thermal deformation threshold, a compensation control signal is generated. The material thermal deformation threshold is determined by a test piece temperature rise experiment. When the axial deformation reaches the deformation threshold, the corresponding temperature value is the material thermal deformation threshold. Extract the continuous sampling data sequence of surface temperature within the window period; Performing linear regression analysis on the data series to calculate the slope of temperature change over time; The slope value was converted into the temperature change rate per minute as the surface temperature change rate.
5. The dynamic weighing method with self-calibration and temperature compensation functions according to claim 1, characterized in that: The steps of selecting a compensation mode according to the compensation control signal and the surface temperature change rate, starting a compensation process based on a closed-loop verification mechanism, correcting the original weighing value according to a temperature-drift relationship database, and generating preliminary compensation data include: When the compensation control signal exists and the generation time is within the preset validity period, the compensation process is started after the temperature validity is confirmed through the closed-loop verification mechanism; When the surface temperature change rate does not exceed the rate threshold, basic compensation is performed. Based on the current temperature difference, the corresponding linear correction coefficient is obtained through the temperature-drift relationship database to correct the weighing value; When the surface temperature change rate exceeds the rate threshold, enhanced compensation is performed, and the principal component factors are extracted through a pre-built temperature data matrix including a preset number of sensors and preset sampling time points, and the weighing value is dynamically corrected through the L2 regularization compensation model; The corrected weighing value is stored as preliminary compensation data.
6. The dynamic weighing method with self-calibration and temperature compensation functions according to claim 5, characterized in that: The steps of constructing the temperature-drift relationship database include: Adjust the temperature difference environment in the temperature-controlled experimental chamber with a preset temperature difference step length; Apply standard load at each temperature difference point and record the output drift of the load cell; The temperature difference-drift relationship curve is established through piecewise linear regression; The cubic spline interpolation is performed on the inflection point area of the curve to encrypt the data points.
7. The dynamic weighing method with self-calibration and temperature compensation functions according to claim 5, characterized in that: The step of enhancing compensation comprises: Construct a state space model of temperature change rate and compensation amount; The compensation amount is dynamically smoothed by using a Kalman filter; When the temperature changes suddenly, the sliding window variance detection is enabled to automatically adjust the filter parameters.
8. The dynamic weighing method with self-calibration and temperature compensation functions according to claim 1, characterized in that: The step of triggering the parameter self-update operation and obtaining the final weighing data includes: When the cumulative temperature shock value calculated by accumulating the duration of each temperature difference exceeding the threshold and the corresponding temperature difference amplitude reaches the set threshold, the parameter self-update operation is triggered; Load standard weights to perform zero point calibration and generate reference compensation parameters; Calculating the deviation rate between the current compensation parameter and the reference compensation parameter; If the deviation rate exceeds the calibration threshold, the temperature-drift relationship database is updated; The preliminary compensation data is corrected secondary based on the updated temperature-drift relationship database, and the final weighing data is output.
9. The dynamic weighing method with self-calibration and temperature compensation functions according to claim 1, characterized in that: The step of outputting the final weighing data with the temperature credibility rating to the interactive interface includes: Calculate the current temperature difference ratio based on the current temperature difference value and the material thermal deformation threshold; Calculate the average absolute deviation of the last three calibrations; Generate risk rating results based on the current temperature difference ratio and absolute deviation mean; The risk rating results are bound to the final weighing data and displayed in real time on the interactive interface.
10. A dynamic weighing system with self-calibration and temperature compensation functions, characterized in that: include: The temperature monitoring module is used to synchronously obtain the surface temperature of the load-bearing structure and the ambient temperature data through a preset temperature sensor array; a compensation decision control module, configured to calculate a current temperature difference between the surface temperature and the ambient temperature, generate a control signal when the current temperature difference exceeds a material thermal deformation threshold, and calculate a surface temperature change rate; The compensation execution module is used to select the compensation mode according to the compensation control signal and the surface temperature change rate, start the compensation process based on the closed-loop verification mechanism, correct the original weighing value based on the temperature-drift relationship database, and generate preliminary compensation data; The parameter self-update control module is used to obtain a cumulative temperature shock value by accumulating the duration of each temperature difference exceeding the threshold value and the corresponding temperature difference amplitude. When the cumulative temperature shock value reaches a set threshold, the parameter self-update operation is triggered to obtain the final weighing data; The data output module is used to output the final weighing data with temperature credibility rating to the interactive interface.
Citation Information
Cited By
On-load comprehensive test system for integrated joint module
CN121090069A
Online weighing and metering system and method for hot-metal bottle
CN121612408A
Weighing compensation method and system for temperature change, medium and program product
CN121632310A
Weighing compensation method, system, medium and program product against temperature variations
CN121632310B
Intelligent operation, maintenance and dynamic calibration management system for vehicle-mounted overweight detection equipment
CN121917035A