quick clarification on residual equation

all, i have a quick question about residual income model. there are two formulas for residual income: Et - (r x Bt-1) (ROE - r) x B(t-1) while the first is the earnings minus equiyty charge we are familiar with, where does the second version come from and how is it equal to the first? any help would be highly appreciated!

Recall earnings = ROE x beginning book value of equity (B_{t-1}). Therefore, RI = E_{t} - (r x B_{t-1}) = (ROE x B_{t-1}) - (r x B_{t-1}) = (ROE - r) x B_{t-1}

ROE * B(t-1) = Et; if the surplus equation holds fully, an assumption in residual income model.