Example=: 1 :0
:
(u x) + u y
)
You put the monadic case before the : and the dyadic case after. If
you want to do that on one line:
1 :(':'; '(u x) + u y')
--
Raul
On Tue, Feb 14, 2012 at 2:12 PM, Edward Mokurai Cherlin
<[email protected]> wrote:
> I am unable to determine how to write an explicit J adverb that
> produces a dyadic verb. There is an example of an explicit conjunction
> at
>
> http://www.rogerstokes.free-online.co.uk/13.htm
>
> H =: 2 : 0
> :
> (u x) + (v y)
> )
> 2 (*: H %:) 16
> 8
>
> and other such constructions work with no problems.
>
> However,
>
> a=.1 : 0
> :
> x u y
> )
> |spelling error
> | x u y
> | ^
> | a=. 1 :0
>
> a=.1 : 'x u y'
> a
> 1 : 'x u y'
> 2 +a 3
> |domain error
> | 2 +a 3
>
> Of course, I could write
>
> a=.1 : '[ u ]'
>
> but that would require reordering topics in the J version of Iverson's
> Algebra: An Algorithmic Treatment that I am editing, and would still
> leave the mystery.
> --
> Edward Mokurai (默雷/धर्ममेघशब्दगर्ज/دھرممیگھشبدگر ج) Cherlin
> Silent Thunder is my name, and Children are my nation.
> The Cosmos is my dwelling place, the Truth my destination.
> http://wiki.sugarlabs.org/go/Replacing_Textbooks
> ----------------------------------------------------------------------
> For information about J forums see http://www.jsoftware.com/forums.htm
----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm