<?xml version='1.0' encoding='UTF-8'?><?xml-stylesheet href="http://www.blogger.com/styles/atom.css" type="text/css"?><feed xmlns='http://www.w3.org/2005/Atom' xmlns:openSearch='http://a9.com/-/spec/opensearchrss/1.0/' xmlns:georss='http://www.georss.org/georss' xmlns:gd='http://schemas.google.com/g/2005' xmlns:thr='http://purl.org/syndication/thread/1.0'><id>tag:blogger.com,1999:blog-38087982</id><updated>2011-07-29T06:33:37.995Z</updated><category term='cooking'/><category term='Software'/><category term='Self defense'/><category term='Math'/><category term='J'/><category term='recipes'/><category term='Video'/><category term='Martial Arts'/><category term='Aikido'/><category term='Programming'/><category term='database'/><title type='text'>Ed Keith</title><subtitle type='html'>Software Development, cooking, Aikido and other unrelated subjects.</subtitle><link rel='http://schemas.google.com/g/2005#feed' type='application/atom+xml' href='http://edkeith.blogspot.com/feeds/posts/default'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/38087982/posts/default?max-results=100'/><link rel='alternate' type='text/html' href='http://edkeith.blogspot.com/'/><link rel='hub' href='http://pubsubhubbub.appspot.com/'/><author><name>Ed</name><uri>http://www.blogger.com/profile/13325146756422019012</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><generator version='7.00' uri='http://www.blogger.com'>Blogger</generator><openSearch:totalResults>20</openSearch:totalResults><openSearch:startIndex>1</openSearch:startIndex><openSearch:itemsPerPage>100</openSearch:itemsPerPage><entry><id>tag:blogger.com,1999:blog-38087982.post-8218610432556639129</id><published>2010-07-28T15:13:00.003Z</published><updated>2010-07-28T15:17:11.829Z</updated><category scheme='http://www.blogger.com/atom/ns#' term='Martial Arts'/><category scheme='http://www.blogger.com/atom/ns#' term='Self defense'/><category scheme='http://www.blogger.com/atom/ns#' term='Aikido'/><title type='text'>Focus in the martial Arts</title><content type='html'>&lt;p&gt;Everyone agrees that "Focus" is very important in martial Arts training. But what is "Focus"? Most source say something like "You must learn to focus all your attention on your opponent to the exclusion of all distractions" This makes a lot of sense in a sporting ring, where you face a single opponent, one on one, in a controlled environment. But I do not think is is good advice in a
more "real world" situation, where the environment is anything but controlled and while many of the "distractions" can be safely ignored, others cannot. You should not allow the dog barking, the child running around, or the flash from the camera to distract you, but the man with the pipe in his hand approaching from your left flack should not be ignored. All the incoming sensory
information must be processed so the decision can be made as to what to can be safely disregarded and what needs immediate attention.&lt;/p&gt;

&lt;p&gt;Aikido rondori practice is good for this. I remember a class once where the instructor occasionally told one of the observers to join  the rondori already in progress, This was a real challenge, I thought I was dealing with four attackers and suddenly without warning a fifth attacker came out of nowhere. If I had been less focused on the attackers I knew about I might not have been taken by surprise by the changed situation.&lt;/p&gt;

&lt;p&gt;I regularly practice "push hands". I believe it to be a very effective, safe, form of simulated combat training. The group I practice with is very informal and low key. We generally keep up a constant light banter for the entire practice session.  I'm sure a "serious martial artist" would be appalled that we are making wise cracks when we should be focused on our practice, but I
disagree. I consider the wise cracking to be part of my training. If the banter distracts me from the practice, my partner/opponent will push me, giving me feed back. My goal is to be able to maintain good root, structure, awareness, flow, etc.  while at the same time keeping up the banter.  This trains me to deal with distractions without being distracted by them.&lt;/p&gt;

&lt;p&gt;Just as in meditation you do not block all thoughts from the mind, but rather let them flow without allowing yourself to be distracted by them, I am training not to block all "distractions" from my mind during practice, but to process them with out being distracted by them.&lt;/p&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/38087982-8218610432556639129?l=edkeith.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://edkeith.blogspot.com/feeds/8218610432556639129/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=38087982&amp;postID=8218610432556639129' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/38087982/posts/default/8218610432556639129'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/38087982/posts/default/8218610432556639129'/><link rel='alternate' type='text/html' href='http://edkeith.blogspot.com/2010/07/focus-in-martial-arts.html' title='Focus in the martial Arts'/><author><name>Ed</name><uri>http://www.blogger.com/profile/13325146756422019012</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-38087982.post-6640039418338793742</id><published>2010-05-17T15:02:00.004Z</published><updated>2010-05-17T16:44:18.432Z</updated><category scheme='http://www.blogger.com/atom/ns#' term='Video'/><category scheme='http://www.blogger.com/atom/ns#' term='Software'/><title type='text'>Video Editing</title><content type='html'>&lt;p&gt;Recently I have been doing a lot of video editing at the local Community Cable
Access. They have a bunch of computers, some high end Windows Boxes, others
High end Macs. Frequently one or more of these machines are tied up doing
rendering while other people would like to be using them, and people using
other machines are contemplating what to do next, utilizing very little of the
available power of the machine they are monopolizing. Every year or two they
need to spend their scares funds to buy updates to the expensive video editing
software and faster hardware required to run the new software. There should be
a better way!&lt;/p&gt;

&lt;p&gt;There are a few constraints that imposed this situation on them. Most of the
users already know how to use either Windows of Mac OS X. They need to learn
a very complex piece of software, but they do not want to have to learn a new
OS at the same time. The people running the operation are technically savvy,
but they are not computer geeks. Given these constraints I
do not think any of the existing free video editing software are better able to
fill their needs than what they have (Final Cup Pro and Adobe Premiere Pro)&lt;/p&gt;

&lt;p&gt;In the ideal world, I think what they really need is a video editing system that
would allow the user to sit in front of an inexpensive computer that they are
familiar with while all the work is done on a central server that can give 
each task the computing resources it requires and make resources that task is not using
available to another tasks and allow big rendering jobs to be batch scheduled to
run at low usage periods.&lt;/p&gt;

&lt;p&gt;What is needed is a free video editing system that uses a client server
model. Thin client front ends can run on Windows or Macs and connect to a
server running on a cluster of *NIX systems. The client system would need to be
able to handle streaming video, but it would not need to be top of the line
powerhouse machines. The server would not require expensive video systems.&lt;/p&gt;

&lt;p&gt;The server software should run on either Linux or some flavor of BSD I would
probably favor a Beowulf cluster running &lt;a href='http://www.dragonflybsd.org/'&gt;DragonFly BSD&lt;/a&gt;, but I'm open to other suggestions. It would not
need to be portable since it would probably be running on dedicated hardware. It
should probably be written in C++ or &lt;a href='http://software.intel.com/en-us/articles/intel-cilk/'&gt;Cilk++&lt;/a&gt;
, using &lt;a href='http://en.wikipedia.org/wiki/Message_Passing_Interface'&gt;MPI&lt;/a&gt;. It might be
a good idea to use &lt;a href'http://gstreamer.freedesktop.org/'&gt;Gstreamer&lt;/a&gt;. It would be a
good idea to make it a minimalist core that supports plug-ins it should be
possible to let the plug-ins be written in Python. It should also support the 
ability to execute batch scripts,
most likely also in Python. I selected Python because it seems to already be
well established in the entertainment industry, I'm open to other suggestions.&lt;/p&gt;

&lt;p&gt;The clients should be native applications on the chosen platform, although it
might not be a bad idea to also have a Java client for people who want to use
platforms without a native client. Third party client development should
probably be encouraged.&lt;/p&gt;

&lt;p&gt;This is too big a project for me to attempt on my own, but if there are others
interested in working with me on it I think it would be worth working on.&lt;/p&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/38087982-6640039418338793742?l=edkeith.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://edkeith.blogspot.com/feeds/6640039418338793742/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=38087982&amp;postID=6640039418338793742' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/38087982/posts/default/6640039418338793742'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/38087982/posts/default/6640039418338793742'/><link rel='alternate' type='text/html' href='http://edkeith.blogspot.com/2010/05/video-editing.html' title='Video Editing'/><author><name>Ed</name><uri>http://www.blogger.com/profile/13325146756422019012</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-38087982.post-5861715294342076921</id><published>2010-04-20T17:50:00.003Z</published><updated>2010-04-20T17:59:02.593Z</updated><category scheme='http://www.blogger.com/atom/ns#' term='Programming'/><category scheme='http://www.blogger.com/atom/ns#' term='Math'/><category scheme='http://www.blogger.com/atom/ns#' term='J'/><title type='text'>Using J : Part I - A Super Calculator</title><content type='html'>&lt;p&gt;J is a VERY complex language, which takes a lot of effort to master, but
doing simple things with it is easy. In this post I will demonstrate how it
can be used as an advanced calculator.&lt;/p&gt;

&lt;p&gt;If you type '2+2' into J you will get the expected result of '4'.&lt;/p&gt;

&lt;p&gt;Similarly '3-2'' will give the expended '1', '2*3' yields the expected '6'.&lt;/p&gt;

&lt;p&gt;J does not use '/' for division, instead it uses '%'. This is
the first of many idiosyncrasies. So '6%2' yields '3'.&lt;/p&gt;

&lt;p&gt;The next idiosyncrasy in J is the order that operators are evaluated in.
As long as you only perform one operation per line there is no question about
order, but is you put multiple operations together in a single line than the
order of evaluation can be important. What is '5-3-2'? Is it 4 or is it 0?
In J it is 4, because J works from right to left when evaluating. This means
that '5*2+3' is 25, not 13 as you might expect. If you want any evaluation
order other than strict right to left you must use parenthesis. '(5-3)-2' is 0
and '(5*2)+3' is 13.&lt;/p&gt;

&lt;p&gt;To see the next idiosyncrasy, enter '2-3'. Instead of the expected '-1', you
get '_1'. The reason for this is that unlike most languages, J does not use
the same notation to indicate the unary operator (called a 'monadic verb' in
J) additive inverse and a negative number. In J '-1' is a verb ('-') followed by
a noun ('1') the result of this computation is '_1', which is just a noun.&lt;/p&gt;

&lt;p&gt;Which brings me to the subject of the representation of numbers.&lt;/p&gt;

&lt;p&gt;The simplest way to represent a floating point number is with a
decimal point like this '34.87', with the one caveat that a number can not
start with a '.', so you must include the leading 0 if the number is between 1
and _1. Another common way to represent is in exponential form. In J
exponential form is written as two numbers separated with an 'e' no spaces
allowed. The second number must be an integer. The result is the first number
multiplied by 10 raised to the power of the second number. So '1.234e3' is the
same as 1234.&lt;/p&gt;

&lt;p&gt;Many programming languages let you express integers in bases
other than ten, must often only bases 2, 8 &amp;amp; 16. J lets you express floating
point numbers in any base (however I have not figured out how to express
digits representing values greater than z which represents 35). To express a
number in a base other than 10 first give the base then 'b' then the number
represented in that base. It is interesting to note that the base does not
need to be an integer. I have not yet though of any use for this feature, but
you may be able to.&lt;/p&gt;

&lt;p&gt;Two other unusual representations are supported by J. Exponential notation in
bases Pi and e, 1p1 is Pi, 2p1 is 2*Pi, 1p2 is Pi squared, 2p2 is twice Pi
Squared, etc. Similarly 1x1 is e (the base of natural logarithms, 2.71828 . .
.) , 2x1 is 2e, 1x2 is e squared, etc.&lt;/p&gt;

&lt;p&gt;Two other important numbers you might find useful are '_' and '__' which are
the values the limit of 1 % x as x approaches 0 and the value of the limit of
_1%x as x approaches 0. It is interesting to note that J believes that '0%0' is
'0'.&lt;/p&gt;

&lt;p&gt;Sometime you want more precision that you can get with floating point. If I
enter the integer 1 J will assume I mean a floating point number very
close to the integer 1. If I want the integer 1 I type '1x' for 1 exact. Now type
'1x % 2' and see the results. '1r2' is a rational number with a numerator of 1
and a denominator of 2. 2r3 is two thirds.&lt;/p&gt;

&lt;p&gt;J also supports complex numbers which are represented by the real and imaginary
parts separated by a lowercase j. For example 2 + 4i is written as '2j4'.&lt;/p&gt;

&lt;p&gt;You can give something an alias. For example, if you would rather use 'Pi'
than '1p1' you could type 'Pi =: 1p1' and then any time you type 'Pi" it will
be the same as if you had typed '1p1'. Any thing can be given an alias. If you
type 'Plus =: +' then you can type '2 Plus 2' to get 4.&lt;/p&gt;

&lt;p&gt;As you have seen '-' can be used as either a binary operator (called a 'dyadic
verb' in J) is in '3-2' or as a unary operator (called a 'monadic verb' in J)
as in '-2'. This is fairly common, But in J nearly all verbs have both a
monodic and dyadic form.&lt;/p&gt;

&lt;p&gt;The verb '%' has the dyadic form 'divide' and the monadic form 'reciprocal'
so '%2' yields '0.5' and '%2x' yields '1r2'.&lt;/p&gt;

&lt;p&gt;The verb '*' has the dyadic form 'times' and the monadic for 'signum' which
returns '1' if the argument is positive, '_1' if it is negative and '0' if it
is '0'.&lt;/p&gt;

&lt;p&gt;The verb '+' has the dyadic form 'plus' and the monadic form 'conjugate'.
Conjugating leave it unchanged, But when you conjugate a complex number it
changes the sign of the imaginary component.&lt;/p&gt;

&lt;p&gt;The square root operator (monadic verb) is '%:'. The dyadic form of %: is
'Root'. '3 %: 8' yields the third root of 8, or 2. One thing that does confuse
me is how it choses which branch of the root to take. '3 %: _8' yields '1j1.73205'
not '_2' as I would expect.&lt;/p&gt;

&lt;p&gt;The power operator is '^'. In its dyadic form it raised its first operand to
the power of its second operand. So '2^3' yields 8. In it monadic form it is
called 'Exponential' and it raises Euler's number (the base of natural
logarithms, e) to the given power.&lt;/p&gt;

&lt;p&gt;The log operator is '^.' The Monadic form yield the natural log. The dyadic
form yields the log given the bases. To get the common log of 100 us '10 ^.
100'. You can define a monadic verb to take the common log 'log =: 10&amp;amp;^.'.
The '&amp;amp;' binds the left operand of 10 to the operator '^.'.&lt;/p&gt;

&lt;p&gt;The residue operator is '|'. Residue is like mod, except that the order of
the operand is reversed. If want the traditional mod operator it is easy to
define 'mod =: |~'. Now you can use 'mod' like an any built in operator,
'187 mod 10' yields '7', just as you would expect. The adverb '~' commutes
the operands to the verb it modifies. The dyadic form of '|' is the magnitude,
or the distance from zero, '|2' yields 2, as does '|_2', '|3j4' yields 5.&lt;/p&gt;

&lt;p&gt;The factorial operator is '!', its dyadic form is called 'out of' or
'combinations',  'x!y' is '(!y)%(!x)*(!y-x)'.&lt;/p&gt;

&lt;p&gt;Any good calculator needs to provide trigonometric functions. J does this in an
unusual manner. The operator 'o.' is used. In it monadic form it simply
multiplies a value by Pi. The dyadic form provides the trigonometric
functions: '1o.' is the sine function; '_1o.' is the arcsine function; '2o.'
and '_2o.' are cos and arccos respectively; '3o.' &amp;amp; '_3o.' are tan
&amp;amp; arctan. The hyperbolic function are similar using 5, 6 &amp;amp; 7 for sinh, cosh
and tanh. You may want to define the monadic following verbs:
&lt;ul&gt;&lt;li&gt;   sin=:1&amp;amp;o.&lt;/li&gt;&lt;li&gt;   asin=:_1&amp;amp;o.&lt;/li&gt;&lt;li&gt;   cos=:2&amp;amp;o.&lt;/li&gt;&lt;li&gt;   acos=:_2&amp;amp;o.&lt;/li&gt;&lt;li&gt;   tan=:3&amp;amp;o.&lt;/li&gt;&lt;li&gt;   atan=:_3&amp;amp;o.&lt;/li&gt;&lt;li&gt;   sinh=:5&amp;amp;o.&lt;/li&gt;&lt;li&gt;   asinh=:_5&amp;amp;o.&lt;/li&gt;&lt;li&gt;   cosh=:6&amp;amp;o.&lt;/li&gt;&lt;li&gt;   acosh=:_6&amp;amp;o.&lt;/li&gt;&lt;li&gt;   tanh=:7&amp;amp;o.&lt;/li&gt;&lt;li&gt;   atanh=:_7&amp;amp;o.&lt;/li&gt;&lt;/ul&gt;the '&amp;amp;' operator binds an operand to an operator. I hope to discuss it in
detail in a future post. Of course this assumes the angle is measured in
radians. If you have it in degrees you need to multiply it by (1p1%180).&lt;/p&gt;

&lt;p&gt;This gives you a good start, but it has not really scratched the suffice of
the true power of J. Arrays are the heart of J, I hope to write about them
soon. If you really want to get the full power out of J you will need to grok
tacit programming, but you can go far without it.&lt;/p&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/38087982-5861715294342076921?l=edkeith.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='related' href='http://www.jsoftware.com/' title='Using J : Part I - A Super Calculator'/><link rel='replies' type='application/atom+xml' href='http://edkeith.blogspot.com/feeds/5861715294342076921/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=38087982&amp;postID=5861715294342076921' title='2 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/38087982/posts/default/5861715294342076921'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/38087982/posts/default/5861715294342076921'/><link rel='alternate' type='text/html' href='http://edkeith.blogspot.com/2010/04/using-j-part-i-super-calculator.html' title='Using J : Part I - A Super Calculator'/><author><name>Ed</name><uri>http://www.blogger.com/profile/13325146756422019012</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>2</thr:total></entry><entry><id>tag:blogger.com,1999:blog-38087982.post-8954010549398449077</id><published>2009-12-06T11:32:00.002Z</published><updated>2009-12-06T11:42:59.232Z</updated><category scheme='http://www.blogger.com/atom/ns#' term='Programming'/><title type='text'>New Software Documentation Tool</title><content type='html'>&lt;p&gt;
Yesterday I published the first beta release of a software documentation tool
I developed which I named &lt;em&gt;Code Extractor&lt;/em&gt;. It is inspired by &lt;a href="http://www.progdoc.org/"&gt;ProgDoc&lt;/a&gt; but is much simpler. ProgDoc is
designed to work with &lt;a href="http://www.latex-project.org/%27"&gt;LaTeX&lt;/a&gt; and performs source highlighting. This also means it needs to know the source language it is dealing with.
&lt;/p&gt;&lt;p&gt;
&lt;em&gt;Code Extractor&lt;/em&gt;, on the other hand, is designed to work with &lt;a href="http://www.methods.co.nz/asciidoc/"&gt;Asciidoc&lt;/a&gt; or &lt;a href="http://www.boost.org/doc/libs/1_41_0/doc/html/quickbook.html"&gt;Quickbook&lt;/a&gt;, both of which can do their own source code highlighting, so there is no need for &lt;em&gt;Code Extractor&lt;/em&gt; to do it.
&lt;/p&gt;&lt;p&gt;
When I registered the project at &lt;a href="http://developer.berlios.de/"&gt;BerliOS
&lt;/a&gt;&lt;a&gt; I made a typo and skipped the 'r', so the project is &lt;/a&gt;&lt;a href="http://developer.berlios.de/projects/codeextactor/"&gt;
http://developer.berlios.de/projects/codeextactor/&lt;/a&gt;. I hope you find it
useful.
&lt;/p&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/38087982-8954010549398449077?l=edkeith.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='related' href='http://developer.berlios.de/projects/codeextactor/' title='New Software Documentation Tool'/><link rel='replies' type='application/atom+xml' href='http://edkeith.blogspot.com/feeds/8954010549398449077/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=38087982&amp;postID=8954010549398449077' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/38087982/posts/default/8954010549398449077'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/38087982/posts/default/8954010549398449077'/><link rel='alternate' type='text/html' href='http://edkeith.blogspot.com/2009/12/new-software-documentation-tool.html' title='New Software Documentation Tool'/><author><name>Ed</name><uri>http://www.blogger.com/profile/13325146756422019012</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-38087982.post-5311342134024234209</id><published>2009-10-28T15:47:00.003Z</published><updated>2009-10-28T16:38:10.340Z</updated><category scheme='http://www.blogger.com/atom/ns#' term='Programming'/><title type='text'>An Interview Question</title><content type='html'>&lt;p&gt;At a recent job interview I was asked to write a program to solve the 
following problem:&lt;/p&gt;

&lt;blockquote&gt;
    You have a sorted array of integer values, you need to generated a sorted 
    array of the results of the results obtained when there values are 
    plugged into the quadratic equation ax^2 + bx + c.
&lt;/blockquote&gt;

&lt;p&gt;My first thought was that this was a problem best suited to the J programming 
language. Unfortunately I did not have my handy dandy J dictionary with me, 
and I do not have it memorized, so I had to wait until I got home to write:&lt;/p&gt;

&lt;code&gt;
      fa =: monad : '/:~(c,b,a)p.y'
&lt;/code&gt;

&lt;p&gt;A J expert would make this tacit, and therefor shorter, but I'm not that 
good yet.&lt;/p&gt;

&lt;p&gt;Using C++ with the Boost Lambda Library I would write:&lt;/p&gt;

&lt;code&gt;&lt;pre&gt;
std::Vector&lt;int&gt;&amp; fa(std::Vector&lt;int&gt;&amp; x)
{
    std::transform(x.begin(), x.end(), x.begin(), a*_1*_1 + b*_1 + c);
    std::sort(x.begin(),x.end());
    return x;
}
&lt;/pre&gt;&lt;/code&gt;

&lt;p&gt;This does all the work in place so it only consumes memory for one array.&lt;/p&gt;

&lt;p&gt;It can be made more efficient by taking advantage of the fact that the input 
array is sorted, so sorting the output array can be done in linear time, but 
that is left as an exercise for the reader.&lt;/p&gt;

&lt;p&gt;I should look into how to do it in Ocaml, Erlang and Oz. But I do not think 
any of them will be as succinct as J or as efficient as C++. If the 
polynomial were of higher order it might be worth pursuing an Erlang solution 
that distributed the evaluation of the polynomial across several machines.&lt;/p&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/38087982-5311342134024234209?l=edkeith.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://edkeith.blogspot.com/feeds/5311342134024234209/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=38087982&amp;postID=5311342134024234209' title='3 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/38087982/posts/default/5311342134024234209'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/38087982/posts/default/5311342134024234209'/><link rel='alternate' type='text/html' href='http://edkeith.blogspot.com/2009/10/interview-question.html' title='An Interview Question'/><author><name>Ed</name><uri>http://www.blogger.com/profile/13325146756422019012</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>3</thr:total></entry><entry><id>tag:blogger.com,1999:blog-38087982.post-8846055255991675552</id><published>2009-06-19T11:10:00.002Z</published><updated>2009-06-19T11:18:00.409Z</updated><category scheme='http://www.blogger.com/atom/ns#' term='cooking'/><category scheme='http://www.blogger.com/atom/ns#' term='recipes'/><title type='text'>Grilled Shrimp</title><content type='html'>&lt;p&gt;I'm visiting my father. We grilled shrimp last night.&lt;/p&gt;

&lt;p&gt;I roasted some Szechuan Peppercorns in a dry skillet until they were aromatic. Then I ground them and put them in some olive oil. I added lots of garlic (all my father had) and a fair amount of salt, some dried parsley (dad's parsley plants did not do well this year), and a few grinds of black pepper.&lt;/p&gt;

&lt;p&gt;We marinated the shrimp in the oil mixture for almost two hours, and grilled them. The were excellent.&lt;/p&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/38087982-8846055255991675552?l=edkeith.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://edkeith.blogspot.com/feeds/8846055255991675552/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=38087982&amp;postID=8846055255991675552' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/38087982/posts/default/8846055255991675552'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/38087982/posts/default/8846055255991675552'/><link rel='alternate' type='text/html' href='http://edkeith.blogspot.com/2009/06/grilled-shrimp.html' title='Grilled Shrimp'/><author><name>Ed</name><uri>http://www.blogger.com/profile/13325146756422019012</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-38087982.post-308472325698968208</id><published>2009-05-01T11:36:00.003Z</published><updated>2009-05-01T11:59:54.947Z</updated><category scheme='http://www.blogger.com/atom/ns#' term='Martial Arts'/><category scheme='http://www.blogger.com/atom/ns#' term='Aikido'/><title type='text'>The four jings and Aikido</title><content type='html'>&lt;p&gt;For many years I have been trying to figure out how the four principals &lt;i&gt;Jings&lt;/i&gt; of &lt;i&gt;Taiji&lt;/i&gt;, &lt;i&gt;Peng&lt;/i&gt;, &lt;i&gt;Lu&lt;/i&gt;, &lt;i&gt;Ji&lt;/i&gt; and &lt;i&gt;An&lt;/i&gt;. I first learned the terms &lt;i&gt;Peng&lt;/i&gt;, &lt;i&gt;Lu&lt;/i&gt;, &lt;i&gt;Ji&lt;/i&gt; &amp;amp; &lt;i&gt;An&lt;/i&gt; when I started practicing push hands. At that time I was told that I had very strong &lt;i&gt;Peng&lt;/i&gt;. As far as I could tell at the time &lt;i&gt;Peng&lt;/i&gt; was the same as unbendable arm. I think I now have a better understanding.&lt;/p&gt;

&lt;h2&gt;Peng&lt;/h2&gt;

&lt;p&gt;&lt;i&gt;Peng&lt;/i&gt; is commonly translated as "ward off", it is associated with the pre-heaven trigram &lt;i&gt;"Chien"&lt;/i&gt; translated as "Heaven" and the post-heaven trigram 
&lt;i&gt;"Kan"&lt;/i&gt; or "Water". I have started to to think of it as "Rise Up".&lt;/p&gt;

&lt;p&gt;&lt;i&gt;Peng&lt;/i&gt; is the first part of the opening if every &lt;i&gt;taiji&lt;/i&gt; form I am aware of. The arms rise while the hips sink and the spine lengthens. It is exemplified by yang energy rising from Earth to Heaven.&lt;/p&gt;

&lt;p&gt;The &lt;i&gt;Peng&lt;/i&gt; response to incoming energy is to bounce it off like a rubber ball.&lt;/p&gt;

&lt;p&gt;It is &lt;b&gt;NOT&lt;/b&gt; weight upper side, because the rising energy presses the lower body down.&lt;/p&gt;

&lt;p&gt;I believe &lt;i&gt;peng&lt;/i&gt; is the same as what voice trainer Arthur Lessac
(http://www.lessacinstitute.com/) calls 'Buoyancy" in his 1978 book "Body
Wisdom". He describes it as the feeling you get if you stand in a doorway and
press the back of both wrists against the door frame, then relax and step out
of the door frame and feel your arms rise of their own accord. He also
describes many exercises to get this feeling in a tub of water.&lt;/p&gt;

&lt;p&gt;It is used to hold an attack at bay. It is associated with the &lt;i&gt;wei chi&lt;/i&gt;, the
chi that protects the body from the external environment. Many sources say
all other &lt;i&gt;jings&lt;/i&gt; arise from &lt;i&gt;Peng&lt;/i&gt;.&lt;/p&gt;

&lt;p&gt;We use it in aikido for Immoveable Body. It is sometime used at the beginning
of a technique to encourage the attacker to over commit, it can also be used
to uproot an attacker, as when you come in under the arm and lift it in Ikkyo,
or is some variants of ryote-mochi kokyu-nage irimi ude-oroshi, where nage
gets under uke and lifts.&lt;/p&gt;

&lt;h2&gt;Lu&lt;/h2&gt;

&lt;p&gt;&lt;i&gt;Lu&lt;/i&gt; is commonly translated as "roll back", it is associated with the pre-heaven
trigram &lt;i&gt;"Kun"&lt;/i&gt; translated as "Earth" and the post-heaven trigram &lt;i&gt;"Li"&lt;/i&gt; or
"Fire". I have started thinking of it as "Draw in".&lt;/p&gt;

&lt;p&gt;&lt;i&gt;Lu&lt;/i&gt; is the third part of the taiji opening. The arms and hips both sink. It is
exemplified by yin energy being drawn into the center. It is cultivated by
Koichi Tohei's (http://www.koichitohei.com/) Contraction Meditation, in which
everything is drawn into the one point. In push hands it incorporates a twist
of the hips to allow the press (it is generally employed to counter &lt;i&gt;Ji&lt;/i&gt;) to
pass by harmlessly, sometimes it can be used to unbalance your partner
forward.&lt;/p&gt;

&lt;p&gt;I remember reading a science fiction story many years ago in which a hard
boiled detective kept running into aliens disguised as humans, each time he
shot one it responded by thanking him for the gift of metal (he ended up
killing them with a water pistol loaded with the booze from his desk as I
recall, but that is not relevant to this discussion). This strikes me as the
ultimate in &lt;i&gt;Lu&lt;/i&gt;.&lt;/p&gt;

&lt;p&gt;&lt;i&gt;Lu&lt;/i&gt; is very common in aikido. You see it when moving back in fune-kogi (the
rowing exercise), and in takubi-kosa (the wrist crossing exercise). It shows
up in most tenkan or ura techniques and techniques where you draw the attacker
into your center to establish control.&lt;/p&gt;

&lt;h2&gt;Ji&lt;/h2&gt;

&lt;p&gt;&lt;i&gt;Ji&lt;/i&gt; is commonly translated as "press", and is associated with the pre-heaven
trigram &lt;i&gt;"Kan"&lt;/i&gt; translated as "Water" and post-heaven &lt;i&gt;"Dui"&lt;/i&gt; or "Lake". It is
the opposite of Lu. I have started thinking of it as "reach out".&lt;/p&gt;

&lt;p&gt;&lt;i&gt;Ji&lt;/i&gt; is the second part of the taiji opening. The arms and hips both rise. It
is exemplified by yang energy radiating out from the center.&lt;/p&gt;

&lt;p&gt;&lt;i&gt;Ji&lt;/i&gt; is a squeezing, sticking energy the follows the opponents energy.&lt;/p&gt;

&lt;p&gt;Arthur Lessac calls it "Potency" or "Muscle Yawn". He teaches unbendable arm
as an example of "Potency", but I am beginning to suspect that unbendable arm
can be an expression of any of the &lt;i&gt;jings&lt;/i&gt;. He also taught something he called a
"Muscle Yawn Push up". My mother was a small, not particularly strong, woman,
but she could do a seemingly unlimited number of Muscle Yawn Push Ups without
tiring.&lt;/p&gt;

&lt;p&gt;&lt;i&gt;Ji&lt;/i&gt; is cultivated by Koichi Tohei's Expansion Meditation, in which the one
point expands to encompass everything.&lt;/p&gt;

&lt;p&gt;I think atemi is &lt;i&gt;Ji&lt;/i&gt;. The first two moves of both 21 count (or 22 count,
depending on how your style counts) jo kata, the tsuki, seem to me to be
expressions of Ji. But, I am drawing a blank trying to think of when it is
used in technique.&lt;/p&gt;

&lt;h2&gt;An&lt;/h2&gt;

&lt;p&gt;&lt;i&gt;An&lt;/i&gt; is commonly translated as "push", and is associated with the pre-heaven
trigram &lt;i&gt;"Li"&lt;/i&gt; translated as "fire" and post-heaven trigram &lt;i&gt;"Zhen"&gt;&lt;/i&gt; or "Thunder".
It is the opposite of &lt;i&gt;Peng&lt;/i&gt;. I have started thinking of it as "Press down".&lt;/p&gt;

&lt;p&gt;&lt;i&gt;An&lt;/i&gt; is the end of the taiji opening, the arms sink as the hips rise. It is
exemplified by yin energy sinking from heaven to earth.&lt;/p&gt;

&lt;p&gt;The downward force of &lt;i&gt;An&lt;/i&gt; comes from the legs pressing into the earth.&lt;/p&gt;

&lt;p&gt;Many people have said that &lt;i&gt;An&lt;/i&gt; is the hardest of the &lt;i&gt;jings&lt;/i&gt; to understand
because you rise up to press down. Some people have said it is like lifting
yourself out of a swimming pool, or maybe doing dips or chin ups (But Lessac
uses chin ups to teach "Potency", which I think is &lt;i&gt;Ji&lt;/i&gt;, so I could be way off).&lt;/p&gt;


&lt;h2&gt;Putting the pieces together&lt;/h2&gt;


&lt;p&gt;Looking at a single technique, and how the &lt;i&gt;jings&lt;/i&gt; are expresses, lets consider
kata-tori ikyo irimi.&lt;/p&gt;

&lt;p&gt;First, as the uke reaches in, nage steps back, drawing uke in (&lt;i&gt;Lu&lt;/i&gt;) to encourage
him to over extend.&lt;/p&gt;

&lt;p&gt;Second, nage brushes uke's hand down (&lt;i&gt;An&lt;/i&gt;) taking his balance.&lt;/p&gt;

&lt;p&gt;Third, nage brings uke's arm up pushing the elbow over uke's head (&lt;i&gt;Peng&lt;/i&gt;).&lt;/p&gt;

&lt;p&gt;Fourth, nage drops uke's arm in front of him, immobilising uke before taking
him to the mat (&lt;i&gt;An&lt;/i&gt; again? The side of the body toward uke seems to be doing
&lt;i&gt;An&lt;/i&gt;, but the other side is not, maybe its doing &lt;i&gt;Peng&lt;/i&gt;? Or maybe it's &lt;i&gt;Lieh&lt;/i&gt;? I'm
nowhere near ready to go there. I'm not going to try to sort out &lt;i&gt;Tsai&lt;/i&gt;, &lt;i&gt;Lieh&lt;/i&gt;,
&lt;i&gt;Jou&lt;/i&gt; &amp;amp; &lt;i&gt;Koo&lt;/i&gt; until I've got a firm grasp on &lt;i&gt;Peng&lt;/i&gt;, &lt;i&gt;Lu&lt;/i&gt;, &lt;i&gt;Ji&lt;/i&gt; &amp;amp; &lt;i&gt;An&lt;/i&gt;).&lt;/p&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/38087982-308472325698968208?l=edkeith.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://edkeith.blogspot.com/feeds/308472325698968208/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=38087982&amp;postID=308472325698968208' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/38087982/posts/default/308472325698968208'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/38087982/posts/default/308472325698968208'/><link rel='alternate' type='text/html' href='http://edkeith.blogspot.com/2009/05/four-jings-and-aikido.html' title='The four jings and Aikido'/><author><name>Ed</name><uri>http://www.blogger.com/profile/13325146756422019012</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-38087982.post-8010954547926722249</id><published>2009-04-13T14:20:00.003Z</published><updated>2009-04-13T14:36:58.986Z</updated><title type='text'>Neo-Marxist Fascist?</title><content type='html'>Conservative radio talk show host Michael Savage says Obama is a Neo-Marxist Fascist. What does he mean?

When I was growing up I learned that Fascists were the extrema right wing and Marxist were the extrema left wing and sane people stuck to the center. How can any one be both at the same time?

Is Michael Savage saying anything? Or is he simply stringing as many inflammatory phrases as he can together with no regard for their meaning?&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/38087982-8010954547926722249?l=edkeith.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://edkeith.blogspot.com/feeds/8010954547926722249/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=38087982&amp;postID=8010954547926722249' title='3 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/38087982/posts/default/8010954547926722249'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/38087982/posts/default/8010954547926722249'/><link rel='alternate' type='text/html' href='http://edkeith.blogspot.com/2009/04/neo-marxist-fascist.html' title='Neo-Marxist Fascist?'/><author><name>Ed</name><uri>http://www.blogger.com/profile/13325146756422019012</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>3</thr:total></entry><entry><id>tag:blogger.com,1999:blog-38087982.post-2946062812299094231</id><published>2009-03-04T14:55:00.002Z</published><updated>2009-10-28T16:43:11.674Z</updated><category scheme='http://www.blogger.com/atom/ns#' term='cooking'/><category scheme='http://www.blogger.com/atom/ns#' term='recipes'/><title type='text'>Mole Sauce</title><content type='html'>&lt;p&gt;Trader Joe's discontinued the Mole Sauce I've been using, and I have not
found any other pre made mole sauce that I like, so I need to make my own. 
In general I have found that Mole takes a long time to prepare, and requires
hard to find ingredients. I have come up with this simple version that is
acceptable.&lt;/p&gt;

&lt;h2&gt;Mole Sauce&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;1 large onion, chopped&lt;/li&gt;
&lt;li&gt;2 cloves Garlic, chopped&lt;/li&gt;
&lt;li&gt;3 Tbsp. Oil&lt;/li&gt;
&lt;li&gt;4 Tbsp. Sugar&lt;/li&gt;
&lt;li&gt;3 Tbsp Flour&lt;/li&gt;
&lt;li&gt;1 tsp. Salt&lt;/li&gt;
&lt;li&gt;2 tsp. Cinnamon&lt;/li&gt;
&lt;li&gt;4 tsp. Chili powder&lt;/li&gt;
&lt;li&gt;1 tsp. Ground cumin&lt;/li&gt;
&lt;li&gt;2 tsp oregano&lt;/li&gt;
&lt;li&gt;1 28 oz can tomatoes&lt;/li&gt;
&lt;li&gt;1 cup chicken broth&lt;/li&gt;
&lt;li&gt;3 oz. Unsweetened baking chocolate&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Blend flour, sugar, &amp;amp; spices.&lt;/p&gt;
&lt;p&gt;Saute onion &amp;amp; garlic in oil until translucent.&lt;p&gt;
&lt;p&gt;Add spice mixture to onion mixture and cook one minute&lt;/p&gt;
&lt;p&gt;Add Broth and tomatoes&lt;/p&gt;
&lt;p&gt;Bring to boil&lt;/p&gt;
&lt;p&gt;Add chocolate stir until chocolate melts.&lt;/p&gt;
&lt;p&gt;Simmer 5 minutes stirring frequently.&lt;/p&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/38087982-2946062812299094231?l=edkeith.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://edkeith.blogspot.com/feeds/2946062812299094231/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=38087982&amp;postID=2946062812299094231' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/38087982/posts/default/2946062812299094231'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/38087982/posts/default/2946062812299094231'/><link rel='alternate' type='text/html' href='http://edkeith.blogspot.com/2009/03/mole-sauce.html' title='Mole Sauce'/><author><name>Ed</name><uri>http://www.blogger.com/profile/13325146756422019012</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-38087982.post-3850262522039240863</id><published>2009-02-05T21:16:00.004Z</published><updated>2009-02-05T21:31:02.888Z</updated><category scheme='http://www.blogger.com/atom/ns#' term='Programming'/><title type='text'>Return to Assembler</title><content type='html'>&lt;p&gt;I got a copy of &lt;i&gt;The Art of Assembly Language&lt;/i&gt; from a local library and am working my way through it. I downloaded it from &lt;a href="http://webster.cs.ucr.edu/"&gt;Webster&lt;/a&gt; years ago and have been meaning to read it, but it is much more pleasant to read a hard copy.&lt;/p&gt;
&lt;p&gt;Assembly Language was my first programming language, but is has been two decades since I used it. I programmed 6800, 6502, 8080, Z-80 &amp;amp; 8086 CPUs in Assembly Language and read up on the 80386 instruction set, but never used it. Things have changed a bit. I never used the FPU before, it is a bit different; and the MMX instruction are not at all what I'm used to. But the basics are still the same.&lt;/p&gt;
&lt;p&gt;I have read lots of complaints about HLA. I understand the complaints. The whole point of writing in assembler is to exercise total control over the machine code, polymorphic functions and exception handling seem to fly in the face of this idea. However, I find to be a very good learning tool. It allows me focus my attention of what I'm trying to understand, not the gory details of I/O etc.&lt;/p&gt;
&lt;p&gt;The book assumes that you have an operating system, so it does not get into issues like resets and IPL. I wish it covered this because I'm very curious how IPL is handled on a multi core CPU.&lt;/p&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/38087982-3850262522039240863?l=edkeith.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://edkeith.blogspot.com/feeds/3850262522039240863/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=38087982&amp;postID=3850262522039240863' title='4 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/38087982/posts/default/3850262522039240863'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/38087982/posts/default/3850262522039240863'/><link rel='alternate' type='text/html' href='http://edkeith.blogspot.com/2009/02/return-to-assembler.html' title='Return to Assembler'/><author><name>Ed</name><uri>http://www.blogger.com/profile/13325146756422019012</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>4</thr:total></entry><entry><id>tag:blogger.com,1999:blog-38087982.post-2174814325030363997</id><published>2008-12-30T16:05:00.002Z</published><updated>2008-12-30T16:16:20.520Z</updated><category scheme='http://www.blogger.com/atom/ns#' term='Programming'/><title type='text'>The problem with OO programming languages</title><content type='html'>&lt;p&gt;In Object Oriented Programming we extend a class by specializing it with a
subclass. Going from the General to the specific. This seems to be the 
excepted way things should be. But it seems backward from the way things work 
in the real world.&lt;/p&gt;

&lt;p&gt;In the real world primitive man had the whole numbers. Eventually problems were
encountered that the whole numbers could not solve, so the integers were
introduces. Later integers were found to insufficient to solve some problems,
so rational numbers were developed. Eventually it was necessary to extend the
rational numbers with the real numbers. Much latter rational numbers were
extended to the complex numbers. Each extension required creating a super
class of the existing class, not a subclass. I am hard pressed to think of a
single field of endeavor where a breakthrough was made by specializing an
existing concept to make a subclass of an existing class, it always seems to
be the other way around.&lt;/p&gt; 

&lt;p&gt;The other problem is that the subclasses must carry all the baggage of the
super classes. Yet in the real world specialized subclasses are less complex
than the general super class, not more complex. Consider the classic shapes
example, we will consider the specializations of a quadrilateral.&lt;/p&gt; 

&lt;p&gt;To specify a quadrilateral, we must specify the lengths of all four sides and
two of the angles.&lt;/p&gt; 

&lt;p&gt;We derive a parallelogram from the quadrilateral. Now all we need to specify
are the lengths of two sides and one angle, only half as much information. But
in most OO languages (Ocaml being the only exception I can think of), we need 
to carry around all the data needed by the super class, a big waist, but it 
gets worse.&lt;/p&gt;

&lt;p&gt;If we now derive a rectangle (a parallelogram the right angles) and a rhombus 
(a parallelogram with equal sides) from the parallelogram. The parallelogram 
requires three data points, but the rectangle and the rhombus each require 
only two, the lengths of two sides in the case of the rectangle and
the length of a side and one angle in the case of the rhombus.&lt;/p&gt; 

&lt;p&gt;A square is both a rectangle and a rhombus (the dreaded diamond), this is the 
definition. Only one data point is required to define a square, It is simpler 
than either the rectangle or the rhombus, so why should it carry the overhead 
of both?&lt;/p&gt;

&lt;p&gt;It seems to me the the existing OO programming concept of going from general 
to specific is backward. We should be going from the specific to the general in 
most cases.&lt;/p&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/38087982-2174814325030363997?l=edkeith.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://edkeith.blogspot.com/feeds/2174814325030363997/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=38087982&amp;postID=2174814325030363997' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/38087982/posts/default/2174814325030363997'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/38087982/posts/default/2174814325030363997'/><link rel='alternate' type='text/html' href='http://edkeith.blogspot.com/2008/12/problem-with-oo-programming-languages.html' title='The problem with OO programming languages'/><author><name>Ed</name><uri>http://www.blogger.com/profile/13325146756422019012</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-38087982.post-1558918701618506042</id><published>2008-12-23T08:20:00.003Z</published><updated>2008-12-23T13:35:18.993Z</updated><category scheme='http://www.blogger.com/atom/ns#' term='cooking'/><category scheme='http://www.blogger.com/atom/ns#' term='recipes'/><title type='text'>Picadillo</title><content type='html'>&lt;p&gt;They say there are as many recipes for Picadillo as there are cooks who make
it. I do not think so, I'm fairly sure there are more recipes than cooks. I know I never make it the same way twice. yesterday I found two recipes in my mother's recipe file, this is not either one of them. This is how I did it last time.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;2 Tbsp. Lard (you can substitute vegetable oil, but it will loose something)&lt;/li&gt;

&lt;li&gt;1 Large onion, chopped&lt;/li&gt;

&lt;li&gt;2 cloves garlic, chopped&lt;/li&gt;

&lt;li&gt;2 zucchini, grated&lt;/li&gt;

&lt;li&gt;1 lb. Ground beef (you can substitute ground poultry, I even used 1/2 lb. firm tofu, and 1/2 lb. tempeh for a vegetarian version once, but beef is best)&lt;/li&gt;

&lt;li&gt;2 cups canned tomatoes&lt;/li&gt;

&lt;li&gt;6 oz. Tomato paste&lt;/li&gt;

&lt;li&gt;2 cups raisins&lt;/li&gt;

&lt;li&gt;3 Tbsp. Red wine vinegar&lt;/li&gt;

&lt;li&gt;6 - 10 tsp. Chili powder (I like a sweet chili powder with not too much heat)&lt;/li&gt;

&lt;li&gt;2 tsp. Cinnamon&lt;/li&gt;

&lt;li&gt;1 tsp. Cumin&lt;/li&gt;

&lt;li&gt;1 - 2 Tbsp Sweetener (Sugar, Honey, molasses, or some combination)&lt;/li&gt;

&lt;li&gt;A pinch of ground cloves&lt;/li&gt;

&lt;li&gt;1 Tbsp. Cocoa powder&lt;/li&gt;

&lt;li&gt;2 Oz. Chocolate (I used bittersweet this time, some times I use unsweetened. You could use dark. You just need to adjust the amount of sweetener.)&lt;/li&gt;

&lt;li&gt;1 - 3 jalapeño peppers, seeded and finely chopped&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Fry onions, garlic and zucchini in the lard until onion is translucent.
Add ground beef and brown well.&lt;/p&gt;
&lt;p&gt;Add all remaining ingredients except the peppers and simmer for two hours.&lt;/p&gt;
&lt;p&gt;Add the peppers&lt;/p&gt;
&lt;p&gt;I serve it in tacos or burritos, or over rice or pasta. I have heard of it being used to stuff peppers or squash, but have not tried this.&lt;/p&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/38087982-1558918701618506042?l=edkeith.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://edkeith.blogspot.com/feeds/1558918701618506042/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=38087982&amp;postID=1558918701618506042' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/38087982/posts/default/1558918701618506042'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/38087982/posts/default/1558918701618506042'/><link rel='alternate' type='text/html' href='http://edkeith.blogspot.com/2008/12/picadillo.html' title='Picadillo'/><author><name>Ed</name><uri>http://www.blogger.com/profile/13325146756422019012</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-38087982.post-4859012294949976597</id><published>2008-01-11T13:17:00.001Z</published><updated>2009-10-28T16:43:53.923Z</updated><category scheme='http://www.blogger.com/atom/ns#' term='Programming'/><title type='text'>There are no bugs in software</title><content type='html'>&lt;p&gt;A 'bug' is a wingless or four winged insect with mouth parts adapted for piercing and sucking of the order Hemitera.&lt;/p&gt;

&lt;p&gt;Code does not have bugs, it has defects! &lt;/p&gt;

&lt;p&gt;When you make an error in your thinking (or your typing) you introduce a defect in your code, if you do not catch it before it goes to testing (or worse, it ships) it will show up as a fault when the code is running. Faults are caused by defects. Defects are caused by errors. Bugs hatch from eggs.&lt;/p&gt;

&lt;p&gt;Defects are cancer in code; the earlier there are detected the easier they are to remove. 
&lt;ul&gt;
    &lt;li&gt;If it is detected before it is checked in, it is as if it never happened.&lt;/li&gt;

    &lt;li&gt;If it is detected by the testing team, it can be eliminated before the customer sees it.&lt;/li&gt;

    &lt;li&gt;If the beta testers detect it, it will not ship to the main customer base.&lt;/li&gt;

    &lt;li&gt;If it ships, you will need to deal with it for as long as the defective release is being supported!&lt;/li&gt;
&lt;/ul&gt;
For this reason it is best to catch defects ASAP! It is best if the compiler can catch them. Next best is if they can be caught by the automated unit tests run automatically by the version control system. Either way they will not be checked in.&lt;/p&gt;

&lt;p&gt;We are convinced that code is defect free when either:
&lt;ol&gt;
 &lt;li&gt;It is so simple there is obviously nothing wrong with it&lt;/li&gt;

 or

 &lt;li&gt;It is so complex there is nothing obviously wrong with it.&lt;/li&gt;
&lt;/ol&gt;
The first is fine, the second is not. Never give code the benefit of the doubt, if you are not sure it is defect free, assume it is defective. You should only assume code is defect free after you have: 
&lt;ol&gt;

    &lt;li&gt;Mathematically proven it to be defect free (and proven that your proof is correct), &lt;/li&gt;

 and 

    &lt;li&gt;Run it through a full coverage test suite that deals with restricted resources, device failures, all possible timing issues, and all other possible condition under which the code could fail (such a test suit is probably not even theoretically possible). &lt;/li&gt;
&lt;/ol&gt;
Since it is very rare (if not imposable) to do either of these, let alone both, it is very rare that you can assume code to be defect free.&lt;/p&gt;

&lt;p&gt;But always remember, bugs do not sneak into code, programmers put defects there!&lt;/p&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/38087982-4859012294949976597?l=edkeith.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://edkeith.blogspot.com/feeds/4859012294949976597/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=38087982&amp;postID=4859012294949976597' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/38087982/posts/default/4859012294949976597'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/38087982/posts/default/4859012294949976597'/><link rel='alternate' type='text/html' href='http://edkeith.blogspot.com/2008/01/there-are-no-bugs-in-software.html' title='There are no bugs in software'/><author><name>Ed</name><uri>http://www.blogger.com/profile/13325146756422019012</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-38087982.post-2532202648680591647</id><published>2007-04-19T13:34:00.000Z</published><updated>2007-04-20T17:11:42.112Z</updated><category scheme='http://www.blogger.com/atom/ns#' term='Martial Arts'/><category scheme='http://www.blogger.com/atom/ns#' term='Self defense'/><category scheme='http://www.blogger.com/atom/ns#' term='Aikido'/><title type='text'>Is That Aikido?</title><content type='html'>&lt;p&gt;When I do a technique which does not appear in a tiagi or on a test sometime someone will tell me "That's not aikido". On the other hand I will sometime stop a randori and say “That is not aikido”. What is the criterion to determine whether a technique is, or is not an aikido technique?&lt;/p&gt;

&lt;p&gt;The person who challenges my technique usually takes the position that there is an official list of aikido techniques, and any technique that is not on that list is not aikido. My position is that this is a ridiculous claim. Watch any randori and you will rarely see a technique that appears on any list. The attack determines what the technique should be, and since there is an infinite variation of attacks, there will be an infinite variation in techniques. No finite list can ever be exhaustive.&lt;/p&gt;

&lt;p&gt;If there is not canonical list, than how can you determine if a technique is aikido or not? Sometime it is clear. Every aikido student knows that aikido does not have any strikes, or does it?  I once saw Koichi Kashiwaya Sensei, Chief Instructor of Ki Society USA, drive his fist into an attackers arm pit and claim that it was an aikido technique. Also many techniques involve atemi, which is striking. To farther confuse the issue, a knowledgeable person, watching my technique will see a bit of a Ba-Gua coil or a Tia-Chi role back in many of my aikido techniques.  Does the Ba-Gua and Tia-Chi influence make the technique less an aikido technique?&lt;/p&gt;

&lt;p&gt;I believe that aikido is distinguished by the principal of non-dissension. When doing aikido you let the attacker do what he wants to do. If you are trying to force him to do something he does not want to do you are not doing aikido.  When doing aikido we do not throw the attacker, we let him fall down. When doing aikido we do not block a punch, we get out of the way and let it go by, or we catch it before it reached its power zone and let the force of the punch move the attackers shoulder. When doing aikido we do not try to break an attackers grip, we let him hold on as we move to a more advantageous position.&lt;/p&gt;

&lt;p&gt;When Koichi Kashiwaya drove his fist into his attacker's arm pit he did not punch the attacker, he allowed the attacker to run into his fist. His attacker did all the work; he just put his fist where the attacker would run into it.&lt;/p&gt;

&lt;p&gt;When we do atemi, the atemi is not intended to hurt the attacker (although it may) it is intended to cause the attacker to shift his balance to set up the technique. To make him do what we want him to do if it does not have this effect we need to change our technique or we will not be doing aikido. If you do an atemi to the face to arrest the forward motion of the attacker’s upper body, but the attacker does not stop, he may get a broken nose, but he will defiantly block your technique making you do a different technique, or stop doing aikido.&lt;/p&gt;

&lt;p&gt;I tell all my students “When done right aikido is effortless. If you are working you are not doing aikido.” This sums it up very well. If you are doing aikido, the attacker is doing all the work. If you are working, you are not doing aikido.&lt;/p&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/38087982-2532202648680591647?l=edkeith.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://edkeith.blogspot.com/feeds/2532202648680591647/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=38087982&amp;postID=2532202648680591647' title='3 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/38087982/posts/default/2532202648680591647'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/38087982/posts/default/2532202648680591647'/><link rel='alternate' type='text/html' href='http://edkeith.blogspot.com/2007/04/is-that-aikido.html' title='Is That Aikido?'/><author><name>Ed</name><uri>http://www.blogger.com/profile/13325146756422019012</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>3</thr:total></entry><entry><id>tag:blogger.com,1999:blog-38087982.post-1395634008130341058</id><published>2007-03-12T11:58:00.000Z</published><updated>2007-03-12T13:40:26.204Z</updated><category scheme='http://www.blogger.com/atom/ns#' term='Programming'/><category scheme='http://www.blogger.com/atom/ns#' term='database'/><title type='text'>Surrogate Keys</title><content type='html'>&lt;p&gt;I may be putting my foot in it with this post. I believe wars have been fought over whether or not to use surrogate keys. There are those who will tell you that the use of surrogate keys is proof that the designer of the database did not know anything about database design. There are others who always use surrogate keys and claim anyone who designs a database with natural keys is asking for trouble. My position is, as it is so often, that both are right.&lt;/p&gt;

&lt;p&gt;Before getting to the debate I will need to define a few terms. You probably already know most of them, but I need be sure what I say is understood, so I need to make it clear what I mean by the terms I am using.&lt;/p&gt;

&lt;dl&gt;

&lt;dt&gt;Candidate Key&lt;/dt&gt;&lt;dd&gt;A set of one or more columns that can be used to uniquely identify a record.&lt;/dd&gt;

&lt;dt&gt;Primary Key&lt;/dt&gt;&lt;dd&gt;The set of one or more columns is used internally to uniquely identify a record.&lt;/dd&gt;

&lt;dt&gt;Natural Key&lt;/dt&gt;&lt;dd&gt;A primary key composed of one or more columns of data which are used by the users in the natural course of their work.&lt;/dd&gt;

&lt;dt&gt;Surrogate Key&lt;/dt&gt;&lt;dd&gt;A single column, created by the data modeller solely for the purpose of uniquely identifying a record. A Surrogate Key is not derived from application data. The value of a surrogate key contains no semantic meaning.&lt;/dd&gt;

&lt;dt&gt;Foreign Key&lt;/dt&gt;&lt;dd&gt;A copy of the primary key of one table, put in another table to reference that table.&lt;/dd&gt;

&lt;dt&gt;Logical Data Model&lt;/dt&gt;&lt;dd&gt;the data model as seen by the user.&lt;/dd&gt;

&lt;dt&gt;Physical Data Model&lt;/dt&gt;&lt;dd&gt;the data model as implemented in the DBMS.&lt;/dd&gt;

&lt;/dl&gt;

&lt;p&gt;The first step is to identify candidate keys. Candidate keys must be guaranteed unique, not coincidentally unique in the current data set. Selecting candidate keys is a business decision, not a technical decision. A database for a small club may use first name as a primary key. The club may have a policy that any new member with the same first name as an existing member will be assigned a nickname which will be unique. This is a perfectly valid business rule. Do not tell the client how they should be doing business, just make sure you understand how they do business, and that you make them aware of potential problems.&lt;/p&gt;

&lt;p&gt;Every table &lt;b&gt;MUST&lt;/b&gt; have one or more natural candidate keys. If you cannot identify a candidate key for a table, you have a problem in your datamodel. &lt;b&gt;Do not generate a surrogate key because you can not find a natural candidate key.&lt;/b&gt; This is a common miss use of a surrogate key, and is, I suspect, the main reason that surrogate keys have gotten a bad name. The structure of the database must reflect the business rules. If there is no natural candidate key for a table that is saying that there are records in that table that the business dose not recognize as being different, in otherwords the table contains duplicate data. You do not want duplicate data in the database.&lt;/p&gt;

&lt;p&gt;After you have identified, and documented, one or more candidate keys for each table, it is necessary to select a single primary key for each table. A natural key would be one of the candidate keys that have already been identified, but not all candidate keys make good primary keys.&lt;/p&gt;

&lt;p&gt;So what is wrong with Natural keys? Imagine a small business that we are designing a customer database for. This business has a policy against assigning customers a customer number, they consider it to be dehumanizing. So they identify customers by name. There is a small problem, names are not unique. The client has a solution to this problem. Instead of using First, Middle and Last name alone as the key they will add date of first order, city, state, and street address. Now there can only be a problem if two people with the same name, living at the same address, place their first order on the same day. An unlikely event which would probably cause lots of confusion no matter how the database is designed. So we run with this as a candidate key.&lt;/p&gt;

&lt;p&gt;Would (First_Name, Middle_Name, Last_Name, Date_of_first_order, City, State, Street_address) be a good primary key? The primary key will be used as a foreign key. The customer table will probably have lots of other tables referencing it via foreign keys. Every table that references this table will need to add seven columns to hold this foreign key. Many of these tables will probably have fewer than seven columns of data so more space will be taken up by foreign keys than by data. With disk prices dropping this may not be a big problem. but it is something you might want to think about.&lt;/p&gt;

&lt;p&gt;There is a bigger problem. What will happen if a customer gets married and changes her name? All the foreign keys into the customer table must be changed. According to Codd, this is not a problem. Codd said that any relational database management system must provide a command to change a primary key and all associated foreign keys. Unfortunately, there is no system available that fits Codd's definition of a relational database management system, and we will need to use an existing system to implement our database. So this will be a problem. We have the same problem if someone moves.&lt;/p&gt;

&lt;p&gt;This case is screaming for a surrogate key. In fact it is contrived, most businesses would assign a customer number. It could be argued that customernumber is a surrogate key, except that the customer number has meaning at the business level, a surrogate key does not. The important things to realize are that; A candidate key has been identified, but for technical reasons it is not well suited to be used as a primary key. Some database designers claim that no natural key is ever well suited to be a primary keybecause they are entered by users and therefor subject to data entry errors and therefor may need to be changed to correct these errors. They have a very good point.&lt;/p&gt;

&lt;p&gt;What is wrong with surrogate keys? The biggest problem is when they are used to cover up problems in the data model by creating a key for tables that otherwise have no candidate keys. This is a big no-no. All tables must have well documented, natural, candidate keys. But there is another problem, admittedly a small one, but a problem none the less, and that is that natural keys are more natural. If the client wants to query the credit history of acustomer the natural key is the natural data to query on. If the database uses a surrogate key then it will be necessary to either do a join or a sub query to the customer data table to get the surrogate key. This can make queries significantly more complex if all tables use surrogate keys.&lt;/p&gt;

&lt;p&gt;There are two definitions I gave at the top of this post that I have not used yet. logical data model and physical data model. IMHO these two terms are the solution to the problem of surrogate keys. The logical data model is the model you design to. The physical data model is an implementation detail that should be encapsulated at the lowest possible level of abstraction, and definitely should never show up in the business logic. You should consider implementing the logical model as views and only access the data through these views, this way you can encapsulate the physical data model inside the RDBMS.&lt;/p&gt;

&lt;p&gt;Like I said, both sides of the surrogate key debate are right. There is no place for surrogate keys in the logical data model, and there should be no user generated primary keys in the physical data model. This give you the best of both worlds.&lt;/p&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/38087982-1395634008130341058?l=edkeith.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://edkeith.blogspot.com/feeds/1395634008130341058/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=38087982&amp;postID=1395634008130341058' title='2 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/38087982/posts/default/1395634008130341058'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/38087982/posts/default/1395634008130341058'/><link rel='alternate' type='text/html' href='http://edkeith.blogspot.com/2007/03/surrogate-keys.html' title='Surrogate Keys'/><author><name>Ed</name><uri>http://www.blogger.com/profile/13325146756422019012</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>2</thr:total></entry><entry><id>tag:blogger.com,1999:blog-38087982.post-5230092327980411572</id><published>2007-03-11T00:14:00.000Z</published><updated>2007-03-12T14:58:38.372Z</updated><category scheme='http://www.blogger.com/atom/ns#' term='Programming'/><category scheme='http://www.blogger.com/atom/ns#' term='database'/><title type='text'>Data Normalization</title><content type='html'>&lt;blockquote&gt;A data element must depend on the key, the whole key and nothing but the key, so help me Codd. - Ray Kirk&lt;/blockquote&gt;

&lt;p&gt;I studied database normalization in the early 1990's when I was working in data modelling with &lt;a href'http://www.ies.aust.com/cbfindex.htm'&gt;Clive Finkelstein&lt;/a&gt;, the father of Information Engineering, and his disciples at Information Engineering Systems, Corp. I am surprised by the aura of mysticism that seems to surrounds data normalization. Most people seem to view data normalization as something that is :

&lt;ol&gt;

&lt;li&gt;highly complicated that requires an advanced degree in mathematics to understand.&lt;/li&gt;

&lt;li&gt;Of no practical value, and not something you'd want to do to a real database.&lt;/li&gt;

&lt;/ol&gt;

Both are wrong.&lt;/p&gt;

&lt;p&gt;Data normalization is nothing more than a restatement of the 'DRY' principal; every piece of data must have a single, unambiguous, authoritative representation within the database.&lt;/p&gt;

&lt;p&gt;Data normalization captures the business rules and encodes them in the data model. Many people believe that normalizing data causes performances problems. It is debatable if this ever was the case, the reported performance improvements were usually gained by ignoring the business rules. But even if it was in the past, it is not now with modern databases.&lt;/p&gt;

&lt;p&gt;So how do you capture the business rule in the data model?&lt;/p&gt;

&lt;p&gt;Each discrete piece of data should be in its own field. Do not encode many pieces of data in a single field. Each field can be independently queried. If many pieces of data are encoded in a single field they can not be independently queried. Just because you do not need to query them independently now, does not mean you will not need to at some time in the future, so do not store compound data in a single field.&lt;/p&gt;

&lt;p&gt;Each discrete piece of data should be recorded in exactly one place in the database (except for foreign keys). If you store the same data in multiple places you will need to put in constraints and triggers to guarantee that the data always remains constant for all copies, if you do not do this they may become inconsistent and since you do not know which copy is authoritative, you will not know what the value really is. The studies that showed data normalization hurt performance ignored this.&lt;/p&gt;

&lt;p&gt;Eliminate repeating data. If your customer data table has columns for home phone number, work phone number, cell phone number, voice mail phone number, pager number, etc. This may represent a problem, many of your customers may not have all the phone numbers in your table, and some may have additional phone numbers that are not in your table. You should consider creating a new table to hold the phone numbers. The primary key should be a foreign key to the customer table and a description column
which will contain "home", "work", "cell", etc. You can allow the description column to be free form, or you can create a type table which will have a single column containing all the legal values for the description field and making the description in the phone number table a foreign key to this type table.&lt;/p&gt;

&lt;p&gt;Eliminate inapplicable data. Codd made a distinction between null values that are unknown and null values that are inapplicable. An example of an inapplicable null value would be if my customer data table has a column for SEX, to record whether the customer is male or female. What value should this field have in the case of a corporate customer? The correct answer is to create a secondary table, with the same primary key as the customer table, which only exists for individual customers, which will contain the sex column, and no corporate customers will have any data in this secondary table.&lt;/p&gt;

&lt;p&gt;This is not all there is to be said about data normalization, many entire books have been written on the subject. But this should be enough to solve 80% of the data normalization problems you are likely to face. To learn more read Codd, Date, and Finkelstein.&lt;/p&gt;

&lt;p&gt;Next time: surrogate keys.&lt;/p&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/38087982-5230092327980411572?l=edkeith.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://edkeith.blogspot.com/feeds/5230092327980411572/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=38087982&amp;postID=5230092327980411572' title='2 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/38087982/posts/default/5230092327980411572'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/38087982/posts/default/5230092327980411572'/><link rel='alternate' type='text/html' href='http://edkeith.blogspot.com/2007/03/data-normalization.html' title='Data Normalization'/><author><name>Ed</name><uri>http://www.blogger.com/profile/13325146756422019012</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>2</thr:total></entry><entry><id>tag:blogger.com,1999:blog-38087982.post-4199179619551468668</id><published>2007-02-26T22:02:00.000Z</published><updated>2007-02-26T22:13:37.752Z</updated><category scheme='http://www.blogger.com/atom/ns#' term='Programming'/><title type='text'>Software Quality</title><content type='html'>&lt;blockquote&gt;
If builders built buildings the way programmers wrote programs, then the
first woodpecker that came along would destroy civilization. 
- Gerald Weinberg
&lt;/blockquote&gt;

&lt;p&gt;I'm not sure when this was written, but I first saw it reproduced in the mid
seventies. At that time I thought it was funny, but did not appreciate the
truth of it. After spending 20 years writing programs I do not think it
would require a woodpecker, a strong breeze would be sufficient.&lt;/p&gt;

&lt;p&gt;I have heard many times that computer programs are the most complex
structures ever built by man. I'm not sure what this claim is based on, but
I find it hard to believe. If it were true we would see a lot more software
failures than we do.&lt;/p&gt;


&lt;blockquote&gt;
When Roman engineers built a bridge, they had to stand under it while
the first legion marched across. If programmers today worked under
similar ground rules, they might well find themselves getting much more
interested in Ada! -- Robert Dewar (President Ada Core Technologies)
&lt;/blockquote&gt;

&lt;p&gt;The Romans did not have sufficiently developed mathematics, physics and
material science to be able to determine in advance whether or not a bridge
would be able to support a legion marching across it. So the engineer was
made to stand under it to demonstrate his confidence in his design. Since
the engineer had to stake his life on his bridge not falling, but had no
objective way of determining whether or not it would, he was forced to make
sure the bridge could not possibly collapse when the legion marched over it,
as a result many of these bridges are still standing thousands of years
after their construction. I strongly suspect that many of the people who
funded the building of these bridges would have preferred to save a few
bucks by building a bridge that would have stood for only a tenth as long,
but they were not given the option.&lt;/p&gt;

&lt;p&gt;True Software Engineering is still a dream, but many tools do exists. For
some reason they seem to be universally regarded as being of interest only
to academics. Industry shuns them, I have worked on many projects, on only
one was a simple Lint tool used. Most professional programmers believe Lint
generates too many warnings when run against production code, so they will
not use it. Is the problem with Lint, or with the production code?&lt;/p&gt;


&lt;p&gt;Why does the software industry shun any of the tools that could move it
toward a true engineering discipline? I cannot say for sure, but I can make
an educated guess. I think it is because they think it may slow things down.
On all projects I've worked on, with only one exception (which was also the
one with the most ridged schedule and the one that used Lint), the goal was
to ship something, anything, on the ship date. I think most of my managers
would have been perfectly happy shipping blank diskettes if they though they
could get them past the test team. Many times there were known serious
problems with the software, but they did not need to be fixed because the
test team had not found them, and hopefully we would ship before they did.
This is patently false economy, since it is less expensive to write good
software than to fix bad software. But the mindset in American business for
the past several decades has been that it is better to spend $100 tomorrow
than it is to spend $1 today. We have to maximize quarterly profits, not
long term profits. &lt;/p&gt;

&lt;p&gt;I heard that in a resent study American consumers were given a choice of a
low quality item which cost $1 and would last a year or a similar higher
quality item which cost $4 and would last ten years, over 80% of them
chose the less expensive item. So writing poor quality software may not be
as foolish as it seems, particularly if you can avoid maintaining the
software, and can get your customers to pay for an upgrade to fix the
defects. If builders could get away with it I'm sure they would rather build buildings like programmers write programs, and sell new buildings to replace the ones destroyed by woodpeckers.&lt;/p&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/38087982-4199179619551468668?l=edkeith.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://edkeith.blogspot.com/feeds/4199179619551468668/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=38087982&amp;postID=4199179619551468668' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/38087982/posts/default/4199179619551468668'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/38087982/posts/default/4199179619551468668'/><link rel='alternate' type='text/html' href='http://edkeith.blogspot.com/2007/02/software-quality.html' title='Software Quality'/><author><name>Ed</name><uri>http://www.blogger.com/profile/13325146756422019012</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-38087982.post-8854564660255856873</id><published>2007-02-26T14:56:00.000Z</published><updated>2007-02-26T15:20:23.308Z</updated><category scheme='http://www.blogger.com/atom/ns#' term='Programming'/><category scheme='http://www.blogger.com/atom/ns#' term='Math'/><title type='text'>Project Euler</title><content type='html'>&lt;p&gt;&lt;a href='http://projecteuler.net/'&gt;Project Euler&lt;/a&gt; is a lot of fun. They post challenging mathematical/computer programming problems for users to solve. Some are quite easy, some are very challenging. I go there to challenge myself. I first solve the problem, usually in 
&lt;a href='http://www.jsoftware.com/'&gt;J&lt;/a&gt;, 
&lt;a href='http://www.python.org/'&gt;Python&lt;/a&gt;, 
&lt;a href='http://caml.inria.fr/'&gt;Ocaml&lt;/a&gt;, 
&lt;a href='http://www.r-project.org/'&gt;R&lt;/a&gt;, 
&lt;a href='http://www.mozart-oz.org/'&gt;Oz&lt;/a&gt;, or 
&lt;a href='http://mathsrv.ku-eichstaett.de/MGF/homes/grothmann/euler/'&gt;Euler&lt;/a&gt; 
(I do not use C++, I write C++ programs professionally, for fun I work with something else). Then I usually try to find a different way of solving it in another language, then I go to the forum (which is only open to users who have solved the problem) and see how others have solved it. Frequently my first attempt does not make the one minute requirement, but I refine it until it does. Maybe I'm weird, but I think it's fun.&lt;/p&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/38087982-8854564660255856873?l=edkeith.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='related' href='http://projecteuler.net/' title='Project Euler'/><link rel='replies' type='application/atom+xml' href='http://edkeith.blogspot.com/feeds/8854564660255856873/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=38087982&amp;postID=8854564660255856873' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/38087982/posts/default/8854564660255856873'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/38087982/posts/default/8854564660255856873'/><link rel='alternate' type='text/html' href='http://edkeith.blogspot.com/2007/02/project-euler.html' title='Project Euler'/><author><name>Ed</name><uri>http://www.blogger.com/profile/13325146756422019012</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-38087982.post-116948616642501452</id><published>2007-01-22T17:14:00.000Z</published><updated>2007-05-12T14:24:41.595Z</updated><category scheme='http://www.blogger.com/atom/ns#' term='Programming'/><title type='text'>Programming Languages</title><content type='html'>&lt;blockquote&gt;
A language that doesn’t affect the way you think about programming is not worth knowing.
– Alan Perlis
&lt;/blockquote&gt;

&lt;blockquote&gt;
Little correlation has been found between performance and years of experience in the field. Actual productivity is better correlated with the number of programming languages the person knows.
- Edward Yourdon
&lt;/blockquote&gt;


&lt;h2&gt;Programming Languages I Have Used&lt;/h2&gt;

&lt;p&gt;I have used many languages. This is a list of those I can remember.&lt;/p&gt;

&lt;h2&gt;&lt;a href="http://en.wikipedia.org/wiki/C++"&gt;C++&lt;/a&gt;&lt;/h2&gt;

&lt;p&gt;I first used C++ in 1990. My first impression was that
regardless of whether or not this OO stuff was any good, being a
type safe version of C was a good thing. Soon I decided that this OO
stuff was a good thing. I fell in love with RAII long before I ever
heard that awful name. My eyes really opened when I read Barton
&amp;amp; Nackman's &lt;i&gt;Scientific and Engineering C++&lt;/i&gt;, opened even
wider when I read Josuttis' &lt;i&gt;The C++ Standard Library: A Tutorial
and Reference&lt;/i&gt;, and nearly fell out of my head when I read
Alexandrescu's &lt;i&gt;Modern C++ Design: Generic Programming and Design
Patterns Applied&lt;/i&gt;. This is a language that you can continue to
learn your whole life!&lt;/p&gt;

&lt;p&gt;Don't get me wrong, C++ is far from perfect. I still think its
syntax is ugly (see &lt;a href="http://www.csse.monash.edu.au/~damian/papers/HTML/ModestProposal.html"&gt;
SPECS&lt;/a&gt; for a proposed improvement); It needs a &lt;i&gt;real&lt;/i&gt; macro
capability, template meta programming is good, but not good enough
(unfortunately &lt;a href="http://www.computing.surrey.ac.uk/research/dsrg/fog/"&gt;FOG&lt;/a&gt; is not
it). Design by Contact is a bear. And I wish functional programming were
easier. But when you use good libraries like STL, &lt;a href="http://www.boost.org"&gt;Boost&lt;/a&gt;, &lt;a href="http://loki-lib.sourceforge.net/"&gt;Loki&lt;/a&gt;, &lt;a href="http://synesis.com.au/software/stlsoft/"&gt;STLsoft&lt;/a&gt;, &lt;a href="http://www-static.cc.gatech.edu/~yannis/fc++/"&gt;FC++&lt;/a&gt; and &lt;a href="http://www-static.cc.gatech.edu/~yannis/lc++/"&gt;LC++&lt;/a&gt;, it is a very
good language. It supposedly was Stroustrup who said &lt;i&gt;"in C it's
fairly easy to shoot yourself in the foot, whereas in C++ it's harder
to shoot yourself in the foot, but when you do, you usually blow your
whole leg off"&lt;/i&gt;, so watch out for the gotchas.&lt;/p&gt;

&lt;h2&gt;
&lt;a href="http://en.wikipedia.org/wiki/C_%28programming_language%29"&gt;
C&lt;/a&gt;&lt;/h2&gt;

&lt;p&gt;I first used C in 1985. C is the Lingua Franca. If you want to call
the same function from C++, Java, Python, J, R, &amp; Clips you have
to call it through a C interface. C is very dangerous to work in, but
there are good tools to solve this problem. Most note worthy is
&lt;a href="http://www.splint.org/"&gt;splint&lt;/a&gt;.&lt;/p&gt;

&lt;h2&gt;&lt;a href="http://java.sun.com/"&gt;Java&lt;/a&gt;&lt;/h2&gt;

&lt;p&gt;I have not done a lot with Java. I worked through all of &lt;a href='http://java.sun.com/docs/books/tutorial/'&gt;Sun's Java Tutorial&lt;/a&gt; in the late 1990's and read several books on the subjects. I have used Java on two contracts in the early 2000's, both time writing installers. One setting up an Axis SOAP server, the other setting up an Oracle Database and a J2EE Server using JMX.
&lt;/p&gt;

&lt;p&gt;Java has been getting a lot of hype, but it looks like back to the future to me. Am I the only person who remembers the p-System? It was a virtual machine that executed p-Code on any machine that ran the p-System so you could write once and run anywhere in the late 1970's!
The p-System died because p-Code was much slower than native code.
Java claims to have solved this problem, I do not know whether or not this is true, but I do know that the JVM takes forever to load on every system I've used it on, and it chews up memory.&lt;/p&gt;

&lt;p&gt;I am told that Java &lt;i&gt;'fixes the problems with C++'&lt;/i&gt;. But I'm not convinced. It is garbage collected, but memory is only one
resource that the programmer needs to manage, garbage collection does not stop you from dropping file handles or other system resources.
Using RAII in C++ make managing memory, and any other resource, fairly painless. Besides, I've always believed that if you did not know the life cycle of your objects, you have bigger problems than just resource management. I have also noted that on every large scale Java project I am familiar with a lot of developer effort has been devoted to controlling the garbage collector. To get the dubious advantaged of garbage collection I have to give up RAII, templates, multiple inheritance, conditional compilation, free functions, and link time checking. I'm not convinced. And if I really want garbage collection in C++ I can us the &lt;a href="http://www.hpl.hp.com/personal/Hans_Boehm/gc/"&gt;Hans-Boehm
conservative garbage collector&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;Don't get me wrong, Java has its place: Applets are great; Swing is nice; Reflection can be useful; and being able to replace a component at run time has some appeal. I just have to remember to release all resources inside finally blocks, not too big a price to pay. It will never replace C++, but it is a useful tool to add to the tool box. It still feels like writing C++ with one hand tied behind my back, I'm sure this will change as I get more experience with it.&lt;/p&gt;

&lt;h2&gt;&lt;a href="http://en.wikipedia.org/wiki/JavaScript"&gt;JavaScript&lt;/a&gt;
&lt;/h2&gt;

&lt;p&gt;I've been using JavaScript since the late 1990's. If you want to write portable DHTML you must use ECMAScript (
&lt;a href="http://www.ecma-international.org/publications/standards/Ecma-262.htm"&gt;
Ecma-262&lt;/a&gt; a.k.a. JavaScript, a.k.a. JScript, a.k.a. Live Script,
. . . ). JavaScript has been called the most misunderstood
programming language. Just as no one seems to be able to agree what
name it should go by, no one seems to give it the respect it deserves.
The syntax of JavaScript is a lot like Java, but the semantics are
completely different, closer to Lisp. It is a powerful functional programming language.
Its prototype based object system is under appreciated. While it is the
only language for DHTML, it can also be used to develop .NET
assemblies, to script either Windows (WSH) or Macintosh (&lt;a href='http://www.latenightsw.com/freeware/JavaScriptOSA/index.html'&gt;OSA&lt;/a&gt;), as a server side
scripting language (&lt;a href='http://www.whitebeam.org/'&gt;Whitebeam&lt;/a&gt;), and there is a wxWidgets interface to it (&lt;a href='http://www.wxjavascript.net/index.html'&gt;wxJS&lt;/a&gt;).&lt;/p&gt;

&lt;h2&gt;
&lt;a href="http://en.wikipedia.org/wiki/C_Sharp"&gt;C#&lt;/a&gt;&lt;/h2&gt;

&lt;p&gt;I have not done much with C# yet. C# is Microsoft's attempt to kill Java, but they are doing it right.
While Java is proprietary, C# is an international standard (&lt;a href="http://www.ecma-international.org/publications/standards/Ecma-334.htm"&gt;
Ecma-334&lt;/a&gt;). I have not used either one enough to say what make
either better than the other, but I have observed that that CRL seems
to load a lot faster than the JVM, but you can't deploy portable web
applets in it.&lt;/p&gt;

&lt;h2&gt;&lt;a href='http://en.wikipedia.org/wiki/APL_programming_language'&gt;APL&lt;/a&gt;, 
&lt;a href="http://www.jsoftware.com/"&gt;J&lt;/a&gt;&lt;/h2&gt;

&lt;p&gt;J is a modern version of APL. I used APL a little in the early 1980's, and used J a little in the late 1990's and started using it again a few weeks ago.&lt;/p&gt;

&lt;p&gt;Like APL, J is a cryptic read only
language, but you do not need a special keyboard like you do for APL.
There is a good reason that it is the language of choice for the
highest scoring users at &lt;a href="http://projecteuler.net/"&gt;Project
Euler&lt;/a&gt;. Once you get past the steep learning curve, it is very easy
to do serious number crunching in J. J is great for crunching numbers
but not as good at accessing external data. While you can do data
analysis in J, reading the data files is no fun (the command to read
from a file is &lt;code&gt;1!:1&lt;/code&gt;, I told you it was cryptic).&lt;/p&gt;

&lt;h2&gt;&lt;a href="http://www.r-project.org/"&gt;R (Gnu S)&lt;/a&gt;&lt;/h2&gt;

&lt;p&gt;I have not done much with R, just worked through a tutorial and done some simple statistical analysis. I like what I have seen. R is a language for data analysis. It is a powerful language with a
plethora of libraries (see &lt;a href="http://cran.r-project.org/"&gt;CRAN
&lt;/a&gt;). The learning curve for R is much less steep than it is for J.
The J wiki even has a page explaining how to call J from R to get the
best of both worlds.&lt;/p&gt;

&lt;h2&gt;&lt;a href="http://www.python.org/"&gt;Python&lt;/a&gt;&lt;/h2&gt;

&lt;p&gt;I've been using Python since the mid 1990's. Python is object oriented and dynamically typed. Many people get hung
up on the fact that white space is significant. All I can say is &lt;i&gt;'get
over it'&lt;/i&gt;. You indent your code consistently anyway (at least I Hope
you do) so what difference does it make if the language requires it?
Python code is easy to read and write. It borrows a lot of good ideas
from Lisp &amp; Icon. There are a lot of good libraries available. It
scales well, you can throw out a simple script quickly, or write a
complex application. It is JIT compiled to byte code, it also can run
on either the JVM (&lt;a href="http://www.jython.org/Project/index.html"&gt;
Jython&lt;/a&gt;) or CRL (&lt;a href="http://www.codeplex.com/Wiki/View.aspx?ProjectName=IronPython"&gt;
Iron Python&lt;/a&gt;) either interpreted or compiled. Python is my
scripting language of choice at this time.&lt;/p&gt;

&lt;h2&gt;&lt;a href="http://www.mozart-oz.org/"&gt;Oz&lt;/a&gt;&lt;/h2&gt;

&lt;p&gt;Oz supports declarative programming, object-oriented programming,
constraint programming, and concurrency as part of a coherent whole.
The syntax is different from what I'm used to, but not hard to adjust
to. I find the single asignment dataflow variables very interesting. In Oz the bind operator (used to bind a variable to a value or another variable) is symentric so &lt;code&gt;X = 7&lt;/code&gt; is the same as &lt;code&gt;7 = X&lt;/code&gt; and binds the variable X to the value 7.&lt;/p&gt;

&lt;p&gt;I am working my way through Van Roy and Haridi's &lt;i&gt;Concepts,
Techniques, and Models of Computer Programming&lt;/i&gt;, I recommend it
highly. I suspect that in time Oz may rival both C++ and Python as my
language of choice.&lt;/p&gt;

&lt;h2&gt;&lt;a href="http://www.ghg.net/clips/CLIPS.html"&gt;Clips&lt;/a&gt;&lt;/h2&gt;

&lt;p&gt;Clips is not billed as a language, but as an expert system shell.
Quoting from the &lt;i&gt;Clips User's Guide&lt;/i&gt;:

&lt;blockquote&gt;A program written in CLIPS may consist of rules,
facts, and objects. The inference engine decides which rules
should be executed and when. A rule-based expert system written
in CLIPS is a data-driven program where the facts, and objects if
desired, are the data that stimulate execution via the inference
engine.&lt;/blockquote&gt;

So a Clips program is quite a bit different from a program in most
other languages. Clips can be used standalone, but more often it is
embed in a C program.&lt;/p&gt;

&lt;h2&gt;ML: &lt;a href="http://caml.inria.fr/"&gt;Objective Caml&lt;/a&gt;,
&lt;a href="http://en.wikipedia.org/wiki/Standard_ML"&gt;SML&lt;/a&gt;,
&lt;a href="http://research.microsoft.com/fsharp/fsharp.aspx"&gt;F#&lt;/a&gt;,
&lt;a href="http://www.ps.uni-sb.de/alice/"&gt;Alice&lt;/a&gt;&lt;/h2&gt;

&lt;p&gt;ML is a polymorphicly typed, strict, impure functional programming
language that I have been playing with for a few years. It is strongly, statically typed, but the types are inferred,
not declared, meaning the programmer does not tell the system what the
types are, the compiler figures it out for itsself. The syntax takes
some getting use to, but I like the pattern matching syntax. ML seems
to be both safe and powerful, not any easy feat. Most of my
experience, and most of the literature, is in imperative programming;
and functional programming is significantly different. I suspect that
functional programming might be easier for a beginner to learn than
empirical programming (frequently writing a functional program is as
simple as restating the specification in the syntax of the language),
but it is not what I have studied and am use to. I am just starting to
learn the Camlp4 pre-processor, it seems to be a great tool.&lt;/p&gt;

&lt;h2&gt;&lt;a href="http://www.haskell.org/"&gt;Haskell&lt;/a&gt;&lt;/h2&gt;

&lt;p&gt;Haskell is a polymorphicly typed, lazy, purely functional
language. Since it is lazy, it does not evaluate function parameters
until they are needed. it is pure because it is stateless. I have not
done much with it yet, but I am going to because there are
several book on functional programming that I want to read that use
it.&lt;/p&gt;

&lt;h2&gt;Assembler&lt;/h2&gt;

&lt;p&gt;Assembler is not really one language, but a family of languages, one
for each CPU. 6800 Assembler was the first language I learned back in
the mid-1970's. Later I learned 6502, Z80, 8086 &amp;amp; 80386 Assembler.
Everyone should be required to learn assembler before they are allowed
to call themselves a programmer, because no mater what language you
write in, it will need to be translated into assembler (well actually
machine code, but no need to get technical) before it can run. If you
need to program directly to the hardware you need to do it in either
C, Forth, or Assembler and only assembler can give you total control.
Only Assembler can maximize performance, but this is often over rated
because the code is only as good as the programmer and a good
optimizing compiler is frequently better than the average assembler
programmer.&lt;/p&gt;

&lt;h2&gt;&lt;a href="http://www.digitalmars.com/d/index.html"&gt;D&lt;/a&gt;&lt;/h2&gt;

&lt;p&gt;D is intended to be the successor to C++. Like all the other
languages that try to be the next C++, it is garbage collected. I have
already expressed my doubts about garbage collection. But, D does
offer some real improvements including true modules, closures, lazy
evaluation, and design by contract. D does not support multiple
inheritance, but I think 90% all the cases where I might use multiple
inheritance can be covered by interfaces or mix-ins much more safely.
I think I could learn to like D, but I have not used it enough to say
for sure yet.&lt;/p&gt;

&lt;h2&gt;&lt;a href="http://scala.epfl.ch/"&gt;Scala&lt;/a&gt;&lt;/h2&gt;

&lt;p&gt;Scala is a very effective blend of functional, imperative and
object oriented techniques and has a practical minded design despite
supporting very advanced techniques. Scala's type system is based on
vObj, a calculus and dependent type system for objects and classes
which can have types as members. It runs on the JVM or .NET, I have
only used it on the JVM. It definitely offers a higher level of
abstraction than Java, but to deploy an applet you need to also deploy
the Scala run time system, which is not small, I'm not sure how big
a problem that is.&lt;/p&gt;

&lt;h2&gt;&lt;a href="http://boo.codehaus.org/"&gt;Boo&lt;/a&gt;&lt;/h2&gt;

&lt;p&gt;Boo is an object oriented statically typed programming language for
the Common Language Infrastructure with a python inspired syntax and a
special focus on language and compiler extensibility. &lt;a href="http://www.icsharpcode.net/OpenSource/SD/"&gt;#delelop&lt;/a&gt; supports Boo
out of the box, including a Boo interpreter window. Boo is staticly
typed but it also supports 'Duck typing' which basicly allows the type
to be tested at run time, not compile time. This seems to give the
best of both worlds. There is also a good macro system. I'm still
learning Boo, but so far I like it. I hope Boo becomes the langage of
choice of .NET development.&lt;/p&gt;

&lt;h2&gt;&lt;a href="http://www.php.net/"&gt;PHP&lt;/a&gt;&lt;/h2&gt;

&lt;p&gt;When I first learned PHP in the mid 1990's PHP was an acronym for &lt;i&gt;Personal Home Page&lt;/i&gt; now it has changed
to the recusive &lt;i&gt;PHP Hypertext Processor&lt;/i&gt;. It is primarily used
for server side web page programming, but it can be used from the
command line and there is a &lt;a href="http://www.gtk.org/"&gt;GTK+&lt;/a&gt;
interface to it (&lt;a href="http://gtk.php.net/"&gt;PHP-GTK&lt;/a&gt;). I used it
to write a few web pages in the mid to late 1990's. I think a good
stratagy for web page construction would be to code the static content
is &lt;a href="http://spyce.sourceforge.net/"&gt;Spyce&lt;/a&gt;, a python based
tool, code the dynamic servers side processing in PHP, because it runs
on most hosting servers, and code the client side DHTML code in
JavaScript. While I have used each of this componant parts I have
never put them together in this fasion. I hope to be doing so soon on my new website 
at &lt;a href='http://ed_keith.byethost18.com/'&gt;ed_keith.byethost18.com/&lt;/a&gt;.&lt;/p&gt;

&lt;h2&gt;&lt;a href="http://www.perl.com/"&gt;Perl&lt;/a&gt;&lt;/h2&gt;

&lt;p&gt;I have been required to use Perl for a couple of jobs, once for CGI in the late 1990's
and once for scripting a build system in the early 2000's. I do not like Perl. It is
almost as ugly as J and does not give me anything I can't get in any
number of other languages. There was a time when it might have been
worth using Perl to get its regular expressions, but now just about
any language offers Perl compatible regular expressions. I do have to admit that &lt;a href='http://www.cpan.org/'&gt;CPAN&lt;/a&gt; is impressive.&lt;/p&gt;

&lt;h2&gt;&lt;a href="http://www.w3.org/TR/xslt"&gt;XSLT&lt;/a&gt;&lt;/h2&gt;

&lt;p&gt;XML Style Language Transformations is used for transforming XML
documents. It is an XML application, and it is a Turing complete
language. I have only used it for a few simple things and have not
started to plumb it's depths. To get a glimpse of the depths see
&lt;a href="http://fxsl.sourceforge.net/"&gt;FXSL - the Functional
Programming Library for XSLT&lt;/a&gt;.&lt;/p&gt;

&lt;h2&gt;&lt;a href="http://www.cs.arizona.edu/icon/"&gt;Icon&lt;/a&gt;,
&lt;a href="http://unicon.sourceforge.net/"&gt;Unicon&lt;/a&gt;&lt;/h2&gt;

&lt;p&gt;I used Icon a bit in the mid 1980's I liked it, but for some reason
I drifted away from it, now most of the features I liked about it can
be found in Python. Unicon bills itself as the unified extended
dialect of Icon. It looks like it may be worth another look.&lt;/p&gt;

&lt;h2&gt;LISP:
&lt;a href="http://www.schemers.org/"&gt;Scheme&lt;/a&gt;,
&lt;a href="http://www.lisp.org/alu/home"&gt;Common Lisp&lt;/a&gt;&lt;/h2&gt;

&lt;p&gt;I first encountered Lisp in the mid 1980's when I read &lt;a href='http://people.csail.mit.edu/phw/Books/LISPBACK.HTML'&gt;&lt;i&gt;Lisp&lt;/i&gt;&lt;/a&gt; by Winston and Horn.
I used &lt;a href='http://www.mv.com/ipusers/xlisper/'&gt;XLISP&lt;/a&gt; in 1993 when I read &lt;i&gt;&lt;a href='http://books.google.com/books?id=Bhtxo60BV0EC&amp;pg=PP8&amp;lpg=PP8&amp;dq=genetic+programming+on+the+programming+of+computers+by+means+of+natural+selection+by+john+koza&amp;source=web&amp;ots=9mhOdxi1US&amp;sig=ZGcDFoagp1jPccp8dhrxP807krY'&gt;Genetic Programming: On the Programming of Computers by Means of Natural Selection&lt;/a&gt;&lt;/i&gt; by John Koza. 
Last year I read Hal Abelson's, Jerry 
Sussman's and Julie Sussman's &lt;a href="http://mitpress.mit.edu/sicp/"&gt; &lt;i&gt;
Structure and Interpretation of Computer Programs&lt;/i&gt;&lt;/a&gt; which 
is based on Scheme, if you have not read this book you should. I plan to read &lt;a href='http://www.gigamonkeys.com/book/'&gt;Practical Common Lisp&lt;/a&gt; by Peter Seibel this year.
&lt;/p&gt;

&lt;p&gt;Lisp is the second oldest language listed here, older than COBOL,
but not as old as Fortran, many people claim it is still the best
language around. Its greatest strength is also its greatest weakness,
its syntax. Generally I do not think syntax is nearly as important as
semantics, but I'm tempted to make an exception for Lisp. The syntax
of Lisp is so simple that it is easy to do metaprogamming for Lisp,
in Lisp. Therefor you can use the full power of Lisp to write macros
for Lisp. It is hard to comprehend how powerful this is unless you
have done it. Also, since the syntax is the same for data as for code
it is easy to write a program that writes code on the fly. On the flip
side the syntax can be infuriating. Many people claim Lisp is an
acronym for 'Lost In Stupid Parentheses'. Lisp has a reputation for
being inefficient, but with modern implementations this is no longer
true. Lisp is also the macro language for emacs, the gimp, and autoCAD.
&lt;/p&gt;

&lt;h2&gt;&lt;a href="http://en.wikipedia.org/wiki/Eiffel_programming_language"&gt;
Eiffel&lt;/a&gt;&lt;/h2&gt;

&lt;p&gt;Designed by Bertrand Meyer and featured in his excellent book
&lt;i&gt;Object-Oriented Software Construction&lt;/i&gt;, which I recomend to anyone working in any OO language, not just Eiffel. Eiffel is best known for
featuring Design By Contract in the core of the language. It has been
standardized as &lt;a href="http://www.ecma-international.org/publications/standards/Ecma-367.htm"&gt;
ECMA-367&lt;/a&gt; &amp; &lt;a href="http://www.iso.org/iso/en/CatalogueDetailPage.CatalogueDetail?CSNUMBER=42924&amp;amp;ICS1=35&amp;ICS2=60&amp;amp;ICS3="&gt;
ISO/IEC DIS 25436&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;&lt;a href="http://www.acm.org/sigada/education/"&gt;Ada&lt;/a&gt;&lt;/h2&gt;

&lt;p&gt;I worked through the &lt;a href='http://www.adahome.com/Tutorials/Lovelace/lovelace.htm'&gt;Lovelace tutorial&lt;/a&gt; in the mid 1990's. Ada has a bad reputation as &lt;i&gt;a language designed by a committee&lt;/i&gt; but the fact is that all language standards are written by committees. I have not used Ada much, but it seem to be pretty good. If I were in
charge of a very large scale project, I'd seriously consider using Ada.
&lt;/p&gt;

&lt;h2&gt;&lt;a href="http://en.wikipedia.org/wiki/Prolog"&gt;Prolog&lt;/a&gt;&lt;/h2&gt;

&lt;p&gt;Prolog (PROgramming in LOGic) is a logic programming language. A
prolog program is not composed of instructions to be executed, but of
a set of constraints to be solved. My first exposure prolog was in the
mid 1980's when I used it in an emergency room triage system. I used
it again in the early 1990's to validate data models. I have not used
it since, but am thinking of revisiting it because the LC++ library
uses a language that is semantical very similar to Prolog, and XPCE,
the GUI tool kit that is part of SWI Prolog, looks very interesting.
&lt;/p&gt;

&lt;h2&gt;&lt;a href="http://plg.uwaterloo.ca/~usystem/uC++.html"&gt;
μC++&lt;/a&gt;&lt;/h2&gt;

&lt;p&gt;μC++ extends C++ with advanced control-flow including
light-weight concurrency. It supports static multi-level exits from
nested loops, enhanced exception handling, coroutines, and concurrent
tasks. Unfortunatly it dose not suport MS-Windows at this time. I should look into how dificult it would be to port it. μC++ is featured in &lt;i&gt;Understanding Control Flow with Concurrent Programming using μC++&lt;/i&gt; by Peter A. Buhr, which is avalable in the μC++ web site. I strongly recomend all programmers read this paper, even if you have no interest in learning a new language, just to improve your understanding of control flow.&lt;/p&gt;

&lt;h2&gt;&lt;a href="http://en.wikipedia.org/wiki/Fortran"&gt;Fortran&lt;/a&gt;&lt;/h2&gt;

&lt;p&gt;To the best of my knowledge Fortran is the oldest language still in
use today. I first used it in 1979, it has changed a lot since then,
but nowhere near as much as BASIC. While many C programmers may have a
hard time accepting this, under some circumstances Fortran can be more
efficient than C. The reason for this is that due to Fortran's more
restrictive semantics the compiler may be better able to take advantage
of pipelining and concurrency.&lt;/p&gt;

&lt;h2&gt;&lt;a href="http://en.wikipedia.org/wiki/PLI"&gt;PL/I&lt;/a&gt;&lt;/h2&gt;

&lt;p&gt;I used PL/I in early 1980's, I've forgotten most of it, but as I
recall it was like Pascal on steroids. Anything you wanted to do, there
was a built in function to do it. I think the compiler was too big to be
ported to a microcomputer. Of course now microcomputers are more
powerful than the mainframe was them, but PL/1 was dead before that
happened.&lt;/p&gt;

&lt;h2&gt;Basic&lt;/h2&gt;

&lt;p&gt;It is hard to say anything meaningful about Basic. I learned BASIC
in the late 1970's, at that time BASIC was an unstructured language,
all flow control was done with goto's. When I used it again in the
late 1990's it was a structured language and I did not use a single
goto. The BASIC I used in the 1990's was like an untyped Pascal (I
know the phrase 'untyped Pascal' is heresy, but I can't think of a
better way of describing it.) Recently I have only used BASIC as the
macro language for Microsoft Office tools (Word, Excel and Access).
&lt;/p&gt;

&lt;h2&gt;&lt;a href="http://www.pascal-central.com/"&gt;Pascal&lt;/a&gt;,
&lt;a href="http://en.wikipedia.org/wiki/Delphi_programming_language"&gt;
Delphi&lt;/a&gt;&lt;/h2&gt;

&lt;p&gt;I first used Pascal in the early 1980's, and last used Delphi in
the late 1990's. Pascal is a nice, under rated language. It might have
become more popular than it is if Wirth had not tried to cripple it.
Like many students in the 1980's, I wrote a Pascal compiler as a class
project.&lt;/p&gt;

&lt;h2&gt;&lt;a href="http://www.modula2.org/"&gt;Modula 2&lt;/a&gt;&lt;/h2&gt;

&lt;p&gt;Wirth did not want Pascal to be extended to make it a useful
language to do real work in. He intended it to remain a toy language
for teaching and Modula 2 was to be the language do do real work in.
When I learned Modula 2, in the mid 1980's, I was used to Pascal, and
hated the fact that Modula 2 was case sensitive. Now I dislike
languages that are not case sensitive.&lt;/p&gt;

&lt;h2&gt;&lt;a href="http://www.sable.mcgill.ca/~hendren/AspectJ.html"&gt;
AspectJ&lt;/a&gt;,
&lt;a href="http://www.aspectc.org/"&gt;AspectC++&lt;/a&gt;,
&lt;a href="http://wwwiti.cs.uni-magdeburg.de/iti_db/forschung/fop/featurec/"&gt;
FeatureC++&lt;/a&gt;&lt;/h2&gt;

&lt;p&gt;AOP is a great idea, but these implementations of it are seriously
flawed. The all suffer from the same non-locality problem as exhibited
by Intercal's &lt;i&gt;come from&lt;/i&gt; statement. For more information read
&lt;i&gt;'AOP Considered Harmful'&lt;/i&gt; by Constantinos Constantinides, Therapon
Skotiniotis &amp; Maximilian Stoerzer. I highly recommend you read
Clarke &amp;amp; Baniassad's &lt;i&gt;Aspect-Oriented Analysis and Design: The
Theme Approach&lt;/i&gt; and use it's ideas in your analysis and design but
do the implementation in an OOP language until a better AOP is
developed. To see some ways to do this refer to Christopher Diggins'
&lt;a href="http://www.ddj.com/184405767"&gt;&lt;i&gt;Aspect-Oriented Programming
&amp; C++&lt;/i&gt;&lt;/a&gt; and the tutorial entitled &lt;i&gt;Aspect-Oriented
Programming with C++ and AspectC++&lt;/i&gt; which can be found at the
AspectC++ web site.&lt;/p&gt;

&lt;h2&gt;&lt;a href="http://op59.net/cmm/cmm-0.28/readme.html"&gt;Cmm&lt;/a&gt;,
&lt;a href="http://src.wongr.net/frost/"&gt;Frost&lt;/a&gt;&lt;/h2&gt;

&lt;p&gt;Cmm and Frost are two different extensions to C++ that add multiple
dispatch. C++ support single dispatch, meaning that the method called
can be determined at run time based on the type of the object the
method is invoked on. Multiple dispatch extends this to also allow
selection based on the types of the parameters. This eliminates the
need of visitor patterns. Cmm has a few additional features, the most
useful are embedded functions, allowing whole function definitions
inside expressions, and reflection. It also allows block structure
from indentation, like python, and an alternative declaration syntax.
&lt;/p&gt;

&lt;h2&gt;&lt;a href="http://www.mathworks.com/products/matlab/"&gt;Matlab&lt;/a&gt;,
&lt;a href="http://www.scilab.org/"&gt;Scilab&lt;/a&gt;,
&lt;a href="http://www.gnu.org/software/octave/"&gt;Octave&lt;/a&gt;&lt;/h2&gt;

&lt;p&gt;MatLab was developed as a substitute for Fortran that would be
easier for students to use. I used it on several projects in the mid
to late 1990's and early 2000's. Scilab and Octave are open source
clones of Matlab, each slightly different.&lt;/p&gt;

&lt;h2&gt;&lt;a href="http://mathsrv.ku-eichstaett.de/MGF/homes/grothmann/euler/"&gt;
Euler&lt;/a&gt;&lt;/h2&gt;

&lt;p&gt;Euler is similar to Matlab, but not a clone. One nice feature is
that you can embed yacas code in it.&lt;/p&gt;

&lt;h2&gt;&lt;a href="http://yacas.sourceforge.net/yacas.html"&gt;Yacas&lt;/a&gt;&lt;/h2&gt;

&lt;p&gt;Yacas (Yet Another Computer Algebra System) is, as the name
suggests, a computer algebra system. It is used to do symbolic math.&lt;/p&gt;

&lt;h2&gt;&lt;a href="http://www.maplesoft.com/"&gt;Maple V&lt;/a&gt;&lt;/h2&gt;

&lt;p&gt;Maple V is a language for doing symbolic math. I first used Maple V
in the early 1990's and have not used it extensively.&lt;/p&gt;

&lt;h2&gt;&lt;a href='http://www.wolfram.com/'&gt;Mathmatica&lt;/a&gt;&lt;/h2&gt;

&lt;p&gt;I used Mathmatica briefly in the early to mid 1990's. It is a powerful computer algebra systems. At that time it was a real memory hog and brought my PC to its knees.&lt;/p&gt;

&lt;h2&gt;&lt;a href="http://futureboy.homeip.net/frinkdocs/"&gt;Frink&lt;/a&gt;&lt;/h2&gt;

&lt;p&gt;Another mathematical language which distinguishes itself by its
support of dimensionality and units.&lt;/p&gt;

&lt;h2&gt;&lt;a href="http://www.forth.org/"&gt;Forth&lt;/a&gt;&lt;/h2&gt;

&lt;p&gt;Forth is a very small language, it has even be written into the
microcode of some CPU's. I first heard of Forth when I heard that the
controllers used to control the cameras and models to create the special
effects in the first star wars movie were programmed in Forth. The
best thing about Forth is Leo Brodie's &lt;i&gt;
&lt;a href="http://home.iae.nl/users/mhx/sf.html"&gt;Starting Forth&lt;/a&gt;&lt;/i&gt;
which is arguably the best programming language book ever written! I
learned Forth in the early 1980's. I even wrote a simple version of
Forth in Z80 assembler.&lt;/p&gt;

&lt;h2&gt;&lt;a href="http://en.wikipedia.org/wiki/COBOL"&gt;COBOL&lt;/a&gt;&lt;/h2&gt;

&lt;p&gt;COBOL (COmmon Business-Oriented Language) is the third oldest
language on this page (after FORTRAN and LISP) and there are probably
more COBOL programs running at this moment that FORTRAN and LISP
combined. What gives COBOL its staying power? I don't know, but I
suspect decimal arithmetic is part of the answer. I think COBOL is the
only language listed here that does decimal arithmetic out of the box
(there are some good C++ class libraries for decimal arithmetic, but
they are not standard).&lt;/p&gt;

&lt;h2&gt;&lt;a href="http://www.rexxla.org/"&gt;Rexx&lt;/a&gt;&lt;/h2&gt;

&lt;p&gt;I read somewhere that there are more lines of Rexx code in
existence than there are of COBOL, that is quite a claim. I used it as
the primary scripting language for OS/2 and as the macro language for
the Kedit editor. I have not used Rexx Since I gave up both OS/2 and
Kedit in the late 1990's.&lt;/p&gt;

&lt;h2&gt;xBase: &lt;a href="http://www.dbase.com/"&gt;dBase&lt;/a&gt;,
&lt;a href="http://en.wikipedia.org/wiki/Clipper_programming_language"&gt;
Clipper&lt;/a&gt;,
&lt;a href="http://www.harbour-project.org/"&gt;Harbor&lt;/a&gt;
&lt;a href="http://www.xharbour.org/"&gt;xHarbor&lt;/a&gt;&lt;/h2&gt;

&lt;p&gt;I used dBase in the mid 1980's and Clipper in the early 1990's. It
is a good environment for small to mid sized database applications. I
thought that it was dead, but I see that dBase is still available and
that there are three open source Clipper compilers available. I'll keep
them in mind next time I need to created a small database application.&lt;/p&gt;

&lt;h2&gt;&lt;a href="http://en.wikipedia.org/wiki/SQL"&gt;SQL&lt;/a&gt;&lt;/h2&gt;

&lt;p&gt;SQL fails to properly capture the relational data model as
expresses in relational calculus, but it is ubiquitous. If you are
going to develop databases you need to know SQL (you should also know
relational calculus). I've been using SQL since 1990.&lt;/p&gt;

&lt;h2&gt;&lt;a href="http://www.suneido.com/"&gt;Suneido&lt;/a&gt;&lt;/h2&gt;

&lt;p&gt;Suneido has some good ideas. It looks like a well designed language
that captures the relational model better than SQL. But I have a big
problem with it. The program is stored in the database file! This
causes several problems. First, you need to write the program in the
IDE, you are not free to use the editor of your choice. This is
inconvenient, but I can live with it. The more important problems are
that since all the code lives in the same file it is difficult for a
team to work on it and version control is a nightmare. The application,
test data, and unit tests all are in the same file. I'll let you
imagine the trouble that can cause. Deploying an update to an existing
system with live data in the database is not easy since you need to
replace part of the file, but not other parts. All in all while there
are many good things to be said for this language, it is far more
trouble than it is worth.&lt;/p&gt;

&lt;h2&gt;PC Focus&lt;/h2&gt;

&lt;p&gt;I worked with PC Focus in the late 1980's. It was a hierarchical
database language. I do not know whether it still exists.&lt;/p&gt;

&lt;h2&gt;&lt;a href="http://en.wikipedia.org/wiki/PostScript"&gt;
PostScript&lt;/a&gt;&lt;/h2&gt;

&lt;p&gt;Many programmers are not even aware that PostScript is a full blown
programming language, it is a dialect of FORTH. If you have never
programmed in PostScript you may want to try it.&lt;/p&gt;

&lt;h2&gt;&lt;a href="http://www.tcl.tk/"&gt;tcl&lt;/a&gt;&lt;/h2&gt;

&lt;p&gt;Tcl (Tool Command Language) syntax resembles Lisp, but its
semantics are no where near as expressive as Lisp. I think the only
reasons anyone ever used tcl was for tk and expect. You can now use tk
from almost any language, But while there have been two attempts to
create a version of expect for python, neither one ever worked properly
to my knowledge, so you still need to learn tcl if want to use expect.
&lt;/p&gt;

&lt;h2&gt;&lt;a href="http://www2.blogger.com/"&gt;ISETL&lt;/a&gt;&lt;/h2&gt;

&lt;p&gt;ISETL (Interactive SET Language) is an interpreted mathematical
programming language closely resembling the language of sets and
functions used by Mathematicians. I used ISETL when I was working my
way through &lt;i&gt;Learning Discreete Mathematics with ISETL&lt;/i&gt; by
Baxter, Dubinsky &amp;amp; Levin some time in the 1990's.&lt;/p&gt;

&lt;h2&gt;&lt;a href='http://www.snobol4.org/'&gt;SNOBOL&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;SNOBOL stands for StriNg Oriented symBOlic Language, is a language for text processing and pattern matching. I used SNOBOL briefly in the early 1980's. It had some nice features, but its lack of high level control structures turned me off and I quickly moved to Icon.&lt;/p&gt;

&lt;h2&gt;&lt;a href="http://www.catb.org/~esr/intercal/"&gt;Intercal&lt;/a&gt;&lt;/h2&gt;

&lt;p&gt;No list of programming languages would be complete without Intercal.
INTERCAL is purposely different from all other computer languages.
Based on the well-known and oft-demonstrated fact that a person whose
work is incomprehensible is held in high esteem, intercal is designed
to make any program incomprehensible. (I sometimes think Perl and J
are based on the same philosophy). Someday I'm going to write a
useful program in Intercal, just to say I did. I'm sure developing
something complex in intercal would change the way you think.
&lt;/p&gt;

&lt;h2&gt;Other&lt;/h2&gt;

&lt;p&gt;I have also used MS-DOS batch language, Unix Shell scripts, lex, yacc, and the
macro languages for many applications including MS-Word 2, Word Perfect,
and the Brief &amp;amp; VIM editors.&lt;/p&gt;

&lt;p&gt;There are several Languages I have not used yet, but interest me:

&lt;dl&gt;
&lt;dt&gt;&lt;a href="http://www.ruby-lang.org/en/"&gt;Ruby&lt;/a&gt;&lt;/dt&gt;
&lt;dd&gt;Ruby looks like Perl done right. I first looked at Ruby many
years ago, but at that time all the documentation was in Japanese.
Now there is plenty of English documentation, so It is time to
give it a second look.&lt;/dd&gt;

&lt;dt&gt;&lt;a href="http://q-lang.sourceforge.net/"&gt;Q&lt;/a&gt;&lt;/dt&gt;
&lt;dd&gt;Q is a functional programming language based on term
rewriting.&lt;/dd&gt;

&lt;dt&gt;&lt;a href="http://www.erlang.org/"&gt;Erlang&lt;/a&gt;&lt;/dt&gt;
&lt;dd&gt;A functional language that supports fine grained concurrency,
transparent distribution, fault detection, persistence, and hot
code replacement. The &lt;a href='http://yaws.hyber.org/'&gt;YAWS&lt;/a&gt; 
web server and &lt;a href='http://erlyweb.org/'&gt;ErlyWeb&lt;/a&gt; web 
development framework look very promising for developing web 
services.&lt;/dd&gt;

&lt;dt&gt;&lt;a href="http://nemerle.org/Main_Page"&gt;Nemerle&lt;/a&gt;&lt;/dt&gt;
&lt;dd&gt;Nemerle is a high-level statically-typed programming language
for the .NET platform. It offers functional, object-oriented and
imperative features. It has a simple C#-like syntax and a powerful
meta-programming system.&lt;/dd&gt;

&lt;dt&gt;&lt;a href="http://www.lua.org/"&gt;Lua&lt;/a&gt;&lt;/dt&gt;
&lt;dd&gt;Lua is a powerful light-weight programming language. It
combines simple procedural syntax with powerful data description
and extensible semantics.&lt;/dd&gt;

&lt;dt&gt;&lt;a href="http://www.iolanguage.com/"&gt;Io&lt;/a&gt;&lt;/dt&gt;
&lt;dd&gt;Io is a small, prototype-based programming language.&lt;/dd&gt;

&lt;dt&gt;&lt;a href="http://www.latrobe.edu.au/philosophy/phimvt/joy.html"&gt;
Joy&lt;/a&gt;&lt;/dt&gt;
&lt;dd&gt;Joy is a functional programming language which is not based on
the application of functions to arguments but on the composition
of functions.&lt;/dd&gt;

&lt;dt&gt;&lt;a href="http://www.canonware.com/onyx/"&gt;Onyx&lt;/a&gt;&lt;/dt&gt;
&lt;dd&gt;Onyx is a powerful stack-based, multi-threaded, interpreted,
general purpose programming language similar to PostScript.&lt;/dd&gt;

&lt;dt&gt;&lt;a href="http://www.cs.mu.oz.au/research/mercury/"&gt;
Mercury&lt;/a&gt;&lt;/dt&gt;
&lt;dd&gt;Mercury is a logic/functional programming language, which
combines the clarity and expressiveness of declarative programming
with advanced static analysis and error detection features. Its
highly optimized execution algorithm delivers efficiency close to
conventional programming systems. Mercury addresses the problems
of large-scale program development, allowing modularity, separate
compilation, and numerous optimization/time trade-offs.&lt;/dd&gt;

&lt;dt&gt;&lt;a href='http://flora.sourceforge.net/'&gt;FLORA-2&lt;/a&gt;&lt;/dt&gt;
&lt;dd&gt;FLORA-2 is an advanced object-oriented knowledge base language and application development environment. The language of FLORA-2 is a dialect of F-logic with numerous extensions, including meta-programming in the style of HiLog and logical updates in the style of Transaction Logic. FLORA-2 was designed with extensibility and flexibility in mind, and it provides strong support for modular software design through its unique feature of dynamic modules.&lt;/dd&gt;


&lt;dt&gt;&lt;a href="http://en.wikipedia.org/wiki/Dylan_programming_language"&gt;
Dylan&lt;/a&gt;&lt;/dt&gt;
&lt;dd&gt;Dylan (DYnamic LANguage) is a multi-paradigm language that
includes support for functional and object-oriented programming,
and is dynamic and reflective while providing a programming model
designed to support efficient machine code generation.&lt;/dd&gt;

&lt;dt&gt;&lt;a href="http://factorcode.org/"&gt;Factor&lt;/a&gt;&lt;/dt&gt;
&lt;dd&gt;Factor is a dynamically typed, stack-based programming language.&lt;/dd&gt;

&lt;dt&gt;&lt;a href="http://www.heron-language.com/"&gt;Heron&lt;/a&gt;&lt;/dt&gt;
&lt;dd&gt;Reading the creator's blog, it looks like he and I have similar
views of we want in a programming language. It looks like Heron
may be my idea of a replacement for C++.&lt;/dd&gt;

&lt;dt&gt;&lt;a href="http://felix.sourceforge.net/"&gt;Felix&lt;/a&gt;&lt;/dt&gt;
&lt;dd&gt;Felix is an advanced Algol like procedural programming
language with a strong functional subsystem. It features ML style
static typing, first class functions, pattern matching, garbage
collection, polymorphism, and has built in support for high
performance microthreading, regular expressions and context free
parsing.&lt;/dd&gt;

&lt;dt&gt;&lt;a href="http://www.cat-language.com/"&gt;Cat&lt;/a&gt;&lt;/dt&gt;
&lt;dd&gt;The Cat language is a pure functional language, inspired by
Joy. All constructs in Cat behave as functions which takes a
single stack as input and returns a new stack. Cat not only has no
variable declaration, there are no argument declarations.&lt;/dd&gt;

&lt;dt&gt;&lt;a href="http://www.icsi.berkeley.edu/~sather/"&gt;Sather&lt;/a&gt;&lt;/dt&gt;
&lt;dd&gt;Sather is an object oriented language designed to be simple,
efficient, safe, flexible and non-proprietary. One way of placing
it in the "space of languages" is to say that it aims to be as
efficient as C, C++, or Fortran, as elegant as and safer than
Eiffel, and support higher-order functions and iteration
abstraction as well as Common Lisp, CLU or Scheme.&lt;/dd&gt;

&lt;dt&gt;&lt;a href="http://www.squeak.org/"&gt;Squeak&lt;/a&gt;&lt;/dt&gt;
&lt;dd&gt;Squeak is a popular dialect of SmallTalk. The IDE looks a bit
strange. I find &lt;a href="http://www.opencroquet.org/index.html"&gt;
Croquet&lt;/a&gt; particularly interesting.&lt;/dd&gt;

&lt;dt&gt;&lt;a href="http://www.strongtalk.org/"&gt;StrongTalk&lt;/a&gt;&lt;/dt&gt;
&lt;dd&gt;StrongTalk is a strong static typed dialect of SmallTalk.&lt;/dd&gt;

&lt;dt&gt;&lt;a href="http://www.stratego-language.org/Stratego/WebHome"&gt;
Stratego&lt;/a&gt;&lt;/dt&gt;
&lt;dd&gt;Stratego is a modular language for the specification of fully
automatic program transformation systems based on the paradigm of
rewriting strategies.&lt;/dd&gt;

&lt;dt&gt;&lt;a href="http://nice.sourceforge.net/"&gt;Nice&lt;/a&gt;&lt;/dt&gt;
&lt;dd&gt;Nice extends the ideas behind object-orientation in order to
better support modular programming and static type safety. It also
incorporates features from functional programming. It is one of
the few languages that support multi-methods&lt;/dd&gt;

&lt;dt&gt;&lt;a href="http://www.ava.fmi.fi/prog/tela.html"&gt;TeLa&lt;/a&gt;&lt;/dt&gt;
&lt;dd&gt;Tela (TEnsor LAnguage) is a scientific computing language and
environment. It is mainly targeted for prototyping large-scale
numerical simulations and doing pre- and post-processing for them.
&lt;/dd&gt;

&lt;dt&gt;&lt;a href="http://www.maumae.net/yorick/doc/index.php"&gt;
Yoric&lt;/a&gt;&lt;/dt&gt;
&lt;dd&gt;Yorick is an interpreted programming language, designed for
postprocessing or steering large scientific simulation codes. The
language features a compact syntax for many common array
operations, so it processes large arrays of numbers very
efficiently. Superficially, yorick code resembles C code, but
yorick variables are never explicitly declared and have a dynamic
scoping similar to many Lisp dialects.&lt;/dd&gt;

&lt;dt&gt;&lt;a href="http://pari.math.u-bordeaux.fr/"&gt;Pari/GP&lt;/a&gt;&lt;/dt&gt;
&lt;dd&gt;PARI/GP is a specialized computer algebra system, primarily
aimed at number theorists, and for speed.&lt;/dd&gt;

&lt;dt&gt;&lt;a href="http://www-gap.mcs.st-and.ac.uk/"&gt;GAP&lt;/a&gt;&lt;/dt&gt;
&lt;dd&gt;GAP (Groups, Algorithms and Programming) is a system for
computational discrete algebra, with particular emphasis on
Computational Group Theory.&lt;/dd&gt;

&lt;dt&gt;&lt;a href="http://lush.sourceforge.net/"&gt;Lush&lt;/a&gt;&lt;/dt&gt;
&lt;dd&gt;Lush is an object-oriented programming language for
large-scale numerical and graphic applications.&lt;/dd&gt;

&lt;dt&gt;&lt;a href='http://withglee.com/'&gt;Glee&lt;/a&gt;&lt;/dt&gt;
&lt;dd&gt;Glee, like J, is derived from APL. it looks like it handles files and string much better than J.&lt;/dd&gt;

&lt;dt&gt;&lt;a href='http://www.nial.com/'&gt;Nial&lt;/a&gt;&lt;/dt&gt;
&lt;dd&gt;NIAL, which stands for the Nested Interactive Array Language, is also derived from APL. It claims to combine some of the best features of functional and procedural programming.&lt;/dd&gt;

&lt;dt&gt;&lt;a href='http://www.vitanuova.com/inferno/limbo.html'&gt;Limbo&lt;/a&gt;&lt;/dt&gt;
&lt;dd&gt;Limbo is the application programming language for &lt;a href='http://www.vitanuova.com/inferno/index.html'&gt;Inferno&lt;/a&gt;. Like Java, Limbo is compiled to architecture-independent object code which is then interpreted by the Dis virtual machine or JIT compiled. Communication channel is a primitive data type in Limbo.&lt;/dd&gt;


&lt;/dl&gt;

&lt;h1&gt;Conclusions&lt;/h1&gt;

&lt;p&gt;A good craftsman needs many tools in his tool box. A good
programmer needs to be able to use many languages. I find myself
reaching for C++ or Python first for most tasks. This changes over
time, at various time in the past I might have picked, Pascal, C,
Rexx or Icon, in the future I my pick D, Oz, Objective Caml, Alice ML, Scala,
Boo, Heron or Unicon. If I'm accessing a database I use SQL, for DHTML
I use JavaScript, I do not have much choice in either case. If I'm
writing an expert system I'd use Clips. If I'm crunching numbers I'd
pick J, R, Euler or a MatLab clone.&lt;/p&gt;

&lt;p&gt;So the question many people want me to answer here will be
&lt;i&gt;'What is the best language?'&lt;/i&gt; but that is a question that has no answer.
Every language represents trade offs, as a results each language has
both strengths and weaknesses. With the possible exception of Intercal,
there is probably some task for which any language you chose will be
best suited for (if you need to write a program to print the full
lyrics to the song &lt;i&gt;99 Bottles of Beer on the Wall&lt;/i&gt; then &lt;a href="http://en.wikipedia.org/wiki/HQ9+"&gt;HQ9+&lt;/a&gt; might be a good choice,
even though it is not Turing Complete).&lt;/p&gt;

&lt;p&gt;The secret of successful program design is to work at the highest
level of abstraction possible at all times. For this reason you should
always work with the language which offers the best high level
abstraction of the problem domain. If the problem is mathematical in
nature use J, R, Yacas or another mathematical language. If the problem
involves manipulating relational data tables use SQL, Suneido, or
xBase. If the problem involves graphic layout use PostScript. If the
problem is to directly control computer hardware you will need to use
C, Forth or Assembler. If you are developing an Expert system you
should use Clips. If you are solving a logic problem use Prolog, Mercury, or Oz.
In most cases there will not be an existing language which embodies
the necessary abstraction so you will need to develop your own
abstraction in the language you chose, so choose a language which will
make developing an abstraction easy, such as C++, Oz, Scala, Nice, Heron,
Boo, Nemerle, Unicon, etc.&lt;/p&gt;

&lt;p&gt;I recommend that all programmers learn C, C++, Assembler, and some
dialect of Lisp. I do not recommend C or C++ as a first language, and a
strong case can be made against Assembler or Lisp as a first language,
although Assembler was my first language, and many people recommend
Scheme as a first language. Pascal is a good first language, it was
designed for teaching. I have heard good things about &lt;a href="http://www.rapideuphoria.com/"&gt;Euphoria&lt;/a&gt; as a first language, but
have no experience with it. A dilect of ML might be a good first
language, but I'm not sure.&lt;/p&gt;

&lt;p&gt;For a chuckle see
&lt;a href="http://www.netfunny.com/rhf/jokes/88q2/3785.4.html"&gt;
http://www.netfunny.com/rhf/jokes/88q2/3785.4.html&lt;/a&gt; or
&lt;a href="http://www.cs.caltech.edu/~mvanier/hacking/rants/cars.html"&gt;
http://www.cs.caltech.edu/~mvanier/hacking/rants/cars.html&lt;/a&gt;.
&lt;/p&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/38087982-116948616642501452?l=edkeith.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://edkeith.blogspot.com/feeds/116948616642501452/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=38087982&amp;postID=116948616642501452' title='7 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/38087982/posts/default/116948616642501452'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/38087982/posts/default/116948616642501452'/><link rel='alternate' type='text/html' href='http://edkeith.blogspot.com/2007/01/programming-languages.html' title='Programming Languages'/><author><name>Ed</name><uri>http://www.blogger.com/profile/13325146756422019012</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>7</thr:total></entry><entry><id>tag:blogger.com,1999:blog-38087982.post-116628191421465310</id><published>2006-12-16T15:06:00.000Z</published><updated>2006-12-16T16:53:48.906Z</updated><title type='text'>New Blog</title><content type='html'>&lt;blockquote&gt;&lt;pre&gt;
"The time has come," the Walrus said,
"To talk of many things:
Of shoes--and ships--and sealing-wax--
Of cabbages--and kings--
And why the sea is boiling hot--
And whether pigs have wings."
 -- Lewis Carroll
&lt;/pre&gt;
&lt;/blockquote&gt;

&lt;p&gt;
This is the start of my new blog. Since I am just starting, I do not know what I will be talking of yet. I'm sure a lot of space will be devoted to software development, since I spend a lot of time doing it. Other subjects that will probably show up are aikido, self defense, traditional Chinese medicine, and book reviews.
&lt;/p&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/38087982-116628191421465310?l=edkeith.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://edkeith.blogspot.com/feeds/116628191421465310/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=38087982&amp;postID=116628191421465310' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/38087982/posts/default/116628191421465310'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/38087982/posts/default/116628191421465310'/><link rel='alternate' type='text/html' href='http://edkeith.blogspot.com/2006/12/new-blog.html' title='New Blog'/><author><name>Ed</name><uri>http://www.blogger.com/profile/13325146756422019012</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry></feed>
