---
title: "Conjugate gradient three iterations (10,-6,0)"
subject: "Computational Techniques in Civil Engineering"
chapter: 2
key: "semester_8/computational_techniques_in_civil_engineering:cg-three-iterations-a"
source: https://www.bctengineer.com/q/semester_8/computational_techniques_in_civil_engineering/cg-three-iterations-a
site: BCT Engineering
---

# Conjugate gradient three iterations (10,-6,0)

Computational Techniques in Civil Engineering · Chapter 2: Solutions of linear equations

- Asked in: 2074 Bhadra, 4 marks
- Answer checked by Claude Opus 5.5 (high effort) on 2026-10-14
- Page: https://www.bctengineer.com/q/semester_8/computational_techniques_in_civil_engineering/cg-three-iterations-a
- Whole chapter: https://www.bctengineer.com/md/semester_8/computational_techniques_in_civil_engineering/chapter-2

## Question

Carry out three iterations of the conjugate gradient method for the following system of linear equations:

$$
\begin{bmatrix} 10 & -6 & 0 \\ -6 & 8 & -2 \\ 0 & -2 & 5 \end{bmatrix}\begin{Bmatrix} x_1 \\ x_2 \\ x_3 \end{Bmatrix} = \begin{Bmatrix} 12 \\ 0 \\ 0 \end{Bmatrix}
$$

## Short answer

Starting from zero, the conjugate gradient computations give x1=1.2, x2=0, x3=0 after one iteration; after two, (2.1818, 1.6364, 0); after three, x1=2.4, x2=2.0, x3=0.8, with zero residual.

## Answer

$A=\begin{bmatrix}10&-6&0\\-6&8&-2\\0&-2&5\end{bmatrix}$ (symmetric, positive definite), $b=\{12,0,0\}^T$. Take $x_0=\{0,0,0\}^T$, so $r_0=b=\{12,0,0\}^T$, $d_0=r_0$.

#### Iteration 1
$$
\begin{aligned}
Ad_0&=\{120,-72,0\}^T\\
\alpha_0&=\frac{144}{1440}=0.1\\
x_1&=\{1.2,\,0,\,0\}^T\\
r_1&=\{0,\,7.2,\,0\}^T\\
\beta_0&=\frac{51.84}{144}=0.36,\quad d_1=\{4.32,\,7.2,\,0\}^T
\end{aligned}
$$

#### Iteration 2
$$
\begin{aligned}
Ad_1&=\{0,\,31.68,\,-14.4\}^T\\
\alpha_1&=\frac{51.84}{228.10}=0.22727\\
x_2&=\{2.1818,\,1.6364,\,0\}^T\\
r_2&=\{0,\,0,\,3.2727\}^T\\
\beta_1&=\frac{10.7107}{51.84}=0.20661,\quad d_2=\{0.8926,\,1.4876,\,3.2727\}^T
\end{aligned}
$$

#### Iteration 3
$$
\begin{aligned}
Ad_2&=\{0,\,0,\,13.388\}^T\\
\alpha_2&=\frac{10.7107}{43.815}=0.24444\\
x_3&=\{2.4,\,2.0,\,0.8\}^T\\
r_3&=\{0,\,0,\,0\}^T
\end{aligned}
$$

| Iteration | $x_1$ | $x_2$ | $x_3$ | $\|r\|$ |
|---|---|---|---|---|
| 0 | 0 | 0 | 0 | 12 |
| 1 | 1.2000 | 0 | 0 | 7.2 |
| 2 | 2.1818 | 1.6364 | 0 | 3.273 |
| 3 | 2.4000 | 2.0000 | 0.8000 | 0 |

**Answer: $x_1=2.4,\ x_2=2.0,\ x_3=0.8$.** Check: $10(2.4)-6(2)=12$, $-6(2.4)+8(2)-2(0.8)=0$, $-2(2)+5(0.8)=0$.

## Check yourself

The answer's key points as multiple-choice questions, with the correct option and why.

1. What is alpha_0?
   A. 0.01
   B. 1.2
   C. 0.36
   D. 0.1 = 144/1440
   Answer: D. Ad0 = {120,-72,0}; d0^T A d0 = 1440. (Key point: First alpha)

2. What is beta_0?
   A. 0.1
   B. 7.2
   C. 0.36 = 51.84/144
   D. 0.2066
   Answer: C. r1 = {0,7.2,0}; 7.2^2 = 51.84. (Key point: First beta)

3. Final solution?
   A. {1.2,0,0}
   B. x = {2.4, 2.0, 0.8}
   C. {2.1818,1.6364,0}
   D. {12,0,0}
   Answer: B. r3 = 0 so converged in n=3. (Key point: Final)

## Related in Computational Techniques in Civil Engineering

- [Conjugate gradient numerical (5 iterations)](https://www.bctengineer.com/question.md?key=semester_8%2Fcomputational_techniques_in_civil_engineering%3Acg-numerical-3-0-1) — Computational Techniques in Civil Engineering, chapter 2
- [Linear solution techniques; CG two iterations](https://www.bctengineer.com/question.md?key=semester_8%2Fcomputational_techniques_in_civil_engineering%3Asolution-techniques-cg-numerical-two-iter) — Computational Techniques in Civil Engineering, chapter 2
- [Conjugate gradient numerical (3,0,2 system)](https://www.bctengineer.com/question.md?key=semester_8%2Fcomputational_techniques_in_civil_engineering%3Acg-numerical-3-0-2) — Computational Techniques in Civil Engineering, chapter 2, asked 2×
- [Conjugate gradient numerical (2,-1 system)](https://www.bctengineer.com/question.md?key=semester_8%2Fcomputational_techniques_in_civil_engineering%3Acg-numerical-three-unknowns-a) — Computational Techniques in Civil Engineering, chapter 2, asked 2×
- [Conjugate gradient method and algorithm](https://www.bctengineer.com/question.md?key=semester_8%2Fcomputational_techniques_in_civil_engineering%3Acg-method-algorithm) — Computational Techniques in Civil Engineering, chapter 2, asked 2×
- [Why conjugate gradient over Gaussian methods](https://www.bctengineer.com/question.md?key=semester_8%2Fcomputational_techniques_in_civil_engineering%3Acg-vs-gaussian) — Computational Techniques in Civil Engineering, chapter 2

## Related in other subjects

- [Conjugate beam: slope and deflection at free end C](https://www.bctengineer.com/question.md?key=semester_4%2Ftheory_of_structures_i%3Aconjugate-udl-2knm-10kn-5kn-2068) — Theory of Structures I, chapter 4, asked 2×
- [Conjugate beam: slope and deflection at free end](https://www.bctengineer.com/question.md?key=semester_4%2Ftheory_of_structures_i%3Aconjugate-beam-24kn-10knm) — Theory of Structures I, chapter 4
- [N-R two iterations, y12 = 10∠−73.74°](https://www.bctengineer.com/question.md?key=semester_5%2Fpower_system_analysis_ii%3Anr-two-bus-y12-10) — Power System Analysis II, chapter 2
- [Conjugate beam: slope and deflection at free end C](https://www.bctengineer.com/question.md?key=semester_4%2Ftheory_of_structures_i%3Aconjugate-udl-15-3kn-2076b) — Theory of Structures I, chapter 4, asked 2×
