Correctness of logical steps for create the matrix of viewing transformation
I'm assuming you mean $A$ is object$\rightarrow$world matrix and $B$ is your camera$\rightarrow$world matrix? If that's the case, to calculate object object$\rightarrow$camera matrix you calculate:

$$C=B^{-1}*A$$

In general your math is correct, i.e. the order of matrix multiplication is reversed for the inverse calculation. It's just that normally these transformations are combined to a single 4x4 transformation matrix which does rotation, scaling and translation, and then you just work with that single matrix instead of it being decomposed to separate rotation &amp; translation matrices. Anyway, if you want to decompose the matrix multiplication, based on the above you would do:

$$A=T_A*Ry_A*Rx_A$$
$$B=T_B*Ry_B*Rx_B$$
$$C=Rx_B^{-1}*Ry_B^{-1}*T_B^{-1}*T_A*Ry_A*Rx_A$$