Numerical modeling of residual stresses in additive manufacturing products using the theory of repeatedly superimposed finite strains