# Algebra/Powers
## Laws of indices of all rational exponents

An index is of the form $a^{x}$, and the laws on how to manipulate them is vital knowledge.

### Power of one and zero

Any base raised to the power of one is simply the base.
For example,
$1^{1}=1$
$8^{1}=8$
$0^{1}=0$
$a^{1}=a$
Zero raised to any positive, nonzero power is zero.
For example,
$0^{1}=0$
$0^{2}=0$
Any nonzero base raised to the power of zero is one.
For example,
$a^{0}=1$
$5^{0}=1$
$0^{0}$ is undefined, as it represents a mathematical singularity: raising zero to any other power is 0, but raising any number to the power of zero is 1.

### Multiplication and division

When two indices are multiplied, as long as the bases are equal, the two indices are simply added together.
For example,
$a^{x}\times a^{y}=a^{x+y}$
$2^{2}\times 2^{3}=2^{2+3}=2^{5}=32$
For division the opposite is true, as long as the bases are equal, the indices are subtracted.
For example,
$a^{x}\div a^{y}=a^{x-y}$
$2^{5}\div 2^{2}=2^{5-2}=2^{3}=8$

### Fractional indices

The denominator of a fractional index is the root that the base must be taken to.
For example,
$a^{\frac {1}{2}}={\sqrt {a^{1}}}={\sqrt {a}}$
$a^{\frac {1}{3}}={\sqrt[{3}]{a^{1}}}={\sqrt[{3}]{a}}$
The numerator of a fractional index is the power the base must be raised to.
For example,
$a^{\frac {2}{3}}={\sqrt[{3}]{a^{2}}}$
$8^{\frac {2}{3}}={\sqrt[{3}]{8^{2}}}=2^{2}=4$

### Negative indices

A negative sign for an index shows that the base is the denominator of a fraction, the index is the power it must be raised to. The numerator of this fraction is one (though if the term is multiplied by a constant, then the numerator is that constant).
For example,
$a^{-1}={\frac {1}{a}}$
$a^{-3}={\frac {1}{a^{3}}}$
$2(a^{-1})={\frac {2}{a}}$

### Indices to the power of another index

When a number is raised to the power of an index, then this term is raised to the power of another index, the two indices are multiplied.
For example,
$\left(a^{x}\right)^{y}=a^{x\times y}=a^{xy}$
$\left(a^{2}\right)^{3}=a^{2\times 3}=a^{6}$
$\left({\sqrt {a}}\right)^{4}=a^{{\frac {1}{2}}\times 4}=a^{2}$
It is tempting to think these mechanical rules always work as stated. However, this is not always the case. Consider
${\sqrt {a^{2}}}=(a^{2})^{1/2}=a^{2\times {\frac {1}{2}}}=a$
but this is actually wrong, because we have failed to account for any possible negative values of $a$. The correct way to "reduce" this is then
${\sqrt {a^{2}}}=|a|$

## Use and manipulation of surds

A surd is an irrational root of a whole number such as ${\sqrt {2}}$ and ${\sqrt {5}}$. Like indices, laws of use and manipulation of surds is vital knowlegde.

### Multiplication and simplification

${\sqrt {a}}\times {\sqrt {b}}={\sqrt {a\times b}}$
${\sqrt {2}}\times {\sqrt {8}}={\sqrt {16}}=4$
Sometimes you will be asked to simplify your answer, this is done simply by finding a square number, like 4 or 9, that divides into the surd, then bringing it outside the square root.
For example,
${\sqrt {50}}={\sqrt {25\times 2}}={\sqrt {25}}\times {\sqrt {2}}=5{\sqrt {2}}$

### Surds in fractions

${\frac {\sqrt {a}}{\sqrt {b}}}={\sqrt {\frac {a}{b}}}$
${\sqrt {\frac {5}{4}}}={\frac {\sqrt {5}}{2}}$

#### Rationalising the denominator

Some times you may be given a fraction with a surd as the denominator and be asked to rationalise the denominator. If you are given a fraction with a single surd as a denominator you can simply multiply numerator and denominator by the surd to get rid of it. In effect you are always multiplying by 1.
For example,
${\frac {3}{\sqrt {2}}}\times \left({\frac {\sqrt {2}}{\sqrt {2}}}\right)={\frac {3{\sqrt {2}}}{2}}$
For a fraction that had a constant plus a surd, for example $a+{\sqrt {b}}$, you need to multiply numerator and denominator by $a-{\sqrt {b}}$.
For example,
${\frac {3}{3+{\sqrt {2}}}}\times \left({\frac {3-{\sqrt {2}}}{3-{\sqrt {2}}}}\right)={\frac {3\left(3-{\sqrt {2}}\right)}{9-3{\sqrt {2}}+3{\sqrt {2}}-2}}={\frac {9-3{\sqrt {2}}}{7}}$
One of the reasons it is useful to rationalise a fraction is because a rationalised expression is easier to evaluate approximately by inspection. Consider the fraction $1/{\sqrt {2}}$, whose value is not easy to eyeball. However, the equivalent fraction ${\sqrt {2}}/2$ is easier to estimate, as we know that ${\sqrt {2}}\approx 1.4$, so ${\sqrt {2}}/2\approx 0.7$. More precisely, we have $1/{\sqrt {2}}=0.70710678118\ldots$.
More graphs

## The discriminant of a quadratic function

We consider the following quadratic function, where $A\neq 0$:
    $f(x)=Ax^{2}+Bx+C.$
We define the discriminant of $f$ as the following quantity:
    ${\text{Discriminant of }}f={\text{Disc}}(f)=B^{2}-4AC.$
The discriminant allows us to classify the roots or zeroes of $f$. In particular, if ${\text{Disc}}(f)>0$ we will have two distinct real roots; if ${\text{Disc}}(f)<0$ we will have no real roots, and if ${\text{Disc}}(f)=0$, we will have one (repeated) real root.

## Completing the square
### Introduction

Completing the square is a technique to rewrite a quadratic expression of the form $ax^{2}+bx+c$ into a perfect-square form plus/minus a constant. This is often used when:
* Solving quadratic equations where factoring is inconvenient,
* Converting a quadratic into vertex form for graphing,
* Simplifying integrals or derivatives of quadratics in more advanced mathematics.

### General idea

A general quadratic expression $ax^{2}+bx+c$ (with $a\neq 0$) can be transformed as follows:
* **Factor out** $a$ from the first two terms (if $a\neq 1$):
    $ax^{2}+bx+c\;=\;a{\Biglx^{2}+{\frac {b}{a}}x{\Bigr )}+c.$
* **Inside the parentheses, form a perfect square.** To do this, add and subtract ${\bigl{\tfrac {b}{2a}}{\bigr )}^{2}$:
    $x^{2}+{\frac {b}{a}}x\;+\;{\Bigl{\frac {b}{2a}}{\Bigr )}^{2}\;-\;{\Bigl{\frac {b}{2a}}{\Bigr )}^{2}.$
* **Rewrite** the first three terms as a perfect square:
    $x^{2}+{\frac {b}{a}}x+{\Bigl{\frac {b}{2a}}{\Bigr )}^{2}\;=\;{\Biglx+{\frac {b}{2a}}{\Bigr )}^{2}.$
* **Distribute $a$ back and combine constants**. The final result has the form:
    $ax^{2}+bx+c\;=\;a{\Biglx+{\frac {b}{2a}}{\Bigr )}^{2}\;+\;{\text{(some constant)}}.$

### Example 1

Complete the square for $x^{2}+6x+7$.
* Here, $a=1$, $b=6$, $c=7$.
* Half of $6$ is $3$, and $3^{2}=9$.
* Add and subtract 9:
    $x^{2}+6x+9\;-\;9+7.$
* The first three terms become $(x+3)^{2}$, leaving us:
    $(x+3)^{2}\;-\;9+7\;=\;(x+3)^{2}-2.$
Hence, $x^{2}+6x+7=(x+3)^{2}-2.$

### Example 2

Complete the square for $2x^{2}+8x+5$.
* Factor out 2 from the first two terms:
    $2{\biglx^{2}+4x{\bigr )}+5.$
* Half of $4$ is $2$, and $2^{2}=4$. Add/subtract 4 inside:
    $2{\biglx^{2}+4x+4-4{\bigr )}+5.$
* Rewrite as a perfect square:
    $2{\Bigl(x+2)^{2}-4{\Bigr )}+5=2(x+2)^{2}-8+5.$
* Combine constants:
    $2(x+2)^{2}-3.$

### Practice questions

* Write $4x^{2}+12x+1$ in completed-square form.
* Rewrite $x^{2}-2x+5$ by completing the square and identify its vertex.

## Simultaneous equations
### Introduction

Simultaneous equations (or a system of equations) are two or more equations that share common variables. The goal is to find all values of these variables that satisfy every equation in the system. Common methods include substitution, elimination, and graphical interpretation.

### Substitution method

* Solve one equation for one variable in terms of the other(s).
* Substitute this expression into the second equation.
* Solve for the remaining variable(s).
* Substitute back to find all other variables.

#### Example (Substitution)

Solve:
    ${\begin{cases}x+y=7\\y-3x=1\end{cases}}$
* From the first equation, $y=7-x$.
* Substitute $y=7-x$ into $y-3x=1$:
    $(7-x)-3x=1\;\;\Longrightarrow \;\;7-4x=1\;\;\Longrightarrow \;\;-4x=-6\;\;\Longrightarrow \;\;x={\tfrac {3}{2}}.$
* Substitute $x={\tfrac {3}{2}}$ back into $y=7-x$:
    $y=7-{\frac {3}{2}}={\frac {14}{2}}-{\frac {3}{2}}={\frac {11}{2}}.$
Thus, the solution is ${\bigl{\tfrac {3}{2}},{\tfrac {11}{2}}{\bigr )}$.

### Elimination method

* Multiply or rearrange equations so that one variable will cancel when you add (or subtract) them.
* Solve the resulting single-variable equation.
* Substitute back to find the other variable(s).

#### Example (Elimination)

Solve:
    ${\begin{cases}2x+3y=5\\4x+6y=9\end{cases}}$
* Multiply the first equation by 2:
    $2\times (2x+3y)=4x+6y=10.$
* Subtract this from the second equation:
    $(4x+6y)-(4x+6y)=9-10\;\;\Longrightarrow \;\;0=-1.$
Since $0=-1$ is a contradiction, there is no solution. The lines are parallel and never intersect.

### Practice questions

* Solve by any method:
    ${\begin{cases}x+2y=6\\2x-y=0\end{cases}}$
* Solve using substitution:
    ${\begin{cases}3x-y=7\\x+4y=13\end{cases}}$
* Solve using elimination:
    ${\begin{cases}2x+y=8\\2y-x=5\end{cases}}$
* (Optional) Solve a quadratic-linear system:
    ${\begin{cases}y=x^{2}+1\\y=-2x+5\end{cases}}$

## Questions

Here are some questions on the above topics to test your knowledge:

### Laws of indices

Evaluate the following terms.
* $2^{2}\times 2^{3}$
* $27^{\frac {2}{3}}$
* $4^{-{\frac {3}{2}}}$
* $(-5)^{-3}$
* $9^{-0.5}$
* $\left(x^{3}\right)^{\frac {2}{3}}$

### Surds

Express the following in the form $a{\sqrt {b}}$.
* ${\sqrt {45}}$
* ${\sqrt {12}}$
* ${\sqrt {32}}$
Rationalise the denominator of the following
* ${\frac {4}{3-{\sqrt {5}}}}$
* ${\frac {11}{3+{\sqrt {11}}}}$
* ${\frac {3-{\sqrt {2}}}{4-{\sqrt {5}}}}$