# 3.4 The prime factor algorithm

 Page 1 / 1

## General index maps

$n=({K}_{1}{n}_{1}+{K}_{2}{n}_{2})\mod N$ $n=({K}_{3}{k}_{1}+{K}_{4}{k}_{2})\mod N$ ${n}_{1}$

0 1 N 1 1
${k}_{1}$
0 1 N 1 1
${n}_{2}$
0 1 N 2 1
${k}_{2}$
0 1 N 2 1

The basic ideas is to simply reorder the DFT computation to expose the redundancies in the DFT , and exploit these to reduce computation!

Three conditions must be satisfied to make this map serve our purposes

• Each map must be one-to-one from $0$ to $N-1$ , because we want to do the same computation, just in a different order.
• The map must be cleverly chosen so that computation is reduced
• The map should be chosen to make the short-length transforms be DFTs . (Not essential, since fast algorithms for short-length DFT -like computations could be developed, but it makes our work easier.)

## Case i

${N}_{1}$ , ${N}_{2}$ relatively prime (greatest common denominator $1$ ) i.e. $\gcd ({N}_{1}, {N}_{2})=1$

${K}_{1}=a{N}_{2}$ and/or ${K}_{2}=b{N}_{1}$ and $\gcd ({K}_{1}, {N}_{1})=1$ , $\gcd ({K}_{2}, {N}_{2})=1$

## Case ii

${N}_{1}$ , ${N}_{2}$ not relatively prime: $\gcd ({N}_{1}, {N}_{2})> 1$

${K}_{1}=a{N}_{2}$ and ${K}_{2}\neq b{N}_{1}$ and $\gcd (a, {N}_{1})=1$ , $\gcd ({K}_{2}, {N}_{2})=1$ or ${K}_{1}\neq a{N}_{2}$ and ${K}_{2}=b{N}_{1}$ and $\gcd ({K}_{1}, {N}_{1})=1$ , $\gcd (b, {N}_{2})=1$ where ${K}_{1}$ , ${K}_{2}$ , ${K}_{3}$ , ${K}_{4}$ , ${N}_{1}$ , ${N}_{2}$ , $a$ , $b$ integers

Requires number-theory/abstract-algebra concepts. Reference: C.S. Burrus
Conditions of one-to-oneness must apply to both $k$ and $n$

## Conditions for arithmetic savings

$X({k}_{1}, {k}_{2})=\sum_{{n}_{1}=0}^{{N}_{1}-1} \sum_{{n}_{2}=0}^{{N}_{2}-1} x({n}_{1}, {n}_{2}){W}_{N}^{\left({K}_{1}{n}_{1}+{K}_{2}{n}_{2}\right)\left({K}_{3}{k}_{1}+{K}_{4}{k}_{2}}=\sum_{{n}_{1}=0}^{{N}_{1}-1} \sum_{{n}_{2}=0}^{{N}_{2}-1} x({n}_{1}, {n}_{2}){W}_{N}^{{K}_{1}{K}_{3}{n}_{1}{k}_{1}}{W}_{N}^{{K}_{1}{K}_{4}{n}_{1}{k}_{2}}{W}_{N}^{{K}_{2}{K}_{3}{n}_{2}{k}_{1}}{W}_{N}^{{K}_{2}{K}_{4}{n}_{2}{k}_{2}}$
• ${K}_{1}{K}_{4}\mod N=0$ exclusive or ${K}_{2}{K}_{3}\mod N=0$ Common Factor Algorithm (CFA). Then $X(k)={\mathrm{DFT}}_{Ni}(\text{twiddle factors}{\mathrm{DFT}}_{Nj}(x({n}_{1}, {n}_{2})))$
• ${K}_{1}{K}_{4}\mod N$ and ${K}_{2}{K}_{3}\mod N=0$ Prime Factor Algorithm (PFA). $X(k)={\mathrm{DFT}}_{Ni}({\mathrm{DFT}}_{Nj})$ No twiddle factors!
A PFA exists only and always for relatively prime ${N}_{1}()$ , ${N}_{2}()$

## Conditions for short-length transforms to be dfts

${K}_{1}{K}_{3}\mod N={N}_{2}$ and ${K}_{2}{K}_{4}\mod N={N}_{1}$

Convenient choice giving a PFA
${K}_{1}={N}_{2}$ , ${K}_{2}={N}_{1}$ , ${K}_{3}={N}_{2}{N}_{2}^{-1}\mod {N}_{1}\mod {N}_{1}$ , ${K}_{4}={N}_{1}{N}_{1}^{-1}\mod {N}_{2}\mod {N}_{2}$ where ${N}_{1}^{-1}\mod {N}_{2}$ is an integer such that ${N}_{1}{N}_{1}^{-1}\mod =1$

${N}_{1}=3$ , ${N}_{2}=5$ $N=15$ $n=(5{n}_{1}+3{n}_{2})\mod 15$ $k=(10{k}_{1}+6{k}_{2})\mod 15$

• ## Checking conditions for one-to-oneness

$5={K}_{1}=a{N}_{2}=5a$ $3={K}_{2}=b{N}_{1}=3b$ $\gcd (5, 3)=1$ $\gcd (3, 5)=1$ $10={K}_{3}=a{N}_{2}=5a$ $6={K}_{4}=b{N}_{1}=3b$ $\gcd (10, 3)=1$ $\gcd (6, 5)=1$
• ## Checking conditions for reduced computation

${K}_{1}{K}_{4}\mod 15=5\times 6\mod 15=0$ ${K}_{2}{K}_{3}\mod 15=3\times 10\mod 15=0$
• ## Checking conditions for making the short-length transforms be dfts

${K}_{1}{K}_{3}\mod 15=5\times 10\mod 15=5={N}_{2}$ ${K}_{2}{K}_{4}\mod 15=3\times 6\mod 15=3={N}_{1}$
Therefore, this is a prime factor map.

## Operation counts

• ${N}_{2}$ length- ${N}_{1}$ DFTs ${N}_{1}$ length- ${N}_{2}$ DFTs ${N}_{2}{N}_{1}^{2}+{N}_{1}{N}_{2}^{2}=N({N}_{1}+{N}_{2})$ complex multiplies
• Suppose $N={N}_{1}{N}_{2}{N}_{3}{N}_{M}$ $N({N}_{1}+{N}_{2}++{N}_{M})$ Complex multiplies
radix-2 , radix-4 eliminate all multiplies in short-length DFTs, but have twiddle factors: PFA eliminates all twiddlefactors, but ends up with multiplies in short-length DFTs . Surprisingly, total operation counts end up being very similarfor similar lengths.

Is there any normative that regulates the use of silver nanoparticles?
what king of growth are you checking .?
Renato
What fields keep nano created devices from performing or assimulating ? Magnetic fields ? Are do they assimilate ?
why we need to study biomolecules, molecular biology in nanotechnology?
?
Kyle
yes I'm doing my masters in nanotechnology, we are being studying all these domains as well..
why?
what school?
Kyle
biomolecules are e building blocks of every organics and inorganic materials.
Joe
anyone know any internet site where one can find nanotechnology papers?
research.net
kanaga
sciencedirect big data base
Ernesto
Introduction about quantum dots in nanotechnology
what does nano mean?
nano basically means 10^(-9). nanometer is a unit to measure length.
Bharti
do you think it's worthwhile in the long term to study the effects and possibilities of nanotechnology on viral treatment?
absolutely yes
Daniel
how to know photocatalytic properties of tio2 nanoparticles...what to do now
it is a goid question and i want to know the answer as well
Maciej
Abigail
for teaching engĺish at school how nano technology help us
Anassong
Do somebody tell me a best nano engineering book for beginners?
there is no specific books for beginners but there is book called principle of nanotechnology
NANO
what is fullerene does it is used to make bukky balls
are you nano engineer ?
s.
fullerene is a bucky ball aka Carbon 60 molecule. It was name by the architect Fuller. He design the geodesic dome. it resembles a soccer ball.
Tarell
what is the actual application of fullerenes nowadays?
Damian
That is a great question Damian. best way to answer that question is to Google it. there are hundreds of applications for buck minister fullerenes, from medical to aerospace. you can also find plenty of research papers that will give you great detail on the potential applications of fullerenes.
Tarell
what is the Synthesis, properties,and applications of carbon nano chemistry
Mostly, they use nano carbon for electronics and for materials to be strengthened.
Virgil
is Bucky paper clear?
CYNTHIA
carbon nanotubes has various application in fuel cells membrane, current research on cancer drug,and in electronics MEMS and NEMS etc
NANO
so some one know about replacing silicon atom with phosphorous in semiconductors device?
Yeah, it is a pain to say the least. You basically have to heat the substarte up to around 1000 degrees celcius then pass phosphene gas over top of it, which is explosive and toxic by the way, under very low pressure.
Harper
Do you know which machine is used to that process?
s.
how to fabricate graphene ink ?
for screen printed electrodes ?
SUYASH
What is lattice structure?
of graphene you mean?
Ebrahim
or in general
Ebrahim
in general
s.
Graphene has a hexagonal structure
tahir
On having this app for quite a bit time, Haven't realised there's a chat room in it.
Cied
what is biological synthesis of nanoparticles
how did you get the value of 2000N.What calculations are needed to arrive at it
Privacy Information Security Software Version 1.1a
Good
Got questions? Join the online conversation and get instant answers!