Question
Question: $\int \frac{\sec x}{3(\sec x + \tan x)+2}dx =$...
∫3(secx+tanx)+2secxdx=

21lntan(x/2)+5tan(x/2)+1+C
Solution
The given integral is I=∫3(secx+tanx)+2secxdx.
First, rewrite the integrand in terms of sinx and cosx: secx=cosx1 and tanx=cosxsinx. The integrand becomes: 3(cosx1+cosxsinx)+2cosx1=3(cosx1+sinx)+2cosx1=cosx3(1+sinx)+2cosxcosx1 =cosx1×3(1+sinx)+2cosxcosx=3+3sinx+2cosx1. So the integral is I=∫3+3sinx+2cosx1dx.
This is an integral of the form ∫a+bsinx+ccosx1dx. We use the substitution t=tan(x/2). We have dx=1+t22dt, sinx=1+t22t, and cosx=1+t21−t2. Substitute these into the integral: I=∫3+3(1+t22t)+2(1+t21−t2)11+t22dt Simplify the denominator: 3+3(1+t22t)+2(1+t21−t2)=1+t23(1+t2)+3(2t)+2(1−t2)=1+t23+3t2+6t+2−2t2=1+t2t2+6t+5. Substitute this back into the integral: I=∫1+t2t2+6t+511+t22dt=∫t2+6t+51+t21+t22dt I=∫t2+6t+52dt.
Factor the quadratic in the denominator: t2+6t+5=(t+1)(t+5). I=∫(t+1)(t+5)2dt.
Use partial fraction decomposition: (t+1)(t+5)2=t+1A+t+5B 2=A(t+5)+B(t+1). Set t=−1: 2=A(−1+5)+B(−1+1)=4A⟹A=21. Set t=−5: 2=A(−5+5)+B(−5+1)=−4B⟹B=−21. So, (t+1)(t+5)2=t+11/2−t+51/2.
Now integrate with respect to t: I=∫(t+11/2−t+51/2)dt=21∫t+11dt−21∫t+51dt I=21ln∣t+1∣−21ln∣t+5∣+C I=21(ln∣t+1∣−ln∣t+5∣)+C I=21lnt+5t+1+C.
Substitute back t=tan(x/2): I=21lntan(x/2)+5tan(x/2)+1+C.