see explanation

using appropriate ##color(blue) Addition formula ##

## sin(A B) = sinAcosB cosAsinB ##

hence ## sin(pi/2 -theta) = sin(pi/2) costheta – cos(pi/2)sintheta ##

now ## sin(pi/2) = 1 and cos(pi/2) = 0 ##

hence ## sin(pi/2)costheta – cos(pi/2)sintheta = costheta – 0 ##

##rArr sin(pi/2 – theta ) = costheta ##