Both a) y=sin (x+ pi/2) and b) y=-cos(x-pi) has identical graphs.
The +- pi/2 shifts to the LEFT or RIGHT respectively. So the first plot is simply a cosine curve.
The second is a cosine shifted by pi, which gives -cos(x) but we have a negative out front so both (a) and (b) are cosine.