<< Chapter < Page
  Digital signal processing - dsp     Page 6 / 14
Chapter >> Page >

There are more efficient ways to write this method taking known symmetry and asymmetry conditions into account. However, I wrote the method the way that Idid because I wanted it to mimic the behavior of an FFT algorithm. Therefore, the complex input must extend from zero to the sampling frequency.

The method does not implement an FFT algorithm. Rather, the inverseTransform method implements a straight-forward sampled-data version of the continuous inverse Fourier transform that is defined usingintegral calculus.

Parameters for the inverseTransform method

The parameters to the inverseTransform method are:

  • double[] realIn - incoming real data
  • double[] imagIn - incoming image data
  • double[] realOut - outgoing real data

The method considers the data length to be realIn.length , and considers the computational time increment to be 1.0/realIn.length .

Assumptions

The method returns a number of points equal to the data length. It assumes that the real input consists of positive frequency points for a symmetric realfrequency function. That is, the real input is assumed to be symmetric about the folding frequency. The method does not test this assumption.

The method assumes that the imaginary input consists of positive frequency points for an asymmetric imaginary frequency function. That is, the imaginaryinput is assumed to be asymmetric about the folding frequency. Once again, the method does not test this assumption.

A real output

A symmetric real part and an asymmetric imaginary part guarantee that theimaginary output will be all zero values. Having made that assumption, the program makes no attempt to compute an imaginary output. If the assumptionsdescribed above are not valid, the results won't be valid.

The program was tested using JDK 1.8 under Windows 7.

Beginning of the inverseTransform method

The beginning of the class and the beginning of the static inverseTransform method is shown in Listing 5 .

Listing 5. Beginning of the class named InverseComplexToReal01.
public class InverseComplexToReal01{ public static void inverseTransform(double[] realIn,double[] imagIn,double[] realOut){int dataLen = realIn.length; double delT = 1.0/realIn.length;double startTime = 0.0;

Listing 5 declares and initializes some variables that will be used later.

The inverse transform computation

Listing 6 contains a pair of nested for loops that perform the actual inverse transform computation.

Listing 6. The inverse transform computation.
//Outer loop interates on time domain // values.for(int i=0; i<dataLen;i++){ double time = startTime + i*delT;double real = 0; //Inner loop iterates on frequency// domain values. for(int j=0; j<dataLen; j++){ real += realIn[j]* Math.cos(2*Math.PI*time*j)+ imagIn[j]*Math.sin(2*Math.PI*time*j); }//end inner looprealOut[i] = real;}//end outer loop }//end inverseTransform}//end class InverseComplexToReal01

If you have been studying the earlier modules in this series, you should be able to understand the code in Listing 6 without further explanation. Pay particular attention to the comments that describe the two for loops.

Questions & Answers

how does Neisseria cause meningitis
Nyibol Reply
what is microbiologist
Muhammad Reply
what is errata
Muhammad
is the branch of biology that deals with the study of microorganisms.
Ntefuni Reply
What is microbiology
Mercy Reply
studies of microbes
Louisiaste
when we takee the specimen which lumbar,spin,
Ziyad Reply
How bacteria create energy to survive?
Muhamad Reply
Bacteria doesn't produce energy they are dependent upon their substrate in case of lack of nutrients they are able to make spores which helps them to sustain in harsh environments
_Adnan
But not all bacteria make spores, l mean Eukaryotic cells have Mitochondria which acts as powerhouse for them, since bacteria don't have it, what is the substitution for it?
Muhamad
they make spores
Louisiaste
what is sporadic nd endemic, epidemic
Aminu Reply
the significance of food webs for disease transmission
Abreham
food webs brings about an infection as an individual depends on number of diseased foods or carriers dully.
Mark
explain assimilatory nitrate reduction
Esinniobiwa Reply
Assimilatory nitrate reduction is a process that occurs in some microorganisms, such as bacteria and archaea, in which nitrate (NO3-) is reduced to nitrite (NO2-), and then further reduced to ammonia (NH3).
Elkana
This process is called assimilatory nitrate reduction because the nitrogen that is produced is incorporated in the cells of microorganisms where it can be used in the synthesis of amino acids and other nitrogen products
Elkana
Examples of thermophilic organisms
Shu Reply
Give Examples of thermophilic organisms
Shu
advantages of normal Flora to the host
Micheal Reply
Prevent foreign microbes to the host
Abubakar
they provide healthier benefits to their hosts
ayesha
They are friends to host only when Host immune system is strong and become enemies when the host immune system is weakened . very bad relationship!
Mark
what is cell
faisal Reply
cell is the smallest unit of life
Fauziya
cell is the smallest unit of life
Akanni
ok
Innocent
cell is the structural and functional unit of life
Hasan
is the fundamental units of Life
Musa
what are emergency diseases
Micheal Reply
There are nothing like emergency disease but there are some common medical emergency which can occur simultaneously like Bleeding,heart attack,Breathing difficulties,severe pain heart stock.Hope you will get my point .Have a nice day ❣️
_Adnan
define infection ,prevention and control
Innocent
I think infection prevention and control is the avoidance of all things we do that gives out break of infections and promotion of health practices that promote life
Lubega
Heyy Lubega hussein where are u from?
_Adnan
en français
Adama
which site have a normal flora
ESTHER Reply
Many sites of the body have it Skin Nasal cavity Oral cavity Gastro intestinal tract
Safaa
skin
Asiina
skin,Oral,Nasal,GIt
Sadik
How can Commensal can Bacteria change into pathogen?
Sadik
How can Commensal Bacteria change into pathogen?
Sadik
all
Tesfaye
by fussion
Asiina
what are the advantages of normal Flora to the host
Micheal
what are the ways of control and prevention of nosocomial infection in the hospital
Micheal
what is inflammation
Shelly Reply
part of a tissue or an organ being wounded or bruised.
Wilfred
what term is used to name and classify microorganisms?
Micheal Reply
Binomial nomenclature
adeolu
Got questions? Join the online conversation and get instant answers!
Jobilize.com Reply

Get Jobilize Job Search Mobile App in your pocket Now!

Get it on Google Play Download on the App Store Now




Source:  OpenStax, Digital signal processing - dsp. OpenStax CNX. Jan 06, 2016 Download for free at https://legacy.cnx.org/content/col11642/1.38
Google Play and the Google Play logo are trademarks of Google Inc.

Notification Switch

Would you like to follow the 'Digital signal processing - dsp' conversation and receive update notifications?

Ask