<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0">
  <channel>
    <link>http://www.mathworks.com/matlabcentral/newsreader/view_thread/253442</link>
    <title>MATLAB Central Newsreader - Creating a movie with varying time steps</title>
    <description>Feed for thread: Creating a movie with varying time steps</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, 11 Jun 2009 13:56:40 -0400</pubDate>
      <title>Creating a movie with varying time steps</title>
      <link>http://www.mathworks.com/matlabcentral/newsreader/view_thread/253442#656406</link>
      <author>Alexander Erlich</author>
      <description>Hi there,&lt;br&gt;
&lt;br&gt;
suppose I have a solution of a differential equation which I would&lt;br&gt;
like to visualize with surf. The numerical solution tells me exactly&lt;br&gt;
when to plot the object in which coordinates. Now, I would like to&lt;br&gt;
create a movie out of these surf plots. I cannot use getframe, as it&lt;br&gt;
does not enable me to consider the varying time steps. Is there&lt;br&gt;
another way to do that?&lt;br&gt;
&lt;br&gt;
Thanks in advance!&lt;br&gt;
&lt;br&gt;
Alexander</description>
    </item>
    <item>
      <pubDate>Thu, 11 Jun 2009 14:14:57 -0400</pubDate>
      <title>Re: Creating a movie with varying time steps</title>
      <link>http://www.mathworks.com/matlabcentral/newsreader/view_thread/253442#656414</link>
      <author>Steven Lord</author>
      <description>&lt;br&gt;
&quot;Alexander Erlich&quot; &amp;lt;alexander.erlich@gmail.com&amp;gt; wrote in message &lt;br&gt;
news:54d79ffd-aeb6-4244-ac04-445c12c94c06@z7g2000vbh.googlegroups.com...&lt;br&gt;
&amp;gt; Hi there,&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt; suppose I have a solution of a differential equation which I would&lt;br&gt;
&amp;gt; like to visualize with surf. The numerical solution tells me exactly&lt;br&gt;
&amp;gt; when to plot the object in which coordinates. Now, I would like to&lt;br&gt;
&amp;gt; create a movie out of these surf plots. I cannot use getframe, as it&lt;br&gt;
&amp;gt; does not enable me to consider the varying time steps. Is there&lt;br&gt;
&amp;gt; another way to do that?&lt;br&gt;
&lt;br&gt;
Solve the system of ODEs to generate a solution struct array (using the &quot;sol &lt;br&gt;
= ...&quot; syntax described in the help rather than the &quot;[t, y] = ...&quot; syntax.) &lt;br&gt;
Once you have the solution struct, use DEVAL to evaluate the solution at &lt;br&gt;
equally-spaced time steps.  Then create the movie from the surfaces created &lt;br&gt;
by the equally-timestep-spaced data.&lt;br&gt;
&lt;br&gt;
-- &lt;br&gt;
Steve Lord&lt;br&gt;
slord@mathworks.com </description>
    </item>
    <item>
      <pubDate>Thu, 11 Jun 2009 18:11:17 -0400</pubDate>
      <title>Re: Creating a movie with varying time steps</title>
      <link>http://www.mathworks.com/matlabcentral/newsreader/view_thread/253442#656498</link>
      <author>Alexander </author>
      <description>Thank you Steve,&lt;br&gt;
&lt;br&gt;
I will try that. But I still have a question: Suppose I had equally-&lt;br&gt;
spaced time steps. Getframe won't know how long one time step is, will&lt;br&gt;
it? It might play the movie much faster than it really (=as given by&lt;br&gt;
the solution of the ODE) is, or slower, probably depending on my&lt;br&gt;
computer. If I'm right with that problem, what could I do?&lt;br&gt;
&lt;br&gt;
Alexander&lt;br&gt;
&lt;br&gt;
On Jun 11, 4:14&#160;pm, &quot;Steven Lord&quot; &amp;lt;sl...@mathworks.com&amp;gt; wrote:&lt;br&gt;
&amp;gt; &quot;Alexander Erlich&quot; &amp;lt;alexander.erl...@gmail.com&amp;gt; wrote in message&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt; news:54d79ffd-aeb6-4244-ac04-445c12c94c06@z7g2000vbh.googlegroups.com...&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt; &amp;gt; Hi there,&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt; &amp;gt; suppose I have a solution of a differential equation which I would&lt;br&gt;
&amp;gt; &amp;gt; like to visualize with surf. The numerical solution tells me exactly&lt;br&gt;
&amp;gt; &amp;gt; when to plot the object in which coordinates. Now, I would like to&lt;br&gt;
&amp;gt; &amp;gt; create a movie out of these surf plots. I cannot use getframe, as it&lt;br&gt;
&amp;gt; &amp;gt; does not enable me to consider the varying time steps. Is there&lt;br&gt;
&amp;gt; &amp;gt; another way to do that?&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt; Solve the system of ODEs to generate a solution struct array (using the &quot;sol&lt;br&gt;
&amp;gt; = ...&quot; syntax described in the help rather than the &quot;[t, y] = ...&quot; syntax.)&lt;br&gt;
&amp;gt; Once you have the solution struct, use DEVAL to evaluate the solution at&lt;br&gt;
&amp;gt; equally-spaced time steps. &#160;Then create the movie from the surfaces created&lt;br&gt;
&amp;gt; by the equally-timestep-spaced data.&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt; --&lt;br&gt;
&amp;gt; Steve Lord&lt;br&gt;
&amp;gt; sl...@mathworks.com</description>
    </item>
    <item>
      <pubDate>Thu, 11 Jun 2009 21:35:03 -0400</pubDate>
      <title>Re: Creating a movie with varying time steps</title>
      <link>http://www.mathworks.com/matlabcentral/newsreader/view_thread/253442#656569</link>
      <author>Steven Lord</author>
      <description>&lt;br&gt;
&quot;Alexander&quot; &amp;lt;alexander.erlich@gmail.com&amp;gt; wrote in message &lt;br&gt;
news:749aa82c-1702-4c71-b5c2-209488908cee@h11g2000yqb.googlegroups.com...&lt;br&gt;
&amp;gt; Thank you Steve,&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt; I will try that. But I still have a question: Suppose I had equally-&lt;br&gt;
&amp;gt; spaced time steps. Getframe won't know how long one time step is, will&lt;br&gt;
&amp;gt; it? It might play the movie much faster than it really (=as given by&lt;br&gt;
&amp;gt; the solution of the ODE) is, or slower, probably depending on my&lt;br&gt;
&amp;gt; computer. If I'm right with that problem, what could I do?&lt;br&gt;
&lt;br&gt;
You're correct that GETFRAME doesn't know how long one time step is. &lt;br&gt;
Technically, MOVIE and AVIFILE don't know how long one time step is either. &lt;br&gt;
But both MOVIE and AVIFILE know how many frames to show per second, and &lt;br&gt;
that's just as good, isn't it?&lt;br&gt;
&lt;br&gt;
&lt;a href=&quot;http://www.mathworks.com/access/helpdesk/help/techdoc/ref/movie.html&quot;&gt;http://www.mathworks.com/access/helpdesk/help/techdoc/ref/movie.html&lt;/a&gt;&lt;br&gt;
&lt;br&gt;
&lt;a href=&quot;http://www.mathworks.com/access/helpdesk/help/techdoc/ref/avifile.html&quot;&gt;http://www.mathworks.com/access/helpdesk/help/techdoc/ref/avifile.html&lt;/a&gt;&lt;br&gt;
&lt;br&gt;
-- &lt;br&gt;
Steve Lord&lt;br&gt;
slord@mathworks.com </description>
    </item>
    <item>
      <pubDate>Fri, 12 Jun 2009 14:31:40 -0400</pubDate>
      <title>Re: Creating a movie with varying time steps</title>
      <link>http://www.mathworks.com/matlabcentral/newsreader/view_thread/253442#656765</link>
      <author>Alexander </author>
      <description>Thanks a lot Steve,&lt;br&gt;
&lt;br&gt;
it makes sense :-)&lt;br&gt;
&lt;br&gt;
It would have taken me ages to figure this out myself, I didn't know&lt;br&gt;
about deval! Now, with a movie of let's say 20fps, I can use deval to&lt;br&gt;
obtain intervals of 1/20th of a second and render the movie! This&lt;br&gt;
method will probably enable me to make my computer render a movie of&lt;br&gt;
60s for three hours or so, hopefully making it both correct and&lt;br&gt;
optically refined!&lt;br&gt;
&lt;br&gt;
Thanks!&lt;br&gt;
&lt;br&gt;
Alexander&lt;br&gt;
&lt;br&gt;
On Jun 11, 11:35&#160;pm, &quot;Steven Lord&quot; &amp;lt;sl...@mathworks.com&amp;gt; wrote:&lt;br&gt;
&amp;gt; &quot;Alexander&quot; &amp;lt;alexander.erl...@gmail.com&amp;gt; wrote in message&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt; news:749aa82c-1702-4c71-b5c2-209488908cee@h11g2000yqb.googlegroups.com...&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt; &amp;gt; Thank you Steve,&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt; &amp;gt; I will try that. But I still have a question: Suppose I had equally-&lt;br&gt;
&amp;gt; &amp;gt; spaced time steps. Getframe won't know how long one time step is, will&lt;br&gt;
&amp;gt; &amp;gt; it? It might play the movie much faster than it really (=as given by&lt;br&gt;
&amp;gt; &amp;gt; the solution of the ODE) is, or slower, probably depending on my&lt;br&gt;
&amp;gt; &amp;gt; computer. If I'm right with that problem, what could I do?&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt; You're correct that GETFRAME doesn't know how long one time step is.&lt;br&gt;
&amp;gt; Technically, MOVIE and AVIFILE don't know how long one time step is either.&lt;br&gt;
&amp;gt; But both MOVIE and AVIFILE know how many frames to show per second, and&lt;br&gt;
&amp;gt; that's just as good, isn't it?&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt; &lt;a href=&quot;http://www.mathworks.com/access/helpdesk/help/techdoc/ref/movie.html&quot;&gt;http://www.mathworks.com/access/helpdesk/help/techdoc/ref/movie.html&lt;/a&gt;&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt; &lt;a href=&quot;http://www.mathworks.com/access/helpdesk/help/techdoc/ref/avifile.html&quot;&gt;http://www.mathworks.com/access/helpdesk/help/techdoc/ref/avifile.html&lt;/a&gt;&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt; --&lt;br&gt;
&amp;gt; Steve Lord&lt;br&gt;
&amp;gt; sl...@mathworks.com</description>
    </item>
  </channel>
</rss>

