trigonometric problem solved in only 1 min