sinc(x) -- defining evaluating and simplifying operations
Subject: sinc(x) -- defining evaluating and simplifying operations
From: Richard Fateman
Date: Sun, 07 Dec 2003 09:01:21 -0800
Stavros Macrakis wrote:
>
>
>All of these issues have long histories, and are not as trivial as you
>might think.
>
> -s
>
Most of these issues also have long futures. They reappear in
subsequent computer algebra
system designs such as Maple and Mathematica, which each have several
notions of
equality, and have special rules for evaluation of some of the arguments
of "functions" like
sum, product, solve....
Regarding a model for evaluation, Mathematica is worth examining, if
only for a reminder
of how difficult it is to do this right.
Mathematica has attributes for some functions named "HoldFirst"
or "HoldAll" and operations that un-do these settings. It also has
two kinds of
binding of the lambda-binding sort attempting to imitate (incorrectly)
lexical and
dynamic scope by patterns.
Mathematica tries to put all the semantics of the programming language
and evaluation
into a single framework, namely pattern-matching and rule application.
However,
the number of people who actually understand all the nuances of this
model are
very small. (Perhaps 0.0001 percent of users?) Thus most people have
ad hoc
mental heuristics of how programs work, and these are sometimes wrong.
Having
a clear model is easy. Just take Scheme, a dialect of lisp. Having a
clear and
intuitive model for mathematicians seems to elude us. Probably because
mathematicians
don't have an unambiguous model, and only those seriously committed to
computer
programs as a vehicle for further understanding can be bothered to learn
a different
model.
There is a book on Classical Mechanics by
Sussman and Wisdom which uses Scheme---
.. from a review in American Scientist...
Not all of the mathematics takes the form of Scheme programs. There is
also much that appears on first glance to be written in conventional
notation. On closer examination, however, the equations turn out to have
a slightly unusual form. They follow a carefully restricted syntax and
semantics, allowing a one-to-one mapping between mathematical and Scheme
expressions.
One aim of writing in such a computer-parsable language is to cleanse
the notation of ambiguities. Sussman and Wisdom report that they found
the task harder than they expected, but illuminating. "We quickly
learned that many things we thought we understood we did not in fact
understand. Our requirement that our mathematical notations be explicit
and precise enough that they can be interpreted automatically, as by a
computer, is very effective in uncovering puns and flaws in reasoning."
http://www.americanscientist.org/template/BookReviewTypeDetail/assetid/17676