<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0">
  <channel>
    <link>http://www.mathworks.com/matlabcentral/newsreader/view_thread/264984</link>
    <title>MATLAB Central Newsreader - Data Fitting to Parametric Equations</title>
    <description>Feed for thread: Data Fitting to Parametric Equations</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>Wed, 04 Nov 2009 15:40:20 -0500</pubDate>
      <title>Data Fitting to Parametric Equations</title>
      <link>http://www.mathworks.com/matlabcentral/newsreader/view_thread/264984#692086</link>
      <author>Anthony Mai</author>
      <description>Hello all,&lt;br&gt;
I have a data set of (x,y,z) Cartesian values, and the following parametric equations for a skewed tear-dropped ellipsoid:&lt;br&gt;
X=a0+a1*cos(theta)*sin(phi)&lt;br&gt;
Y=b0+b1*sin(phi)*sin(theta)&lt;br&gt;
Z=c0+c1*cos(phi)*exp(d0*phi)&lt;br&gt;
theta=(0:2*pi)&lt;br&gt;
phi=(0:pi)&lt;br&gt;
Is there any way possible to determine these parameters a0, a1, etc.? I have attempted to google every link regarding at surface fitting and have come up empty handed. These equations are weird in that it's in parametric and it's in 3d. The equations are for experimental data obtained from testing antennae strengths. Possibly it could be some type of spheroid also, but again same complexity of equations. Also maybe I could try using the implicit equation instead of using parametric? With that regard I tried finding some implicit data fitting methods and again nothing. Any help or points in some direction would greatly help. Thanks!&lt;br&gt;
&lt;br&gt;
Anthony</description>
    </item>
    <item>
      <pubDate>Wed, 04 Nov 2009 16:01:03 -0500</pubDate>
      <title>Re: Data Fitting to Parametric Equations</title>
      <link>http://www.mathworks.com/matlabcentral/newsreader/view_thread/264984#692094</link>
      <author>Matt </author>
      <description>&quot;Anthony Mai&quot; &amp;lt;antoniusmae@gmail.com&amp;gt; wrote in message &amp;lt;hcs794$m3p$1@fred.mathworks.com&amp;gt;...&lt;br&gt;
&amp;gt; Hello all,&lt;br&gt;
&amp;gt; I have a data set of (x,y,z) Cartesian values, and the following parametric equations for a skewed tear-dropped ellipsoid:&lt;br&gt;
&amp;gt; X=a0+a1*cos(theta)*sin(phi)&lt;br&gt;
&amp;gt; Y=b0+b1*sin(phi)*sin(theta)&lt;br&gt;
&amp;gt; Z=c0+c1*cos(phi)*exp(d0*phi)&lt;br&gt;
&amp;gt; theta=(0:2*pi)&lt;br&gt;
&amp;gt; phi=(0:pi)&lt;br&gt;
&amp;gt; Is there any way possible to determine these parameters a0, a1, etc.? I have attempted to google every link regarding at surface fitting and have come up empty handed. These equations are weird in that it's in parametric and it's in 3d. The equations are for experimental data obtained from testing antennae strengths. Possibly it could be some type of spheroid also, but again same complexity of equations. Also maybe I could try using the implicit equation instead of using parametric? With that regard I tried finding some implicit data fitting methods and again nothing. Any help or points in some direction would greatly help. Thanks!&lt;br&gt;
------&lt;br&gt;
&lt;br&gt;
Doesn't seem weird to me. It's almost a linear fitting problem, apart from the parameter d0, which is your only intrinisically non-linear parameter. Check the file exchange for the function fminspleas()</description>
    </item>
    <item>
      <pubDate>Wed, 04 Nov 2009 17:04:07 -0500</pubDate>
      <title>Re: Data Fitting to Parametric Equations</title>
      <link>http://www.mathworks.com/matlabcentral/newsreader/view_thread/264984#692114</link>
      <author>Anthony Mai</author>
      <description>This is in the documentation:&lt;br&gt;
&lt;br&gt;
%            FMINSPLEAS assumes a model of the form:&lt;br&gt;
%            ydata = a1*f1(INLP,xdata) + a2*f2(INLP,xdata) + ...&lt;br&gt;
%            funlist is the list of functions {f1,f2,...}.&lt;br&gt;
&lt;br&gt;
Yet, I am still quite not comprehending how to approach this using fmins, as I have 3 parametrics not a z=f(x,y), or some ydata = ... I am still a novice at this and wish to find out how to utilize the inputs of &quot;xdata&quot;, &quot;ydata&quot; given cartesian data. Thanks for helping!&lt;br&gt;
&lt;br&gt;
Anthony&lt;br&gt;
&lt;br&gt;
&quot;Matt &quot; &amp;lt;xys@whatever.com&amp;gt; wrote in message &amp;lt;hcs8fv$bi4$1@fred.mathworks.com&amp;gt;...&lt;br&gt;
&lt;br&gt;
&amp;gt; Doesn't seem weird to me. It's almost a linear fitting problem, apart from the parameter d0, which is your only intrinisically non-linear parameter. Check the file exchange for the function fminspleas()</description>
    </item>
    <item>
      <pubDate>Wed, 04 Nov 2009 17:48:02 -0500</pubDate>
      <title>Re: Data Fitting to Parametric Equations</title>
      <link>http://www.mathworks.com/matlabcentral/newsreader/view_thread/264984#692135</link>
      <author>Matt </author>
      <description>&quot;Anthony Mai&quot; &amp;lt;antoniusmae@gmail.com&amp;gt; wrote in message &amp;lt;hcsc67$644$1@fred.mathworks.com&amp;gt;...&lt;br&gt;
&amp;gt; This is in the documentation:&lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; %            FMINSPLEAS assumes a model of the form:&lt;br&gt;
&amp;gt; %            ydata = a1*f1(INLP,xdata) + a2*f2(INLP,xdata) + ...&lt;br&gt;
&amp;gt; %            funlist is the list of functions {f1,f2,...}.&lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; Yet, I am still quite not comprehending how to approach this using fmins, as I have 3 parametrics not a z=f(x,y),&lt;br&gt;
===========&lt;br&gt;
&lt;br&gt;
A few notes that might help:&lt;br&gt;
&lt;br&gt;
(1)  f1, f2, etc... can be vector-valued functions in fminspleas&lt;br&gt;
&lt;br&gt;
(2) You don't have a z=f(x,y), but you do have an X=f(theta,phi). &lt;br&gt;
In other words, instead of z,x,y you have X, theta,phi respectively. The labelling is the only real difference. &lt;br&gt;
&lt;br&gt;
(3) The fact that you have 3 parametrics doesn't add much complexity in this case, because all three of X, Y, Z depend on a different set of parameters. So you can really treat this as three separate surface fitting problems&lt;br&gt;
&lt;br&gt;
X=f(theta,phi); %problem 1 - fit a surface to X&lt;br&gt;
Y=g(theta,phi); %problem 2 - fit a surface to Y&lt;br&gt;
Z=h(theta,phi); %problem 3 - fit a surface to Z&lt;br&gt;
&lt;br&gt;
(4) The dependence of X on a0, a1 is purely linear. &lt;br&gt;
It's just a linear fitting. Similarly for Y.</description>
    </item>
  </channel>
</rss>

