# Translation

Translations are Non Deformative Simple Transformations that any object can be subjected to. It refers to linear change in the position of coordinate points of an object, either because the object is moved or the origin of the coordinate system is moved. Following illustrates both:

1. Moving the object: In this case the coordinate of the new point is obtained by adding the change to the existing coordinates of the point. For example, suppose a point is represented by (x,y), and the object changes its position by (-3,5) (i.e. it shifts by 3 units towards left and five units towards top) , then the new point becomes (x-3,y+5)
However, when an object is represented by an equation, representing the new equation involves subtracting the change from x and y. For example let us take following equations:
1. $$3x + 2y +5 = 0$$
2. $$(x-5)^2 + (y-3)^2 = 25$$
On moving the object by (-3,5) the new equations shall become
1. $$\Rightarrow 3(x+3) + 2(y-5) +5 = 0$$
$$\Rightarrow 3x + 2y + 4 = 0$$
2. $$\Rightarrow ((x+3)-5)^2 + ((y-5)-3)^2 = 25$$
$$\Rightarrow (x-2)^2 + (y-8)^2 = 25$$
2. Shifting of the origin of the coordinate system: In this case the coordinate of the new point is obtained by subtracting coordinates of the new origin from the existing point coordinates. For example, suppose a point is represented by (x,y), and the origin is shifted to (-3,5) (i.e. it shifts by 3 units towards left and five units towards top) , then the new point becomes (x+3,y-5).
However, when an object is represented by an equation, representing the new equation involves adding the changed coordinate origin to x and y. For example let us take following equations:
1. $$3x + 2y +5 = 0$$
2. $$(x-5)^2 + (y-3)^2 = 25$$
On shifting the origin to (-3,5) new equations shall become
1. $$\Rightarrow 3(x-3) + 2(y+5) +5 = 0$$
$$\Rightarrow 3x + 2y + 6 = 0$$
2. $$\Rightarrow ((x-3)-5)^2 + ((y+5)-3)^2 = 25$$
$$\Rightarrow (x-8)^2 + (y+2)^2 = 25$$
The following summerises the formula for translations in 2D:
 Translation Type Equation Form Matrix Multiplication Form Moving the object by $$t_x,t_y$$ (or if the equation changes because of shifting of origin to $$(t_x,t_y)$$) $$x' = x + t_x$$ $$y' = y + t_y$$ $$\begin{bmatrix} 1 & 0 & t_x \\ 0 & 1 & t_y \\ 0 & 0 & 1 \end{bmatrix} \begin{bmatrix} x \\ y \\ 1 \end{bmatrix} = \begin{bmatrix} x' \\ y' \\ 1 \end{bmatrix}\hspace{1cm} OR \hspace{1cm} \begin{bmatrix} x & y & 1 \end{bmatrix} \begin{bmatrix} 1 & 0 & 0 \\ 0 & 1 & 0 \\ t_x & t_y & 1 \end{bmatrix} = \begin{bmatrix} x' & y' & 1 \end{bmatrix}$$ Shifting of the origin of the coordinate system to $$t_x,t_y$$ (or if the equation changes because of moving object by $$(t_x,t_y)$$) $$x' = x - t_x$$ $$y' = y - t_y$$ $$\begin{bmatrix} 1 & 0 & -t_x \\ 0 & 1 & -t_y\\ 0 & 0 & 1 \end{bmatrix} \begin{bmatrix} x \\ y \\ 1 \end{bmatrix} = \begin{bmatrix} x' \\ y' \\ 1 \end{bmatrix}\hspace{1cm} OR \hspace{1cm} \begin{bmatrix} x & y & 1 \end{bmatrix} \begin{bmatrix} 1 & 0 & 0 \\ 0 & 1 & 0 \\ -t_x & -t_y & 1 \end{bmatrix} = \begin{bmatrix} x' & y' & 1 \end{bmatrix}$$

Likewise, the following summerises the formula for translations in 3D:
 Translation Type Equation Form Matrix Multiplication Form Moving the object by $$t_x,t_y,t_z$$ (or if the equation changes because of shifting of origin to $$(t_x,t_y,t_z)$$) $$x' = x + t_x$$ $$y' = y + t_y$$ $$z' = z + t_z$$ $$\begin{bmatrix} 1 & 0 & 0 & t_x \\ 0 & 1 & 0 & t_y \\ 0 & 0 & 1 & t_z \\ 0 & 0 & 0 & 1 \end{bmatrix} \begin{bmatrix} x \\ y \\ z \\ 1 \end{bmatrix} = \begin{bmatrix} x' \\ y' \\ z' \\ 1 \end{bmatrix}\hspace{1cm} OR \hspace{1cm} \begin{bmatrix} x & y & z & 1 \end{bmatrix} \begin{bmatrix} 1 & 0 & 0 & 0 \\ 0 & 1 & 0 & 0 \\ 0 & 0 & 1 & 0 \\ t_x & t_y & t_z & 1 \end{bmatrix} = \begin{bmatrix} x' & y' & z' & 1 \end{bmatrix}$$ Shifting of the origin of the coordinate system to $$t_x,t_y,t_z$$ (or if the equation changes because of moving object by $$(t_x,t_y,t_z)$$) $$x' = x - t_x$$ $$y' = y - t_y$$ $$z' = z - t_z$$ $$\begin{bmatrix} 1 & 0 & 0 & -t_x \\ 0 & 1 & 0 & -t_y \\ 0 & 0 & 1 & -t_z \\ 0 & 0 & 0 & 1 \end{bmatrix} \begin{bmatrix} x \\ y \\ z \\ 1 \end{bmatrix} = \begin{bmatrix} x' \\ y' \\ z' \\ 1 \end{bmatrix}\hspace{1cm} OR \hspace{1cm} \begin{bmatrix} x & y & z & 1 \end{bmatrix} \begin{bmatrix} 1 & 0 & 0 & 0 \\ 0 & 1 & 0 & 0 \\ 0 & 0 & 1 & 0 \\ -t_x & -t_y & -t_z & 1 \end{bmatrix} = \begin{bmatrix} x' & y' & z' & 1 \end{bmatrix}$$