## Factorizing Quadratics

**Factorising quadratics is basically putting them in brackets. In this section we will look at two different ways of factorising quadratics( for simple and complex ones) and when they should be used.**

### Note/ sometimes a quadratic cannot be factorized using whole numbers, this is when you must use the quadratic equation to find the values of x. See my earlier post and c++ program

### Simple type

Use when there is no coefficent of x^{2}

eg)x^{2}+2x-8

start by opening 2 brackets with an x in each

(x )(x )

put the first sign in the first bracket. If the second sign is + put the same sign in both, if its – put the opposite sign in the second bracket

(x+ )(x- )

find the 2 numbers that will add(if both signs in brackets are +) or subtract(if the signs in the brackets are different) to make the middle number(2) and multiply to make the end number(8)

(x+4)(x-2)

and thats your quadratic factorized

**Complex Type**

Use when there is a coefficent of x^{2}

eg) 8x^{2}-14x-15

Before we can open brackets we need to split up the 14x

8x^{2} ?x ?x-15

the rule for the signs is the same as in the simple case, put the first sign before the first x term. If the second sign is + put the same sign in both, if its – put the opposite sign before the second x term

8x^{2}-?x+?x-15

we also use the same rule for the to coefficients of x, they must add or subtract to make the middle number(14) but they must times to make the end number times the first(15×8=120)

8x^{2}-20x+6x-15

we then take out the common factor of the first 2 terms(4x)

4x(2x-5) + 6x -15

we use the bracket(2x-5) as the common factor for the second 2 terms and find what we need to multiply by(3)

4x(2x-5)+3(2x-5)

we then take the 2 numbers in front of the brackets(4x and 3) as our second bracket

(4x+3)(2x-5)

and there we have a fully factorized quadratic

## Area And Circumference of a Circle : pi

**This site is now at www.breakingwave.co.nr**

This is a basic guide to using pi to find the area and circumference of a circle using pi. And also explores why pi makes our formulae work.

area =πr^{2}

circumference = 2πr or πd

where r = radius and d=diameter

**Area**

^{2}. This is simple enough to use, we multiply the radius by itself and then by pi.

**Does this make sense?**

^{2}. Of course the circle’s area is a bit smaller so we need to find the ratio between the areas of the square and circle. If we then times this value by four we have a magic constant to multiply r squared by to find the area of a circle (we times by four because we need the area of 4 quadrants and r squared gives us one).

**Circumference**

**Does this also make sense?**

**Conclusion**

perimeter of square to circumference of circle.

By David Woodford

## Quadratic Formula

The quadratic formula is a quick(unless you can factorise) way of solving quadratic equations. You basically take the coefficient’s of x, x^{2} and numbers, put then in the formula, work out the two answers and have your 2 solutions of x. And if that wasn’t easy enough written a console program in c++ that will solve them for you(and gives dodgy answers for complex solution ie) imaginary answers when there are no real roots.

so for the general quadratic

ax^{2}+bx+c=0

So what do you do, well enter a, b and c from the general equation into the formula, work out the answers and they are your solutions.

Whats the plus/minus thingy. You might be wondering what the thing is after the -b, well its a plus or minus sign. Because when you work out a square root it can have to answers, eg)root 9 = +3 and -3, he formula takes this into account by saying you must use the plus and the minus answers. This therefore means you will be 2 solutions to the quadratic, which makes sense as the graph is a curve and it therefore must cut the x-axis twice.

When the root part is negative(before you find the root) there are no real roots, only complex ones. This means that the curve comes down above the x-axis and doesn’t cut it. If you work out the complex roots, using i for root(-1), your pair of answers will be a conjugate pair.

**David Woodfords Quadratic Calculator**

This is a console program that i wrote in c++ that will solve a quadratic for you. Just download the file and run it, follow the instructions and it will output the 2 answers for you. I tried to make it work for complex roots as well but somewhere in the decimal data types Ive messed up so only the second parts of the complex answers are correct – though im sure working out -b/2a isn’t too hard for you.

Download quadratic calculator

### Other posts relating to the quadratic formula

**Derive the Quadratic formula**: an explanation of how to derive and prove the quadratic formula by completing the square**Factorise Quadratics**: how to solve a quadratic without using the formula

## Trevor Changes

Its been a while since i last made some updates to trevor so i have. Ive also included to new levels in the download, although there some digging to do if you want to play the previous levels(there stored as a complied subclass of level, not as a text file in the levels folder).

So what are the changes?

well really only that i have made the movement of trevor much smoother. On the first versions the screen was repainted evrey time the main game loop was run. This meant it could only move one block per frame, making the animation verey jumpy. Now ive made it so that it is repainted 4 times for evrey block he moves, so he moves 5px per frame at 10 frames a second, so the motion looks verey smooth.

Becuase people found the “simple to use” level design method to hard!!!!!!! ive made it even simpler. When your level is read in the borders are automatically added, so all you have to do is make sure your level isnt more than 19 lines high and 59 accorss and add and blank line and then end at the end. Simple!!!

Ive included 2 new levels for you to play. Just change the play.bat file so that it pass the game the level you want to plays file name as a parameter.

Happy trevoring. You can also visit the trevor section my site www.breakingwave.co.nr/computing/trevor/intro.htm

## TREVOR PYTHAGORAS + C >> download update

The latest version of trevor is now downloadable. I have made quite a few improvements to it since last time 🙂 and ive made a new level. To download click below, all posts on this blog also have a download on the left or from my site(www.breakingwave.co.nr — ull need to navigate away from the home page to see the trevor link in the nave bar)

## Whats new?

- Trevors motion is much smoother. Ive added in frame between each execution loop so the motion appears smooth and less like hes jumping around
- A scrolling screen. This means the screen follows trevor around the level, displaying 20 blocks either side, opposed to displaying the whole level. This allows much larger levels to be created
- A text file reader allowing you to write your own levels for trevor in a text file with no knowledge of codeing 🙂

## How to create you own level

After downloading trevor you can create your own levels, just follow the simple steps below

- Open up a plain text editor – like note pad found in accessories
- Each chracter in the file represents a object in the game.
- once you have produced you level design leave a blank line and then on the next line type “end”
- save you level in the levels folder of trevor
- edit the play.bat file to have the name of your level instead of test.lev — rember to put in the file extenstion(probably .txt)
- run play.bat

#### so how do i create objects?

The level can be 59 objects wide(so 59 characters across) and 19 high (so on 19 rows). For an empty space use any key other than the ones specified below. You will need to build a floor and walls using the ground object else the game will crash when trevor leaves the games area (you may also need a ceiling)

object codes:

ground — g

triangle — t

evil fish — >

spikes — s

spring — ^

heart — h

exit — e **Note: ** when using exit it takes up a square of 9 objects referenced from the top left so make sure there is nothing 3 objects to the right and down

**Note** Trevor starts at around object 3 across 4 down ish

MOST IMPORTANTLY ENJOY >> for more trevorness visit my site www.breakingwave.co.nr

## 3 Clubs and Mills Mess Juggling Tutrials

HI, ive just uploaded 2 new juggling tutorials to my Youtube account , thse are Mills mess and Juggling

Clubs. These are to go with my written tutorials on this blog as well as on my site (www.breakingwave.co.nr)

Any way here they are

## Probablity of a Miracle = 0.149 :: the mathmatical proof

Below is a mathematical proof that miracles can occur and a calculation of their probability.

any finite number divided by 0 = infinite

so 3 / 0 = infinite

which can be rearranged so

0 x infinite = 3

if a miracle is defined as something with probability 0 (ie it is impossible and would require divine intervention to occur) and we assume the universe is infinite in either time or space or both.

the expected number of success of n trials is the number of trials x the probability of success (eg if you threw a dice 12 times you’d expect 2 sixes). So if the universe is infinite then there are infinite trials and if a miracle if a miracle has probability 0 the expected number of miracle = infinite x 0 and as shown above this equals 3.

so to recap

3/0 = infinite

so 0 x infinite = 3

p(miracle) = 0

E(miracle) = n p = 0 x infinite = 3

so in all of time and space 3 miracles are expected. However as any finite number divided by 0 = infinite then all we can say is that in all of infinite time and space a finite number of miracles are expected.

From this we can calculate the probability of one miracle occurring using the poission distribution

if X = number of miracles

X ~ P_{o}(3) as above

P(X = 1) = (e^{-3}3^{1})/1! = 0.0498 x 3 = **0.149**

So there you go, when the universe is infinite

## The probability of a single miracle is 0.149

or

## Comments