<?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: More beautiful fold zipping</title>
	<atom:link href="http://conal.net/blog/posts/more-beautiful-fold-zipping/feed" rel="self" type="application/rss+xml" />
	<link>http://conal.net/blog/posts/more-beautiful-fold-zipping</link>
	<description>Inspirations &#38; experiments, mainly about denotative/functional programming in Haskell</description>
	<lastBuildDate>Sat, 26 Sep 2020 21:06:12 +0000</lastBuildDate>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=4.1.17</generator>
	<item>
		<title>By: 什么# 39；如此糟糕，懒惰的I / O？ &#8211; CodingBlog</title>
		<link>http://conal.net/blog/posts/more-beautiful-fold-zipping#comment-50860</link>
		<dc:creator><![CDATA[什么# 39；如此糟糕，懒惰的I / O？ &#8211; CodingBlog]]></dc:creator>
		<pubDate>Wed, 31 May 2017 16:07:06 +0000</pubDate>
		<guid isPermaLink="false">http://conal.net/blog/?p=59#comment-50860</guid>
		<description><![CDATA[&lt;p&gt;[&#8230;] inconvenient to have to do this for every stream processor. There are some generalizations (Conal Elliott &#8211; Beautiful Fold Zipping), but they don&#8217;t seem to have caught on. However, iteratees can get you a similar level of [&#8230;]&lt;/p&gt;
]]></description>
		<content:encoded><![CDATA[<p>[&#8230;] inconvenient to have to do this for every stream processor. There are some generalizations (Conal Elliott &#8211; Beautiful Fold Zipping), but they don&#8217;t seem to have caught on. However, iteratees can get you a similar level of [&#8230;]</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Edward Kmett</title>
		<link>http://conal.net/blog/posts/more-beautiful-fold-zipping#comment-198</link>
		<dc:creator><![CDATA[Edward Kmett]]></dc:creator>
		<pubDate>Tue, 31 May 2011 22:54:44 +0000</pubDate>
		<guid isPermaLink="false">http://conal.net/blog/?p=59#comment-198</guid>
		<description><![CDATA[&lt;p&gt;FYI- In the newly broken out category-extras, the Apply class in semigroupoids provides the &#039;Applicative-consistent&#039; semantics you noticed that you want for Zip here, while the Zip class in &#039;keys&#039; provides the zip-like semantics.&lt;/p&gt;
]]></description>
		<content:encoded><![CDATA[<p>FYI- In the newly broken out category-extras, the Apply class in semigroupoids provides the &#8216;Applicative-consistent&#8217; semantics you noticed that you want for Zip here, while the Zip class in &#8216;keys&#8217; provides the zip-like semantics.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: conal</title>
		<link>http://conal.net/blog/posts/more-beautiful-fold-zipping#comment-197</link>
		<dc:creator><![CDATA[conal]]></dc:creator>
		<pubDate>Mon, 23 Feb 2009 18:38:32 +0000</pubDate>
		<guid isPermaLink="false">http://conal.net/blog/?p=59#comment-197</guid>
		<description><![CDATA[&lt;p&gt;It recently hit me that &lt;code&gt;Zip&lt;/code&gt; and &lt;code&gt;zip&lt;/code&gt; aren&#039;t such a great choice of names after all.  I&#039;d like the this notion to coincide with the &lt;code&gt;Monoidal&lt;/code&gt; operation in section 7 of &lt;em&gt;&lt;a href=&quot;http://www.soi.city.ac.uk/~ross/papers/Applicative.html&quot; rel=&quot;nofollow&quot;&gt;Applicative Programming with Effects&lt;/a&gt;&lt;/em&gt;, which must be consistent with &lt;code&gt;Applicative&lt;/code&gt; instance.  So the operation on lists would be cross product, not &lt;code&gt;zip&lt;/code&gt;.  On &lt;code&gt;ZipList&lt;/code&gt; and &lt;code&gt;Stream&lt;/code&gt;, &lt;code&gt;zip&lt;/code&gt; is fine.&lt;/p&gt;
]]></description>
		<content:encoded><![CDATA[<p>It recently hit me that <code>Zip</code> and <code>zip</code> aren&#8217;t such a great choice of names after all.  I&#8217;d like the this notion to coincide with the <code>Monoidal</code> operation in section 7 of <em><a href="http://www.soi.city.ac.uk/~ross/papers/Applicative.html" rel="nofollow">Applicative Programming with Effects</a></em>, which must be consistent with <code>Applicative</code> instance.  So the operation on lists would be cross product, not <code>zip</code>.  On <code>ZipList</code> and <code>Stream</code>, <code>zip</code> is fine.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: conal</title>
		<link>http://conal.net/blog/posts/more-beautiful-fold-zipping#comment-196</link>
		<dc:creator><![CDATA[conal]]></dc:creator>
		<pubDate>Mon, 23 Feb 2009 18:37:44 +0000</pubDate>
		<guid isPermaLink="false">http://conal.net/blog/?p=59#comment-196</guid>
		<description><![CDATA[&lt;p&gt;Thanks for the pointer, Dan.  I hadn&#039;t explored that corner of category-extras.  Will look further.&lt;/p&gt;

&lt;p&gt;Meanwhile, here&#039;s a tweaked definition of &lt;code&gt;prod&lt;/code&gt;:&lt;/p&gt;

&lt;p&gt;&lt;div&gt;
&lt;pre class=&quot;haskell&quot;&gt;prod u v = &lt;span style=&quot;color: green;&quot;&gt;&#040;&lt;/span&gt;u . &lt;a href=&quot;http://haskell.org/ghc/docs/latest/html/libraries/base/Prelude.html#v:fmap&quot; rel=&quot;nofollow&quot;&gt;&lt;span style=&quot;font-weight: bold;&quot;&gt;fmap&lt;/span&gt;&lt;/a&gt; &lt;a href=&quot;http://haskell.org/ghc/docs/latest/html/libraries/base/Prelude.html#v:fst&quot; rel=&quot;nofollow&quot;&gt;&lt;span style=&quot;font-weight: bold;&quot;&gt;fst&lt;/span&gt;&lt;/a&gt;&lt;span style=&quot;color: green;&quot;&gt;&#041;&lt;/span&gt; `&lt;a href=&quot;http://haskell.org/ghc/docs/latest/html/libraries/base/Prelude.html#v:zip&quot; rel=&quot;nofollow&quot;&gt;&lt;span style=&quot;font-weight: bold;&quot;&gt;zip&lt;/span&gt;&lt;/a&gt;` &lt;span style=&quot;color: green;&quot;&gt;&#040;&lt;/span&gt;u . &lt;a href=&quot;http://haskell.org/ghc/docs/latest/html/libraries/base/Prelude.html#v:fmap&quot; rel=&quot;nofollow&quot;&gt;&lt;span style=&quot;font-weight: bold;&quot;&gt;fmap&lt;/span&gt;&lt;/a&gt; &lt;a href=&quot;http://haskell.org/ghc/docs/latest/html/libraries/base/Prelude.html#v:snd&quot; rel=&quot;nofollow&quot;&gt;&lt;span style=&quot;font-weight: bold;&quot;&gt;snd&lt;/span&gt;&lt;/a&gt;&lt;span style=&quot;color: green;&quot;&gt;&#041;&lt;/span&gt;&lt;/pre&gt;
&lt;/div&gt;&lt;/p&gt;

&lt;p&gt;Or replace &lt;code&gt;`zip`&lt;/code&gt; with &lt;code&gt;&amp;&amp;&amp;&lt;/code&gt;.&lt;/p&gt;
]]></description>
		<content:encoded><![CDATA[<p>Thanks for the pointer, Dan.  I hadn&#8217;t explored that corner of category-extras.  Will look further.</p>

<p>Meanwhile, here&#8217;s a tweaked definition of <code>prod</code>:</p>

<p><div>
<pre class="haskell">prod u v = <span style="color: green;">&#40;</span>u . <a href="http://haskell.org/ghc/docs/latest/html/libraries/base/Prelude.html#v:fmap" rel="nofollow"><span style="font-weight: bold;">fmap</span></a> <a href="http://haskell.org/ghc/docs/latest/html/libraries/base/Prelude.html#v:fst" rel="nofollow"><span style="font-weight: bold;">fst</span></a><span style="color: green;">&#41;</span> `<a href="http://haskell.org/ghc/docs/latest/html/libraries/base/Prelude.html#v:zip" rel="nofollow"><span style="font-weight: bold;">zip</span></a>` <span style="color: green;">&#40;</span>u . <a href="http://haskell.org/ghc/docs/latest/html/libraries/base/Prelude.html#v:fmap" rel="nofollow"><span style="font-weight: bold;">fmap</span></a> <a href="http://haskell.org/ghc/docs/latest/html/libraries/base/Prelude.html#v:snd" rel="nofollow"><span style="font-weight: bold;">snd</span></a><span style="color: green;">&#41;</span></pre>
</div></p>

<p>Or replace <code>`zip`</code> with <code>&amp;&amp;&amp;</code>.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Dan Piponi</title>
		<link>http://conal.net/blog/posts/more-beautiful-fold-zipping#comment-195</link>
		<dc:creator><![CDATA[Dan Piponi]]></dc:creator>
		<pubDate>Mon, 23 Feb 2009 18:17:56 +0000</pubDate>
		<guid isPermaLink="false">http://conal.net/blog/?p=59#comment-195</guid>
		<description><![CDATA[&lt;p&gt;This zip for folds is a product in the category of certain F-algebras. More generally we can write:&lt;/p&gt;

&lt;pre&gt;
import Control.Morphism.Cata

prod :: Functor f =&gt; Algebra f a -&gt; Algebra f b -&gt; Algebra f (a,b)
prod u v x = (u $ fmap fst x,v $ fmap snd x)
&lt;/pre&gt;

&lt;p&gt;which generalises this to all catamorphisms.&lt;/p&gt;
]]></description>
		<content:encoded><![CDATA[<p>This zip for folds is a product in the category of certain F-algebras. More generally we can write:</p>

<pre>
import Control.Morphism.Cata

prod :: Functor f =&gt; Algebra f a -&gt; Algebra f b -&gt; Algebra f (a,b)
prod u v x = (u $ fmap fst x,v $ fmap snd x)
</pre>

<p>which generalises this to all catamorphisms.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Conal Elliott &#187; Blog Archive &#187; Proofs for left fold zipping</title>
		<link>http://conal.net/blog/posts/more-beautiful-fold-zipping#comment-194</link>
		<dc:creator><![CDATA[Conal Elliott &#187; Blog Archive &#187; Proofs for left fold zipping]]></dc:creator>
		<pubDate>Sun, 15 Feb 2009 02:22:18 +0000</pubDate>
		<guid isPermaLink="false">http://conal.net/blog/?p=59#comment-194</guid>
		<description><![CDATA[&lt;p&gt;[...]      &#171; More beautiful fold zipping Enhancing a Zip [...]&lt;/p&gt;
]]></description>
		<content:encoded><![CDATA[<p>[&#8230;]      &laquo; More beautiful fold zipping Enhancing a Zip [&#8230;]</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Conal Elliott &#187; Blog Archive &#187; Enhancing a Zip</title>
		<link>http://conal.net/blog/posts/more-beautiful-fold-zipping#comment-193</link>
		<dc:creator><![CDATA[Conal Elliott &#187; Blog Archive &#187; Enhancing a Zip]]></dc:creator>
		<pubDate>Sun, 16 Nov 2008 01:10:36 +0000</pubDate>
		<guid isPermaLink="false">http://conal.net/blog/?p=59#comment-193</guid>
		<description><![CDATA[&lt;p&gt;[...] a pattern that&#8217;s been steering me lately toward natural (inevitable) design of libraries. * Part Two simplified that representation to help get to the essence of zipping, and in doing so lost the [...]&lt;/p&gt;
]]></description>
		<content:encoded><![CDATA[<p>[&#8230;] a pattern that&#8217;s been steering me lately toward natural (inevitable) design of libraries. * Part Two simplified that representation to help get to the essence of zipping, and in doing so lost the [&#8230;]</p>
]]></content:encoded>
	</item>
</channel>
</rss>
