mathSolve in R sinx=1+cos^2x

2 Answers | Add Yours

justaguide's profile pic

justaguide | College Teacher | (Level 2) Distinguished Educator

Posted on

We have to solve sin x = 1 + (cos x)^2

(cos x)^2 = 1 - (sin x)^2

sin x = 1 + (cos x)^2

=> sin x = 1 + 1 - (sin x)^2

=> (sin x)^2 + sin x - 2 = 0

=> (sin x)^2 + 2*sin x - sin x - 2 = 0

=> (sin x)(sin x + 2) - 1(sin x + 2) = 0

=> (sin x - 1)(sin x + 2) = 0

=> sin x = 1 and sin x = -2

But sin x cannot be less than -1, we eliminate this root.

sin x = 1

x = pi/2 + 2*n*pi

The values of x are pi/2 + 2*n*pi

giorgiana1976's profile pic

giorgiana1976 | College Teacher | (Level 3) Valedictorian

Posted on

We'll write (cos x)^2 with respect to (sin x)^2, from the fundamental formula of trigonomtery:

(cos x)^2 = 1 - (sin x)^2 (1)

We'll substitute (1) in the given equation:

sin x = 1 + 1 - (sin x)^2

We'll combine like terms and we'll move all terms to the right side:

(sin x)^2 + sin x - 2  =0

We'll substitute sin x by t:

t^2 + t - 2 = 0

We'll apply the quadratic formula:

t1 = [-1+sqrt(1 + 8)]/2

t1 = (-1+3)/2

t1 = 1

t2 = (-1-3)/2

t2 = -2

But t1 = sin x => sin x = 1

x = (-1)^k*arcsin (1) + k*pi

x = (-1)^k*(pi/2) +  k*pi

We'll reject the second solution for t since -1 =< sin x =< 1.

We’ve answered 318,913 questions. We can answer yours, too.

Ask a question