Mathematics Stack Exchange is a question and answer site for people studying math at any level and professionals in related fields. 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 know the coordinate of the center of an object (box of any size). I also know the rotation of the box and its size.

How could I calculate the position of the top left corner?

I have no math knowledge, and this problem is killing me.

share|cite|improve this question
Just to make sure we're on the same page: Is this in 2D, or 3D? "box" means a square, right? What's the "size" of the box? Do you mean "side length" or area/volume? What's the "rotation" of a box? It is the angle it's diagonal makes with the $x$-axis? – user2468 Oct 20 '12 at 0:28
up vote 1 down vote accepted

In 2D

Mathematica graphics

The position of $D'$ is

$$\left\{\left(x_1-x_0\right) \cos (\theta )+x_0+\left(y_0-y_1\right) \sin (\theta ),\left(x_1-x_0\right) \sin (\theta )+\left(y_1-y_0\right) \cos (\theta )+y_0\right\}$$

share|cite|improve this answer

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.