Road slope calculation method and device, equipment, storage medium and product

By acquiring historical slope data and calculating projection matrix, the problem of environmental noise and cumulative errors when directly measuring road slope data is solved, and more accurate road slope data calculation is achieved.

CN119573669APending Publication Date: 2025-03-07SHANXI ELECTRIC POWER CONSTR CO LTD (CEEC)
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202411661459.6
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-11-20
Publication Date
2025-03-07

AI Technical Summary

Technical Problem

The road slope data obtained by direct measurement is susceptible to environmental noise and cumulative errors, and accurate road slope data cannot be obtained.

Method used

By obtaining historical slope measurement data, the projection matrix of the previous moment is calculated, and the slope estimate value of the current moment is calculated based on the slope measurement data and projection matrix of the current moment is calculated.

Benefits of technology

By considering historical data, the impact of environmental noise and cumulative errors is reduced, and the accuracy of road slope data is improved.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119573669A_ABST
    Figure CN119573669A_ABST
Patent Text Reader

Abstract

The invention discloses a road slope calculation method and device, equipment, a storage medium and a product, and relates to the technical field of road detection, the road slope calculation method comprises the following steps: obtaining historical slope measurement data, the historical slope measurement data being historical data in a preset time period from the current moment; based on the historical gradient measurement data, a projection matrix at the previous moment is obtained through calculation; and receiving gradient measurement data at the current moment, and calculating to obtain a gradient estimation value at the current moment based on the gradient measurement data and the projection matrix. The accuracy of the road slope calculation result is improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of road detection technology, and in particular to a road slope calculation method, device, equipment, storage medium and computer program product. Background Art

[0002] The pitch angle of a road is also called the slope of a road. Calculating the pitch angle of a road surface is very important for road design, construction, maintenance, traffic safety and other aspects. Therefore, it is necessary to accurately measure the pitch angle of the road. In related technologies, the pitch angle is generally measured by an inertial sensor. Since the pitch angle of a road surface is usually not abrupt, its change needs to go through a certain gradual process. The slope data obtained by direct measurement is easily affected by environmental noise and cumulative errors. Therefore, accurate road slope data cannot be obtained.

[0003] The above contents are only used to assist in understanding the technical solution of the present application and do not constitute an admission that the above contents are prior art. Summary of the invention

[0004] The main purpose of this application is to provide a road slope calculation method, device, equipment, storage medium and computer program product, aiming to solve the technical problem in the related art that the slope data directly measured is easily affected by environmental noise and cumulative errors, and accurate road slope data cannot be obtained.

[0005] To achieve the above purpose, the present application proposes a road slope calculation method, which includes:

[0006] Acquire historical slope measurement data, where the historical slope measurement data is historical data for a preset time period from the current moment;

[0007] Based on the historical slope measurement data, a projection matrix at the previous moment is calculated;

[0008] The slope measurement data at the current moment is received, and based on the slope measurement data and the projection matrix, an estimated slope value at the current moment is calculated.

[0009] In one embodiment, the step of calculating the projection matrix at the previous moment based on the historical slope measurement data includes:

[0010] Obtaining filter coefficients and a preset data matrix in a preset filter;

[0011] Based on the filter coefficients and the preset data matrix, an estimated value vector is calculated;

[0012] Based on the estimated value vector and the historical slope measurement data, the projection matrix at the last moment is calculated.

[0013] In one embodiment, the step of calculating the slope estimation value at the current moment based on the slope measurement data and the projection matrix includes:

[0014] Based on the slope measurement data, updating the projection matrix to obtain an updated projection matrix;

[0015] Based on the updated projection matrix and the slope measurement data, the slope estimation value at the current moment is calculated, wherein the calculation formula of the slope estimation value is as follows:

[0016]

[0017] in, Represents the estimated slope value at the current moment, P X,x(n+1) represents the updated projection matrix, and x(n+1) represents the slope measurement data at the current moment.

[0018] In one embodiment, the step of updating the projection matrix based on the slope measurement data to obtain an updated projection matrix includes:

[0019] Determine an orthogonal projection matrix corresponding to the projection matrix;

[0020] Based on the orthogonal projection matrix, the projection matrix and the slope measurement data, an updated projection matrix is ​​calculated, wherein the calculation formula of the updated projection matrix is ​​as follows:

[0021] P X,x(n+1) =P(n)+P ⊥ (n)x(n+1) <P ⊥ (n)x(n+1),P ⊥ (n)x(n+1)> -1 x T (n+1)P ⊥ (n)

[0022] Among them, x(n+1) represents the slope measurement data at the current moment, p(n) represents the projection matrix at the previous moment, and P ⊥ (n) represents the orthogonal projection matrix, P X,x(n+1) Represents the updated projection matrix.

[0023] In one embodiment, after the step of calculating the projection matrix at the previous moment based on the historical slope measurement data, the method further includes:

[0024] Based on the historical slope measurement data and the orthogonal projection matrix, an error vector at the last moment is calculated, wherein the error vector is used to characterize the error value between the slope estimation value and the actual data.

[0025] In one embodiment, after the step of calculating the slope estimation value at the current moment based on the slope measurement data and the projection matrix, the method further includes:

[0026] Determine a first orthogonal matrix corresponding to the updated projection matrix;

[0027] Based on the first orthogonal matrix and the slope measurement data, the error vector at the current moment is calculated, wherein the calculation formula of the error vector at the current moment is as follows:

[0028] e m (n+1)=P ⊥ X,x(n+1) x(n+1)

[0029] Among them, e m (n+1) represents the error vector at the current moment, P ⊥ X,x(n+1) represents a first orthogonal matrix, wherein the first orthogonal matrix represents an updated orthogonal projection matrix, and x(n+1) represents the slope measurement data at the current moment.

[0030] In addition, to achieve the above purpose, the present application also proposes a road slope calculation device, the road slope calculation device comprising:

[0031] An acquisition module, used to acquire historical slope measurement data, wherein the historical slope measurement data is historical data of a preset time period from the current moment;

[0032] A first calculation module, used for calculating the projection matrix at the last moment based on the historical slope measurement data;

[0033] The receiving module is used to receive the slope measurement data at the current moment, and calculate the slope estimation value at the current moment based on the slope measurement data and the projection matrix.

[0034] In addition, to achieve the above-mentioned purpose, the present application also proposes a road slope calculation device, which includes: a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the computer program is configured to implement the steps of the road slope calculation method described above.

[0035] In addition, to achieve the above-mentioned purpose, the present application also proposes a storage medium, which is a computer-readable storage medium, and a computer program is stored on the storage medium. When the computer program is executed by a processor, the steps of the road slope calculation method described above are implemented.

[0036] In addition, to achieve the above-mentioned purpose, the present application also provides a computer program product, which includes a computer program, and when the computer program is executed by a processor, the steps of the road slope calculation method described above are implemented.

[0037] The present application proposes a road slope calculation method, device, equipment, storage medium and computer program product. The present application obtains historical slope measurement data to calculate the projection matrix of the previous moment, and receives the slope measurement data of the current moment, and calculates the slope estimation value of the current moment through the slope measurement data and the projection matrix. Since the historical slope measurement data is historical data far away from the current moment, and the slope estimation value is calculated through the slope measurement data and the projection matrix corresponding to the historical slope measurement data, the slope estimation value includes historical data of a preset time period from the current moment, which can play a role in the data prediction at the current moment, making the calculation result more accurate, and thus obtaining accurate road slope data. BRIEF DESCRIPTION OF THE DRAWINGS

[0038] The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the present application and, together with the description, serve to explain the principles of the present application.

[0039] In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, for ordinary technicians in this field, other drawings can be obtained based on these drawings without paying any creative labor.

[0040] Figure 1 A schematic diagram of a flow chart provided for the first embodiment of the method for calculating the road slope of the present application;

[0041] Figure 2 A schematic diagram of a flow chart provided for the second embodiment of the method for calculating the road slope of the present application;

[0042] Figure 3 A schematic diagram of the overall implementation process of the road slope calculation method of this application;

[0043] Figure 4 This is a schematic diagram of the module structure of the road slope calculation device according to an embodiment of the present application;

[0044] Figure 5 Schematic diagram of the device structure of the hardware operating environment involved in the road slope calculation method in the embodiment of the present application.

[0045] The purpose, features and advantages of this application will be further described in conjunction with the embodiments and with reference to the accompanying drawings. DETAILED DESCRIPTION

[0046] It should be understood that the specific embodiments described herein are only used to explain the technical solutions of the present application and are not used to limit the present application.

[0047] In order to better understand the technical solution of the present application, a detailed description will be given below in conjunction with the accompanying drawings and specific implementation methods.

[0048] The main solutions of the embodiments of this application are:

[0049] Acquire historical slope measurement data, where the historical slope measurement data is historical data for a preset time period from the current moment;

[0050] Based on the historical slope measurement data, a projection matrix at the previous moment is calculated;

[0051] The slope measurement data at the current moment is received, and based on the slope measurement data and the projection matrix, an estimated slope value at the current moment is calculated.

[0052] In the prior art, pitch angle measurement is generally performed through inertial sensors. Since the pitch angle of a road surface is usually not abrupt, but needs to undergo a gradual change over a certain process, the slope data obtained by direct measurement is easily affected by environmental noise and cumulative errors. Therefore, accurate road slope data cannot be obtained.

[0053] The present application proposes a road slope calculation method, device, equipment, storage medium and computer program product. The present application obtains historical slope measurement data to calculate the projection matrix of the previous moment, and receives the slope measurement data of the current moment, and calculates the slope estimation value of the current moment through the slope measurement data and the projection matrix. Since the historical slope measurement data is historical data far away from the current moment, and the slope estimation value is calculated through the slope measurement data and the projection matrix corresponding to the historical slope measurement data, the slope estimation value includes historical data far away from the current moment, which can play a role in the data prediction of the current moment, making the calculated result more accurate, and accurate road pitch angle data can be obtained.

[0054] It should be noted that the execution subject of this embodiment can be a computing service device with data processing, network communication and program running functions, such as a tablet computer, a personal computer, a mobile phone, etc., or an electronic device capable of realizing the above functions, a road slope calculation device, etc. The following takes the road slope calculation device as an example to illustrate this embodiment and the following embodiments.

[0055] Based on this, the present application embodiment provides a method for calculating the road slope. Figure 1 , Figure 1This is a flow chart of the first embodiment of the road slope calculation method of the present application.

[0056] In this embodiment, the road slope calculation method includes steps S10 to S40:

[0057] Step S10, obtaining historical slope measurement data, wherein the historical slope measurement data is historical data of a preset time period from the current moment;

[0058] It should be noted that the historical slope measurement data can be the slope data measured from the 1st moment to the nth moment in the historical time period, and the historical slope measurement data includes historical data that is far away from the current moment. The preset time period can be 1 hour or one day, etc., without specific limitation. In the subsequent calculation of the estimated value of the slope, it is mainly to make the obtained slope estimate take into account the influence of data that is far away from the current time period, so that the prediction or calculation of the estimated value is more accurate.

[0059] It should be noted that the historical slope measurement data is the slope data measured from the historical preset time period to the current time point. For example, if the current time is the N+1th moment, the historical wind speed measurement data is d(1), d(2)...d(n+1).

[0060] Step S20, calculating the projection matrix at the last moment based on the historical slope measurement data;

[0061] It should be noted that the projection matrix is ​​used to represent the sensor estimation vector It is the projection of the sensor measurement value vector x on the subspace spanned by the preset data matrix X. The calculated projection matrix is ​​added to the data calculation at the next moment to increase the accuracy of the calculation result.

[0062] In a feasible implementation manner, the step S20 of calculating the projection matrix at the previous moment based on the historical slope measurement data includes:

[0063] Obtaining filter coefficients and a preset data matrix in a preset filter;

[0064] It should be noted that the preset filter is an estimated value filter of the true value, hereinafter referred to as the estimated value filter or the filter

[0065] Where w i (n), i = 1, 2, ..., m represents the estimated value filter coefficient at the nth time. When m is used, the maximum value of m can be all sampling moments. That is, assuming that sampling starts at a certain moment, at the nth moment, a total of n sampling values ​​of the sensor are obtained, then the maximum value of m can be n. In normal use, m is not limited to n, and can be less than or equal to n.

[0066] It should be noted that the preset data matrix can be expressed as the following formula:

[0067]

[0068] Define the data matrix as:

[0069] Abbreviated as X.

[0070] The filter coefficients of the estimated value filter are:

[0071] Abbreviated as w m .

[0072] Estimate vector Abbreviated as

[0073] Based on the above definition, the matrix form of the preset filter can be written as: Here w m For the estimated filter coefficient vector, the least squares estimation method is used to obtain w m =(X T X) -1 X T x(n), where is the sensor measurement vector, abbreviated as x.

[0074] Based on the filter coefficients and the preset data matrix, an estimated value vector is calculated;

[0075] It should be noted that the estimated value vector can be calculated as follows:

[0076]

[0077] Among them, X is the preset data matrix, w m is the filter coefficient, and by multiplying the two, we get the estimated value vector.

[0078] Based on the estimated value vector and the historical slope measurement data, the projection matrix at the last moment is calculated.

[0079] It should be noted that the steps for calculating the projection matrix at the previous moment can be:

[0080]

[0081] Where P(n)=X(X T X) -1 X T , where P(n) is the projection matrix of the data matrix X, and its physical meaning is: the sensor estimated value vector It is the projection of the sensor measurement vector x on the subspace spanned by the data matrix X.

[0082] In a feasible implementation manner, after the step S20 of calculating the projection matrix at the previous moment based on the historical slope measurement data, the following step is further included:

[0083] Based on the historical slope measurement data and the orthogonal projection matrix, an error vector at the last moment is calculated, wherein the error vector is used to characterize the error value between the slope estimation value and the actual data.

[0084] It should be noted that the error vector is: according to and the definition of orthogonal projection, we get e m =P ⊥ (n)x(n), the error vector e of the sensor estimate vector m It is the orthogonal projection of the sensor measurement value vector x on the subspace spanned by the preset data matrix X.

[0085] It should be noted that when the projection matrix is ​​calculated, the orthogonal projection matrix can also be determined. The error vector is the product of the historical slope measurement data and the orthogonal projection matrix. The calculation of the error vector is used to indicate the accuracy of the slope estimate. While improving the accuracy of the estimate, it provides a reference to reduce the error of the calculation result.

[0086] Step S30, receiving the slope measurement data at the current moment, and calculating the slope estimation value at the current moment based on the slope measurement data and the projection matrix.

[0087] It should be noted that the slope measurement data at the current moment may be the slope measurement data at the n+1th moment. In the slope estimation value calculation formula at the current moment, the projection matrix must be updated first, and then the updated projection matrix and the slope measurement data at the current moment are used for calculation to obtain the slope estimation value.

[0088] In a feasible implementation manner, the step S30 of calculating the slope estimation value at the current moment based on the slope measurement data and the projection matrix includes:

[0089] Based on the slope measurement data, updating the projection matrix to obtain an updated projection matrix;

[0090] It should be noted that at the new moment, that is, the n+1th moment, the sensor measurement value vector is x(n+1), then x(n+1) and X form a new data space, and the updated projection matrix is ​​expressed as:

[0091] P X,x(n+1) =P(n)+P x(n+1)

[0092] Where P(n) is the projection matrix of the original data space. Since the introduction of the new sensor measurement value vector x(n+1) brings changes to the original data space, the projection matrix needs to be changed accordingly. Except for the part that can be linearly represented by the original projection matrix, the remaining part cannot be linearly represented by the original projection matrix, which is recorded as P x(n+1) , which is orthogonal to P(n), so the matrix product is a zero matrix, that is, P(n)P x(n+1) =0

[0093] Based on the updated projection matrix and the slope measurement data, the slope estimation value at the current moment is calculated, wherein the calculation formula of the slope estimation value is as follows:

[0094]

[0095] in, Represents the estimated slope value at the current moment, P X,x(n+1) represents the updated projection matrix, and x(n+1) represents the slope measurement data at the current moment.

[0096] It should be noted that, according to the updated projection matrix and orthogonal projection matrix obtained above, the sensor estimation value vector at the n+1th moment can be obtained: That is, at the n+1th moment, the updated projection matrix is ​​multiplied by the sensor measurement value vector x(n+1).

[0097] In a feasible implementation manner, the step of updating the projection matrix based on the slope measurement data to obtain an updated projection matrix includes:

[0098] Determine an orthogonal projection matrix corresponding to the projection matrix;

[0099] It should be noted that after the projection matrix is ​​determined, the orthogonal projection matrix can also be obtained by calculation.

[0100] Based on the orthogonal projection matrix, the projection matrix and the slope measurement data, an updated projection matrix is ​​calculated, wherein the calculation formula of the updated projection matrix is ​​as follows:

[0101] P X,x(n+1) =P(n)+P ⊥ (n)x(n+1),P⊥ (n)x(n+1),P ⊥ (n)x(n+1)> -1 x T (n+1)P ⊥ (n)

[0102] Among them, x(n+1) represents the slope measurement data at the current moment, p(n) represents the projection matrix at the previous moment, and P ⊥ (n) represents the orthogonal projection matrix, P X,x(n+1) Represents the updated projection matrix.

[0103] It should be noted that <P ⊥ (n)x(n+1),P ⊥ (n)x(n+1)> -1 Represents the inverse of the vector inner product. This formula is the update of the original projection matrix P(n) after the introduction of the new sensor measurement value vector x(n+1), that is, the projection matrix after including the new information x(n+1). It is important here that the introduction of the new information x(n+1) makes the projection matrix at the n+1th moment include the new information, which can keep up with the changes of the new data while taking into account the previous m historical data.

[0104] The present application proposes a road slope calculation method, device, equipment, storage medium and computer program product. The present application obtains historical slope measurement data to calculate the projection matrix of the previous moment, and receives the slope measurement data of the current moment, and calculates the slope estimation value of the current moment through the slope measurement data and the projection matrix. Since the historical slope measurement data is historical data far away from the current moment, and the slope estimation value is calculated through the slope measurement data and the projection matrix corresponding to the historical slope measurement data, the slope estimation value includes historical data far away from the current moment, which can play a role in the data prediction of the current moment, making the calculated result more accurate, and accurate road pitch angle data can be obtained.

[0105] Based on the first embodiment of the present application, in the second embodiment of the present application, the same or similar contents as those in the above-mentioned embodiment 1 can be referred to the above introduction, and will not be repeated in the following. Figure 2 After the step S30 of calculating the slope estimation value at the current moment based on the slope measurement data and the projection matrix, the method further includes:

[0106] Step S40, determining a first orthogonal matrix corresponding to the updated projection matrix;

[0107] It should be noted that according to the definition of the orthogonal projection matrix, the orthogonal projection matrix P corresponding to the original projection matrix P(n) ⊥(n), that is, the first orthogonal matrix, also needs to be updated. According to the definition of the orthogonal projection matrix, the updated orthogonal projection matrix is

[0108] P ⊥ X,x(n+1) =P ⊥ (n)-P ⊥ (n)x(n+1) <P ⊥ (n)x(n+1),P ⊥ (n)x(n+1)> -1 x T (n+1)P ⊥ (n).

[0109] The new information x(n+1) is introduced here, so that the orthogonal projection matrix at the n+1th moment contains the new information and can keep up with the changes in new data while taking into account the previous m historical data.

[0110] Step S50, based on the first orthogonal matrix and the slope measurement data, calculate the error vector at the current moment, wherein the calculation formula of the error vector at the current moment is as follows:

[0111] e m (n+1)=P ⊥ X,x(n+1) x(n+1)

[0112] Among them, e m (n+1) represents the error vector at the current moment, P ⊥ X,x(n+1) represents a first orthogonal matrix, wherein the first orthogonal matrix represents an updated orthogonal projection matrix, and x(n+1) represents the slope measurement data at the current moment.

[0113] It should be noted that the error vector corresponding to the estimated value vector is e m (n+1)=P ⊥ X,x(n+1) x(n+1), after calculating the error vector, can make the slope estimate more accurate.

[0114] It should be noted that the advantages of this application are:

[0115] 1. It can take into account up to m historical data and maximize the value of historical data for the estimated value.

[0116] 2. In addition, when calculating at the n+1th moment, the new information x(n+1) is fully considered, that is, the new information is introduced to update the projection matrix and the orthogonal projection matrix, while taking into account the previous m historical data to calculate the projection matrix and the orthogonal projection matrix at the nth moment. The estimated value vector, error vector, projection matrix, and orthogonal projection matrix are recursively updated so that the calculation can be performed recursively, which is suitable for time series data processing (because time series data is collected in chronological order, only the current value can be obtained at the current sampling moment and can be stored as historical data for the next sampling moment).

[0117] 3. Small amount of calculation, easy to run on a small computing power processor.

[0118] In this embodiment, the accuracy of the calculated slope estimation value is improved by calculating the error vector.

[0119] For example, to help understand the implementation process of the road slope calculation method obtained by combining this embodiment with the above-mentioned embodiment 1, please refer to Figure 3 , Figure 3 A brief flowchart of a road slope calculation method is provided, specifically:

[0120] By obtaining historical slope measurement data, and then calculating the projection matrix of the previous moment based on the historical slope measurement data, the projection matrix and the slope measurement data of the current moment are calculated to determine the slope estimate and error vector of the current moment. Finally, the error value between the slope estimate and the actual data is determined by the error vector. Since the true value cannot be calculated, the accuracy of the calculation result can only be maximized by calculating the estimated value and the error vector.

[0121] It should be noted that the above examples are only used to understand the present application and do not constitute a limitation on the road slope calculation method of the present application. More simple transformations based on this technical concept are all within the scope of protection of the present application.

[0122] This application also provides a road slope calculation device, please refer to Figure 4 , the road slope calculation device comprises:

[0123] An acquisition module 10 is used to acquire historical slope measurement data, where the historical slope measurement data is historical data within a preset time period from the current moment;

[0124] A first calculation module 20, configured to calculate a projection matrix at a previous moment based on the historical slope measurement data;

[0125] The receiving module 30 is used to receive the slope measurement data at the current moment, and calculate the slope estimation value at the current moment based on the slope measurement data and the projection matrix.

[0126] Optionally, the first calculation module includes:

[0127] An acquisition unit, used for acquiring filter coefficients in a preset filter and a preset data matrix;

[0128] A first calculation unit, configured to calculate an estimated value vector based on the filter coefficient and a preset data matrix;

[0129] The second calculation unit is used to calculate the projection matrix at the previous moment based on the estimated value vector and the historical slope measurement data.

[0130] Optionally, the receiving module includes:

[0131] An updating unit, configured to update the projection matrix based on the slope measurement data to obtain an updated projection matrix;

[0132] The third calculation unit is used to calculate the slope estimation value at the current moment based on the updated projection matrix and the slope measurement data, wherein the calculation formula of the slope estimation value is as follows:

[0133]

[0134] in, Represents the estimated slope value at the current moment, P X,x(n+1) represents the updated projection matrix, and x(n+1) represents the slope measurement data at the current moment.

[0135] Optionally, the updating unit includes:

[0136] A determination subunit, used to determine an orthogonal projection matrix corresponding to the projection matrix;

[0137] A calculation subunit is used to calculate an updated projection matrix based on the orthogonal projection matrix, the projection matrix and the slope measurement data, wherein the calculation formula of the updated projection matrix is ​​as follows:

[0138] P X,x(n+1) =P(n)+P ⊥ (n)x(n+1) <P ⊥ (n)x(n+1),P ⊥ (n)x(n+1)> -1 x T (n+1)P ⊥ (n)

[0139] Among them, x(n+1) represents the slope measurement data at the current moment, p(n) represents the projection matrix at the previous moment, and P ⊥ (n) represents the orthogonal projection matrix, PX,x(n+1) Represents the updated projection matrix.

[0140] Optionally, the device further comprises:

[0141] The second calculation module is used to calculate the error vector at the previous moment based on the historical slope measurement data and the orthogonal projection matrix, wherein the error vector is used to characterize the error value between the slope estimation value and the actual data.

[0142] Optionally, the device further comprises:

[0143] A determination module, used to determine a first orthogonal matrix corresponding to the updated projection matrix;

[0144] The third calculation module is used to calculate the error vector at the current moment based on the first orthogonal matrix and the slope measurement data, wherein the calculation formula of the error vector at the current moment is as follows:

[0145] e m (n+1)=P ⊥ X,x(n+1) x(n+1)

[0146] Among them, e m (n+1) represents the error vector at the current moment, P ⊥ X,x(n+1) represents a first orthogonal matrix, wherein the first orthogonal matrix represents an updated orthogonal projection matrix, and x(n+1) represents the slope measurement data at the current moment.

[0147] The road slope calculation device provided by the present application adopts the road slope calculation method in the above embodiment, which can solve the technical problem of road slope calculation. Compared with the prior art, the beneficial effects of the road slope calculation device provided by the present application are the same as the beneficial effects of the road slope calculation method provided by the above embodiment, and other technical features in the road slope calculation device are the same as the features disclosed in the above embodiment method, which will not be repeated here.

[0148] The present application provides a road slope calculation device, which includes: at least one processor; and a memory connected to the at least one processor in communication; wherein the memory stores instructions that can be executed by the at least one processor, and the instructions are executed by the at least one processor so that the at least one processor can execute the road slope calculation method in the above-mentioned embodiment 1.

[0149] Reference below Figure 5, which shows a schematic diagram of the structure of a road slope calculation device suitable for implementing the embodiment of the present application. The road slope calculation device in the embodiment of the present application may include but is not limited to mobile terminals such as mobile phones, laptop computers, digital broadcast receivers, PDAs (Personal Digital Assistants), PADs (Portable Application Descriptions), PMPs (Portable Media Players), vehicle-mounted terminals (such as vehicle-mounted navigation terminals), etc., and fixed terminals such as digital TVs, desktop computers, etc. Figure 5 The road slope calculation device shown is only an example and should not bring any limitation to the functions and scope of use of the embodiments of the present application.

[0150] like Figure 5 As shown, the road slope calculation device may include a processing device 1001 (e.g., a central processing unit, a graphics processor, etc.), which can perform various appropriate actions and processes according to a program stored in a read-only memory (ROM: Read Only Memory) 1002 or a program loaded from a storage device 1003 to a random access memory (RAM: Random Access Memory) 1004. In RAM1004, various programs and data required for the operation of the road slope calculation device are also stored. The processing device 1001, ROM1002, and RAM1004 are connected to each other through a bus 1005. An input / output (I / O) interface 1006 is also connected to the bus. Generally, the following systems can be connected to the I / O interface 1006: an input device 1007 including, for example, a touch screen, a touch pad, a keyboard, a mouse, an image sensor, a microphone, an accelerometer, a gyroscope, etc.; an output device 1008 including, for example, a liquid crystal display (LCD: Liquid Crystal Display), a speaker, a vibrator, etc.; a storage device 1003 including, for example, a magnetic tape, a hard disk, etc.; and a communication device 1009. The communication device 1009 can allow the road slope calculation device to communicate with other devices wirelessly or by wire to exchange data. Although the figure shows a road slope calculation device with various systems, it should be understood that it is not required to implement or have all the systems shown. More or fewer systems can be implemented or provided instead.

[0151] In particular, according to the embodiments disclosed in the present application, the process described above with reference to the flowchart can be implemented as a computer software program. For example, the embodiments disclosed in the present application include a computer program product, which includes a computer program carried on a computer-readable medium, and the computer program includes a program code for executing the method shown in the flowchart. In such an embodiment, the computer program can be downloaded and installed from a network through a communication device, or installed from a storage device 1003, or installed from a ROM 1002. When the computer program is executed by the processing device 1001, the above-mentioned functions defined in the method of the embodiment disclosed in the present application are executed.

[0152] The road slope calculation device provided by the present application adopts the road slope calculation method in the above embodiment, which can solve the technical problem of road slope calculation. Compared with the prior art, the beneficial effects of the road slope calculation device provided by the present application are the same as the beneficial effects of the road slope calculation method provided by the above embodiment, and other technical features in the road slope calculation device are the same as the features disclosed in the method of the previous embodiment, which will not be repeated here.

[0153] It should be understood that the various parts disclosed in this application can be implemented by hardware, software, firmware or a combination thereof. In the description of the above embodiments, specific features, structures, materials or characteristics can be combined in any one or more embodiments or examples in a suitable manner.

[0154] The above is only a specific implementation of the present application, but the protection scope of the present application is not limited thereto. Any person skilled in the art who is familiar with the present technical field can easily think of changes or substitutions within the technical scope disclosed in the present application, which should be included in the protection scope of the present application. Therefore, the protection scope of the present application should be based on the protection scope of the claims.

[0155] The present application provides a computer-readable storage medium having computer-readable program instructions (ie, computer programs) stored thereon, and the computer-readable program instructions are used to execute the road slope calculation method in the above-mentioned embodiment.

[0156] The computer-readable storage medium provided in the present application may be, for example, a USB flash drive, but is not limited to electrical, magnetic, optical, electromagnetic, infrared, or semiconductor systems, systems or devices, or any combination of the above. More specific examples of computer-readable storage media may include, but are not limited to: an electrical connection with one or more wires, a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the above. In this embodiment, the computer-readable storage medium may be any tangible medium containing or storing a program that can be used by or in combination with an instruction execution system, system or device. The program code contained on the computer-readable storage medium may be transmitted using any appropriate medium, including but not limited to: wires, optical cables, RF (Radio Frequency), etc., or any suitable combination of the above.

[0157] The computer-readable storage medium may be included in the road slope calculation device; or may exist independently without being assembled into the road slope calculation device.

[0158] The computer-readable storage medium carries one or more programs. When the one or more programs are executed by the road slope calculation device, the road slope calculation device:

[0159] Acquire historical slope measurement data, where the historical slope measurement data is historical data for a preset time period from the current moment;

[0160] Based on the historical slope measurement data, a projection matrix at the previous moment is calculated;

[0161] The slope measurement data at the current moment is received, and based on the slope measurement data and the projection matrix, an estimated slope value at the current moment is calculated.

[0162] Computer program code for performing the operations of the present application may be written in one or more programming languages ​​or a combination thereof, including object-oriented programming languages ​​such as Java, Smalltalk, C++, and conventional procedural programming languages ​​such as "C" or similar programming languages. The program code may be executed entirely on the user's computer, partially on the user's computer, as a separate software package, partially on the user's computer and partially on a remote computer, or entirely on a remote computer or server. In the case of a remote computer, the remote computer may be connected to the user's computer through any type of network, including a local area network (LAN) or a wide area network (WAN), or may be connected to an external computer (e.g., via the Internet using an Internet service provider).

[0163] The flow chart and block diagram in the accompanying drawings illustrate the possible architecture, function and operation of the system, method and computer program product according to various embodiments of the present application. In this regard, each square box in the flow chart or block diagram can represent a module, a program segment or a part of a code, and the module, the program segment or a part of the code contains one or more executable instructions for realizing the specified logical function. It should also be noted that in some alternative implementations, the functions marked in the square box can also occur in a sequence different from that marked in the accompanying drawings. For example, two square boxes represented in succession can actually be executed substantially in parallel, and they can sometimes be executed in the opposite order, depending on the functions involved. It should also be noted that each square box in the block diagram and / or flow chart, and the combination of the square boxes in the block diagram and / or flow chart can be implemented with a dedicated hardware-based system that performs a specified function or operation, or can be implemented with a combination of dedicated hardware and computer instructions.

[0164] The modules involved in the embodiments described in this application may be implemented by software or hardware, wherein the name of the module does not constitute a limitation on the unit itself in some cases.

[0165] The readable storage medium provided by the present application is a computer-readable storage medium, which stores computer-readable program instructions (i.e., computer programs) for executing the above-mentioned road slope calculation method, and can solve the technical problem of road slope calculation. Compared with the prior art, the beneficial effects of the computer-readable storage medium provided by the present application are the same as the beneficial effects of the road slope calculation method provided by the above-mentioned embodiment, and will not be repeated here.

[0166] The present application also provides a computer program product, including a computer program, which implements the steps of the road slope calculation method as described above when executed by a processor.

[0167] The computer program product provided by the present application can solve the technical problem of road slope calculation. Compared with the prior art, the beneficial effects of the computer program product provided by the present application are the same as the beneficial effects of the road slope calculation method provided by the above embodiment, which will not be repeated here.

[0168] The above descriptions are only some embodiments of the present application, and are not intended to limit the patent scope of the present application. All equivalent structural changes made using the contents of the present application specification and drawings under the technical concept of the present application, or direct / indirect applications in other related technical fields are included in the patent protection scope of the present application.

Claims

1. A method for calculating road slope, characterized in that: The method comprises: Acquire historical slope measurement data, where the historical slope measurement data is historical data for a preset time period from the current moment; Based on the historical slope measurement data, a projection matrix at the last moment is calculated; The slope measurement data at the current moment is received, and based on the slope measurement data and the projection matrix, an estimated slope value at the current moment is calculated.

2. The method according to claim 1, characterized in that The step of calculating the projection matrix at the previous moment based on the historical slope measurement data comprises: Obtaining filter coefficients and a preset data matrix in a preset filter; Based on the filter coefficients and the preset data matrix, an estimated value vector is calculated; Based on the estimated value vector and the historical slope measurement data, the projection matrix at the last moment is calculated.

3. The method according to claim 1, characterized in that The step of calculating the slope estimation value at the current moment based on the slope measurement data and the projection matrix comprises: Based on the slope measurement data, updating the projection matrix to obtain an updated projection matrix; Based on the updated projection matrix and the slope measurement data, the slope estimation value at the current moment is calculated, wherein the calculation formula of the slope estimation value is as follows: in, Represents the estimated slope value at the current moment, P X,x(n+1) represents the updated projection matrix, and x(n+1) represents the slope measurement data at the current moment.

4. The method according to claim 3, characterized in that The step of updating the projection matrix based on the slope measurement data to obtain an updated projection matrix comprises: Determine an orthogonal projection matrix corresponding to the projection matrix; Based on the orthogonal projection matrix, the projection matrix and the slope measurement data, an updated projection matrix is ​​calculated, wherein the calculation formula of the updated projection matrix is ​​as follows: P X,x(n+1) =P(n)+P ⊥ (n)x(n+1) <P ⊥ (n)x(n+1), P ⊥ (n)x(n+1)> -1 x T (n+1)P ⊥ (n) Among them, x(n+1) represents the slope measurement data at the current moment, p(n) represents the projection matrix at the previous moment, and P ⊥ (n) represents the orthogonal projection matrix, P X,x(n+1) Represents the updated projection matrix.

5. The method according to claim 4, characterized in that After the step of calculating the projection matrix at the previous moment based on the historical slope measurement data, the method further includes: Based on the historical slope measurement data and the orthogonal projection matrix, an error vector at the last moment is calculated, wherein the error vector is used to characterize the error value between the slope estimation value and the actual data.

6. The method according to claim 1, characterized in that After the step of calculating the slope estimation value at the current moment based on the slope measurement data and the projection matrix, the method further includes: Determine a first orthogonal matrix corresponding to the updated projection matrix; Based on the first orthogonal matrix and the slope measurement data, the error vector at the current moment is calculated, wherein the calculation formula of the error vector at the current moment is as follows: e m (n+1)=P ⊥ X,x(n+1) x(n+1) Among them, e m (n+1) represents the error vector at the current moment, P ⊥ X,x(n+1) represents a first orthogonal matrix, wherein the first orthogonal matrix represents an updated orthogonal projection matrix, and x(n+1) represents the slope measurement data at the current moment.

7. A road slope calculation device, characterized in that: The device comprises: An acquisition module, used to acquire historical slope measurement data, wherein the historical slope measurement data is historical data of a preset time period from the current moment; A first calculation module, used for calculating the projection matrix at the last moment based on the historical slope measurement data; The receiving module is used to receive the slope measurement data at the current moment, and calculate the slope estimation value at the current moment based on the slope measurement data and the projection matrix.

8. A road slope calculation device, characterized in that: The device comprises: a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the computer program is configured to implement the steps of the road slope calculation method according to any one of claims 1 to 6.

9. A storage medium, characterized in that: The storage medium is a computer-readable storage medium, and a computer program is stored on the storage medium. When the computer program is executed by a processor, the steps of the road slope calculation method according to any one of claims 1 to 6 are implemented.

10. A computer program product, characterized in that The computer program product comprises a computer program, and when the computer program is executed by a processor, the steps of the road gradient calculation method according to any one of claims 1 to 6 are implemented.