If the roots of the quadratic equation \(x^2+px+q=0\) are tan 30° and tan 15° respectively, then the value of 2 + q - p is
Step-by-step Solution:
We know that: \[ (1 + \tan \theta)(1 + \tan (45^\circ - \theta)) = 2. \] Substituting \( \theta = 30^\circ \) and \( 45^\circ - \theta = 15^\circ \), we have: \[ (1 + \tan 30^\circ)(1 + \tan 15^\circ) = 2. \] Let the roots be \( \alpha \) and \( \beta \). Then: \[ (1 + \alpha)(1 + \beta) = 2 \quad \Rightarrow \quad 1 + \alpha + \beta + \alpha \beta = 2. \] Simplifying: \[ \alpha \beta + \alpha + \beta - 1 = 0. \] Substitute \( \alpha + \beta = q \) and \( \alpha \beta = p \): \[ p + q - 1 = 0 \quad \Rightarrow \quad q - p = 1. \] Thus: \[ 2 + q - p = 3 \]