calculate the root mean square error between two signals
calculate the relative root mean square error between two signals
RootMeanSquareError( X, Y )
RelativeRootMeanSquareError( X, Y )
rtables or lists of real or complex data.
The RootMeanSquareError command takes two rtables or lists of data with compatible dimensions, and returns the Root Mean Square Error (RMSE), which is the Root Mean Square (RMS) of the difference of X and Y. When X and Y are Vectors with n elements:
The RelativeRootMeanSquareError command takes two rtables or lists of data with compatible dimensions, and returns the Relative Root Mean Square Error (RRMSE), which is the Root Mean Square (RMS) of the difference of X and Y, divided by the RMS of Y. When X and Y are Vectors with n elements:
The advantage of using RRMSE over RMSE to quantify error is that the error is relative to the comparison container, which prevents relatively small errors from appearing large, and relatively large errors from appearing small.
The inputs are converted to Arrays of float or complex datatype, and an error will be thrown if this is not possible. For this reason, it is most efficient for the inputs to already be rtables having the appropriate datatypes.
The RelativeRootMeanSquareError and RootMeanSquareError commands are not thread safe.
X ≔ Vectorrow⁡1,2,3
Y ≔ Vectorcolumn⁡4,5,6
X ≔ 1.1,1.9,3.1
Y ≔ 1,2,3
In this example, the RMSE suggests two Vectors are very close (in the absolute sense), but the RRMSE shows that to not be the case (in the relative sense):
P ≔ 0.00003,0.00004
Q ≔ 0.00001,0.00002
Here, the RMSE suggests two Vectors are not very close (in the absolute sense), but the RRMSE shows the Vectors are in fact pretty close (in the relative sense):
U ≔ 503,604
V ≔ 500,600
Complex data is also supported:
A ≔ Vector⁡1,2−I,'datatype'='complex8'
B ≔ Vector⁡3,4+I,'datatype'='complex8'
P ≔ Vector⁡5,6,'datatype'='float8'
Q ≔ Vector⁡10−3⁢I,7,'datatype'='complex8'
The SignalProcessing[RootMeanSquareError] and SignalProcessing[RelativeRootMeanSquareError] commands were introduced in Maple 2021.
For more information on Maple 2021 changes, see Updates in Maple 2021.
The SignalProcessing[RootMeanSquareError] and SignalProcessing[RelativeRootMeanSquareError] commands were updated in Maple 2022.
Download Help Document
What kind of issue would you like to report? (Optional)