We have
LHS `= (sin theta + "cosec" theta)^(2)+(cos theta + sec theta)^2 `
` =(sin^(2)theta + "cosec"^(2)theta +2 sin theta "cosec" theta)+(cos^(2)theta + sec^(2)theta + 2 cos theta sec theta )`
` = (sin^(2) theta + "cosec"^(2)theta +2)+(cos^(2)theta + sec^(2)theta +2) `
` [ because sin theta "cosec"theta =1 and cos theta sec theta=1] `
` = (sin^(2)theta + cos^(2)theta)+4+("cosec"^(2) theta + sec^(2) theta)`
` = 1+4+(1+cot^(2) theta)+(1+tan^(2)theta) `
` [ because sin^(2) theta + cos^(2)theta =1, "cosec"^(2)theta =1+cot^(2) theta and sec^(2)theta=1+tan^(2)theta] `
` =(7+ tan^(2)theta + cot^(2) theta )= RHS. `
`therefore LHS = RHS. `