I'm working with output from a CAS so there is no ambiguity. Thanks for the article, interesting read.
On Thu, Aug 1, 2013 at 7:58 PM, Roger Hui <[email protected]> wrote: > A problem with "paper math" is that the rules are ambiguous. For example, > in ab+ba do you interpret ab as the name ab or as a times b? > > See Ken Iverson's *Conventions Governing Order of > Evaluation<http://www.jsoftware.com/papers/EvalOrder.htm> > *from 1966. > > > On Thu, Aug 1, 2013 at 9:40 AM, EelVex <[email protected]> wrote: > > > Hi bob, > > that's the problem (I think I was not clear): I want to read the output > > from another program that makes symbolic calculations and I don't want to > > have to read huge expressions just to parenthesise them correctly. > > > > > > On Thu, Aug 1, 2013 at 7:31 PM, bob therriault <[email protected] > > >wrote: > > > > > Hi Eelvex, > > > > > > I think that the monadic primitive Do (".) may be the answer, although > > you > > > would need to use parenthesis to get the order of execution that you > > would > > > like. > > > > > > a=.2 > > > b=.3 > > > ".'a*b+b*a' > > > 18 > > > ".'(a*b)+b*a' > > > 12 > > > > > > Cheers, bob > > > > > > On 2013-08-01, at 9:22 AM, EelVex wrote: > > > > > > > Is there a verb in the library to read "paper math" into J > expressions? > > > > > > > > Eg. > > > > a =: 2 > > > > b =: 3 > > > > read 'a * b + b * a' > > > > 12 > > > > > ---------------------------------------------------------------------- > > > > For information about J forums see > http://www.jsoftware.com/forums.htm > > > > > > ---------------------------------------------------------------------- > > > For information about J forums see http://www.jsoftware.com/forums.htm > > > > > ---------------------------------------------------------------------- > > For information about J forums see http://www.jsoftware.com/forums.htm > > > ---------------------------------------------------------------------- > For information about J forums see http://www.jsoftware.com/forums.htm > ---------------------------------------------------------------------- For information about J forums see http://www.jsoftware.com/forums.htm
