Farmland soil acidification space-time sequence data construction and trend diagnosis method
By introducing temporal variation parameters and spatiotemporal data integration technology, a spatiotemporal variation model of soil acidification is constructed, and combined with Krigin interpolation and trend analysis methods, the problem that traditional monitoring methods are difficult to capture the spatial and temporal changes in soil acidification is solved, and high-precision soil acidification trend prediction and sustainability analysis are achieved.
Patent Information
- Application Number
- CN202411820302.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-12-11
- Publication Date
- 2025-04-08
- Estimated Expiration
- 2044-12-11
AI Technical Summary
Traditional soil pH monitoring methods have problems such as limited sampling points, long data acquisition period, high cost and inconsistent spatial coordinates. It is difficult to fully capture the wide distribution characteristics of soil acidification in the spatial dimension and its evolution trajectory over time.
Introduce time variation parameters, integrate the spatial and temporal information of soil pH through a spatiotemporal sparse grid data frame, calculate the empirical variogram function of space-time, build a separable and measured spatiotemporal variogram model, combine spatial-temporal Kriging interpolation for prediction, establish a trend analysis model of Theil-Sen Median and Mann-Kendall tests, and analyze sustainability using Hurst index.
It has achieved a comprehensive grasp of the spatial and temporal changes of soil acidification, improved the accuracy of data analysis and prediction, reduced the spatial and temporal uncertainty of monitoring data, and is suitable for large-scale and multi-time period analysis of farmland soil acidification trends.
Smart Images

Figure CN119782683A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of soil science, and in particular to a method for constructing spatiotemporal series data of farmland soil acidification and diagnosing its trend. Background Art
[0002] As one of the key phenomena of soil quality degradation worldwide, soil acidification poses a severe challenge to global food security due to its widespread existence and continued aggravation. Soil acidification directly weakens the fertility base of the soil, thereby affecting the balance of soil microbial community structure, the rate of organic matter decomposition and the smooth nutrient cycle. This series of chain reactions ultimately endangers the growth potential of crops and the yield and quality of agricultural products, thus posing a potential risk to the stability of global food security. Existing studies have extensively explored the negative impact of soil acidification on the sustainability of agricultural systems, including crop yield reduction, soil organic matter degradation and enhanced aluminum toxicity. Stable soil pH is the cornerstone of ensuring the integrity of ecosystem structure, sound function and long-term sustainability, and plays an indispensable role in promoting healthy plant growth, maintaining biodiversity and regulating carbon and nitrogen cycles. However, in China, the spatial distribution characteristics of soil pH are affected by both natural and human activities and show a high degree of variability, which further emphasizes the urgency of conducting regional soil acidification monitoring and prevention and control research. As global climate change intensifies, soil acidification has become one of the core obstacles restricting the sustainable development of regional agriculture. In-depth analysis of its spatiotemporal distribution characteristics and its internal occurrence mechanism has far-reaching significance for promoting sustainable agricultural development.
[0003] Traditional soil pH monitoring methods mainly rely on manual sampling and laboratory analysis. Although this method can obtain relatively accurate soil pH data, it has problems such as limited sampling points, long data acquisition cycle, high cost, and inconsistent spatial coordinates of sampling points over many years. The in-depth application of geostatistical methods has laid a solid foundation for in-depth understanding of the complex mechanism of soil acidification by analyzing the temporal and spatial variation of soil nutrients. The introduction of geographic information system (GIS) technology has further promoted the mining of the correlation between soil nutrient spatial data and attribute data. In particular, the application of techniques such as Kriging interpolation and geographically weighted regression has effectively improved the accuracy of spatial distribution prediction of soil attribute values. Due to the spatial heterogeneity of farmland soil, monitoring data from a single point or a small number of points is often difficult to fully reflect the soil acidification status of the entire region. The above methods mostly focus on local or short-term monitoring, and it is difficult to fully capture the wide distribution characteristics of soil acidification in the spatial dimension and its evolution trajectory over time. At the same time, due to the diversity of data sources, the uneven distribution of sample points and the accuracy of geographic coordinates, the uncertainty of soil acidification trend research is increased. In view of this, integrating soil acidification data through more accurate spatial interpolation and other advanced technical means to achieve comprehensive analysis across long time series and wide spatial scales has become a key way to deeply analyze the intrinsic mechanisms of soil acidification and its environmental effects.
[0004] Based on the two major challenges currently faced by farmland soil monitoring: spatial discreteness and inconsistency of sampling points. These problems lead to discontinuity and uncertainty in soil data in space and time, which seriously affects the accurate assessment and prediction of soil acidification trends. Farmland soil acidification is a complex and dynamically changing process, which is affected by a variety of natural and human factors, such as climate, vegetation, fertilization habits, etc. At the technical level, this method first recognizes that soil acidification is a complex spatiotemporal process that is not only affected by spatial variability, but also evolves over time. Therefore, the traditional interpolation method that only considers spatial variability can no longer meet the accuracy requirements of farmland soil acidification trend monitoring. Summary of the invention
[0005] The purpose of the present invention is to introduce time variation parameters to comprehensively capture the changing laws of soil acidification in the temporal and spatial dimensions, thereby proposing a method for constructing and diagnosing the spatiotemporal series data of farmland soil acidification.
[0006] The technical solution of the present invention is to provide a method for constructing and diagnosing farmland soil acidification spatiotemporal series data, which includes:
[0007] S1. Data collection and preprocessing: Collect annual farmland soil pH observation data, including spatial information and timestamps; clean the data, remove erroneous records and invalid points beyond the study area; construct a spatiotemporal sparse grid data framework, input the cleaned data into the spatiotemporal sparse grid data framework, and unify the spatial and temporal dimensions;
[0008] S2. Calculate the spatiotemporal empirical variogram based on the collected data: Calculate the spatiotemporal variogram and empirical estimate of soil pH value separately, and put them together to form the spatiotemporal empirical variogram to quantify the variation of soil pH value under different spatial and temporal conditions;
[0009] S3. Constructing a spatiotemporal variogram model to fit the spatiotemporal variogram: Based on the calculation results of the spatiotemporal variogram, a separable model and a metric model are systematically constructed to model the spatiotemporal changes of soil acidification, and the parameters of the two models are continuously optimized to fit a more accurate spatiotemporal variogram;
[0010] S4. Spatiotemporal prediction through spatiotemporal kriging interpolation: Construct a unified spatiotemporal grid, combine the spatial and temporal information in the farmland soil pH observation data, and predict the farmland soil pH value based on spatiotemporal kriging interpolation; generate a full spatiotemporal observation grid to predict the spatial distribution of farmland soil acidification and its changing trend over time;
[0011] S5. Soil acidification trend analysis: Based on the collected data, a soil acidification trend identification model was established through the Theil-SenMedian trend analysis of time series raster images and the non-parametric Mann-Kendall test to evaluate the significance of farmland soil acidification trends;
[0012] S6. Sustainability identification: Use the Hurst index to analyze the sustainability of soil acidification trends and provide a basis for future soil improvement and management.
[0013] In any of the above technical solutions, further, the specific process of calculating the spatiotemporal empirical variation function in step S2 includes:
[0014] Assume that soil pH is defined in the spatial domain and time domain The Gaussian space-time random field on the n ,t n )∈S×T The observed soil pH sample PH(s n ,t n ), which may include repeated measurements at the same location or simultaneous measurements at different spatial locations;
[0015] Introducing the space-time covariance function: For the space-time random process {PH(s,t):s∈R 2,t∈R}, under the assumption of second-order stationarity, the covariance function of the spatiotemporal random field PH(s,t) depends only on the spatial distance h between the two observation points s and time lag h t , and has nothing to do with the specific time and space positions of the two observation points, then the space-time covariance function is:
[0016] C(h s ,h t )=Cov(PH(s+h s ,t+h t ),PH(s,t));
[0017] In order to more intuitively describe the spatiotemporal variability of soil pH, the temporal variation parameters were integrated into the spatial variation model and the spatiotemporal variation function γ(h s ,h t ) measures the degree of difference between random variables:
[0018]
[0019] For the spatiotemporal dataset of soil pH, the empirical estimate of its spatiotemporal covariance can be expressed as:
[0020] μ PH (h s ,h t )][PH(s i ,t i )-μ PH (0,0)];
[0022] Among them, N(h s ,h t ) is to satisfy the spatial offset h s and time lag h t The set of soil pH observation point pairs, is the number of such observation point pairs, PH(s,t) represents the soil pH value measured at location s and time t, μ PH (h s ,h t ) and μ PH (0,0) are the empirical means at the sampling point offset and the origin respectively;
[0023] Similarly, the empirical estimation of the spatiotemporal variogram of soil pH is for:
[0024]
[0025] In order to make the covariance function meaningful, the function C(h s ,h t) must satisfy the positive definiteness condition, that is, to ensure the non-negative definiteness and invertibility of the covariance matrix. For any real number a i (i=1,…,n) and any space-time point (s i ,t i ) have:
[0026]
[0027] The above-mentioned spatiotemporal variation function γ(h s ,h t ) and empirical estimates Construct the spatiotemporal empirical variation function.
[0028] In any of the above technical solutions, further, the specific process of constructing the spatiotemporal variogram model in step S3 includes: constructing a separable model and a measurement model;
[0029] In the separable model, the spatiotemporal covariance function of soil pH can be expressed as the product of the spatial covariance function and the temporal covariance function, that is:
[0030] C sep (h,u)=C s (h)·C t (u);
[0031] Among them, h represents the spatial distance and u represents the time lag, then the corresponding variation function form is:
[0032]
[0033] are standardized spatial and temporal variograms, with separated nugget effects, and the joint parameter in the sill is set to 1, and the overall sill is defined by the sill parameter; in R, such a model can be constructed using the gstat package; first, the parameters of the spatial and temporal variograms are set separately, then the separable model is specified by the vgmST function, and the empirical variogram is fitted using the fit.StVariogram function to optimize the model parameters;
[0034] The metric model expands the two-dimensional geographic space to three-dimensional space-time, and introduces an anisotropy parameter (κ) to match the spatial and temporal scales. The space-time distance is obtained by correcting the spatial distance (h) and the time lag (u) by κ, as follows:
[0035]
[0036] The corresponding variogram is:
[0037]
[0038] When building a metric model in R language, first define a variogram model that includes the nugget effect, specify the metric model through the vgmST function, and use the joint variogram and anisotropy parameters as input. Also use the fit.StVariogram function to fit the empirical variogram, optimize the model parameters to minimize the fitting error, and find the optimal variogram parameters; select the optimal model by comparing the MSE values or other statistical indicators of different models.
[0039] In any of the above technical solutions, further, the process of predicting soil pH value by spatiotemporal Kriging interpolation in step S4 includes:
[0040] Construct a spatiotemporal observation grid, which includes a spatial grid and a temporal grid. In terms of the spatial grid, a unified spatial reference system is determined. According to the size of the study area and the required accuracy, the spatial grid is divided, and the resolution of the grid is determined to generate SpatialPixelsDataFrame pixel points. Each point represents a potential farmland soil pH value observation data. In terms of the temporal grid, the time range is determined in the time dimension, and this period is evenly divided into several time periods in combination with the data accuracy. Each time period represents a prediction time point. Combine the spatial grid and the temporal grid to create a spatiotemporal prediction grid. Each grid point corresponds to a specific spatial position and time point.
[0041] Using the optimal spatiotemporal variogram model fitted in step S3, the krigeST function is called on the constructed full spatiotemporal observation grid to perform spatiotemporal Kriging interpolation to predict the spatial distribution of farmland soil acidification and its changing trend over time. For any point (s0, t0) on the STF grid, the spatiotemporal Kriging interpolation prediction value of the soil pH value PH(s0, t0) can be given by the following formula:
[0042]
[0043] Where: PH(s i ,t i ) is the pH observation value at the soil sampling point, PH(s0,t0) is the estimated value at the time and space point (s0,t0); n is the number of observation points involved in the prediction, λ i is the neighboring observation value PH(s i ,t i ), μ is the weight coefficient of the introduced Lagrangian coefficient; where λ i It is necessary to ensure that the variance of the prediction error is minimized and the unbiased condition is met by solving the weight coefficient, which is usually transformed into solving the following optimization problem: At the same time, the unbiasedness condition is satisfied: The Lagrangian function can be constructed as follows:
[0044]
[0045] Let L(λ i ,μ) vs.λ i Find the partial derivative of μ and set it to 0, thus solving the weight coefficient λ i ;
[0046] After the interpolation is completed, the spatiotemporal Kriging interpolation results need to be evaluated based on the parameters. Based on the evaluation results, the model needs to be verified and the parameters need to be optimized and debugged as needed to improve the prediction performance of the model.
[0047] In any of the above technical solutions, further, step S4 also includes: after the interpolation is completed, the following steps need to be performed:
[0048] Model validation: Check whether the model meets the unbiased condition, that is, whether the average value of the predicted value is close to the average value of the observed value, analyze the error distribution, check whether there are systematic deviations or outliers, evaluate the stability and consistency of the model, and ensure that reasonable prediction results can be obtained on different data subsets or time points;
[0049] Adjust and optimize the parameters of the spatiotemporal empirical variogram: According to the evaluation results and prior knowledge, adjust the parameters of the spatiotemporal variogram to improve the model's fit and prediction accuracy;
[0050] Explore different model types: try different spatiotemporal variogram models, compare their differences in predictive performance, and choose the model that best suits the current data;
[0051] Consider covariates: If the data contain other covariates that may be associated with soil pH, include them in the model as fixed effects or as part of random effects to improve the explanatory power and prediction accuracy of the model;
[0052] Iterative optimization: Compare and analyze the preliminary evaluation results and the new prediction results after parameter optimization and debugging to determine whether the optimization is effective. By comparing the prediction results with the data of known observation points, the accuracy and reliability of spatiotemporal Kriging interpolation are evaluated.
[0053] Repeat the above steps for multiple iterations of optimization until satisfactory prediction performance is achieved.
[0054] In any of the above technical solutions, further, the soil acidification trend identification model established in step S5 is:
[0055]
[0056] S PHis the median slope calculated by the Theil - Sen Median trend analysis method, which is used to evaluate the trend of the soil pH value time series. When S PH > 0, it indicates that the soil pH value shows an acidification trend; otherwise, it indicates that the soil pH value tends to be alkalized;
[0057] Define the statistic S:
[0058]
[0059] Among them, the sign function sgn is defined as:
[0060]
[0061] Among them, pH i and pH j represent the soil pH values in the i - th year and the j - th year respectively, and n represents the length of the time series;
[0062] At a given significance level α, α = 0.05, when |Z| > u 1-α / 2 it indicates that there is a significant change trend in the soil pH value time series at the α level.
[0063] In any of the above - mentioned technical solutions, further, the specific content of using the Hurst exponent to analyze the sustainability of the soil acidification trend in step S6 includes:
[0064] The calculation method of the Hurst exponent is as follows:
[0065]
[0066] Among them, is the mean time series of the pH value, X(t,τ) is the cumulative deviation of the pH value, R(τ) is the range, S(τ) is the standard deviation, H is the Hurst exponent. If there is a relationship R(τ) / S(τ) ∝ τ H , it indicates that there is a Hurst phenomenon in the soil pH value time series;
[0067] When 0.5 < H < 1, it indicates that the soil pH value time series has persistence, that is, the soil acidification / alkalization trend may continue in the future, and the closer H is to 1, the stronger this persistence is;
[0068] When H = 0.5, it indicates that the soil pH value time series is random and there is no long - term correlation, that is, the change of the soil pH value is unpredictable;
[0069] When 0 < H < 0.5, it indicates that the soil pH value time series has anti - persistence, that is, the soil acidification / alkalization trend may be opposite to the past in the future, and the closer H is to 0, the stronger this anti - persistence is.
[0070] The beneficial effects of the present invention are:
[0071] The present invention proposes a soil acidification data construction and trend diagnosis method that combines spatial and temporal dimensions. By integrating the spatiotemporal data of farmland soil acidification, a comprehensive grasp of the spatiotemporal variation laws of soil acidification can be achieved. This method makes up for the shortcomings of traditional monitoring methods in terms of insufficient information in spatial and temporal dimensions, and provides a scientific basis for the sustainable development of regional agriculture.
[0072] Among them, by introducing spatiotemporal variation parameters and using optimized spatiotemporal variation function models, the accuracy of data analysis and prediction was improved. Through separable models and measurement models, the dynamic characteristics of soil acidification were deeply explored, and the spatial and temporal uncertainty of monitoring data was significantly reduced.
[0073] The spatiotemporal Kriging interpolation technology is used to interpolate on the constructed full-time and space prediction grid, which can quickly cover the entire study area, including unmonitored areas, and achieve efficient prediction of the spatial distribution of soil acidification. This method is suitable for large-scale and multi-time period farmland soil acidification trend analysis, reducing the time and cost of manual monitoring.
[0074] The present invention can flexibly adjust the parameters and grid resolution of the spatiotemporal model according to the actual situation of the study area, and can incorporate other environmental variables (such as rainfall, vegetation cover, etc.) to further enhance the applicability and accuracy of the model. This high adaptability makes the method have a wide range of application value in different regions and environmental conditions. BRIEF DESCRIPTION OF THE DRAWINGS
[0075] The advantages of the above and additional aspects of the present invention will become apparent and easily understood in the description of the embodiments in conjunction with the following drawings, in which:
[0076] Figure 1 It is a flow chart of a method for constructing spatiotemporal series data of farmland soil acidification and diagnosing trends according to an embodiment of the present invention;
[0077] Figure 2 is a spatiotemporal empirical variation function of the fusion time variation parameter of the method for constructing spatiotemporal series data of farmland soil acidification and trend diagnosis according to an embodiment of the present invention;
[0078] Figure 3 It is a separable and metric spatiotemporal variogram of the fitting of the farmland soil acidification spatiotemporal series data construction and trend diagnosis method according to one embodiment of the present invention;
[0079] Figure 4 It is a schematic diagram of full-space-time observation grid prediction based on space-time Kriging interpolation according to a method for constructing space-time series data and diagnosing trends of farmland soil acidification according to an embodiment of the present invention;
[0080] Figure 5 This is an example diagram of soil acidification significance and sustainability trend identification according to a method for constructing spatiotemporal series data of farmland soil acidification and diagnosing trends in accordance with an embodiment of the present invention. DETAILED DESCRIPTION
[0081] In order to more clearly understand the above-mentioned purpose, features and advantages of the present invention, the present invention is further described in detail below in conjunction with the accompanying drawings and specific embodiments. It should be noted that the embodiments of the present invention and the features in the embodiments can be combined with each other without conflict.
[0082] In the following description, many specific details are set forth to facilitate a full understanding of the present invention. However, the present invention may also be implemented in other ways different from those described herein. Therefore, the protection scope of the present invention is not limited to the specific embodiments disclosed below.
[0083] like Figure 1 As shown, this embodiment provides a method for constructing spatiotemporal series data of farmland soil acidification and diagnosing trends, the method comprising:
[0084] S1. Collect annual farmland soil pH observation data, which includes spatial information, i.e. longitude and latitude or grid index, and timestamp, i.e. year; clean the above data, remove erroneous records and invalid points beyond the study area, and ensure the integrity and accuracy of the data.
[0085] Construct a spatiotemporal sparse grid data framework, unify and integrate spatial and temporal dimensions, and mark missing points to support subsequent interpolation processing.
[0086] Specifically, the first step in the operation of the system is to integrate the scattered soil acidity and alkalinity (pH value) observation data into a set of orderly and easy-to-analyze "skeleton"; in order to achieve this goal, it is first necessary to collect annual soil pH observations from various sources (such as monitoring sites or historical experimental data). These data are usually stored in tabular form, and each record must carry clear spatial location information (such as longitude and latitude) and time stamp (year or date); however, there are often certain problems with the data: some records may be distorted due to collection errors, and some points are repeated. For this reason, it is necessary to use automated programs or manual cleaning to eliminate invalid information and ensure the integrity of the data.
[0087] Then, by constructing a spatiotemporal index, each valid data is accurately located to the corresponding geographical location and time dimension, thus forming a sparse but clear three-dimensional spatiotemporal grid. The construction of this grid lays the foundation for subsequent interpolation analysis, just like finding the border for a puzzle.
[0088] S2. Calculate the spatiotemporal empirical variogram. By introducing spatiotemporal variation parameters and combining the variation characteristics of space and time, calculate the spatiotemporal empirical variogram of soil pH. This step is to understand the changing laws of soil acidification under different spatial and temporal conditions.
[0089] Figure 2 This is a schematic diagram of the spatiotemporal empirical variogram, showing the variation pattern of soil acidification data in time and space. The horizontal axis is the spatial distance h between the observation points in the spatiotemporal empirical variogram. s , the ordinate is the time lag h t The color scale represents the empirical estimate of the spatiotemporal variogram of soil pH. The empirical variogram is a mathematical tool used to describe the similarities or differences between observation points. It reveals the spatial and temporal correlation of data by comparing the variation of soil pH at different locations and times. Figure 2 The variogram curve in the figure reflects how to combine temporal variation characteristics (such as the acidification trend from year to year) with spatial differences (such as the pH value difference between different plots) to build a model. It intuitively presents the spatiotemporal covariance characteristics of the data and is an important basis for building a spatiotemporal variation model.
[0090] When all spatiotemporal data are integrated into the grid, the system needs to reveal the inherent laws of soil acidification in different regions and time points. Assume that the soil pH value is defined in the spatial domain and time domain The Gaussian space-time random field on the n ,t n )∈S×T The observed soil pH sample PH(s n ,t n ), which may include repeated measurements at the same location or simultaneous measurements at different spatial locations.
[0091] In order to describe the correlation between these spatiotemporal sample data, the spatiotemporal covariance function is introduced: For the spatiotemporal random process {PH(s,t):s∈R 2 ,t∈R}, under the assumption of second-order stationarity, the covariance function of the spatiotemporal random field PH(s,t) depends only on the spatial distance h between the two observation points s and time lag h t , and has nothing to do with the specific time and space positions of the two observation points, then the space-time covariance function is:
[0092] C(h s ,h t )=Cov(PH(s+h s ,t+h t ),PH(s,t));
[0093] In order to more intuitively describe the spatiotemporal variability of soil pH, the temporal variation parameters were integrated into the spatial variation model and the spatiotemporal variation function γ(h s ,h t ) measures the degree of difference between random variables:
[0094]
[0095] For the spatiotemporal dataset of soil pH, the empirical estimate of its spatiotemporal covariance can be expressed as:
[0096] μ PH (h s ,h t )][PH(s i ,t i )-μ PH (0,0)];
[0098] Among them, N(h s ,h t ) is to satisfy the spatial offset h s and time lag h t The set of soil pH observation point pairs, is the number of such observation point pairs, PH(s,t) represents the soil pH value measured at location s and time t, μ PH (h s ,h t ) and μ PH (0,0) are the empirical means at the sampling point offset and the origin respectively.
[0099] Similarly, the empirical estimation of the spatiotemporal variogram of soil pH is for:
[0100]
[0101] In order to make the covariance function meaningful, the function C(h s ,h t ) must satisfy the positive definiteness condition, that is, to ensure the non-negative definiteness and invertibility of the covariance matrix. For any real number a i (i=1,…,n) and any space-time point (s i ,t i ) have:
[0102]
[0103] S3. Constructing a spatiotemporal variogram model. This embodiment constructs two main spatiotemporal variogram models: a separable model and a metric model.
[0104] After step S2, the data pattern is initially clarified and the system enters the key modeling stage. Traditional analysis often only focuses on spatial correlation and ignores the important impact of time on data. This system deeply explores the dynamic characteristics of soil acidification by constructing separable models and measurement models. The separable model assumes that spatial and temporal variations are independent, while the measurement model considers the correlation between spatial and temporal variations. Through the optimization of these models, the spatiotemporal variation function can be fitted more accurately.
[0105] In the separable model, the spatiotemporal variation of soil pH is considered to vary independently in space and time. The model decomposes the spatiotemporal variogram into a linear combination of pure spatial variogram and pure temporal variogram; it is assumed that the spatiotemporal covariance function of soil pH can be expressed as the product of the spatial covariance function and the temporal covariance function, that is:
[0106] C sep (h,u)=C s (h)·C t (u);
[0107] Among them, h represents the spatial distance and u represents the time lag, then the corresponding variation function form is:
[0108]
[0109] are standardized spatial and temporal variograms, respectively, with a separable nugget effect, and the joint parameter in the sill is set to 1, and the overall sill is defined by the sill parameter; in R (R is a free software programming language and operating environment, mainly used for statistical analysis, graphics, and data mining), such models can be constructed using the gstat package; first, the parameters of the spatial and temporal variograms (such as partial sills, model types, ranges, and nugget effects) are set separately, then the separable model is specified (stModel = "separable") through the vgmST function, and the empirical variogram is fit using the fit.StVariogram function to optimize the model parameters.
[0110] The metric model assumes that the spatiotemporal variability of soil pH is considered jointly, that is, the spatial and temporal correlations are not completely independent and rely on an anisotropy parameter to adjust the relative contributions of spatial and temporal scales. The metric covariance model extends the two-dimensional geographic space to three-dimensional space-time by introducing an anisotropy parameter (κ) to match the spatial and temporal scales. The spatiotemporal distance is obtained by correcting the spatial distance (h) and the time lag (u) by κ, and the form is as follows:
[0111]
[0112] The corresponding variogram is:
[0113]
[0114] When building a metric model in R language, first define a variogram model (such as Gaussian, spherical, exponential model, etc.) that includes the nugget effect, specify the metric model (stModel = "metric") through the vgmST function, and use the joint variogram and anisotropy parameters as input. Also use the fit.StVariogram function to fit the empirical variogram, optimize the model parameters to minimize the fitting error (such as mean square error MSE) to find the optimal variogram parameters. Select the optimal model by comparing the MSE values or other statistical indicators of different models.
[0115] Figure 3 The complex dynamics of soil acidification trends are described using separable and metric models. Figure 3 It is divided into the separable on the left and the metric on the right. The separable on the left represents the separable model constructed in step S3, and the metric on the right represents the metric model constructed in step S3.
[0116] Figure 3 The horizontal axis on the left side is the spatial distance h between the observation points in the spatiotemporal empirical variogram fitted based on the separable model in step S3. s , the ordinate is the time lag h t ; Figure 3 The horizontal axis on the right side is the spatial distance h between the observation points in the spatiotemporal empirical variogram fitted based on the metric model in step S3. s , the ordinate is the time lag h t ; The color scale represents the empirical estimation of the spatiotemporal variogram of soil pH after fitting different models
[0117] S4. Construction of spatiotemporal prediction grid and Kriging interpolation: By constructing a unified spatiotemporal grid, spatial and temporal data are combined to perform spatiotemporal Kriging interpolation to predict soil acidification in unsampled areas. This step combines error analysis and optimization to ensure the accuracy of the interpolation model.
[0118] like Figure 4As shown in the figure, through the optimized model, the system extends the prediction tentacles to the entire study area, covering both monitored plots and areas with missing data. This step is similar to connecting sparse point data into a surface, mapping each plot and time point onto a virtual map. To achieve this goal, the system first divides the spatial grid according to the geographical characteristics of the study area, and sets the prediction time interval according to the time span. Subsequently, these spatial grids and time intervals are integrated into a complete spatiotemporal prediction grid. At each point in the grid, the system performs interpolation calculations based on the degree of influence of the surrounding data points; ultimately, the complete spatiotemporal prediction grid shows the soil acidification status of the entire area and its evolution trajectory over time.
[0119] The full spatiotemporal observation grid (STF) takes into account both spatial and temporal dimensions. In terms of spatial grids, first determine a unified spatial reference system (such as WGS84 geographic coordinate system / Krasovsky projection coordinate system), divide the spatial grid according to the size of the study area and the required accuracy, and determine the resolution of the grid to generate SpatialPixelsDataFrame pixel points, where each column corresponds to different longitude and latitude spatial features, so that each pixel point can be accurately located in space, and each point represents a potential farmland soil pH observation data. In terms of temporal grids, determine the time range in the time dimension, and divide this period of time evenly into several time periods combined with data accuracy, each time period represents a prediction time point. Then combine the spatial grid and the temporal grid to create a spatiotemporal prediction grid (STF). Each grid point corresponds to a specific spatial location and time point for subsequent spatiotemporal Kriging interpolation prediction.
[0120] Using the fitted optimal spatiotemporal variogram model, the krigeST function is called on the constructed full spatiotemporal observation grid (STF) for spatiotemporal kriging interpolation to predict the spatial distribution of farmland soil acidification and its changing trend over time. Specifically, for any point (s0, t0) on the STF grid, the spatiotemporal kriging interpolation prediction value of the soil pH value PH(s0, t0) can be given by the following formula:
[0121]
[0122] Where: PH(s i ,t i ) is the pH observation value at the soil sampling point, PH(s0,t0) is the estimated value at the time and space point (s0,t0); n is the number of observation points involved in the prediction, λ i is the neighboring observation value PH(s i ,t i ), μ is the weight coefficient of the introduced Lagrangian coefficient. iIt is necessary to solve the weight coefficients to ensure that the variance of the prediction error is minimized and the unbiased condition is met. This is usually transformed into solving the following optimization problem: At the same time, the unbiasedness condition is satisfied: The Lagrangian function can be constructed as follows:
[0123]
[0124] Let L(λ i ,μ) vs.λ i Find the partial derivative of μ and set it to 0, thus solving the weight coefficient λ i .
[0125] After the interpolation is completed, the spatiotemporal kriging interpolation results need to be evaluated based on the parameters. Based on the evaluation results, we need to verify the model and optimize the debugging parameters as needed to improve the prediction performance of the model. The following are some specific steps: First, model verification: Check whether the model meets the unbiased condition, that is, whether the average value of the predicted value is close to the average value of the observed value. Analyze the error distribution and check whether there are systematic deviations or outliers. Evaluate the stability and consistency of the model to ensure that reasonable prediction results can be obtained on different data subsets or time points. Second, adjust and optimize the spatiotemporal empirical variogram parameters: According to the evaluation results and prior knowledge, adjust the parameters of the spatiotemporal variogram such as the partial sill, range, and nugget to improve the model's fit and prediction accuracy. Third, explore different model types: try different spatiotemporal variogram models (such as separable models, metric models, etc.), compare their differences in prediction performance, and select the model that best suits the current data. Fourth, consider covariates: If the data contains other covariates that may be related to soil pH (such as soil type, rainfall, vegetation cover, etc.), they can be included in the model as part of fixed effects or random effects to improve the explanatory power and prediction accuracy of the model. Fifth, iterative optimization: Compare and analyze the new prediction results based on the preliminary evaluation results and the parameter optimization and debugging to determine whether the optimization is effective. By comparing the prediction results with the data of known observation points, the accuracy and reliability of spatiotemporal Kriging interpolation are evaluated, including the calculation of statistical indicators such as mean square error (MSE). If necessary, the above steps can be repeated for multiple iterative optimizations until satisfactory prediction performance is achieved.
[0126] S5. Soil acidification trend analysis: Based on the Theil-Sen Median trend analysis of time series raster images and the non-parametric Mann-Kendall test, a soil acidification trend identification model was established to evaluate the significance of farmland soil acidification trends.
[0127] It is not enough to just map the spatial distribution of soil acidification. The system further analyzes whether these changes are meaningful and whether there is a persistent trend. Two tools are introduced here: one is the Theil-Sen trend analysis method, which is used to calculate the slope of the change of pH value over time at each grid point; the other is the Mann-Kendall test, which is used to evaluate whether these trends are significant.
[0128] Theil-Sen Median trend analysis combined with the Mann-Kendall test method provides an effective and robust nonparametric statistical method for identifying trends in soil pH acidification. Theil-Sen Median evaluates trends by calculating the median slope, while Mann-Kendall is used to verify the significance of this trend. The formula is as follows:
[0129]
[0130] S PH is the median slope calculated by the Theil-Sen Median trend analysis method, which is used to evaluate the trend of the soil pH time series. PH When it is >0, it indicates that the soil pH value is acidifying; otherwise, it indicates that the soil pH value is tending to alkalinize.
[0131] Define the statistic S:
[0132]
[0133] Among them, the symbolic function sgn is defined as:
[0134]
[0135] Among them, pH i and pH j represent the soil pH values in the i-th year and the j-th year respectively, and n represents the length of the time series. Under a given significance level α (α=0.05), when |Z|>u 1-α / 2 , it indicates that there is a significant change trend in the soil pH time series at the α level.
[0136] S6. Identification of the sustainability of soil acidification: A soil acidification sustainability identification model is constructed through the Hurst index to analyze the sustainability of soil acidification trends, evaluate the sustainability or anti-sustainability trend of soil acidification in the future, and provide a basis for soil improvement and management.
[0137] After analyzing the trends, the system can also predict whether these changes will continue or reverse. This assessment is based on a mathematical tool called the Hurst exponent, whose core idea is to measure the long-term correlation of data. Through this assessment, the system can not only identify which plots require long-term attention for acidification but also provide alerts for potential risk areas.
[0138] The Hurst exponent is used to evaluate the long-range dependence of time series. The Hurst exponent can be used to evaluate the persistent trend characteristics of predicting future soil pH value changes. The calculation method is as follows:
[0139]
[0140] Where, is the mean time series of pH values, X(t,τ) is the cumulative deviation of pH values, R(τ) is the range, S(τ) is the standard deviation. If there is a relationship R(τ) / S(τ)∝τ H (where H is the Hurst exponent), it indicates that there is a Hurst phenomenon in the soil pH value time series. When 0.5 < H < 1, it indicates that the soil pH value time series has persistence, that is, the trend of soil acidification (or alkalization) may continue in the future, and the closer H is to 1, the stronger this persistence. When H = 0.5, it means that the soil pH value time series is random and there is no long-term correlation, that is, the change of soil pH value is unpredictable. When 0 < H < 0.5, it indicates that the soil pH value time series has anti-persistence, that is, the trend of soil acidification (or alkalization) may be opposite to the past in the future, and the closer H is to 0, the stronger this anti-persistence.
[0141] As Figure 5 shown, the observed data of farmland soil pH values in a certain area and a certain period are used for actual analysis. Finally, the Hurst exponents of each block are obtained, and the values are segmented and marked with different colors on the map to visually display the diagnostic results.
[0142] Figure 5 (a) is the Theil-Sen Median trend result in step S5, that is, the Theil-Sen Median trend based on the time series raster image from 2009 to 2020 for 12 years. When S PH > 0, it indicates that the soil pH value shows an acidification trend; otherwise, it indicates that the soil pH value tends to alkalization.
[0143] Figure 5 (b) is the result after verifying the significance of this trend by Mann-Kendall in step S5. At a given significance level α (α = 0.05), when |Z| > u 1-α / 2When , it means that there is a significant change trend in the soil pH time series at the α level. (It distinguishes between extremely significant, significant, relatively significant, not significant, no change, etc.).
[0144] Figure 5 (c) is the classification result of the Hurst index value in the continuous trend characteristic of the future soil pH change predicted by the Hurst index evaluation in step S6.
[0145] Figure 5 (d) is the type zone divided based on the judgment criteria of the Hurst index value in step S6 (wherein strong persistent acidification, weak persistent acidification, reverse persistent acidification, etc. are distinguished).
[0146] This system uses multi-level and multi-dimensional technical means to transform scattered and discrete soil acidification data into complete and visual trend analysis charts and forecast reports. This integrated and innovative method not only solves the blind spots in traditional monitoring, but also provides a reliable basis for agricultural management, policy formulation and ecological protection.
[0147] In summary, the present invention proposes a method for constructing and diagnosing farmland soil acidification spatiotemporal series data, including:
[0148] S1. Data collection and preprocessing: Collect annual farmland soil pH observation data, including spatial information and timestamps; clean the data, remove erroneous records and invalid points beyond the study area, and ensure the integrity and accuracy of the data; construct a spatiotemporal sparse grid data framework to unify and integrate spatial and temporal dimensions.
[0149] S2. Calculate the spatiotemporal empirical variation function: Introduce spatiotemporal variation parameters, and calculate the spatiotemporal empirical variation function of soil pH value by combining the variation characteristics of space and time, revealing the changing law of soil acidification under different space and time conditions.
[0150] S3. Construct a spatiotemporal variogram model: construct a separable model and a metric model, optimize the parameters of the two models, and fit the spatiotemporal variogram more accurately.
[0151] S4. Space-time Kriging interpolation and prediction: Build a unified space-time grid, combine spatial and temporal data, and make predictions based on space-time Kriging interpolation; generate a full space-time observation grid to predict the spatial distribution of farmland soil acidification and its changing trend over time.
[0152] S5. Trend analysis: Based on the Theil-Sen Median trend analysis of time series raster images and the non-parametric Mann-Kendall test, a soil acidification trend identification model was established to evaluate the significance of farmland soil acidification trends.
[0153] S6. Sustainability identification: Use the Hurst index to analyze the sustainability of soil acidification trends and provide a basis for future soil improvement and management.
[0154] The steps in the present invention can be adjusted in order, combined or deleted according to actual needs.
[0155] The units in the device of the present invention can be combined, divided and deleted according to actual needs.
[0156] Although the present invention is disclosed in detail with reference to the accompanying drawings, it should be understood that these descriptions are merely exemplary and are not intended to limit the application of the present invention. The scope of protection of the present invention is defined by the appended claims and may include various modifications, alterations and equivalents made to the invention without departing from the scope and spirit of the present invention.
Claims
1. A method for constructing and diagnosing farmland soil acidification spatiotemporal series data, characterized in that: The method comprises: S1. Data collection and preprocessing: Collect annual farmland soil pH observation data, including spatial information and timestamps; clean the data, remove erroneous records and invalid points beyond the study area; construct a spatiotemporal sparse grid data framework, input the cleaned data into the spatiotemporal sparse grid data framework, and unify the spatial and temporal dimensions; S2. Calculate the spatiotemporal empirical variogram based on the collected data: Calculate the spatiotemporal variogram and empirical estimate of soil pH value separately, and put them together to form the spatiotemporal empirical variogram to quantify the variation of soil pH value under different spatial and temporal conditions; S3. Constructing a spatiotemporal variogram model to fit the spatiotemporal variogram: Based on the calculation results of the spatiotemporal variogram, a separable model and a metric model are systematically constructed to model the spatiotemporal changes of soil acidification, and the parameters of the two models are continuously optimized to fit a more accurate spatiotemporal variogram; S4. Spatiotemporal prediction through spatiotemporal kriging interpolation: Construct a unified spatiotemporal grid, combine the spatial and temporal information in the farmland soil pH observation data, and predict the farmland soil pH value based on spatiotemporal kriging interpolation; generate a full spatiotemporal observation grid to predict the spatial distribution of farmland soil acidification and its changing trend over time; S5. Soil acidification trend analysis: Based on the collected data, a soil acidification trend identification model was established through the Theil-Sen Median trend analysis of time series raster images and the non-parametric Mann-Kendall test to evaluate the significance of farmland soil acidification trends; S6. Sustainability identification: Use the Hurst index to analyze the sustainability of soil acidification trends and provide a basis for future soil improvement and management.
2. The method for constructing and diagnosing farmland soil acidification spatiotemporal series data according to claim 1, characterized in that: The specific process of calculating the spatiotemporal empirical variogram in step S2 includes: Assume that soil pH is defined in the spatial domain and time domain The Gaussian space-time random field on the n ,t n )∈S×T The observed soil pH sample PH(s n ,t n ), which may include repeated measurements at the same location or simultaneous measurements at different spatial locations; Introducing the space-time covariance function: For the space-time random process {PH(s,t):s∈R 2 ,t∈R}, under the assumption of second-order stationarity, the covariance function of the spatiotemporal random field PH(s,t) depends only on the spatial distance h between the two observation points s and time lag h t , and has nothing to do with the specific time and space positions of the two observation points, then the space-time covariance function is: C(h s ,h t )=Cov(PH(s+h s ,t+h t ),PH(s,t)); In order to more intuitively describe the spatiotemporal variability of soil pH, the temporal variation parameters were integrated into the spatial variation model and the spatiotemporal variation function γ(h s ,h t ) measures the degree of difference between random variables: For the spatiotemporal dataset of soil pH, the empirical estimate of its spatiotemporal covariance can be expressed as: Among them, N(h s ,h t ) is to satisfy the spatial offset h s and time lag h t The set of soil pH observation point pairs, is the number of such observation point pairs, PH(s,t) represents the soil pH value measured at location s and time t, μ PH (h s ,h t ) and μ PH (0,0) are the empirical means at the sampling point offset and the origin respectively; Similarly, the empirical estimation of the spatiotemporal variogram of soil pH is for: In order to make the covariance function meaningful, the function C(h s ,h t ) must satisfy the positive definiteness condition, that is, to ensure the non-negative definiteness and invertibility of the covariance matrix. For any real number a i (i=1,…,n) and any space-time point (s i ,t i ) have: The above-mentioned spatiotemporal variation function γ(h s ,h t ) and empirical estimates Construct the spatiotemporal empirical variation function.
3. The method for constructing and diagnosing farmland soil acidification spatiotemporal series data according to claim 1, characterized in that: The specific process of constructing the spatiotemporal variogram model in step S3 includes: constructing a separable model and a measurement model; In the separable model, the spatiotemporal covariance function of soil pH can be expressed as the product of the spatial covariance function and the temporal covariance function, that is: C sep (h,u)=C s (h)·C t (u); Among them, h represents the spatial distance and u represents the time lag, then the corresponding variation function form is: are standardized spatial and temporal variograms, with separated nugget effects, and the joint parameter in the sill is set to 1, and the overall sill is defined by the sill parameter; in R, such a model can be constructed using the gstat package; first, the parameters of the spatial and temporal variograms are set separately, then the separable model is specified by the vgmST function, and the empirical variogram is fitted using the fit.StVariogram function to optimize the model parameters; The metric model expands the two-dimensional geographic space to three-dimensional space-time, and introduces an anisotropy parameter (κ) to match the spatial and temporal scales. The space-time distance is obtained by correcting the spatial distance (h) and the time lag (u) by κ, as follows: The corresponding variogram is: When building a metric model in R language, first define a variogram model that includes the nugget effect, specify the metric model through the vgmST function, and use the joint variogram and anisotropy parameters as input. Also use the fit.StVariogram function to fit the empirical variogram, optimize the model parameters to minimize the fitting error, and find the optimal variogram parameters; select the optimal model by comparing the MSE values or other statistical indicators of different models.
4. The method for constructing and diagnosing farmland soil acidification spatiotemporal series data according to claim 1, characterized in that: The process of predicting soil pH value by spatiotemporal Kriging interpolation in step S4 includes: Construct a spatiotemporal observation grid, which includes a spatial grid and a temporal grid. In terms of the spatial grid, a unified spatial reference system is determined. According to the size of the study area and the required accuracy, the spatial grid is divided, and the resolution of the grid is determined to generate SpatialPixelsDataFrame pixel points. Each point represents a potential farmland soil pH value observation data. In terms of the temporal grid, the time range is determined in the time dimension, and this period is evenly divided into several time periods in combination with the data accuracy. Each time period represents a prediction time point. Combine the spatial grid and the temporal grid to create a spatiotemporal prediction grid. Each grid point corresponds to a specific spatial position and time point. Using the optimal spatiotemporal variogram model fitted in step S3, the krigeST function is called on the constructed full spatiotemporal observation grid to perform spatiotemporal Kriging interpolation to predict the spatial distribution of farmland soil acidification and its changing trend over time. For any point (s0, t0) on the STF grid, the spatiotemporal Kriging interpolation prediction value of the soil pH value PH(s0, t0) can be given by the following formula: Where: PH(s i ,t i ) is the pH observation value at the soil sampling point, PH(s0,t0) is the estimated value at the time and space point (s0,t0); n is the number of observation points involved in the prediction, λ i is the neighboring observation value PH(s i ,t i ), μ is the weight coefficient of the introduced Lagrangian coefficient; where λ i It is necessary to ensure that the variance of the prediction error is minimized and the unbiased condition is met by solving the weight coefficient, which is usually transformed into solving the following optimization problem: At the same time, the unbiasedness condition is satisfied: The Lagrangian function can be constructed as follows: Let L(λ i ,μ) vs.λ i Find the partial derivative of μ and set it to 0, thus solving the weight coefficient λ i ; After the interpolation is completed, the spatiotemporal Kriging interpolation results need to be evaluated based on the parameters. Based on the evaluation results, the model needs to be verified and the parameters need to be optimized and debugged as needed to improve the prediction performance of the model.
5. The method for constructing and diagnosing the spatiotemporal sequence data of farmland soil acidification according to claim 4, characterized in that: The step S4 also includes: after the interpolation is completed, the following steps need to be performed: Model validation: Check whether the model meets the unbiased condition, that is, whether the average value of the predicted value is close to the average value of the observed value, analyze the error distribution, check whether there are systematic deviations or outliers, evaluate the stability and consistency of the model, and ensure that reasonable prediction results can be obtained on different data subsets or time points; Adjust and optimize the parameters of the spatiotemporal empirical variogram: According to the evaluation results and prior knowledge, adjust the parameters of the spatiotemporal variogram to improve the model's fit and prediction accuracy; Explore different model types: try different spatiotemporal variogram models, compare their differences in predictive performance, and choose the model that best suits the current data; Consider covariates: If the data contain other covariates that may be associated with soil pH, include them in the model as fixed effects or as part of random effects to improve the explanatory power and prediction accuracy of the model; Iterative optimization: Compare and analyze the preliminary evaluation results and the new prediction results after parameter optimization and debugging to determine whether the optimization is effective. By comparing the prediction results with the data of known observation points, the accuracy and reliability of spatiotemporal Kriging interpolation are evaluated. Repeat the above steps for multiple iterations of optimization until satisfactory prediction performance is achieved.
6. The method for constructing and diagnosing farmland soil acidification spatiotemporal series data according to claim 1, characterized in that: The soil acidification trend identification model established in step S5 is: S PH is the median slope calculated by the Theil-Sen Median trend analysis method, which is used to evaluate the trend of the soil pH time series. PH When it is >0, it indicates that the soil pH value is acidifying; On the contrary, it indicates that the soil pH value tends to be alkaline; Define the statistic S: Among them, the symbolic function sgn is defined as: Among them, pH i and pH j represent the soil pH values in the i-th and j-th years, respectively, and n represents the length of the time series; At a given significance level α, α = 0.05, when |Z|>u 1-α / 2 , it indicates that there is a significant change trend in the soil pH time series at the α level.
7. The method for constructing and diagnosing farmland soil acidification spatiotemporal series data according to claim 1, characterized in that: The specific contents of analyzing the sustainability of soil acidification trend using the Hurst index in step S6 include: The Hurst index is calculated as follows: in, is the mean time series of pH value, X(t,τ) is the cumulative deviation of pH value, R(τ) is the range, S(τ) is the standard deviation, H is the Hurst index, if there is a relationship R(τ) / S(τ)∝τ H , it indicates that the soil pH time series has the Hurst phenomenon; When 0.5 < H < 1, it indicates that the time series of soil pH value has persistence, that is, the trend of soil acidification / alkalization may continue in the future, and the closer H is to 1, the stronger this persistence is; When H = 0.5, it indicates that the time series of soil pH value is random and there is no long-term correlation, that is, the change of soil pH value is unpredictable; When 0 < H < 0.5, it indicates that the time series of soil pH value has anti-persistence, that is, the trend of soil acidification / alkalization may be opposite to the past in the future, and the closer H is to 0, the stronger this anti-persistence is.
Citation Information
Patent Citations
Soil organic carbon spatial sampling network design method giving consideration to non-stationary characteristic of spatial-temporal distribution
CN106227965A
Variation function model optimization method in forest site index spatial-temporal estimation
CN106372277A
Comprehensive analysis method for spatial and temporal distribution of environment variables
CN107610021A
In-land irrigation method based on spatial and temporal distribution of potato roots
CN115968760A
Soil cadmium risk prediction method based on spatial-temporal interaction relationship
WO2023168781A1
Cited By
Progressive soil acidity and alkalinity regulation and control method and system using dilute sulfuric acid solution
CN120226499A
Wind speed interpolation prediction method based on function type space variable coefficient model
CN120316491A
Soil trace element dynamic monitoring method and system for land reclamation
CN120338201A