in this tutorial we will talk about prime number factorization or factorization into prime factors or representation of any composite number as a multiplication of prime numbers we have a result in mathematics that every composite number can be represented uniquely as a product of prime factors at the end of this tutorial you will learn how to write any composite number as a multiplication of prime numbers as in this example you see now let's get started we will describe an algorithm using several examples the first example which describes our algorithm example example one let's write factorization into prime numbers for number n 1984. to do this we write 1984 we divide this number by 2 because if you watched previous tutorials you know that divisibility criteria for number two is that last number must be even or equal to zero since four is even number actually this is obvious but anyway um this is divisible by 2 and result will be 992 this is also divisible by 2 and it will be 490 this is also divisible by 2 and we have 284 divide by number 2 and we have 124 divisible by 2 and we have 62 this is also divisible by 2 and we have 39 31 sorry 31 is prime number and this is uh not divisible by 2 of course this is only divisible by 31 and we have a finishing point of our algorithm 1. that's why we write that as a result of this algorithm our number 1984 is divisible uh sorry is repres can be represented as a multiplication of 2 times 2 times 2 times 2 times 2 times 2 times 31 all these numbers are prime numbers so we represented our number as a multiplication of prime numbers and shortly this can be written as 2 to the power of 6 times 31 and this is the result this is the representation of our number as a multiplication of prime numbers next example example number two example number two uh this is about writing number 1050 [Music] as a multiplication of prime numbers uh let's do it let's write 1050 and this number obviously is divisible uh by number two because last digit is zero and if you don't know divisibility criteria by numbers 2 3 4 5 6 7 and 9 watch previous tutorials if we divide 1050 by the number 2 we will have 525 this number is not divisible by 2 because last number is not even or 0.
is this number divisible by number three the next prime number using divisibility criteria for number three we have to check is the sum of the digits 5 plus 2 plus 5 is this number divisible by number 3. this is 12 and this is divisible by 3 that's why answer is yes so [Music] 525 is divisible by three and result will be one hundred seventy five is this number divisible by number three one plus seven plus five is thirteen thirteen is not divisible by three that's why answer is no so 175 is not divisible by 3. next prime number is number 5.
very important note is that i forget forgot to mention is that for number 1050 we know all the prime numbers all the prime numbers prior to this number that this any of this number can potentially divide our number and we can write every prime number less than 1050 using uh eratosthenes algorithm described in previous tutorial so this number two three five and so on we already know these numbers using uh algorithm of eratosthenes sieve of erathosphinus so uh 175 is not divisible by 3 next prime number is 5. is this number divisible by 5 yes of course because last digit is 5. and if we divide our number by 5 result will be 35 305 is also divisible by 5.
we divide this number by 5 and we have 7. [Music] 7 is prime number and this is divisible only by the next number 7 and we have finishing point of our algorithm that's why our number 1050 can be represented as a multiplication of prime numbers 2 times 3 times 5 times 5 times 7 or in shorter form this is 2 times 3 times 5 squared [Music] times 7. and so we found a representation of our number as a multiplication of prime numbers or this is the prime number factorization of number 1050 next example example number three [Music] example number three let's write more complex numbers say fourteen thousand seven hundred fourteen thousand and seven hundred um [Music] let's begin right fourteen thousand and seven hundred this number is divisible by 2 because last digit is 0.
then it will be 7 350. and this number is also divisible by 2 because last number is 0. then it will be 3 675 is this number divisible by 2 no because last digit is not even number and or 0.
is this number divisible by 3 let's check it 3 plus 6 plus 7 plus 5 is equal to 21 so that's why yes so our number 3 3675 is divisible by number three and if we divide for example using calculator we um have 1220 is this number divisible by number three let's check it 1 plus plus 2 plus 2 plus 5 is equal to 10 and 10 is not divisible by 3 that's why our number is not divisible by 3 next prime number is number 5.