Filter löschen
Filter löschen

FFT of Earthquake Data

6 Ansichten (letzte 30 Tage)
Okan
Okan am 28 Okt. 2011
Hi,
I am trying to plot amplitude of part of earthquake data in frequency domain by using Discrete Fourier Spectrum. The code works but there is a problem that the initial line of amplitude graph seems downward in stead of upward. One can say "there may not be such a rule that the initial line should be downward" but it should be downward according to my instructor.
How can i solve this problem?
dosyae=fopen('EWD.txt','r');
datae=fscanf(dosyae,'%f');
datae=datae*9.81;
fclose(dosyae);
B=fft(datae,400);
B1=abs(B)*2;
Fs=100;
f=(Fs/2)*linspace(0,1,length(B1)/2+1);
loglog(f,B1(1:numel(f)),'b');
xlabel('Frequency (Hz)');
ylabel('Amplitude (m/sec)');
legend('Earthquake Data');
Data:
-0.00553477900 -0.00397129400 -0.00208622400 -0.00122476000 0.00067980280 0.00303870900 0.00339254500 0.00467129300 0.00846823800 0.01222916000 0.01282478000 0.01075421000 0.00799149300 0.00509135700 0.00508811200 0.00864743800 0.01280674000 0.01781000000 0.02397607000 0.02930591000 0.03267581000 0.03229749000 0.02694955000 0.01991085000 0.01433657000 0.01167962000 0.01100430000 0.00859380100 0.00419463900 -0.00046160920 -0.00302519800 -0.00201483800 -0.00173750200 -0.00552095300 -0.01092579000 -0.01583778000 -0.02078425000 -0.02506230000 -0.02660052000 -0.02618380000 -0.02442823000 -0.02145001000 -0.01874804000 -0.01473566000 -0.00870957500 -0.00293592000 0.00042775400 0.00073886510 -0.00021423300 -0.00061938290 0.00004800546 0.00115364200 0.00269358600 0.00414229200 0.00611985000 0.00968789800 0.01336065000 0.01761493000 0.02011806000 0.01894172000 0.01770879000 0.01629669000 0.01457834000 0.01242693000 0.00642771200 -0.00215688400 -0.01086596000 -0.01880673000 -0.02337801000 -0.02490362000 -0.02427681000 -0.01992116000 -0.01329518000 -0.00640658800 -0.00037598920 0.00459782300 0.01002213000 0.01518335000 0.02087825000 0.02630514000 0.02666586000 0.02184806000 0.01192238000 -0.00315772300 -0.01922679000 -0.03334001000 -0.04332575000 -0.04856583000 -0.05167564000 -0.05324002000 -0.05253643000 -0.04770679000 -0.03518541000 -0.01831131000 -0.00180115300 0.01352053000 0.02657438000 0.03693100000 0.04014033000 0.03540291000 0.02621543000 0.01457976000 0.00444119500 -0.00568907600 -0.01667677000 -0.02653736000 -0.03528119000 -0.04016536000 -0.03889929000 -0.02983623000 -0.01343450000 0.00518522100 0.02041368000 0.03107378000 0.03879858000 0.04235689000 0.04191164000 0.03888687000 0.03154537000 0.02180639000 0.01061276000 -0.00317777500 -0.01591940000 -0.02761689000 -0.03655147000 -0.03715329000 -0.03055196000 -0.01968053000 -0.00518376800 0.01186290000 0.02832767000 0.03977504000 0.04514512000 0.04396709000 0.03464750000 0.02207926000 0.01096917000 0.00084395580 -0.00765588000 -0.01308556000 -0.01484366000 -0.01319132000 -0.00825978400 -0.00161215900 0.00522835000 0.01014989000 0.01054296000 0.00906028100 0.00711820200 0.00370909600 -0.00096605270 -0.00809755100 -0.01495590000 -0.01592948000 -0.01026305000 -0.00123623800 0.00718244100 0.01149409000 0.01158974000 0.00917557900 0.00262303900 -0.00698288300 -0.01606166000 -0.02343234000 -0.02789891000 -0.03139848000 -0.03445436000 -0.03483347000 -0.03160355000 -0.02304145000 -0.01081701000 0.00182262300 0.01287664000 0.01856834000 0.01689200000 0.00928049200 -0.00163457600 -0.01115042000 -0.01627698000 -0.01709570000 -0.01484664000 -0.01337353000 -0.01309318000 -0.01144993000 -0.00740783900 -0.00178271800 0.00421463300 0.01127468000 0.01613966000 0.01693469000 0.01636380000 0.01561736000 0.01533460000 0.01541644000 0.01731204000 0.01929178000 0.01801548000 0.01423365000 0.00793532600 0.00050891970 -0.00699469400 -0.01380226000 -0.01742886000 -0.01759557000 -0.01545268000 -0.01208178000 -0.00668483900 0.00195934000 0.01266522000 0.02247404000 0.02681177000 0.02357928000 0.01705706000 0.00981504600 0.00176543100 -0.00617424700 -0.01379979000 -0.01922433000 -0.02165849000 -0.02096784000 -0.01755586000 -0.01273809000 -0.00729208100 -0.00352993800 -0.00053533210 0.00268413400 0.00510191200 0.00755391200 0.00834915000 0.00630584100 0.00249914900 -0.00288489100 -0.00827690800 -0.01079724000 -0.00810712700 -0.00108132400 0.00566474200 0.00725889900 0.00080779710 -0.01055296000 -0.02054481000 -0.02706354000 -0.02935482000 -0.02847072000 -0.02725681000 -0.02785152000 -0.02988321000 -0.03078256000 -0.02976853000 -0.02569154000 -0.01860512000 -0.01008441000 -0.00216712800 0.00417928900 0.00956090400 0.01259333000 0.01437791000 0.01682521000 0.01848922000 0.01896184000 0.02046768000 0.02421331000 0.02906397000 0.03292610000 0.03237464000 0.02691481000 0.01870505000 0.00934468000 0.00199340900 -0.00419635700 -0.01094889000 -0.01782549000 -0.02632317000 -0.03426988000 -0.03980554000 -0.04301531000 -0.04247258000 -0.03614089000 -0.02450130000 -0.01348940000 -0.00641263900 -0.00193963800 0.00132651600 0.00464236000 0.00870766900 0.01271628000 0.01674791000 0.02094100000 0.02450756000 0.02757990000 0.02942070000 0.02932406000 0.02786366000 0.02538048000 0.02201072000 0.01778762000 0.01211007000 0.00663777400 0.00297899300 0.00034221710 -0.00134669500 -0.00243180100 -0.00330905100 -0.00295758100 -0.00044122120 0.00349044300 0.00836323400 0.01384517000 0.01785219000 0.02063917000 0.02267090000 0.02059885000 0.01428178000 0.00697271100 0.00011601690 -0.00585176900 -0.01084905000 -0.01526852000 -0.01959770000 -0.02232276000 -0.02293638000 -0.02154739000 -0.01635472000 -0.00975526900 -0.00431952600 0.00119177600 0.00746404000 0.01385014000 0.01940681000 0.02358159000 0.02436299000 0.02171993000 0.01904399000 0.01617896000 0.01206650000 0.00836248000 0.00580290400 0.00525708900 0.00593338300 0.00602938300 0.00457846600 -0.00062259450 -0.00748137000 -0.01229391000 -0.01553813000 -0.01746952000 -0.01717464000 -0.01525861000 -0.01385641000 -0.01304828000 -0.01259737000 -0.01349457000 -0.01383672000 -0.01197946000 -0.00804459600 -0.00292126300 0.00078515870 0.00300670300 0.00636154800 0.01131528000 0.01621608000 0.01981585000 0.02149594000 0.02083606000 0.01822049000 0.01442460000 0.00939073500 0.00297176100 -0.00465530400 -0.01153404000 -0.01545522000 -0.01631590000 -0.01448552000 -0.01158169000 -0.00776934000 -0.00341756500 -0.00017135120 0.00247532600 0.00566308800 0.01149641000 0.01824492000 0.02331108000 0.02700441000 0.02666041000 0.02216969000 0.01539858000 0.00708515000 0.00042869710 -0.00371466600 -0.00701718000 -0.01057736000 -0.01468739000 -0.01828729000 -0.02054199000 -0.02043365000 -0.01750206000 -0.01312320000 -0.00871673000 -0.00410869200 0.00092831410

Antworten (1)

Walter Roberson
Walter Roberson am 28 Okt. 2011
The 9.81 you are multiplying by strongly suggests that your data is acceleration. You would need to integrate that twice in order to get amplitude. On the other hand, the fact that your text legend lists amplitude as being in m/sec suggests that what you are calling amplitude is what other people would call velocity.
Anyhow, whether you integrate once or twice, the fact that your acceleration start negative imply that your initial velocity or distance measures are going to be negative unless the constant of integration takes them positive.
Perhaps your teacher is thinking that "since the system is at rest at the start, it doesn't make sense for it to "slow down" (negative velocity.) But in real life circumstances, going from rest to "slowing down" just means that the wave is pushing out towards you from a direction that happens to be aligned opposite of the absolute coordinate reference of the accelerometer. There is nothing inherently wrong with that: earthquakes can come from nearly any direction so you expect that if you arbitrarily mark "forward" and "backward" on the axes that some of them will move the sensor "forward" first and some will move it "backwards" first.

Kategorien

Mehr zu Earthquake Engineering finden Sie in Help Center und File Exchange

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by