Google Answers Logo
View Question
 
Q: Curve Fit for Weather Model ( Answered 1 out of 5 stars,   5 Comments )
Question  
Subject: Curve Fit for Weather Model
Category: Science
Asked by: paxriver-ga
List Price: $2.00
Posted: 19 Oct 2004 15:55 PDT
Expires: 18 Nov 2004 14:55 PST
Question ID: 417205
"Given a seemingly random set of data points (x,y)in the range of y =
+/- 1 and x=a seemingly random set of dates.

I seek a sine wave (S1) formula of fixed frequency F1 and fixed
amplitude A1 in which A1 always = +/- 1.0 (Y axis) and units of X-axis
are calendar days.

I need to find the formula for S1 that best fits the (x,y) data points.

Then if I have a second sinewave S2 of a different frequency F2, (same
A1 and x-axis units) then what is the formula of the best fit of S2
for the same set of data points (x,y).

As for S3, F3.

This has to do with an analysis of weather patterns and will be
modeled in a computer and used on a government research project.
Answer  
Subject: Re: Curve Fit for Weather Model
Answered By: hedgie-ga on 02 Nov 2004 20:15 PST
Rated:1 out of 5 stars
 
Tom

hfshaw-ga  can not paste his formulation into the answer box,
 since he is not GA researcher (his name is not clickable) See
http://answers.google.com/answers/threadview?id=384017

I doubt that fit you are seeking is the right approach.
You probably want to correlate Y(t) data with other time series ..
 I am sure you can find expert help within the defense community, which
can help to formulate problem and select algorithms - 
admitedly, not for $2.  GA seems to be unique in this respect.

So - here is $2 answer: You may want to look Fourier series tool in this toolbox:

Curve Fitting Toolbox
http://www.mathworks.com/access/helpdesk/help/toolbox/curvefit/ch_fitt6.html

Not forcing the frequency - and just getting a Fourier spectrum may be
better approach. If you are sure that only one specific frequency is
of interest you may just 'filter away' the noise.

Search Terms: filter noise time series

Hedgie

Clarification of Answer by hedgie-ga on 05 Dec 2004 10:44 PST
paxriver-ga 

The reference I gave you explains sentence 'his name is not clickable'

Explanation is not in the answer, but in the comments:
----------------------
Comments 
  Subject: Re: What are some good recommendations about buying a DVD duplicator? 
 From: pinkfreud-ga on 05 Aug 2004 15:07 PDT 
  John,

Crythias is one of our most helpful commenters, but he is not a Google
Answers Researcher, and thus cannot post an official answer nor
receive compensation.....

------------------------------
Please try reading it again. The whole page.
paxriver-ga rated this answer:1 out of 5 stars
Poor evasive answer that tries to tell me what I should have asked
rather than answering what I did ask.  If I had other resources, I
would not have used this service.  He also refers to a link to an
answer that when clicked gives "There is no answer at this time.". 
Even this little bit was not worth $2.

Comments  
Subject: Re: Curve Fit for Weather Model
From: hedgie-ga on 19 Oct 2004 20:35 PDT
 
"government research project" ?

  Which government is funding this?
  Just curious :-)
Subject: Re: Curve Fit for Weather Model
From: hfshaw-ga on 20 Oct 2004 10:52 PDT
 
You have constrained the problem such that the only free parameter
that can be optimized is the phase of the trigonometric function.

For N data points, and for each frequency F_j, find the value of d
that minimizes the sum:

    E = {Sum i = 1 to N}[(y_i - sin(F_j*x_i + d))^2]
Subject: Re: Curve Fit for Weather Model
From: paxriver-ga on 20 Oct 2004 12:44 PDT
 
The contract is with the US Department of Defense but aspects of the
contract are classified so I cannot give any more details.

You are right that the constraint is down to shifting the phase.  Is
there some math formula (that can be put into a computer) that would
find the minimum sum.  I would imagine that it could take hundreds or
thousands of calculations of all of the data points if I cannot find a
math way to "find the value of d
that minimizes the sum".
Subject: Re: Curve Fit for Weather Model
From: hfshaw-ga on 20 Oct 2004 12:54 PDT
 
"Is there some math formula (that can be put into a computer) that would
find the minimum sum."

Yes, there are.
Subject: Re: Curve Fit for Weather Model
From: paxriver-ga on 20 Oct 2004 15:20 PDT
 
hfshaw-ga, you have been very helpful.  Please copy your last response
into the ANSWER area so that I can pay you.  I think you for your time
and consideration.

Tom

Important Disclaimer: Answers and comments provided on Google Answers are general information, and are not intended to substitute for informed professional medical, psychiatric, psychological, tax, legal, investment, accounting, or other professional advice. Google does not endorse, and expressly disclaims liability for any product, manufacturer, distributor, service or service provider mentioned or any opinion expressed in answers or comments. Please read carefully the Google Answers Terms of Service.

If you feel that you have found inappropriate content, please let us know by emailing us at answers-support@google.com with the question ID listed above. Thank you.
Search Google Answers for
Google Answers  


Google Home - Answers FAQ - Terms of Service - Privacy Policy