If we so desire we can also modify the right-hand side to match the left-hand side.
We should write ##sinxtanx## in terms of ##sinx## and ##cosx## using the identity ##color(red)(tanx=sinx/cosx)##:
##sinxtanx=sinx(sinx/cosx)=sin^2x/cosx##
Now we use the Pythagorean identity which is ##sin^2x+cos^2x=1##. We can modify this to solve for ##sin^2x## so: ##color(red)(sin^2x=1-cos^2x)##:
##sin^2x/cosx=(1-cos^2x)/cosx##
Now just split up the numerator:
##(1-cos^2x)/cosx=1/cosx-cos^2x/cosx=1/cosx-cosx##
Use the reciprocal identity ##color(red)(secx=1/cosx##:
##1/cosx-cosx=secx-cosx##