I don't have access to the paper, but assuming:

   BV    is  a boolean vector
   Z     is  a rank 2 array
   \     is  the scan/expand symbol
   []IO  is  1

Then the expression   BV \[2] Z  expands Z.  That is, it inserts a fill row 
(all spaces) in  Z  at each  0  in BV.  The mnemonic is  \  (expand) is "the 
opposite" of  /  (compress).  Similarly, in J, the equivalent is:

              BV #^:_1 Z

           1 0 1 #^:_1 >;:'Howdy pardner'   
        Howdy  
               
        pardner

another option is:

              BV (#~ ] (1 j.#);._1~ 1: 0} ])~ Z

           1 0 1 (#~ ] (1 j.#);._1~ 1: 0} ])~ > ;:'Howdy pardner'
        Howdy  
               
        pardner
           
I'm not really sure when it's better to use  #^:_1  with a boolean LHA vs  #  
with a complex LHA.

-Dan


----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm

Reply via email to