# Nakafa Learning Content

> For AI agents: use [llms.txt](https://nakafa.com/llms.txt) for the site index. Markdown versions are available by appending `.md` to content URLs or sending `Accept: text/markdown`.

URL: https://nakafa.com/id/materi/matematika/transformasi-fungsi/rotasi
Source: https://raw.githubusercontent.com/nakafaai/nakafa.com/refs/heads/main/packages/contents/material/lesson/mathematics/function-transformation/rotation/id.mdx

Pelajari rotasi fungsi terhadap titik tetap dengan contoh bertahap. Pelajari rumus rotasi, sudut, dan transformasi untuk berbagai jenis fungsi.

---

## Pengertian Rotasi Fungsi

Rotasi adalah transformasi geometri yang memutar suatu objek terhadap titik pusat tertentu dengan sudut rotasi yang ditentukan. Dalam konteks fungsi, rotasi mengubah posisi grafik fungsi dengan cara memutar setiap titik pada grafik tersebut.

Bayangkan seperti memutar sebuah roda. Setiap titik pada roda akan bergerak mengikuti lingkaran dengan pusat rotasi sebagai pusatnya. Begitu juga dengan grafik fungsi, setiap titik akan berputar mengikuti pola yang sama.

## Rumus Rotasi Terhadap Titik Pusat

Untuk rotasi terhadap titik pusat $$(a, b)$$ dengan sudut $$\theta$$, rumus transformasinya adalah:

Visible text: Untuk rotasi terhadap titik pusat dengan sudut , rumus transformasinya adalah:

Component: MathContainer
Children:

```math
x' = (x - a) \cos \theta - (y - b) \sin \theta + a
```

```math
y' = (x - a) \sin \theta + (y - b) \cos \theta + b
```

Dimana:

- $$(x, y)$$ adalah koordinat titik asal
- <InlineMath math="(x', y')" /> adalah koordinat titik hasil rotasi
- $$(a, b)$$ adalah titik pusat rotasi
- $$\theta$$ adalah sudut rotasi (positif untuk arah berlawanan jarum jam)

Visible text: - adalah koordinat titik asal
- <InlineMath math="(x', y')" /> adalah koordinat titik hasil rotasi
- adalah titik pusat rotasi
- adalah sudut rotasi (positif untuk arah berlawanan jarum jam)

## Rotasi Khusus Terhadap Titik Asal

Ketika rotasi dilakukan terhadap titik asal $$(0, 0)$$, rumus menjadi lebih sederhana:

Visible text: Ketika rotasi dilakukan terhadap titik asal , rumus menjadi lebih sederhana:

1. Rotasi $$90^\circ$$

    
   
   ```math
   (x, y) \rightarrow (-y, x)
   ```

2. Rotasi $$180^\circ$$

    
   
   ```math
   (x, y) \rightarrow (-x, -y)
   ```

3. Rotasi $$270^\circ$$

    
   
   ```math
   (x, y) \rightarrow (y, -x)
   ```

Visible text: 1. Rotasi 

 
 

2. Rotasi 

 
 

3. Rotasi

## Visualisasi Rotasi Fungsi Kuadrat

Mari kita lihat bagaimana rotasi mempengaruhi fungsi kuadrat $$y = x^2$$:

Visible text: Mari kita lihat bagaimana rotasi mempengaruhi fungsi kuadrat :

Component: LineEquation
Props:
- title: Rotasi Fungsi $$y = x^2$$ Terhadap Titik Asal
  Visible text: Rotasi Fungsi Terhadap Titik Asal
- description: Perbandingan fungsi asli dengan hasil rotasi $$90^\circ$$ berlawanan arah jarum jam.
  Visible text: Perbandingan fungsi asli dengan hasil rotasi berlawanan arah jarum jam.
- data: [
{
points: Array.from({ length: 21 }, (_, i) => {
const x = (i - 10) * 0.5;
const y = x * x * 0.25;
return { x, y, z: 0 };
}),
color: getColor("PURPLE"),
showPoints: false,
labels: [
{
text: "y = x²",
at: 15,
offset: [0.5, 0.5, 0],
},
],
},
{
points: Array.from({ length: 21 }, (_, i) => {
const x = (i - 10) * 0.5;
const y = x * x * 0.25;
// Rotasi 90° terhadap titik asal: (x,y) → (-y,x)
const xRotated = -y;
const yRotated = x;
return { x: xRotated, y: yRotated, z: 0 };
}),
color: getColor("ORANGE"),
showPoints: false,
labels: [
{
text: "Hasil Rotasi 90°",
at: 5,
offset: [-1, 0.5, 0],
},
],
},
]

## Sifat Rotasi Fungsi

Rotasi memiliki beberapa sifat penting:

- **Mempertahankan Bentuk**: Rotasi tidak mengubah bentuk dasar grafik, hanya mengubah orientasinya
- **Mempertahankan Jarak**: Jarak antara dua titik pada grafik tetap sama setelah rotasi
- **Komposisi Rotasi**: Rotasi berturut-turut dapat digabungkan dengan menjumlahkan sudut rotasinya

## Penerapan Rotasi pada Berbagai Fungsi

### Rotasi Fungsi Linear

Untuk fungsi linear $$y = mx + c$$, rotasi akan mengubah kemiringan dan posisi garis.

Visible text: Untuk fungsi linear , rotasi akan mengubah kemiringan dan posisi garis.

Component: LineEquation
Props:
- title: Rotasi Fungsi Linear $$y = 2x + 1$$
  Visible text: Rotasi Fungsi Linear
- description: Rotasi $$45^\circ$$ terhadap titik asal.
  Visible text: Rotasi terhadap titik asal.
- data: [
{
points: Array.from({ length: 11 }, (_, i) => {
const x = (i - 5);
const y = 2 * x + 1;
return { x, y, z: 0 };
}),
color: getColor("TEAL"),
showPoints: false,
labels: [
{
text: "y = 2x + 1",
at: 6,
offset: [1, 0.5, 0],
},
],
},
{
points: Array.from({ length: 11 }, (_, i) => {
const x = (i - 5);
const y = 2 * x + 1;
// Rotasi 45° terhadap titik asal
const cos45 = Math.cos(Math.PI / 4);
const sin45 = Math.sin(Math.PI / 4);
const xRotated = x * cos45 - y * sin45;
const yRotated = x * sin45 + y * cos45;
return { x: xRotated, y: yRotated, z: 0 };
}),
color: getColor("VIOLET"),
showPoints: false,
labels: [
{
text: "Rotasi 45°",
at: 6,
offset: [-0.5, 0.5, 0],
},
],
},
]

### Rotasi Fungsi Eksponensial

Rotasi juga dapat diterapkan pada fungsi eksponensial dengan hasil yang menarik.

Component: LineEquation
Props:
- title: Rotasi Fungsi $$y = 2^x$$
  Visible text: Rotasi Fungsi
- description: Rotasi $$90^\circ$$ berlawanan arah jarum jam.
  Visible text: Rotasi berlawanan arah jarum jam.
- cameraPosition: [8, 6, 8]
- data: [
{
points: Array.from({ length: 15 }, (_, i) => {
const x = (i - 7) * 0.5;
const y = Math.pow(2, x * 0.5);
return { x, y, z: 0 };
}),
color: getColor("EMERALD"),
showPoints: false,
labels: [
{
text: "y = 2^x",
at: 12,
offset: [0.5, 0.5, 0],
},
],
},
{
points: Array.from({ length: 15 }, (_, i) => {
const x = (i - 7) * 0.5;
const y = Math.pow(2, x * 0.5);
// Rotasi 90° terhadap titik asal: (x,y) → (-y,x)
const xRotated = -y;
const yRotated = x;
return { x: xRotated, y: yRotated, z: 0 };
}),
color: getColor("AMBER"),
showPoints: false,
labels: [
{
text: "Rotasi 90°",
at: 3,
offset: [-0.5, 0.5, 0],
},
],
},
]

## Langkah Menentukan Hasil Rotasi

Untuk menentukan hasil rotasi suatu fungsi, ikuti langkah berikut:

- Tentukan titik pusat rotasi dan sudut rotasi yang diinginkan
- Pilih beberapa titik pada grafik fungsi asli sebagai sampel
- Terapkan rumus rotasi pada setiap titik sampel
- Hubungkan titik hasil rotasi untuk membentuk grafik fungsi baru
- Verifikasi hasil dengan memeriksa beberapa titik tambahan

## Latihan

1. Tentukan hasil rotasi titik $$(3, 4)$$ terhadap titik asal dengan sudut $$90^\circ$$ berlawanan arah jarum jam.

2. Fungsi $$f(x) = x^2 - 2x + 1$$ dirotasi $$180^\circ$$ terhadap titik asal. Tentukan koordinat titik puncak hasil rotasi jika titik puncak asli berada di $$(1, 0)$$.

3. Garis $$y = 3x - 2$$ dirotasi $$270^\circ$$ terhadap titik asal. Tentukan persamaan garis hasil rotasi.

4. Titik $$(2, 5)$$ dirotasi $$60^\circ$$ terhadap titik $$(1, 1)$$. Tentukan koordinat hasil rotasi.

5. Fungsi $$y = \sqrt{x}$$ untuk $$x \geq 0$$ dirotasi $$90^\circ$$ berlawanan arah jarum jam terhadap titik asal. Jelaskan bentuk grafik hasil rotasi.

Visible text: 1. Tentukan hasil rotasi titik terhadap titik asal dengan sudut berlawanan arah jarum jam.

2. Fungsi dirotasi terhadap titik asal. Tentukan koordinat titik puncak hasil rotasi jika titik puncak asli berada di .

3. Garis dirotasi terhadap titik asal. Tentukan persamaan garis hasil rotasi.

4. Titik dirotasi terhadap titik . Tentukan koordinat hasil rotasi.

5. Fungsi untuk dirotasi berlawanan arah jarum jam terhadap titik asal. Jelaskan bentuk grafik hasil rotasi.

### Kunci Jawaban

1. Menggunakan rumus rotasi $$90^\circ$$:

   <MathContainer>
   
   
   ```math
   (x, y) \rightarrow (-y, x)
   ```

   
   
   ```math
   (3, 4) \rightarrow (-4, 3)
   ```

   </MathContainer>

   Jadi hasil rotasi adalah $$(-4, 3)$$.

   <LineEquation
     title={<>Visualisasi Rotasi Titik $$(3, 4)$$</>}
     description={<>Rotasi $$90^\circ$$ berlawanan arah jarum jam terhadap titik asal.</>}
     cameraPosition={[8, 6, 8]}
     data={[
       {
         points: [
           { x: 0, y: 0, z: 0 },
           { x: 3, y: 4, z: 0 }
         ],
         color: getColor("PURPLE"),
         showPoints: false,
         labels: [
           {
             text: "(3, 4)",
             at: 1,
             offset: [0.3, 0.3, 0],
           },
         ],
         cone: { position: "end", size: 0.3 }
       },
       {
         points: [
           { x: 0, y: 0, z: 0 },
           { x: -4, y: 3, z: 0 }
         ],
         color: getColor("ORANGE"),
         showPoints: false,
         labels: [
           {
             text: "(-4, 3)",
             at: 1,
             offset: [-0.5, 0.3, 0],
           },
         ],
         cone: { position: "end", size: 0.3 }
       },
     ]}
   />

2. Titik puncak asli dirotasi $$180^\circ$$:

   <MathContainer>
   
   
   ```math
   (x, y) \rightarrow (-x, -y)
   ```

   
   
   ```math
   (1, 0) \rightarrow (-1, 0)
   ```

   </MathContainer>

   Koordinat titik puncak hasil rotasi adalah $$(-1, 0)$$.

   <LineEquation
     title={<>Rotasi Fungsi $$f(x) = x^2 - 2x + 1$$</>}
     description={<>Rotasi $$180^\circ$$ terhadap titik asal.</>}
     cameraPosition={[10, 6, 10]}
     data={[
       {
         points: Array.from({ length: 21 }, (_, i) => {
           const x = (i - 10) * 0.3;
           const y = x * x - 2 * x + 1;
           return { x, y, z: 0 };
         }),
         color: getColor("TEAL"),
         showPoints: false,
         labels: [
           {
             text: "f(x) = x² - 2x + 1",
             at: 18,
             offset: [1, 0.5, 0],
           },
         ],
       },
       {
         points: Array.from({ length: 21 }, (_, i) => {
           const x = (i - 10) * 0.3;
           const y = x * x - 2 * x + 1;
           // Rotasi 180°: (x,y) → (-x,-y)
           const xRotated = -x;
           const yRotated = -y;
           return { x: xRotated, y: yRotated, z: 0 };
         }),
         color: getColor("VIOLET"),
         showPoints: false,
         labels: [
           {
             text: "Hasil Rotasi 180°",
             at: 8,
             offset: [-0.5, -0.5, 0],
           },
         ],
       },
     ]}
   />

3. Ambil dua titik pada garis dan rotasi $$270^\circ$$:

   <MathContainer>
   
   
   ```math
   (x, y) \rightarrow (y, -x)
   ```

   
   
   ```math
   (0, -2) \rightarrow (-2, 0)
   ```

   
   
   ```math
   (1, 1) \rightarrow (1, -1)
   ```

   
   
   ```math
   m = \frac{-1 - 0}{1 - (-2)} = \frac{-1}{3}
   ```

   
   
   ```math
   y = -\frac{1}{3}x - \frac{2}{3}
   ```

   </MathContainer>

   Maka persamaan garis hasil rotasi adalah $$y = -\frac{1}{3}x - \frac{2}{3}$$.

   <LineEquation
     title={<>Rotasi Garis $$y = 3x - 2$$</>}
     description={<>Rotasi $$270^\circ$$ terhadap titik asal.</>}
     cameraPosition={[8, 6, 8]}
     data={[
       {
         points: Array.from({ length: 11 }, (_, i) => {
           const x = (i - 5) * 0.8;
           const y = 3 * x - 2;
           return { x, y, z: 0 };
         }),
         color: getColor("EMERALD"),
         showPoints: false,
         labels: [
           {
             text: "y = 3x - 2",
             at: 6,
             offset: [2, 0.5, 0],
           },
         ],
       },
       {
         points: Array.from({ length: 11 }, (_, i) => {
           const x = (i - 5) * 0.8;
           const y = 3 * x - 2;
           // Rotasi 270°: (x,y) → (y,-x)
           const xRotated = y;
           const yRotated = -x;
           return { x: xRotated, y: yRotated, z: 0 };
         }),
         color: getColor("AMBER"),
         showPoints: false,
         labels: [
           {
             text: "y = -⅓x - ⅔",
             at: 5,
             offset: [-0.5, 1.5, 0],
           },
         ],
       },
     ]}
   />

4. Menggunakan rumus rotasi terhadap titik dengan sudut $$60^\circ$$:

   <MathContainer>
   <BlockMath math="x' = (x-a) \cos \theta - (y-b) \sin \theta + a" />
   <BlockMath math="y' = (x-a) \sin \theta + (y-b) \cos \theta + b" />
   <BlockMath math="x' = (2-1) \cdot \frac{1}{2} - (5-1) \cdot \frac{\sqrt{3}}{2} + 1" />
   <BlockMath math="x' = \frac{3}{2} - 2\sqrt{3}" />
   <BlockMath math="y' = (2-1) \cdot \frac{\sqrt{3}}{2} + (5-1) \cdot \frac{1}{2} + 1" />
   <BlockMath math="y' = 3 + \frac{\sqrt{3}}{2}" />
   </MathContainer>

   Koordinat hasil rotasi: $$(\frac{3}{2} - 2\sqrt{3}, 3 + \frac{\sqrt{3}}{2})$$

   <LineEquation
     title={<>Rotasi Titik $$(2, 5)$$ Terhadap Titik $$(1, 1)$$</>}
     description={<>Rotasi $$60^\circ$$ berlawanan arah jarum jam.</>}
     cameraPosition={[8, 6, 8]}
     data={[
       {
         points: [
           { x: 1, y: 1, z: 0 },
           { x: 2, y: 5, z: 0 }
         ],
         color: getColor("CYAN"),
         showPoints: false,
         labels: [
           {
             text: "(2, 5)",
             at: 1,
             offset: [0.3, 0.3, 0],
           },
           {
             text: "Pusat (1, 1)",
             at: 0,
             offset: [0.3, -0.3, 0],
           },
         ],
         cone: { position: "end", size: 0.3 }
       },
       {
         points: [
           { x: 1, y: 1, z: 0 },
           { x: 1.5 - 2 * Math.sqrt(3), y: 3 + Math.sqrt(3) / 2, z: 0 }
         ],
         color: getColor("PINK"),
         showPoints: false,
         labels: [
           {
             text: "Hasil Rotasi",
             at: 1,
             offset: [-0.5, 0.3, 0],
           },
         ],
         cone: { position: "end", size: 0.3 }
       },
     ]}
   />

5. Fungsi $$y = \sqrt{x}$$ dirotasi $$90^\circ$$ menjadi:

   <MathContainer>
   
   
   ```math
   x = -\sqrt{y}
   ```

   
   
   ```math
   y = x^2 \text{ untuk} x \leq 0
   ```

   </MathContainer>

   Grafik hasil rotasi berbentuk parabola yang terbuka ke atas dengan domain $$x \leq 0$$ dan range $$y \geq 0$$. Ini adalah refleksi dari parabola $$y = x^2$$ terhadap sumbu $$y$$.

   <LineEquation
     title={<>Rotasi Fungsi $$y = \sqrt{x}$$</>}
     description={<>Rotasi $$90^\circ$$ berlawanan arah jarum jam terhadap titik asal.</>}
     cameraPosition={[8, 6, 8]}
     data={[
       {
         points: Array.from({ length: 21 }, (_, i) => {
           const x = i * 0.25;
           const y = Math.sqrt(x);
           return { x, y, z: 0 };
         }),
         color: getColor("LIME"),
         showPoints: false,
         labels: [
           {
             text: "y = √x",
             at: 15,
             offset: [0.5, 0.3, 0],
           },
         ],
       },
       {
         points: Array.from({ length: 21 }, (_, i) => {
           const x = i * 0.25;
           const y = Math.sqrt(x);
           // Rotasi 90°: (x,y) → (-y,x)
           const xRotated = -y;
           const yRotated = x;
           return { x: xRotated, y: yRotated, z: 0 };
         }),
         color: getColor("ROSE"),
         showPoints: false,
         labels: [
           {
             text: "y = x² (x ≤ 0)",
             at: 15,
             offset: [-0.8, 0.3, 0],
           },
         ],
       },
     ]}
   />

Visible text: 1. Menggunakan rumus rotasi :

 <MathContainer>
 
 

 
 

 </MathContainer>

 Jadi hasil rotasi adalah .

 <LineEquation
 title={<>Visualisasi Rotasi Titik </>}
 description={<>Rotasi berlawanan arah jarum jam terhadap titik asal.</>}
 cameraPosition={[8, 6, 8]}
 data={[
 {
 points: [
 { x: 0, y: 0, z: 0 },
 { x: 3, y: 4, z: 0 }
 ],
 color: getColor("PURPLE"),
 showPoints: false,
 labels: [
 {
 text: "(3, 4)",
 at: 1,
 offset: [0.3, 0.3, 0],
 },
 ],
 cone: { position: "end", size: 0.3 }
 },
 {
 points: [
 { x: 0, y: 0, z: 0 },
 { x: -4, y: 3, z: 0 }
 ],
 color: getColor("ORANGE"),
 showPoints: false,
 labels: [
 {
 text: "(-4, 3)",
 at: 1,
 offset: [-0.5, 0.3, 0],
 },
 ],
 cone: { position: "end", size: 0.3 }
 },
 ]}
 />

2. Titik puncak asli dirotasi :

 <MathContainer>
 
 

 
 

 </MathContainer>

 Koordinat titik puncak hasil rotasi adalah .

 <LineEquation
 title={<>Rotasi Fungsi </>}
 description={<>Rotasi terhadap titik asal.</>}
 cameraPosition={[10, 6, 10]}
 data={[
 {
 points: Array.from({ length: 21 }, (_, i) => {
 const x = (i - 10) * 0.3;
 const y = x * x - 2 * x + 1;
 return { x, y, z: 0 };
 }),
 color: getColor("TEAL"),
 showPoints: false,
 labels: [
 {
 text: "f(x) = x² - 2x + 1",
 at: 18,
 offset: [1, 0.5, 0],
 },
 ],
 },
 {
 points: Array.from({ length: 21 }, (_, i) => {
 const x = (i - 10) * 0.3;
 const y = x * x - 2 * x + 1;
 // Rotasi 180°: (x,y) → (-x,-y)
 const xRotated = -x;
 const yRotated = -y;
 return { x: xRotated, y: yRotated, z: 0 };
 }),
 color: getColor("VIOLET"),
 showPoints: false,
 labels: [
 {
 text: "Hasil Rotasi 180°",
 at: 8,
 offset: [-0.5, -0.5, 0],
 },
 ],
 },
 ]}
 />

3. Ambil dua titik pada garis dan rotasi :

 <MathContainer>
 
 

 
 

 
 

 
 

 
 

 </MathContainer>

 Maka persamaan garis hasil rotasi adalah .

 <LineEquation
 title={<>Rotasi Garis </>}
 description={<>Rotasi terhadap titik asal.</>}
 cameraPosition={[8, 6, 8]}
 data={[
 {
 points: Array.from({ length: 11 }, (_, i) => {
 const x = (i - 5) * 0.8;
 const y = 3 * x - 2;
 return { x, y, z: 0 };
 }),
 color: getColor("EMERALD"),
 showPoints: false,
 labels: [
 {
 text: "y = 3x - 2",
 at: 6,
 offset: [2, 0.5, 0],
 },
 ],
 },
 {
 points: Array.from({ length: 11 }, (_, i) => {
 const x = (i - 5) * 0.8;
 const y = 3 * x - 2;
 // Rotasi 270°: (x,y) → (y,-x)
 const xRotated = y;
 const yRotated = -x;
 return { x: xRotated, y: yRotated, z: 0 };
 }),
 color: getColor("AMBER"),
 showPoints: false,
 labels: [
 {
 text: "y = -⅓x - ⅔",
 at: 5,
 offset: [-0.5, 1.5, 0],
 },
 ],
 },
 ]}
 />

4. Menggunakan rumus rotasi terhadap titik dengan sudut :

 <MathContainer>
 <BlockMath math="x' = (x-a) \cos \theta - (y-b) \sin \theta + a" />
 <BlockMath math="y' = (x-a) \sin \theta + (y-b) \cos \theta + b" />
 <BlockMath math="x' = (2-1) \cdot \frac{1}{2} - (5-1) \cdot \frac{\sqrt{3}}{2} + 1" />
 <BlockMath math="x' = \frac{3}{2} - 2\sqrt{3}" />
 <BlockMath math="y' = (2-1) \cdot \frac{\sqrt{3}}{2} + (5-1) \cdot \frac{1}{2} + 1" />
 <BlockMath math="y' = 3 + \frac{\sqrt{3}}{2}" />
 </MathContainer>

 Koordinat hasil rotasi: 

 <LineEquation
 title={<>Rotasi Titik Terhadap Titik </>}
 description={<>Rotasi berlawanan arah jarum jam.</>}
 cameraPosition={[8, 6, 8]}
 data={[
 {
 points: [
 { x: 1, y: 1, z: 0 },
 { x: 2, y: 5, z: 0 }
 ],
 color: getColor("CYAN"),
 showPoints: false,
 labels: [
 {
 text: "(2, 5)",
 at: 1,
 offset: [0.3, 0.3, 0],
 },
 {
 text: "Pusat (1, 1)",
 at: 0,
 offset: [0.3, -0.3, 0],
 },
 ],
 cone: { position: "end", size: 0.3 }
 },
 {
 points: [
 { x: 1, y: 1, z: 0 },
 { x: 1.5 - 2 * Math.sqrt(3), y: 3 + Math.sqrt(3) / 2, z: 0 }
 ],
 color: getColor("PINK"),
 showPoints: false,
 labels: [
 {
 text: "Hasil Rotasi",
 at: 1,
 offset: [-0.5, 0.3, 0],
 },
 ],
 cone: { position: "end", size: 0.3 }
 },
 ]}
 />

5. Fungsi dirotasi menjadi:

 <MathContainer>
 
 

 
 

 </MathContainer>

 Grafik hasil rotasi berbentuk parabola yang terbuka ke atas dengan domain dan range . Ini adalah refleksi dari parabola terhadap sumbu .

 <LineEquation
 title={<>Rotasi Fungsi </>}
 description={<>Rotasi berlawanan arah jarum jam terhadap titik asal.</>}
 cameraPosition={[8, 6, 8]}
 data={[
 {
 points: Array.from({ length: 21 }, (_, i) => {
 const x = i * 0.25;
 const y = Math.sqrt(x);
 return { x, y, z: 0 };
 }),
 color: getColor("LIME"),
 showPoints: false,
 labels: [
 {
 text: "y = √x",
 at: 15,
 offset: [0.5, 0.3, 0],
 },
 ],
 },
 {
 points: Array.from({ length: 21 }, (_, i) => {
 const x = i * 0.25;
 const y = Math.sqrt(x);
 // Rotasi 90°: (x,y) → (-y,x)
 const xRotated = -y;
 const yRotated = x;
 return { x: xRotated, y: yRotated, z: 0 };
 }),
 color: getColor("ROSE"),
 showPoints: false,
 labels: [
 {
 text: "y = x² (x ≤ 0)",
 at: 15,
 offset: [-0.8, 0.3, 0],
 },
 ],
 },
 ]}
 />