The correct option is
B π4−log√2Consider,
I=∫π40xsec2xdx,
Solving the indefinite integral,
I1=∫xsec2xdx,
Applying integral by parts,
⇒I1=xtanx−∫tanxdx
⇒I1=xtanx+lncosx+C
The value of the indefinite integral,
⇒I=[xtanx+lncosx]π40
⇒I=[π4tanπ4+lncosπ4]−[0−ln(cos0)]
⇒I=π4+ln1√2