Re: Problem fitting a curve

From: maison.mousse (maison.mousse_at_wanadoo.fr)
Date: 03/03/05


Date: Thu, 3 Mar 2005 17:18:10 +0100


tadchem a écrit dans le message
<1109861008.762461.316630@g14g2000cwa.googlegroups.com>...
>
>proton wrote:
>> I have to fit the following points using the given equation:
>>
>> points x(n): 0.39, 0.72, 1.00, 1.52, 2.8, 5.2, 9.54, 19.2, 30.1
>>
>> equation: a/x^2 + b/x + c log(x) = n*K, where n is an integer
>>
>>
>> I have to find the best approximate values for the constants a, b, c,
>> K.
>>
>> The problem is that the values of n are ANY integer, so instead of
>> being n= 0, 1, 2, ... it could be n=-19, -18, -17, ...
>>
>> I need help to: 1. find the best fit for this equation and these
>values
>> (at least for a simple case, such as n= 0, 1, 2...) and 2. see if
>there
>> is a general way of tackling this kind of problem, when the sequence
>> for n does not have any constraints.
>>
>> Any help will be very much appreciated.
>
>To get started we must irst understand the problem.
>
>Your given data:
>"points x(n): 0.39, 0.72, 1.00, 1.52, 2.8, 5.2, 9.54, 19.2, 30.1"
>only makes sense for curve fitting if the following table is used:
>
> n | x(n)
>---------
> 1 | 0.39
> 2 | 0.72
> 3 | 1.00
> 4 | 1.52
> 5 | 2.8
> 6 | 5.2
> 7 | 9.54
> 8 | 19.2
> 9 | 30.1
>
>After all, it is a *curve-fitting* problem, and curves must be at least
>two-dimensional, so it only makes sense if our points require at least
>two coordinates to specify.
>
>Plot x(n) versus n and you will see a curve. A semilog plot is
>recommended.
>
>Now you have 9 data points and 4 parameters, giving 5 degrees of
>freedom for minimizing whatever criterion you are using to measure
>deviation from "best" fit.
>
>If this doesn't at least get you started, let us know.
>
>Tom Davidson
>Richmond, VA
>

You are correct! If you use the data as above and plot
n on the x axis and x(n) on the log y axis the result is a fairly straight
line.

You might want to look at this site.
http://curvefit.com/

JOL



Relevant Pages

  • Re: Problem fitting a curve
    ... >proton wrote: ... >only makes sense for curve fitting if the following table is used: ... >Plot xversus n and you will see a curve. ... n on the x axis and xon the log y axis the result is a fairly straight ...
    (sci.physics)
  • Re: Problem fitting a curve
    ... >proton wrote: ... >only makes sense for curve fitting if the following table is used: ... >Plot xversus n and you will see a curve. ... n on the x axis and xon the log y axis the result is a fairly straight ...
    (sci.math.symbolic)
  • Re: Axis not depth sorted ?
    ... engine. ... Besides if someone really wants to apply a ruler to a 3d plot (The can ... But I do agree the axis does serve to mark relative positions roughly. ... Always labelling an outside edge of the graph box achieves that. ...
    (comp.graphics.apps.gnuplot)
  • Re: Aligning multiple x axes
    ... I'll play around with adding data to both axes so that their alignment ... The basic problem is that you didn't actually plot anything using the ... x2 axis, so autoscaling doesn't mean anything because there are no ... the x2 axes such that the data labels are in the wrong places, ...
    (comp.graphics.apps.gnuplot)
  • Re: Book on Pre-MATH for cryptography and cryptanalysis.
    ... Marwan change the axis by the technical key? ... plot, if Diane therefore parts the editor? ...
    (sci.crypt)