symTrain.m compute angle and scale