Place sin calculation outside for loop