Solve the differential equation: e^(2y) * (dy/dx) + tan(x) = 0, given that y = 0 when x = 0. Give your answer in the form y = f(x).

This is a question taken from a core 4 paper and is a typical example of a differential equation question.

The first thing to notice about this equation is that it is "separable", meaning we can rearrange it to get 

e^(2y) dy = - tan(x) dx

Now we can solve this by integrating both sides. We know how to integrate the left hand side, and we get (1/2)e^(2y), but how can we integrate -tan(x)?

To see how we can do this, we write

-tan(x) = -sin(x) / cos(x)

Then, we realise that the numerator is the derivative of the denominator, and so integrating -tan(x) gives ln(|cos(x)|) + C, where C is the constant of integration. 

So, we now have that

(1/2)e^(2y) = ln(|cos(x)|) + C

Now we apply the condition that y(x=0) = 0, giving

1/2 = C

Subbing this in, we have

(1/2)e^(2y) = ln(|cos(x)|) + 1/2


e^(2y) = 2ln(|cos(x)|) + 1

The question asked for the answer to be written in the form y = f(x), and so we need to get the y out of the exponent, which we can do by taking ln of both sides to give

2y = ln( 1 + 2ln(|cos(x)|)  )

And so the final answer is

y = (1/2) ln( 1 + 2ln(|cos(x)|) )

Dominic D. GCSE Further Mathematics  tutor, A Level Further Mathemati...

4 months ago

Answered by Dominic, an A Level Maths tutor with MyTutor

Still stuck? Get one-to-one help from a personally interviewed subject specialist


£30 /hr

Araba S.

Degree: Business & Marketing (Masters) - Warwick University

Subjects offered:Maths, Further Mathematics

Further Mathematics

“About me: I am a Chemical Engineering graduate currently studying a Masters in Business at the Warwick Business School. Maths is a subject I thoroughly enjoyed at school and nothing brought me more satisfaction than breaking down othe...”

MyTutor guarantee

£20 /hr

Andrew G.

Degree: Physics (Bachelors) - Exeter University

Subjects offered:Maths, Physics


“About Me: I am Physics student studying at University of Exeter. I have a real passion for my subject and would love the opportunity to pass on some of my knowledge and experiences. As well as making tough subjects fun and easy to und...”

MyTutor guarantee

£22 /hr

Kyna F.

Degree: Materials Engineering (Masters) - Exeter University

Subjects offered:Maths, Science+ 2 more

-Personal Statements-

“About me Hello, my name is Kyna and I'm a second year Materials Engineering student studying at theUniveristy of Exeter. I have always had a love for all things science and maths, and would love to help any students in need of extra s...”

About the author

Dominic D.

Currently unavailable: for new students

Degree: MSci Theoretical Physics (Masters) - Birmingham University

Subjects offered:Maths, Physics+ 1 more

Further Mathematics

“Hi, I'm Dom, a third year Theoretical Physics student at the University of Birmingham. I have always been fascinated by the rich subjects that are maths and physics and look to convey that enthusiasm in my teaching. I have previous ...”

You may also like...

Other A Level Maths questions

How do I do integration by substitution?

What is the tangent line to the curve y = x^3+4x+5 at the point where x = 2?

What are the set of values for x that satisfy the below equation?

How do you differentiate parametric equations?

View A Level Maths tutors

We use cookies to improve your site experience. By continuing to use this website, we'll assume that you're OK with this. Dismiss