Maybe something like this?
  13 : '25,~y*>:y'
25 ,~ ] * >:
  (13 : '25,~y*>:y') 3
12 25

These sutras look like shortcuts for doing arithmetic by hand - any
reason to automate manual shortcuts?

On 6/9/07, Terrence Brannon <[EMAIL PROTECTED]> wrote:

I am trying to implement some simple vedic math formulas as shown here
http://www.vedamu.org/Mathematics/MathematicalFormulae/Sutras/sutras.asp

and

sq5 =:  (] * (] + 1)) , (*: 5)

leads to syntax errors. The implicit one generated by J looks much the
same:

sq5 =: 3 : '(y * (y+1)) , (*: 5)'
   sq5 22
506 25
   sq5 =: 13 : '(y * (y+1)) , (*: 5)'

except is uses flip for some reason... help appreciated.

--
HIV/AIDS on trial - http://www.aliveandwell.org/
Let's play chess: http://www.SlowChess.com
----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm




--
Devon McCormick, CFA
^me^ at acm.
org is my
preferred e-mail
----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm

Reply via email to