<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0">
  <channel>
    <link>http://www.mathworks.com/matlabcentral/newsreader/view_thread/238057</link>
    <title>MATLAB Central Newsreader - Curve Fitting</title>
    <description>Feed for thread: Curve Fitting</description>
    <language>en-us</language>
    <copyright>&amp;copy;1994-2012 by MathWorks, Inc.</copyright>
    <webmaster>webmaster@mathworks.com</webmaster>
    <generator>MATLAB Central Newsreader</generator>
    <docs>http://blogs.law.harvard.edu/tech/rss</docs>
    <ttl>60</ttl>
    <image>
      <title>MathWorks</title>
      <url>http://www.mathworks.com/images/membrane_icon.gif</url>
    </image>
    <item>
      <pubDate>Thu, 23 Oct 2008 19:13:03 -0400</pubDate>
      <title>Curve Fitting</title>
      <link>http://www.mathworks.com/matlabcentral/newsreader/view_thread/238057#607034</link>
      <author>Rockeratw Atw</author>
      <description>Hi,&lt;br&gt;
&lt;br&gt;
I have a set of four battery discharging curves at discharging rate 1A, 10A, 30A, 40A respectively. I have an equation that describes the battery discharging behavior, so what I need to do now is to find the parameters of this equation so that the equation could predict other discharging rates. &lt;br&gt;
&lt;br&gt;
I have used least squares fit to find a unique set of parameters based on the data points i took on the four curves, but the results are not very good. &lt;br&gt;
&lt;br&gt;
I want to use some other fitting methods for parameter identification such as linear interpolation or bicubic spline fit but don't know how to program them. Could someone please provides me with some examples, references? I would very appreciated it.</description>
    </item>
    <item>
      <pubDate>Fri, 24 Oct 2008 09:26:01 -0400</pubDate>
      <title>Re: Curve Fitting</title>
      <link>http://www.mathworks.com/matlabcentral/newsreader/view_thread/238057#607123</link>
      <author>John D'Errico</author>
      <description>&quot;Rockeratw Atw&quot; &amp;lt;northcarolinastate@gmail.com&amp;gt; wrote in message &amp;lt;gdqibv$g77$1@fred.mathworks.com&amp;gt;...&lt;br&gt;
&amp;gt; Hi,&lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; I have a set of four battery discharging curves at discharging rate 1A, 10A, 30A, 40A respectively. I have an equation that describes the battery discharging behavior, so what I need to do now is to find the parameters of this equation so that the equation could predict other discharging rates. &lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; I have used least squares fit to find a unique set of parameters based on the data points i took on the four curves, but the results are not very good. &lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; I want to use some other fitting methods for parameter identification such as linear interpolation or bicubic spline fit but don't know how to program them. Could someone please provides me with some examples, references? I would very appreciated it.&lt;br&gt;
&amp;gt; &lt;br&gt;
&lt;br&gt;
You can't really use a spline to infer the parameters&lt;br&gt;
of a nonlinear equation, so I'm unsure what you are&lt;br&gt;
asking. Or maybe you are asking for something that&lt;br&gt;
you can't do.&lt;br&gt;
&lt;br&gt;
If your least squares estimation was inadequate in&lt;br&gt;
your opinion, then either you have noisy data, or&lt;br&gt;
the model is not really correct. Perhaps there are&lt;br&gt;
other factors that enter in, or the model is only an&lt;br&gt;
approximation.&lt;br&gt;
&lt;br&gt;
But, why not do a simple spline fit to each curve,&lt;br&gt;
one such spline at each discharge rate.&lt;br&gt;
&lt;br&gt;
Take your pick of any spline that you want,&lt;br&gt;
although in matlab without the splines toolbox,&lt;br&gt;
you will be limited to either spline or pchip. One&lt;br&gt;
of these should be adequate though.&lt;br&gt;
&lt;br&gt;
Now, to predict a value at any other discharge rate,&lt;br&gt;
you have 4 spline curves. You can predict a value&lt;br&gt;
on those curves using ppval. Now you have 4 points.&lt;br&gt;
Interpolate in discharge rate. Again, take your pick&lt;br&gt;
of methods here. Anything from a linear interpolant&lt;br&gt;
using interp1, to a spline or pchip, or even a cubic&lt;br&gt;
interpolating polynomial.&lt;br&gt;
&lt;br&gt;
HTH,&lt;br&gt;
John</description>
    </item>
  </channel>
</rss>

