errors - Maple Help
For the best experience, we recommend viewing online help using Google Chrome or Microsoft Edge.

Online Help

All Products    Maple    MapleSim


combine/errors

combine quantities-with-error in an expression

 

Calling Sequence

Parameters

Description

Examples

Calling Sequence

combine( expr, errors, opts )

Parameters

expr

-

expression containing quantities-with-error

opts

-

(optional) equation(s) of the form option=value, where option is one of 'rule' or 'correlations'; determine behavior

Description

• 

The combine( expr, errors, opts ) command combines quantities-with-error in a mathematical expression, or in other words, propagates the errors through an expression.

• 

The opts argument can contain one or more of the following equations that determine the behavior:

  

 

  

'rule' = name

  

If the optional parameter rule=name is given, the rounding rule name is applied to the result of combine. Otherwise, the default rounding rule is used ('digits', or as set by ScientificErrorAnalysis[UseRule]).

  

 

  

'correlations' = true or false

  

If 'correlations'=true, combine/errors uses correlations defined between the quantities-with-error combined. The default value of 'correlations' is true. If 'correlations'=false, combine/errors ignores any correlations defined between the quantities-with-error.

  

If no correlations have been directly defined between the quantities-with-error in expr (using ScientificErrorAnalysis[SetCorrelation]), 'correlations'=false does not produce a result different from the default.

  

'correlations'=false has no effect on further induced error analysis calculations. That is, when combine/errors requires the variance of a quantity-with-error with functional dependence, that calculation is performed using correlations.

• 

The result of combine/errors is a quantity-with-error returned in a Quantity object.

• 

The uncertainty is calculated using the usual formula of error analysis involving a first-order expansion with the variances of the quantities-with-error.

  

The error uy in y, where y is a function of variables xi, is

  

 

uy2=i=1Nⅆyⅆxi2uxi2

  

where uxi is the error in xi, and the partials are evaluated at the central values of the xi.

  

When correlations are included, the formula also involves the covariances uxi,xj between the quantities-with-error.

  

 

uy2=i=1Nⅆyⅆxi2uxi2+2i=1N1j=i+1Nⅆyⅆxiⅆyⅆxjuxi,xj

  

The covariance uxi,xj can be expressed in terms of the correlation rxi,xj and errors uxi, uxj as:

  

 

uxi,xj=rxi,xjuxiuxj

  

where uxi and uxj are the errors in xi and xj.

• 

ScientificErrorAnalysis[Variance] and ScientificErrorAnalysis[Covariance] are used to calculate the variances and covariances of the quantities-with-error. Thus, any quantity-with-error combined can have functional dependence on other quantities-with-error.

Examples

withScientificErrorAnalysis:

aQuantity10.,1.:

bQuantity20.,1.:

combineab,errors

Quantity200.,22.36067977

(1)

combineab,errors,rule=round2

Quantity200.,22.

(2)

combineba,errors

Quantity2.000000000,0.2236067977

(3)

SetCorrelationa,b,0.1

combineab,errors

Quantity200.,23.23790008

(4)

combineba,errors

Quantity2.000000000,0.2144761059

(5)

combineba,errors,correlations=false

Quantity2.000000000,0.2236067977

(6)

withScientificConstants:

e5ConstanthConstantca

e5ConstanthConstantcQuantity10.,1.

(7)

combinee5,errors

Quantity1.986445824×10−24,1.986445824×10−25

(8)

e6ConstantmeConstantmp

e6ConstantmeConstantmp

(9)

combinee6,errors

Quantity0.0005446170214,5.176301769×10−14

(10)

See Also

combine

Overview of ScientificErrorAnalysis

Rounding rules

ScientificConstants

ScientificConstants[Constant]

ScientificErrorAnalysis

ScientificErrorAnalysis and ScientificConstants

ScientificErrorAnalysis[Covariance]

ScientificErrorAnalysis[GetCorrelation]

ScientificErrorAnalysis[Quantity]

ScientificErrorAnalysis[SetCorrelation]

ScientificErrorAnalysis[UseRule]

ScientificErrorAnalysis[UsingRule]

ScientificErrorAnalysis[Variance]