Here's a way to look inside a 5x5x5 color cube. There are 125 colors.  Any
ideas to do it more simply or in a better image?

 

load 'viewmat'

A=:#:i.8

N=:<.63.75*i.5

B=:((4#0),N),.N,4#255

BIGBOX=:<"2(|."2)1 0 2{"1(|:"2)8 3 9$,|:(,A){"1 B

'BLACK BLUE RED MAGENTA GREEN CYAN YELLOW WHITE'=:>BIGBOX

LYELLOW=:(i.5){"2 YELLOW

LCYAN=:(i.5){"2  CYAN

TOP=:25 3$,CYAN<."1/LYELLOW

INSIDE=:((125 3$1 0 1)*125 3$,TOP)+0,.(,25#"0 |.N),.0

Q=:29 5$,(i.5 5 5)(,"2)0

INSIDE viewmat Q

 

Linda

 

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

Reply via email to