<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
		>
<channel>
	<title>Comments on: Paper: Beautiful differentiation</title>
	<atom:link href="http://conal.net/blog/posts/paper-beautiful-differentiation/feed" rel="self" type="application/rss+xml" />
	<link>http://conal.net/blog/posts/paper-beautiful-differentiation</link>
	<description>Inspirations &#38; experiments, mainly about denotative/functional programming in Haskell</description>
	<lastBuildDate>Mon, 21 Nov 2011 12:42:05 +0000</lastBuildDate>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.1</generator>
	<item>
		<title>By: conal</title>
		<link>http://conal.net/blog/posts/paper-beautiful-differentiation/comment-page-1#comment-41633</link>
		<dc:creator>conal</dc:creator>
		<pubDate>Tue, 16 Mar 2010 20:14:25 +0000</pubDate>
		<guid isPermaLink="false">http://conal.net/blog/?p=85#comment-41633</guid>
		<description>&lt;p&gt;Yrogirg - I fixed this typo in the paper and in the software (&lt;a href=&quot;http://hackage.haskell.org/cgi-bin/hackage-scripts/package/vector-space&quot; rel=&quot;nofollow&quot;&gt;vector-space&lt;/a&gt; 0.6.0 and later).  Thanks very much for this catch!&lt;/p&gt;
</description>
		<content:encoded><![CDATA[<p>Yrogirg &#8211; I fixed this typo in the paper and in the software (<a href="http://hackage.haskell.org/cgi-bin/hackage-scripts/package/vector-space" rel="nofollow">vector-space</a> 0.6.0 and later).  Thanks very much for this catch!</p>]]></content:encoded>
	</item>
	<item>
		<title>By: Yrogirg</title>
		<link>http://conal.net/blog/posts/paper-beautiful-differentiation/comment-page-1#comment-41412</link>
		<dc:creator>Yrogirg</dc:creator>
		<pubDate>Sat, 13 Mar 2010 11:44:06 +0000</pubDate>
		<guid isPermaLink="false">http://conal.net/blog/?p=85#comment-41412</guid>
		<description>&lt;p&gt;I believe there is a small typo in Figure 2 --- recip (D x x&#039;) should be&lt;/p&gt;

&lt;p&gt;recip (D x x&#039;) = D (recip x) (- x&#039; / sqr x)&lt;/p&gt;

&lt;p&gt;(I mean minus is required)&lt;/p&gt;
</description>
		<content:encoded><![CDATA[<p>I believe there is a small typo in Figure 2 &#8212; recip (D x x&#8217;) should be</p>

<p>recip (D x x&#8217;) = D (recip x) (- x&#8217; / sqr x)</p>

<p>(I mean minus is required)</p>]]></content:encoded>
	</item>
	<item>
		<title>By: Tim S</title>
		<link>http://conal.net/blog/posts/paper-beautiful-differentiation/comment-page-1#comment-17557</link>
		<dc:creator>Tim S</dc:creator>
		<pubDate>Tue, 24 Mar 2009 22:19:00 +0000</pubDate>
		<guid isPermaLink="false">http://conal.net/blog/?p=85#comment-17557</guid>
		<description>&lt;p&gt;I read Spivak&#039;s rant about notation a few years ago at the same I was learning about Haskell. At the time I thought his suggestions almost amounted to writing a Haskell program, so it was very gratifying to read this excellent paper.&lt;/p&gt;
</description>
		<content:encoded><![CDATA[<p>I read Spivak&#8217;s rant about notation a few years ago at the same I was learning about Haskell. At the time I thought his suggestions almost amounted to writing a Haskell program, so it was very gratifying to read this excellent paper.</p>]]></content:encoded>
	</item>
	<item>
		<title>By: conal</title>
		<link>http://conal.net/blog/posts/paper-beautiful-differentiation/comment-page-1#comment-17260</link>
		<dc:creator>conal</dc:creator>
		<pubDate>Tue, 17 Mar 2009 15:59:37 +0000</pubDate>
		<guid isPermaLink="false">http://conal.net/blog/?p=85#comment-17260</guid>
		<description>&lt;blockquote&gt;
  &lt;p&gt;this confusion is traditional in mathematics and the name &quot;calculus of several variables&quot; though nonsensical really is the name of the subject.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;Hi Omar,&lt;/p&gt;

&lt;p&gt;I relate to naming (more generally, language) as evolving, not static (as in &quot;is&quot; &amp; &quot;the&quot;).
I do believe muddled thinking produces muddled language, which then perpetuates muddled thinking.
So I like to contribute my own bit of energy to evolving toward language (and indirectly, thinking) I&#039;d like to see catch on.
Given your encouragement to use a non-traditionally accurate replacement, I suspect you agree.&lt;/p&gt;

&lt;p&gt;Thanks for mentioning Spivak&#039;s rant.  I vaguely remember reading &amp; enjoying it.  BTW, his book made a lasting impression on me when I was 19, and only last year was I finally able to use what I learned there.&lt;/p&gt;
</description>
		<content:encoded><![CDATA[<blockquote>
  <p>this confusion is traditional in mathematics and the name &#8220;calculus of several variables&#8221; though nonsensical really is the name of the subject.</p>
</blockquote>

<p>Hi Omar,</p>

<p>I relate to naming (more generally, language) as evolving, not static (as in &#8220;is&#8221; &amp; &#8220;the&#8221;).
I do believe muddled thinking produces muddled language, which then perpetuates muddled thinking.
So I like to contribute my own bit of energy to evolving toward language (and indirectly, thinking) I&#8217;d like to see catch on.
Given your encouragement to use a non-traditionally accurate replacement, I suspect you agree.</p>

<p>Thanks for mentioning Spivak&#8217;s rant.  I vaguely remember reading &amp; enjoying it.  BTW, his book made a lasting impression on me when I was 19, and only last year was I finally able to use what I learned there.</p>]]></content:encoded>
	</item>
	<item>
		<title>By: Omar</title>
		<link>http://conal.net/blog/posts/paper-beautiful-differentiation/comment-page-1#comment-17257</link>
		<dc:creator>Omar</dc:creator>
		<pubDate>Tue, 17 Mar 2009 15:03:13 +0000</pubDate>
		<guid isPermaLink="false">http://conal.net/blog/?p=85#comment-17257</guid>
		<description>&lt;p&gt;You&#039;re right that &quot;calculus of several variables&quot; is strictly speaking wrong. But this confusion is traditional in mathematics and the name &quot;calculus of several variables&quot; though nonsensical really is the name of the subject.&lt;/p&gt;

&lt;p&gt;So you could call it that, using it not as description of the subject but literally just a name.&lt;/p&gt;

&lt;p&gt;But your suggestion of &quot;calculus on vector spaces&quot; is even better; I hope you go with that.&lt;/p&gt;

&lt;p&gt;By the way, in Calculus on Manifolds Spivak has a nice rant about the classical notation for derivatives, a notation which incorporates the variable confusion you mentioned.&lt;/p&gt;
</description>
		<content:encoded><![CDATA[<p>You&#8217;re right that &#8220;calculus of several variables&#8221; is strictly speaking wrong. But this confusion is traditional in mathematics and the name &#8220;calculus of several variables&#8221; though nonsensical really is the name of the subject.</p>

<p>So you could call it that, using it not as description of the subject but literally just a name.</p>

<p>But your suggestion of &#8220;calculus on vector spaces&#8221; is even better; I hope you go with that.</p>

<p>By the way, in Calculus on Manifolds Spivak has a nice rant about the classical notation for derivatives, a notation which incorporates the variable confusion you mentioned.</p>]]></content:encoded>
	</item>
	<item>
		<title>By: conal</title>
		<link>http://conal.net/blog/posts/paper-beautiful-differentiation/comment-page-1#comment-17256</link>
		<dc:creator>conal</dc:creator>
		<pubDate>Tue, 17 Mar 2009 14:37:27 +0000</pubDate>
		<guid isPermaLink="false">http://conal.net/blog/?p=85#comment-17256</guid>
		<description>&lt;p&gt;Thanks, Oma.  I&#039;ll downplay the &quot;manifolds&quot; thing some more.&lt;/p&gt;

&lt;p&gt;I&#039;m unsure what label (if any) to use, as the traditional names you mentioned are problematic for me.  I hear &quot;Calculus of several variables&quot; (or &quot;multi-variate&quot; calculus) as a (traditional) syntax/semantics confusion, since functions don&#039;t have variables (though syntax for them might).  And &quot;calculus on R^n&quot; is a more specific setting than I have in mind.  Perhaps &quot;calculus on vector spaces&quot;.&lt;/p&gt;
</description>
		<content:encoded><![CDATA[<p>Thanks, Oma.  I&#8217;ll downplay the &#8220;manifolds&#8221; thing some more.</p>

<p>I&#8217;m unsure what label (if any) to use, as the traditional names you mentioned are problematic for me.  I hear &#8220;Calculus of several variables&#8221; (or &#8220;multi-variate&#8221; calculus) as a (traditional) syntax/semantics confusion, since functions don&#8217;t have variables (though syntax for them might).  And &#8220;calculus on R^n&#8221; is a more specific setting than I have in mind.  Perhaps &#8220;calculus on vector spaces&#8221;.</p>]]></content:encoded>
	</item>
	<item>
		<title>By: Omar</title>
		<link>http://conal.net/blog/posts/paper-beautiful-differentiation/comment-page-1#comment-17255</link>
		<dc:creator>Omar</dc:creator>
		<pubDate>Tue, 17 Mar 2009 13:59:29 +0000</pubDate>
		<guid isPermaLink="false">http://conal.net/blog/?p=85#comment-17255</guid>
		<description>&lt;p&gt;I enjoyed the paper, your implementation really is pretty.&lt;/p&gt;

&lt;p&gt;I just wanted to point out a mathematical naming issue:&lt;/p&gt;

&lt;p&gt;In the abstract you mention &quot;calculus on manifolds&quot;, but your paper doesn&#039;t use manifolds at all. Finite-dimensional real vector spaces are very simple special cases of manifolds so it is misleading to mention manifolds at all. Instead of &quot;calculus on manifolds&quot; you can use the traditional names for the calculus on vector spaces: &quot;calculus of several variables&quot; or &quot;calculus on R^n&quot;.&lt;/p&gt;

&lt;p&gt;You should correct this lest more mathematicians get excited by the reference to manifolds in the abstract and later disappointed when they read the paper, as happened to me. ;)&lt;/p&gt;
</description>
		<content:encoded><![CDATA[<p>I enjoyed the paper, your implementation really is pretty.</p>

<p>I just wanted to point out a mathematical naming issue:</p>

<p>In the abstract you mention &#8220;calculus on manifolds&#8221;, but your paper doesn&#8217;t use manifolds at all. Finite-dimensional real vector spaces are very simple special cases of manifolds so it is misleading to mention manifolds at all. Instead of &#8220;calculus on manifolds&#8221; you can use the traditional names for the calculus on vector spaces: &#8220;calculus of several variables&#8221; or &#8220;calculus on R^n&#8221;.</p>

<p>You should correct this lest more mathematicians get excited by the reference to manifolds in the abstract and later disappointed when they read the paper, as happened to me. <img src='http://conal.net/blog/wp-includes/images/smilies/icon_wink.gif' alt=';)' class='wp-smiley' /> </p>]]></content:encoded>
	</item>
	<item>
		<title>By: conal</title>
		<link>http://conal.net/blog/posts/paper-beautiful-differentiation/comment-page-1#comment-16513</link>
		<dc:creator>conal</dc:creator>
		<pubDate>Mon, 02 Mar 2009 05:41:36 +0000</pubDate>
		<guid isPermaLink="false">http://conal.net/blog/?p=85#comment-16513</guid>
		<description>&lt;p&gt;Thanks, Jared!&lt;/p&gt;
</description>
		<content:encoded><![CDATA[<p>Thanks, Jared!</p>]]></content:encoded>
	</item>
	<item>
		<title>By: Jared Updike</title>
		<link>http://conal.net/blog/posts/paper-beautiful-differentiation/comment-page-1#comment-16502</link>
		<dc:creator>Jared Updike</dc:creator>
		<pubDate>Mon, 02 Mar 2009 02:16:45 +0000</pubDate>
		<guid isPermaLink="false">http://conal.net/blog/?p=85#comment-16502</guid>
		<description>&lt;p&gt;Typo on page 7: &quot;an group&quot; should be &quot;a group&quot;.&lt;/p&gt;
</description>
		<content:encoded><![CDATA[<p>Typo on page 7: &#8220;an group&#8221; should be &#8220;a group&#8221;.</p>]]></content:encoded>
	</item>
	<item>
		<title>By: conal</title>
		<link>http://conal.net/blog/posts/paper-beautiful-differentiation/comment-page-1#comment-16448</link>
		<dc:creator>conal</dc:creator>
		<pubDate>Sat, 28 Feb 2009 17:11:25 +0000</pubDate>
		<guid isPermaLink="false">http://conal.net/blog/?p=85#comment-16448</guid>
		<description>&lt;p&gt;Freddie -- yes, thanks!&lt;/p&gt;
</description>
		<content:encoded><![CDATA[<p>Freddie &#8212; yes, thanks!</p>]]></content:encoded>
	</item>
	<item>
		<title>By: Freddie Manners</title>
		<link>http://conal.net/blog/posts/paper-beautiful-differentiation/comment-page-1#comment-16433</link>
		<dc:creator>Freddie Manners</dc:creator>
		<pubDate>Sat, 28 Feb 2009 09:14:24 +0000</pubDate>
		<guid isPermaLink="false">http://conal.net/blog/?p=85#comment-16433</guid>
		<description>&lt;p&gt;Figure 2, page 2, you&#039;ve implemented fromInteger in a Fractional instance; should this be fromRational?&lt;/p&gt;
</description>
		<content:encoded><![CDATA[<p>Figure 2, page 2, you&#8217;ve implemented fromInteger in a Fractional instance; should this be fromRational?</p>]]></content:encoded>
	</item>
	<item>
		<title>By: Paul Liu</title>
		<link>http://conal.net/blog/posts/paper-beautiful-differentiation/comment-page-1#comment-16429</link>
		<dc:creator>Paul Liu</dc:creator>
		<pubDate>Sat, 28 Feb 2009 05:12:55 +0000</pubDate>
		<guid isPermaLink="false">http://conal.net/blog/?p=85#comment-16429</guid>
		<description>&lt;p&gt;Sure, I agree that taking derivatives of AD is efficient by design. So integral is an issue outside the scope of your paper, but I feel like discussing it anyway - it&#039;s part of the space leak puzzle that fascinated me :-)&lt;/p&gt;

&lt;p&gt;If you define an integral function for AD values, it&#039;s likely recursive. For example, using Euler method with a fixed global dt:&lt;/p&gt;

&lt;pre&gt;
dt = 0.01
next (D v d@(D u _)) = D (v + u * dt) (next d)
integral x t = xs !! (truncate (t / dt))
  where xs = x : (map next xs)
&lt;/pre&gt;

&lt;p&gt;Then if you use it with any AD value (all high order AD values would be recursive, including constants), there is nested recusion. For example:&lt;/p&gt;

&lt;pre&gt;
e = D 1.0 e
&lt;/pre&gt;

&lt;p&gt;Enter &quot;integral e 1&quot; and &quot;exp 1&quot;. Well, approximately the same, and that&#039;s good.&lt;/p&gt;

&lt;p&gt;Enter &quot;integral e 100&quot;. Boom! It blows up immediately.&lt;/p&gt;

&lt;p&gt;Note that by using the list &quot;xs&quot;, it&#039;s already memoizing past values. So I don&#039;t think there exists an easy memoization solution to this problem.&lt;/p&gt;
</description>
		<content:encoded><![CDATA[<p>Sure, I agree that taking derivatives of AD is efficient by design. So integral is an issue outside the scope of your paper, but I feel like discussing it anyway &#8211; it&#8217;s part of the space leak puzzle that fascinated me <img src='http://conal.net/blog/wp-includes/images/smilies/icon_smile.gif' alt=':-)' class='wp-smiley' /> </p>

<p>If you define an integral function for AD values, it&#8217;s likely recursive. For example, using Euler method with a fixed global dt:</p>

<pre>
dt = 0.01
next (D v d@(D u _)) = D (v + u * dt) (next d)
integral x t = xs !! (truncate (t / dt))
  where xs = x : (map next xs)
</pre>

<p>Then if you use it with any AD value (all high order AD values would be recursive, including constants), there is nested recusion. For example:</p>

<pre>
e = D 1.0 e
</pre>

<p>Enter &#8220;integral e 1&#8243; and &#8220;exp 1&#8243;. Well, approximately the same, and that&#8217;s good.</p>

<p>Enter &#8220;integral e 100&#8243;. Boom! It blows up immediately.</p>

<p>Note that by using the list &#8220;xs&#8221;, it&#8217;s already memoizing past values. So I don&#8217;t think there exists an easy memoization solution to this problem.</p>]]></content:encoded>
	</item>
	<item>
		<title>By: conal</title>
		<link>http://conal.net/blog/posts/paper-beautiful-differentiation/comment-page-1#comment-16427</link>
		<dc:creator>conal</dc:creator>
		<pubDate>Sat, 28 Feb 2009 04:45:37 +0000</pubDate>
		<guid isPermaLink="false">http://conal.net/blog/?p=85#comment-16427</guid>
		<description>&lt;p&gt;Anonymous -- Thanks a bunch for catching these mistakes.  If you want to share your name with me, I&#039;d enjoy acknowledging your help in the paper.&lt;/p&gt;
</description>
		<content:encoded><![CDATA[<p>Anonymous &#8212; Thanks a bunch for catching these mistakes.  If you want to share your name with me, I&#8217;d enjoy acknowledging your help in the paper.</p>]]></content:encoded>
	</item>
	<item>
		<title>By: conal</title>
		<link>http://conal.net/blog/posts/paper-beautiful-differentiation/comment-page-1#comment-16406</link>
		<dc:creator>conal</dc:creator>
		<pubDate>Fri, 27 Feb 2009 19:19:27 +0000</pubDate>
		<guid isPermaLink="false">http://conal.net/blog/?p=85#comment-16406</guid>
		<description>&lt;blockquote&gt;
  &lt;p&gt;BTW, the most basic operation on a high order derivative is to integrate it over an given interval. But it&#039;s difficult to do this efficiently with the stream representation for AD in Haskell. So I would question the efficiency claim you made in the introduction.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;The comment about efficiency is about sampling the derivatives, not integrating them.  For instance, to compute surface normals during rendering.&lt;/p&gt;

&lt;blockquote&gt;
  &lt;p&gt;It&#039;s very easy to run into space leaks when there is nested recursion. I won&#039;t get into the details, but it&#039;s yet another problem caused by the loss of sharing in lazy evaluation. Explicit knot tying is a possible solution, but it&#039;s ugly and utterly destroys the beauty of AD.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;Are you referring to the challenges with recursive &lt;em&gt;integrals&lt;/em&gt;, or with derivatives?&lt;/p&gt;
</description>
		<content:encoded><![CDATA[<blockquote>
  <p>BTW, the most basic operation on a high order derivative is to integrate it over an given interval. But it&#8217;s difficult to do this efficiently with the stream representation for AD in Haskell. So I would question the efficiency claim you made in the introduction.</p>
</blockquote>

<p>The comment about efficiency is about sampling the derivatives, not integrating them.  For instance, to compute surface normals during rendering.</p>

<blockquote>
  <p>It&#8217;s very easy to run into space leaks when there is nested recursion. I won&#8217;t get into the details, but it&#8217;s yet another problem caused by the loss of sharing in lazy evaluation. Explicit knot tying is a possible solution, but it&#8217;s ugly and utterly destroys the beauty of AD.</p>
</blockquote>

<p>Are you referring to the challenges with recursive <em>integrals</em>, or with derivatives?</p>]]></content:encoded>
	</item>
	<item>
		<title>By: conal</title>
		<link>http://conal.net/blog/posts/paper-beautiful-differentiation/comment-page-1#comment-16405</link>
		<dc:creator>conal</dc:creator>
		<pubDate>Fri, 27 Feb 2009 19:12:04 +0000</pubDate>
		<guid isPermaLink="false">http://conal.net/blog/?p=85#comment-16405</guid>
		<description>&lt;blockquote&gt;
  &lt;p&gt;I&#039;m not sure if the exact ideas have been implemented in Haskell before, but for me, I first learnt about it from Henrik Nilsson&#039;s paper &quot;Functional Automatic Differentiation with Dirac Impulses&quot;.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;Thanks for the reminder about Henrik&#039;s paper, which I like very much.  Henrik&#039;s paper extends Jerzy Karczmarczuk&#039;s higher-order AD to impulses (distributions), while mine extends it to vector spaces (foundation for general manifolds).  I&#039;ve added a citation to Henrik&#039;s work.  Thanks!&lt;/p&gt;
</description>
		<content:encoded><![CDATA[<blockquote>
  <p>I&#8217;m not sure if the exact ideas have been implemented in Haskell before, but for me, I first learnt about it from Henrik Nilsson&#8217;s paper &#8220;Functional Automatic Differentiation with Dirac Impulses&#8221;.</p>
</blockquote>

<p>Thanks for the reminder about Henrik&#8217;s paper, which I like very much.  Henrik&#8217;s paper extends Jerzy Karczmarczuk&#8217;s higher-order AD to impulses (distributions), while mine extends it to vector spaces (foundation for general manifolds).  I&#8217;ve added a citation to Henrik&#8217;s work.  Thanks!</p>]]></content:encoded>
	</item>
</channel>
</rss>

