Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.soft-sys.math.mathematica > #3232
| From | Richard Fateman <fateman@cs.berkeley.edu> |
|---|---|
| Newsgroups | comp.soft-sys.math.mathematica |
| Subject | Re: Again : Is there a BNF for Mathematica? |
| Date | 2011-06-22 07:44 +0000 |
| Organization | Steven M. Christensen and Associates, Inc and MathTensor, Inc. |
| Message-ID | <its6hn$60e$1@smc.vnet.net> (permalink) |
| References | <irijpq$qf8$1@smc.vnet.net> |
On 5/25/2011 2:57 AM, E. Martin-Serrano wrote: ... stuff about parsing ... 1. BNF can be used to describe a context-free language. 2. The Mathematica language is not context free, and thus cannot be described completely in BNF. 3. If you need to parse Mathematica expressions and you have a Mathematica system around, you can simply use it to convert the expressions to FullForm, which is easily re-parsed (and does have a BNF). 4. If you do not have a Mathematica around, there are (free) programs that will parse Mathematica into something equivalent to FullForm. 5. Your ideas about what you would do if you had a BNF for Mathematica seem to conflate syntax with semantics (evaluation) and, so far as I can tell, do not seem to make sense. If you wish to do experiments with programming language transformations, you can easily learn about other programming languages that are (a) well-defined (b) much more popular (c) can be described by BNF (d) are susceptible to transformations into the same language for efficiency or readability or program proofs or other purposes. There is a substantial literature on such subjects. I suspect that Mathematica has little or nothing to add to the discussion, and in my opinion certainly does not have enough value added to compensate for its complexity syntactically or semantically. For example, do you think that you fully understand the matching process at the core of the rule-based transformation system that underlies Mathematica evaluation? Can you really demonstrate that two non-trivial Mathematica "programs" compute the same thing? RJF
Back to comp.soft-sys.math.mathematica | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
Again : Is there a BNF for Mathematica? "E. Martin-Serrano" <eMartinSerrano@telefonica.net> - 2011-05-25 09:57 +0000
Re: Again : Is there a BNF for Mathematica? David Bailey <dave@removedbailey.co.uk> - 2011-05-25 23:33 +0000
Re: Again : Is there a BNF for Mathematica? Richard Fateman <fateman@cs.berkeley.edu> - 2011-06-22 07:44 +0000
Re: Again : Is there a BNF for Mathematica? Szabolcs Horvát <szhorvat@gmail.com> - 2011-06-22 11:29 +0000
Re: Again : Is there a BNF for Mathematica? Richard Fateman <fateman@cs.berkeley.edu> - 2011-06-23 11:34 +0000
Re: Again : Is there a BNF for Mathematica? "E. Martin-Serrano" <eMartinSerrano@telefonica.net> - 2011-06-24 11:44 +0000
csiph-web