I have some comments in addition to R.E.Boss's comments
(and using his M)
M=:1 _1 0 1,1 1 _1 1,:0 1 0 _1
A simple approach to supressing fill uses box (<) followed
by raze (;). In other words:
<@(_1 1 (] i.&0)}"0 1 ])`<@.(# = i.&0)"1 M
+---------+--------+---------+
|1 _1 _1 1|1 1 _1 1|_1 1 0 _1|
|1 _1 1 1| | 1 1 0 _1|
+---------+--------+---------+
;<@(_1 1 (] i.&0)}"0 1 ])`<@.(# = i.&0)"1 M
1 _1 _1 1
1 _1 1 1
1 1 _1 1
_1 1 0 _1
1 1 0 _1
However, J currently does does not have special
code for this pattern, so you might instead delete
your fills (caution: I have not actually tested this
so this might be either slower or faster):
,/(_1 1 (] i.&0)}"0 1 ])[EMAIL PROTECTED](# = i.&0)"1 M
1 _1 _1 1
1 _1 1 1
1 1 _1 1
0 0 0 0
_1 1 0 _1
1 1 0 _1
(-. 1{.0#]),/(_1 1 (] i.&0)}"0 1 ])[EMAIL PROTECTED](# = i.&0)"1 M
1 _1 _1 1
1 _1 1 1
1 1 _1 1
_1 1 0 _1
1 1 0 _1
You have some other possibilities, too. For example:
;((+ <@:~.@:,: -)"1 =&0)M
--
Raul
----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm