M.,

I found a couple of problems with the code. One line is too long and
in three places the character - appears as ‾  . With these changes in
the abbreviated code below, I get some good results, but no animation
on my Mac. That is probably a Mac problem though.

The line that is too long is below and the "m" is on a line by itself.

Thank you for sharing your art.

2009/12/21 M.Shimura <[email protected]>:

[snip]

> Holyday greeting!!
> NB. --------new------------
> NB. find candidate----
> NB. using metropolis random number
> index_zrp_sub1 =: 4 : 0
> NB. find candidate for lane change
> NB. x is congestion rate  // y is  TMP (is prob a b lane)
> CONG=. +/ L:0 INDX=: (1, L:0 }. L:0 -. L:0 y)<;.1 L:0 y   NB. search congestio
> m

[snip]

> NB. ---------------------------
> ANS
> NB. nub(‾.) adjust head of overrup
> NB. if null --> find  0=# ans --> 1
> )
>
> metropolis_x=: 4 : 0
> NB. Usage: 0.55 metropolis_x 6
> NB. remove  0   --> 0
> NB. if null --> 0
> NB. case. 0 -->on using script write skip patarn
> TMP=. ‾. /:‾ x metropolis0 y NB. not burn_in and sort
> select.  # TMP
>  case. 0 do. TMP=. 0                    NB. null -->0
>  case. 1 do.
>      if. 1 = TMP do. TMP=. 0 else. TMP=. TMP end.
>  fcase. do.  TMP=.( -. TMP e. 0 ) # TMP NB. except 0
>      if. 0 =  # TMP do. TMP=. 0 end.  NB. null --> 0
> end.
> TMP
> )
>
----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm

Reply via email to