-pi/4 plus 15pi/4 divided by 2=7pi/4

how is the math done regarding the fractions (dividing and multiplying)

i will use n to represent pi because it is much easier to read

(-n/4+15n/4)/2 = 7n/4
((-n+15n)/4)/2 = 7n/4
(14n/4)/2 = 7n/4

since dividing by 2 is the same as multiplying by 1/2, the 14n/4 becomes 14n/8 which equals 7n/4.