Geology 491 – Spectral Analysis Computing the Amplitude Spectrum with PSI-Plot The objective of today's lab is to gain some additional familiarity conceptualizing the problem of analyzing periodic functions and to become familiar with PSI-Plot’s Fourier transform option We will work initially on the simulated data sets that you will construct in today’s lab. Our work in the next two-three weeks will continue with the spectral analysis of some additional climate data sets, but the objective for today is to gain familiarity with concepts and tools. Copy the file simclim.xls from the H:\Drive to your G:\ drive. You will find the file in the folder Climate. You can copy the entire folder over to your G:\Drive now if you want, since you’ll be using some of these files in our next lab exercise. The file SimClim.xls is set up with formulas already entered to compute idealized precession, tilt and eccentricity variations over a 500,000 year time period. We will use sample intervals of 1000 years to avoid having lots of zeroes in our frequency plots. For example, a component with a period of 100,000 years will have a frequency of 0.00001 cycles per year. By using multiples of 1000 years as our time interval the equivalent 100000 year period becomes 100 and the corresponding frequency 0.01 cycles per 1000 years. Follow along in class as we simulate a data set consisting of 3 periodic components, and add some random noise. Once we have completed construction of this data set, open PsiPlot and copy the data in the column labeled “sum of signal and noise” from Excel to column 2 of PsiPlot. We will fill column 1 with times running from 0 to 500. Rename column 1 to Time and Column 2 to Effect or Response. Save your Excel file for future use. Compute the Fourier Transform MATH Fourier Trsfm Forward (Half) At this point a Forward Fourier Transform window will appear First: On the left side of the window be sure to select the column you want to transform!! In the present case, this will be Effect, since your data set, at this point, consists of the dependent variable (Time) in column 1 and the independent variable (affect) in column 2. Second: On the right fill in the Sampling Interval. This will be the time interval at which the data are sampled. The sample interval in this case is just 1. Third: When you click OK, a message will appear indicating that the data number are not a power of 2 and ask you if you want to use the FFT. Answer No. FFT stands for Fast Fourier Transform. The FFT is a time-saving method used to compute the Fourier transform. In most cases you will not have a power-of-2 number of data. You should click on the NO to avoid the errors that will result if the FFT approach is used in this case. The Fourier Transform will then be calculated and displayed. The output consists of the Frequencies at which the computations are made, the Amplitude (NOTE – The column labeled Amplitude, is actually the power, or square of the amplitude), the Phase, Real and Imaginary parts of the spectrum. The problem with the amplitude column is easily solved, but it does provide additional support for the Maxim “Never trust someone else’s program”. Since the amplitudes listed in column4 (labeled AMP4) are actually the square of the amplitudes, you will need to transform them into amplitude. Computing their square root does this. Enter MATH Transform (select one line) Double click the formula window and enter AMP=AMP4^0.5, (the destination column is always the first blank column to the right.) Click on > OK AMP4^0.5 tells the program to take the square root of the AMP4. The result will be returned to column6, which will be labeled AMP. The column labeled FREQ3 contains the frequencies of the calculation points. We would also like to examine the data in terms of the periods of the different components in the transform. The PERIOD is just the reciprocal of the frequency, i.e. 1/FREQ3. So the period T = 1/f, where f is frequency. Compute T as follows Select MATH Transform One line Formula: PERIOD=1/FREQ3 Click on > OK You’ll end up with a blank in row 1 of column 7, which is now labeled PERIOD. Just leave that cell blank. Change the value of the amplitude in row 1of the AMP column to 0. You will get an error message indicating that if you change the value you will loose the calculation. Click OK. This amplitude is just the 0-frequency (or average) component, and we are not interested in it. Now plot your data GENERAL PLOTTING FORMAT FOR THIS ASSIGNMENT Place three plots on one page. 1. The upper plot on the page should be your input data set (Time (in thousands of years) vs. Climate Effect or Climate Response for example). 2. The second plot should be the frequency spectrum (i.e. FREQ3 vs. AMP). 3. The third plot should be of the AMP’s versus PERIOD. Some plot layouts are shown below. A Drop Line plot can be selected from the 2D XYLInes Plot Menu. This may be useful in both the period and frequency plots for getting accurate reference to the period or frequency of a given peak. The second figure from the top illustrates a plot of the spectrum over a restricted range of f. This may help enhance data of interest particularly when, as in the present case, frequencies above 0.1 or 0.2 (and also periods above 100) are devoid of significant peaks. Hand in your plot at the end of today’s lab. Some example plots Relative Response Amplitude Spectrum 2.5 2.0 1.5 1.0 0.5 0.0 0.0 0.1 0.2 0.3 0.4 0.5 Relative Response Frequency (cycles per thousand years) Amplitude Spectrum 2.5 2.0 1.5 1.0 0.5 0.0 0.00 0.02 0.04 0.06 0.08 0.10 0.12 Frequency (cycles per thousand years) Relative Response Consider reducing the maximum frequency to enhance region containing your data. Periods 2.5 2.0 1.5 1.0 0.5 0.0 0 100 200 300 400 500 Relative Response Period (in multiples of 1000 years) Think about the relationship between period and frequency Drop Line version of Period Plot 2.5 2.0 1.5 1.0 0.5 0.0 500 400 300 200 PERIOD 100 0 P = 1/f increased f corresponds to decreased P