# Nakafa Framework: LLM
URL: https://nakafa.com/en/subject/high-school/12/mathematics/function-transformation/horizontal-translation
Source: https://raw.githubusercontent.com/nakafaai/nakafa.com/refs/heads/main/packages/contents/subject/high-school/12/mathematics/function-transformation/horizontal-translation/en.mdx
Output docs content for large language models.
---
export const metadata = {
  title: "Horizontal Translation",
  description: "Learn how horizontal translation shifts a function's graph left or right without altering its shape, enhancing your understanding of function transformations.",
  authors: [{ name: "Nabil Akbarazzima Fatih" }],
  date: "05/26/2025",
  subject: "Function Transformation",
};
import { getColor } from "@repo/design-system/lib/color";
import { LineEquation } from "@repo/design-system/components/contents/line-equation";
## Basic Concepts of Horizontal Translation
Horizontal translation is a geometric transformation that shifts the graph of a function left or right along the x-axis without changing the shape of the graph. Imagine sliding an object horizontally on a table, its shape remains the same, only its position changes.
If we have a function , then horizontal translation produces a new function  where  is the translation constant.
### Rules of Horizontal Translation
For any function , horizontal translation is defined as:
Where:
- If , the graph shifts to the **right** by  units
- If , the graph shifts to the **left** by  units
- If , there is no translation (graph remains the same)
## Visualization of Horizontal Translation
Let's see how horizontal translation works on the quadratic function .
Horizontal Translation of Quadratic Function >}
  description="Notice how the graph shifts horizontally without changing the parabola shape."
  showZAxis={false}
  cameraPosition={[12, 8, 12]}
  data={[
    {
      points: Array.from({ length: 41 }, (_, i) => {
        const x = (i - 20) * 0.25;
        return { x, y: x * x, z: 0 };
      }),
      color: getColor("PURPLE"),
      labels: [{ text: "f(x) = x²", offset: [0.5, 1, 0] }],
      showPoints: false,
    },
    {
      points: Array.from({ length: 41 }, (_, i) => {
        const x = (i - 20) * 0.25;
        return { x, y: (x - 3) * (x - 3), z: 0 };
      }),
      color: getColor("ORANGE"),
      labels: [{ text: "g(x) = (x - 3)²", offset: [0.5, 1, 0] }],
      showPoints: false,
    },
    {
      points: Array.from({ length: 41 }, (_, i) => {
        const x = (i - 20) * 0.25;
        return { x, y: (x + 2) * (x + 2), z: 0 };
      }),
      color: getColor("TEAL"),
      labels: [{ text: "h(x) = (x + 2)²", offset: [0.5, 1, 0] }],
      showPoints: false,
    },
  ]}
/>
From the visualization above, we can observe:
- The original function  has its vertex at 
- Function  shifts right by 3 units with vertex at 
- Function  shifts left by 2 units with vertex at 
## Horizontal Translation on Linear Functions
Now let's apply the same concept to the linear function .
Horizontal Translation of Linear Function >}
  description="The line maintains the same slope, only its horizontal position changes."
  showZAxis={false}
  cameraPosition={[10, 6, 10]}
  data={[
    {
      points: Array.from({ length: 21 }, (_, i) => {
        const x = (i - 10) * 0.5;
        return { x, y: 2 * x + 1, z: 0 };
      }),
      color: getColor("VIOLET"),
      labels: [{ text: "f(x) = 2x + 1", offset: [1, 0.5, 0] }],
      showPoints: false,
    },
    {
      points: Array.from({ length: 21 }, (_, i) => {
        const x = (i - 10) * 0.5;
        return { x, y: 2 * (x - 4) + 1, z: 0 };
      }),
      color: getColor("AMBER"),
      labels: [{ text: "g(x) = 2(x - 4) + 1", offset: [1, 0.5, 0] }],
      showPoints: false,
    },
    {
      points: Array.from({ length: 21 }, (_, i) => {
        const x = (i - 10) * 0.5;
        return { x, y: 2 * (x + 3) + 1, z: 0 };
      }),
      color: getColor("CYAN"),
      labels: [{ text: "h(x) = 2(x + 3) + 1", offset: [1, 0.5, 0] }],
      showPoints: false,
    },
  ]}
/>
Notice that:
- All lines have the same slope of 2
- Function  shifts right by 4 units
- Function  shifts left by 3 units
## Important Properties of Horizontal Translation
### Graph Shape Remains Unchanged
Horizontal translation preserves the original shape of the graph. The vertical distance between points on the graph remains the same, only the horizontal position changes.
### Effect on Coordinate Points
If point  is on the graph of , then after horizontal translation by , that point becomes  on the graph of .
### Domain and Range
- **Domain**: Shifts by  units
- **Range**: Does not change after horizontal translation
If the domain of the original function is , then the domain after horizontal translation  becomes .
## Application Examples
### Exponential Function Example
Let's look at horizontal translation on the exponential function .
Horizontal Translation of Exponential Function >}
  description="The exponential curve maintains its characteristics after horizontal translation."
  showZAxis={false}
  cameraPosition={[8, 5, 8]}
  data={[
    {
      points: Array.from({ length: 31 }, (_, i) => {
        const x = (i - 15) * 0.3;
        return { x, y: Math.pow(2, x), z: 0 };
      }),
      color: getColor("INDIGO"),
      labels: [{ text: "f(x) = 2^x", offset: [0.5, 1, 0] }],
      showPoints: false,
    },
    {
      points: Array.from({ length: 31 }, (_, i) => {
        const x = (i - 15) * 0.3;
        return { x, y: Math.pow(2, x - 2), z: 0 };
      }),
      color: getColor("EMERALD"),
      labels: [{ text: "g(x) = 2^(x-2)", offset: [0.5, 1, 0] }],
      showPoints: false,
    },
    {
      points: Array.from({ length: 31 }, (_, i) => {
        const x = (i - 15) * 0.3;
        return { x, y: Math.pow(2, x + 1), z: 0 };
      }),
      color: getColor("ROSE"),
      labels: [{ text: "h(x) = 2^(x+1)", offset: [0.5, 1, 0] }],
      showPoints: false,
    },
  ]}
/>
For exponential functions:
- The horizontal asymptote remains at  for all functions
- The y-intercept changes due to horizontal shift
- Function  shifts right by 2 units
- Function  shifts left by 1 unit
## Difference from Vertical Translation
It's important to understand the difference between horizontal and vertical translation:
### Horizontal Translation
- Changes the function input: 
- Affects the x position of each point
- Domain changes, range remains
### Vertical Translation
- Changes the function output: 
- Affects the y position of each point
- Domain remains, range changes
## Exercises
1. Given the function . Determine the equation of the function resulting from horizontal translation to the right by 3 units.
2. If the graph of function  is translated horizontally to the left by 4 units, determine:
   - The equation of the resulting translated function
   - The domain of the function after translation
3. Function  undergoes horizontal translation such that point  becomes . Determine the translation constant value and the equation of the resulting translated function.
### Answer Key
1. Horizontal translation to the right by 3 units: 
   Function  and Its Translation Result>}
     description="Original quadratic function and the result of horizontal translation to the right by 3 units."
     showZAxis={false}
     cameraPosition={[12, 8, 12]}
     data={[
       {
         points: Array.from({ length: 41 }, (_, i) => {
           const x = (i - 20) * 0.25;
           return { x, y: x * x + 2 * x + 1, z: 0 };
         }),
         color: getColor("PURPLE"),
         labels: [{ text: "f(x) = x² + 2x + 1", offset: [1, 1, 0] }],
         showPoints: false,
       },
       {
         points: Array.from({ length: 41 }, (_, i) => {
           const x = (i - 20) * 0.25;
           return { x, y: x * x - 4 * x + 4, z: 0 };
         }),
         color: getColor("ORANGE"),
         labels: [{ text: "f'(x) = x² - 4x + 4", offset: [1, 1, 0] }],
         showPoints: false,
       },
     ]}
   />
2. Equation of the resulting translated function:
    
   - Translation to the left by 4 units: 
   - Domain after translation: , so  or 
   Visualization:
   Function  and Its Translation Result>}
     description="Original square root function and the result of horizontal translation to the left by 4 units."
     showZAxis={false}
     cameraPosition={[8, 6, 8]}
     data={[
       {
         points: Array.from({ length: 21 }, (_, i) => {
           const x = i * 0.25;
           return { x, y: Math.sqrt(x), z: 0 };
         }),
         color: getColor("VIOLET"),
         labels: [{ text: "g(x) = √x", offset: [1, 0.5, 0] }],
         showPoints: false,
       },
       {
         points: Array.from({ length: 21 }, (_, i) => {
           const x = i * 0.25 - 4;
           if (x + 4 >= 0) {
             return { x, y: Math.sqrt(x + 4), z: 0 };
           }
           return null;
         }).filter(Boolean),
         color: getColor("TEAL"),
         labels: [{ text: "g'(x) = √(x + 4)", offset: [1, 0.5, 0] }],
         showPoints: false,
       },
     ]}
   />
3. Point  on  becomes , meaning horizontal translation by  units to the right.
   Equation of the translation result: 
   Function  and Its Translation Result>}
     description="Original exponential function and the result of horizontal translation to the right by 2 units."
     showZAxis={false}
     cameraPosition={[10, 6, 10]}
     data={[
       {
         points: Array.from({ length: 31 }, (_, i) => {
           const x = (i - 15) * 0.2;
           return { x, y: Math.pow(3, x), z: 0 };
         }),
         color: getColor("INDIGO"),
         labels: [{ text: "h(x) = 3^x", offset: [0.5, 1, 0] }],
         showPoints: false,
       },
       {
         points: Array.from({ length: 31 }, (_, i) => {
           const x = (i - 15) * 0.2;
           return { x, y: Math.pow(3, x - 2), z: 0 };
         }),
         color: getColor("EMERALD"),
         labels: [{ text: "h'(x) = 3^(x-2)", offset: [0.5, 1, 0] }],
         showPoints: false,
       },
     ]}
   />