For the repeated measures design _D.C.Montgomery_ in his "Design and Analysis of Experiments" classic [book](http://www.amazon.com/Design-Analysis-Experiments-5th-Edition/dp/0471316490) provides the mathematical / statistical (linear) model: $y_{ij} = \mu + \tau_i+ \beta_j + \epsilon_{ij}$, where $\tau$ is the effect of the $i$th treatment, $\beta$ is a parameter associated with the $j$th subject, and $\epsilon_{ij}$ is the independent error.  
In a ([document](http://www.docstoc.com/docs/25226940/Repeated-Measures-and-Related-Designs), p. 2) it is stated that to check the model's assumptions we should operate with residuals calculated as (_A_): $$\hat\epsilon_{ij} = Y_{ij} - \bar Y_{i.} - \bar Y_{.j} + \bar Y.$$  
 
The [formula](http://en.wikipedia.org/wiki/Errors_and_residuals_in_statistics) (_B_) on Wikipedia is $$\hat\epsilon_i = Y_i - \bar Y.$$  

My question is:  
what formula is used to correctly calculate residuals in the model describing a single-factor repeated measures design to check its assumptions (multivariate normality, homoscedasticity, sphericity, linearity, additivity)?  

Thank you.

---
EDIT  
_E.Vonesh_ and _V.M.Chinchilli_ in their "Linear and Nonlinear Models for the Analysis of Repeated Measurements" [monograph](http://www.amazon.com/Nonlinear-Analysis-Repeated-Measurements-Statistics/dp/0824782488#reader_0824782488) state that the single-sample RM design may be written as $y_{i} = \mu + \epsilon_{i}$.