Step-by-step derivation
S001 · calculation
Before
total mass numerator := sum(19, 2, 1)
After
total mass numerator = 22
Conditions: none
Nonnegative integer masses must sum to D for normalized weights.
Step identifiers and dependencies
Rule: exact_rational_arithmetic · Uses: G001
S002 · implies
Before
indexed masses=[19, 2, 1];D=22
After
probabilities=[19/22, 1/11, 1/22]
Conditions: none
Outcome indices start at0 and align masses with X and Y values.Retain zero-mass outcomes;negative random-variable values are allowed.
Step identifiers and dependencies
Rule: indexed_normalized_expectation_model · Uses: G001, S001
S003 · calculation
Before
X weighted numerator0 := mul(19, -18)
After
X weighted numerator0 = -342
Conditions: none
Multiply the mass by the value at the same index;deleting zero masses must not shift alignment.
Step identifiers and dependencies
Rule: exact_rational_arithmetic · Uses: G001, S002
S004 · calculation
Before
X contribution0 := div(-342, 22)
After
X contribution0 = -171/11
Conditions: none
Divide by the common positive denominator,retaining the index position of a zero contribution.
Step identifiers and dependencies
Rule: exact_rational_arithmetic · Uses: G001, S003
S005 · calculation
Before
X weighted numerator1 := mul(2, 2)
After
X weighted numerator1 = 4
Conditions: none
Multiply the mass by the value at the same index;deleting zero masses must not shift alignment.
Step identifiers and dependencies
Rule: exact_rational_arithmetic · Uses: G001, S004
S006 · calculation
Before
X contribution1 := div(4, 22)
After
X contribution1 = 2/11
Conditions: none
Divide by the common positive denominator,retaining the index position of a zero contribution.
Step identifiers and dependencies
Rule: exact_rational_arithmetic · Uses: G001, S005
S007 · calculation
Before
X weighted numerator2 := mul(1, 19)
After
X weighted numerator2 = 19
Conditions: none
Multiply the mass by the value at the same index;deleting zero masses must not shift alignment.
Step identifiers and dependencies
Rule: exact_rational_arithmetic · Uses: G001, S006
S008 · calculation
Before
X contribution2 := div(19, 22)
After
X contribution2 = 19/22
Conditions: none
Divide by the common positive denominator,retaining the index position of a zero contribution.
Step identifiers and dependencies
Rule: exact_rational_arithmetic · Uses: G001, S007
S009 · calculation
Before
X expectation := sum(-171/11, 2/11, 19/22)
After
X expectation = -29/2
Conditions: none
Add every indexed expectation contribution.
Step identifiers and dependencies
Rule: exact_rational_arithmetic · Uses: G001, S008
S010 · calculation
Before
Y weighted numerator0 := mul(19, 20)
After
Y weighted numerator0 = 380
Conditions: none
Multiply the mass by the value at the same index;deleting zero masses must not shift alignment.
Step identifiers and dependencies
Rule: exact_rational_arithmetic · Uses: G001, S009
S011 · calculation
Before
Y contribution0 := div(380, 22)
After
Y contribution0 = 190/11
Conditions: none
Divide by the common positive denominator,retaining the index position of a zero contribution.
Step identifiers and dependencies
Rule: exact_rational_arithmetic · Uses: G001, S010
S012 · calculation
Before
Y weighted numerator1 := mul(2, -1)
After
Y weighted numerator1 = -2
Conditions: none
Multiply the mass by the value at the same index;deleting zero masses must not shift alignment.
Step identifiers and dependencies
Rule: exact_rational_arithmetic · Uses: G001, S011
S013 · calculation
Before
Y contribution1 := div(-2, 22)
After
Y contribution1 = -1/11
Conditions: none
Divide by the common positive denominator,retaining the index position of a zero contribution.
Step identifiers and dependencies
Rule: exact_rational_arithmetic · Uses: G001, S012
S014 · calculation
Before
Y weighted numerator2 := mul(1, 2)
After
Y weighted numerator2 = 2
Conditions: none
Multiply the mass by the value at the same index;deleting zero masses must not shift alignment.
Step identifiers and dependencies
Rule: exact_rational_arithmetic · Uses: G001, S013
S015 · calculation
Before
Y contribution2 := div(2, 22)
After
Y contribution2 = 1/11
Conditions: none
Divide by the common positive denominator,retaining the index position of a zero contribution.
Step identifiers and dependencies
Rule: exact_rational_arithmetic · Uses: G001, S014
S016 · calculation
Before
Y expectation := sum(190/11, -1/11, 1/11)
After
Y expectation = 190/11
Conditions: none
Add every indexed expectation contribution.
Step identifiers and dependencies
Rule: exact_rational_arithmetic · Uses: G001, S015
S017 · calculation
Before
pointwise XY0 := mul(-18, 20)
After
pointwise XY0 = -360
Conditions: none
First multiply X_iY_i at the same outcome,then apply its original weight.
Step identifiers and dependencies
Rule: exact_rational_arithmetic · Uses: G001, S016
S018 · calculation
Before
pointwise XY1 := mul(2, -1)
After
pointwise XY1 = -2
Conditions: none
First multiply X_iY_i at the same outcome,then apply its original weight.
Step identifiers and dependencies
Rule: exact_rational_arithmetic · Uses: G001, S017
S019 · calculation
Before
pointwise XY2 := mul(19, 2)
After
pointwise XY2 = 38
Conditions: none
First multiply X_iY_i at the same outcome,then apply its original weight.
Step identifiers and dependencies
Rule: exact_rational_arithmetic · Uses: G001, S018
S020 · calculation
Before
XY weighted numerator0 := mul(19, -360)
After
XY weighted numerator0 = -6840
Conditions: none
Multiply the mass by the value at the same index;deleting zero masses must not shift alignment.
Step identifiers and dependencies
Rule: exact_rational_arithmetic · Uses: G001, S019
S021 · calculation
Before
XY contribution0 := div(-6840, 22)
After
XY contribution0 = -3420/11
Conditions: none
Divide by the common positive denominator,retaining the index position of a zero contribution.
Step identifiers and dependencies
Rule: exact_rational_arithmetic · Uses: G001, S020
S022 · calculation
Before
XY weighted numerator1 := mul(2, -2)
After
XY weighted numerator1 = -4
Conditions: none
Multiply the mass by the value at the same index;deleting zero masses must not shift alignment.
Step identifiers and dependencies
Rule: exact_rational_arithmetic · Uses: G001, S021
S023 · calculation
Before
XY contribution1 := div(-4, 22)
After
XY contribution1 = -2/11
Conditions: none
Divide by the common positive denominator,retaining the index position of a zero contribution.
Step identifiers and dependencies
Rule: exact_rational_arithmetic · Uses: G001, S022
S024 · calculation
Before
XY weighted numerator2 := mul(1, 38)
After
XY weighted numerator2 = 38
Conditions: none
Multiply the mass by the value at the same index;deleting zero masses must not shift alignment.
Step identifiers and dependencies
Rule: exact_rational_arithmetic · Uses: G001, S023
S025 · calculation
Before
XY contribution2 := div(38, 22)
After
XY contribution2 = 19/11
Conditions: none
Divide by the common positive denominator,retaining the index position of a zero contribution.
Step identifiers and dependencies
Rule: exact_rational_arithmetic · Uses: G001, S024
S026 · calculation
Before
XY expectation := sum(-3420/11, -2/11, 19/11)
After
XY expectation = -3403/11
Conditions: none
Add every indexed expectation contribution.
Step identifiers and dependencies
Rule: exact_rational_arithmetic · Uses: G001, S025
S027 · calculation
Before
product of means := mul(-29/2, 190/11)
After
product of means = -2755/11
Conditions: none
Compute the product of means separately;do not substitute it for the expectation of the product.
Step identifiers and dependencies
Rule: exact_rational_arithmetic · Uses: G001, S026
S028 · implies
Before
E[XY]=-3403/11;E[X]E[Y]=-2755/11
After
report in this order;no independence inferred
Conditions: none
Independence implies this moment equality,but one moment equality alone does not establish general independence;compute only the two values in the declared joint model.
Step identifiers and dependencies
Rule: mixed_moment_not_independence · Uses: G001, S027