Mathematics Stack Exchange is a question and answer site for people studying math at any level and professionals in related fields. It's 100% free, no registration required.

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 have a 2D square S. S is described by s, the side length, theta, the angle it is rotated by, and c, the position of S's center.

There is an axis-aligned rectangle R that extends infinitely in the x direction. The bottom of R has height 0, and the top of R has some height k.

I need to find the magnitude of the area this rotated square intersects with R. I'm confident I could do this with some crufty logic and line-line intersections, but is there an elegant way to accomplish the same?

share|cite|improve this question

Your Answer


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

Browse other questions tagged or ask your own question.