Mathematica Stack Exchange is a question and answer site for users of Mathematica. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I'm afraid this is going to be a really stupid question.

Evaluating the following definite integral

Integrate[Sqrt[1 - (x^2 + y^2)], {x, -1, 1}, {y, -1, 1}]


(2/3) (Pi - I (-2 + Log[4]))

I don't want the imaginary part. Adding the option

Assumptions -> x^2 + y^2 <= 1

doesn't work. What did I miss?

share|improve this question
You try to integrate Sqrt[1 - (x^2 + y^2)] over the region where the integrand becomes imaginary (for {x,y} outside the unit circle}), namely you're integrating over a square (-1,1) x (-1,1). – Artes Jun 12 '13 at 13:07
up vote 7 down vote accepted


Integrate[Sqrt[1 - (x^2 + y^2)] Boole[x^2 + y^2 <= 1], {x, -1, 1}, {y, -1, 1}]


Integrate[r Sqrt[1 - r^2], {r, 0, 1}, {θ, -π, π}]

Vastly better:

2 π Integrate[r Sqrt[1 - r^2], {r, 0, 1}]

Exercise: why?

share|improve this answer
Because in the polar coordinates the area outside the integration region is automatically avoided? – Taiki Jun 12 '13 at 13:17
Good show. You're right, @Taiki. :) – J. M. Jun 12 '13 at 13:18

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.