<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	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/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Tapdancing Goats &#187; fix</title>
	<atom:link href="http://www.tapdancinggoats.com/tag/fix/feed" rel="self" type="application/rss+xml" />
	<link>http://www.tapdancinggoats.com</link>
	<description>A parfait of physics, Linux, LaTeX, and coding tips large and small.</description>
	<lastBuildDate>Wed, 25 Jan 2012 03:14:39 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0</generator>
		<item>
		<title>Better billboarding in Papervision3D</title>
		<link>http://www.tapdancinggoats.com/better-billboarding-in-papervision3d.htm</link>
		<comments>http://www.tapdancinggoats.com/better-billboarding-in-papervision3d.htm#comments</comments>
		<pubDate>Thu, 08 Nov 2007 02:42:30 +0000</pubDate>
		<dc:creator>Alex</dc:creator>
				<category><![CDATA[Flash]]></category>
		<category><![CDATA[3d]]></category>
		<category><![CDATA[billboard]]></category>
		<category><![CDATA[code]]></category>
		<category><![CDATA[example]]></category>
		<category><![CDATA[fix]]></category>
		<category><![CDATA[graphics]]></category>
		<category><![CDATA[Papervision3D]]></category>

		<guid isPermaLink="false">http://www.tapdancinggoats.com/better-billboarding-in-papervision3d.htm</guid>
		<description><![CDATA[The Papervision3D wiki has an example for making billboarded sprites with just three extra lines of code. Trouble is, it doesn&#8217;t really work. Anyone who&#8217;s tried it may have noticed that when the planes get too close to the camera, or if the camera rotates around it&#8217;s z-axis at all, the planes start rolling instead [...]]]></description>
			<content:encoded><![CDATA[<p>The <a href="http://wiki.papervision3d.org/">Papervision3D wiki</a> has an example for making billboarded sprites with just three extra lines of code. Trouble is, it doesn&#8217;t really work. Anyone who&#8217;s tried it may have noticed that when the planes get too close to the camera, or if the camera rotates around it&#8217;s z-axis at all, the planes start rolling instead of staying vertical.</p>

<p>The problem is that the lookAt method defaults to using the world y-axis as &#8220;up&#8221; for the billboards, which isn&#8217;t usually correct.  Of course we don&#8217;t really care about the world y-axis with billboards.  We just want them to be vertical in the camera.  Here&#8217;s some code that does it.</p>

<div class="dean_ch" style="white-space: wrap;"><span class="co1">// calculate the camera vertical in world coordinates</span><br />
<span class="kw2">var</span> <span class="kw3">up</span> : Number3D = <span class="kw2">new</span> Number3D<span class="br0">&#40;</span><span class="nu0">0</span>, <span class="nu0">1</span>, <span class="nu0">0</span><span class="br0">&#41;</span>;<br />
Matrix3D.<span class="me1">rotateAxis</span><span class="br0">&#40;</span><span class="kw3">camera</span>.<span class="me1">transform</span>, <span class="kw3">up</span><span class="br0">&#41;</span>;<br />
<br />
<span class="co1">// billboard is the plane you want to billboard.</span><br />
billboard.<span class="me1">lookAt</span><span class="br0">&#40;</span>viewpoint, <span class="kw3">up</span><span class="br0">&#41;</span>;<br />
billboard.<span class="me1">roll</span><span class="br0">&#40;</span><span class="nu0">180</span><span class="br0">&#41;</span>;<br />
billboard.<span class="me1">pitch</span><span class="br0">&#40;</span><span class="nu0">180</span><span class="br0">&#41;</span>;</div>
]]></content:encoded>
			<wfw:commentRss>http://www.tapdancinggoats.com/better-billboarding-in-papervision3d.htm/feed</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Easy Scientific Notation In LaTeX</title>
		<link>http://www.tapdancinggoats.com/easy-scientific-notation-in-latex.htm</link>
		<comments>http://www.tapdancinggoats.com/easy-scientific-notation-in-latex.htm#comments</comments>
		<pubDate>Fri, 02 Mar 2007 21:46:30 +0000</pubDate>
		<dc:creator>Alex</dc:creator>
				<category><![CDATA[LaTeX]]></category>
		<category><![CDATA[Math]]></category>
		<category><![CDATA[Physics]]></category>
		<category><![CDATA[code]]></category>
		<category><![CDATA[example]]></category>
		<category><![CDATA[fix]]></category>
		<category><![CDATA[scientific notation]]></category>
		<category><![CDATA[thesis]]></category>

		<guid isPermaLink="false">http://www.tapdancinggoats.com/easy-scientific-notation-in-latex.htm</guid>
		<description><![CDATA[I use LaTeX for all my physics homework and lab reports, and I&#8217;ll be using it for a master&#8217;s thesis in the next few years, so I&#8217;m constantly adding to my library of LaTeX commands to save some typing. Here&#8217;s a good one when you need to use scientific or engineering notation. Put the following [...]]]></description>
			<content:encoded><![CDATA[<p>I use LaTeX for all my physics homework and lab reports, and I&#8217;ll be using it for a master&#8217;s thesis in the next few years, so I&#8217;m constantly adding to my library of LaTeX commands to save some typing.  Here&#8217;s a good one when you need to use scientific or engineering notation.  Put the following in the document preamble (before <tt>\begin{document}</tt>):</p>

<div class="dean_ch" style="white-space: wrap;"><br />
<span class="re2">\providecommand</span>{<span class="re3"><span class="re2">\e</span>}[<span class="re4">1</span>]{<span class="re2">\ensuremath</span>{<span class="re2">\times</span> 10^{#1}}</span>}<br />
&nbsp;</div>

<p>Then, typing</p>

<div class="dean_ch" style="white-space: wrap;"><br />
The [<span class="re4">111</span>] crystal planes are 3.2<span class="re2">\e</span>{<span class="re3">-10</span>} m apart.<br />
&nbsp;</div>

<p>gives you:
<samp>
The [111] crystal planes are 3.2&#215;10<sup>-10</sup> m apart.
</samp>
whether or not you&#8217;re already in a math environment.  If the exponent is just one number, you can omit the braces, like this: <tt>3\e8 m/s</tt>.  Cool, huh?</p>

<p>(Of course, for 10<sup>-10</sup> m you can just use Angstroms, <tt>\AA</tt>.  If you&#8217;re in a math environment, use <tt>\text{\AA}</tt>, or else the circle won&#8217;t line up with the A.  That is, if you&#8217;re okay with non-SI units.)</p>
]]></content:encoded>
			<wfw:commentRss>http://www.tapdancinggoats.com/easy-scientific-notation-in-latex.htm/feed</wfw:commentRss>
		<slash:comments>11</slash:comments>
		</item>
		<item>
		<title>Bold vectors in LaTeX</title>
		<link>http://www.tapdancinggoats.com/bold-vectors-in-latex.htm</link>
		<comments>http://www.tapdancinggoats.com/bold-vectors-in-latex.htm#comments</comments>
		<pubDate>Tue, 13 Feb 2007 02:26:53 +0000</pubDate>
		<dc:creator>Alex</dc:creator>
				<category><![CDATA[LaTeX]]></category>
		<category><![CDATA[Math]]></category>
		<category><![CDATA[Physics]]></category>
		<category><![CDATA[code]]></category>
		<category><![CDATA[example]]></category>
		<category><![CDATA[fix]]></category>
		<category><![CDATA[thesis]]></category>
		<category><![CDATA[vector]]></category>

		<guid isPermaLink="false">http://tapdancinggoats.com/?p=12</guid>
		<description><![CDATA[Vectors can be typeset in LaTeX with the command \vec, which decorates the argument with a little arrow. This was cute at first, but it doesn&#8217;t look very good, especially in fractions. Textbooks use bold face for vectors, so here&#8217;s how to do that in LaTeX. \let\oldhat\hat \renewcommand{\vec}[1]{\mathbf{#1}} \renewcommand{\hat}[1]{\oldhat{\mathbf{#1}}} This also makes unit vectors (typeset [...]]]></description>
			<content:encoded><![CDATA[<p>
Vectors can be typeset in LaTeX with the command <tt>\vec</tt>, which decorates the argument with a little arrow.  This was cute at first, but it doesn&#8217;t look very good, especially in fractions.  Textbooks use bold face for vectors, so here&#8217;s how to do that in LaTeX.
</p>

<div class="dean_ch" style="white-space: wrap;"><span class="re2">\let</span><span class="re2">\oldhat</span><span class="re2">\hat</span><br />
<span class="re2">\renewcommand</span>{<span class="re3"><span class="re2">\vec</span>}[<span class="re4">1</span>]{<span class="re2">\mathbf</span>{#1}</span>}<br />
<span class="re2">\renewcommand</span>{<span class="re3"><span class="re2">\hat</span>}[<span class="re4">1</span>]{<span class="re2">\oldhat</span>{<span class="re2">\mathbf</span>{#1}}</span>}</div>

<p>
This also makes unit vectors (typeset with <tt>\hat</tt>) bold.
</p>
]]></content:encoded>
			<wfw:commentRss>http://www.tapdancinggoats.com/bold-vectors-in-latex.htm/feed</wfw:commentRss>
		<slash:comments>11</slash:comments>
		</item>
		<item>
		<title>wxCL, SBCL, and Windows</title>
		<link>http://www.tapdancinggoats.com/wxcl-sbcl-and-windows.htm</link>
		<comments>http://www.tapdancinggoats.com/wxcl-sbcl-and-windows.htm#comments</comments>
		<pubDate>Fri, 26 Jan 2007 03:46:09 +0000</pubDate>
		<dc:creator>Alex</dc:creator>
				<category><![CDATA[Lisp]]></category>
		<category><![CDATA[Windows]]></category>
		<category><![CDATA[asdf]]></category>
		<category><![CDATA[fix]]></category>
		<category><![CDATA[SBCL]]></category>
		<category><![CDATA[wxCL]]></category>

		<guid isPermaLink="false">http://tapdancinggoats.com/?p=10</guid>
		<description><![CDATA[wxCL is a GUI package for Common Lisp that uses wxWidgets, and it seems to look pretty good on Windows and Linux, and the code is sufficiently lispy. Exactly what I&#8217;m looking for, except it&#8217;s in alpha. Serious, seeping wound alpha. I haven&#8217;t gotten it working on Linux yet, but it works on Windows. The [...]]]></description>
			<content:encoded><![CDATA[<p>wxCL is a GUI package for Common Lisp that uses wxWidgets, and it seems to look pretty good on Windows and Linux, and the code is sufficiently lispy.  Exactly what I&#8217;m looking for, except it&#8217;s in alpha.  Serious, seeping wound alpha.
I haven&#8217;t gotten it working on Linux yet, but it works on Windows.  The asdf-install included in SBCL 1.0 for Windows doesn&#8217;t work, and asdf doesn&#8217;t work with Windows links, so here is what I ended up doing.  First, I unpacked the wxcl archive to ~/.scbl/site.  This is where asdf-install would put it.  Then I copied the function sysdef-source-dir-search from the current asdf-install release to installer.lisp in SBCL&#8217;s version.  Finally, I add that function to asdf:<em>system-definition-search-functions</em> so ASDF can find stuff in .sbcl/site.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.tapdancinggoats.com/wxcl-sbcl-and-windows.htm/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>KPAX, SLIME, and SBCL</title>
		<link>http://www.tapdancinggoats.com/kpax-slime-and-sbcl.htm</link>
		<comments>http://www.tapdancinggoats.com/kpax-slime-and-sbcl.htm#comments</comments>
		<pubDate>Sun, 24 Sep 2006 03:56:19 +0000</pubDate>
		<dc:creator>Alex</dc:creator>
				<category><![CDATA[Emacs]]></category>
		<category><![CDATA[Lisp]]></category>
		<category><![CDATA[Web development]]></category>
		<category><![CDATA[fix]]></category>
		<category><![CDATA[KPAX]]></category>
		<category><![CDATA[SBCL]]></category>
		<category><![CDATA[SLIME]]></category>

		<guid isPermaLink="false">http://tapdancinggoats.com/?p=5</guid>
		<description><![CDATA[I&#8217;ve been struggling on and off to get KPAX to work for the past few days. It turns out that the default method SLIME uses to communicate with the Lisp interpreter causes problems with the way s-sysdeps sets up the socket listening function in SBCL. The workaround is to set swank:communication-style to :fd-handler, but it [...]]]></description>
			<content:encoded><![CDATA[<p>I&#8217;ve been struggling on and off to get KPAX to work for the past few days.  It turns out that the default method SLIME uses to communicate with the Lisp interpreter causes problems with the way s-sysdeps sets up the socket listening function in SBCL.  The workaround is to set swank:<em>communication-style</em> to :fd-handler, but it has to be set before SLIME starts, so put the following form in ~/.swank.lisp</p>

<p><code>(defparameter swank:<em>communication-style</em> :fd-handler)</code></p>

<p>Now to get KPAX to work with mod_lisp&#8230;</p>
]]></content:encoded>
			<wfw:commentRss>http://www.tapdancinggoats.com/kpax-slime-and-sbcl.htm/feed</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
	</channel>
</rss>

