On Sep 25, 2013, at 4:59 AM, Damian Kösters <[email protected]> wrote:

> I changed the x,y section as you recommended.
> 
> I then tried inside the "if step>10"-clause:
>  >>>       phi[bacteria2.value] = phi[bacteria5.value]        
>  >>>       phi.constraints[2].value = phi.value[bacteria5]
> 
> It seems that the first line does have an effect (even though when I print 
> the right side it gives me reasonable numbers).

phi.constrain(10, bacteria2) takes precedence over any value you assign at the 
location of bacteria2

> The second line gives me an indexing error ("unsupported iterator index"). 
> Changing the right side to phi[bacteria5.value] 
>  gave me a RuntimeError.

Yes, it needs to be `bacteria5.value`.

Can you provide the full error traceback?


_______________________________________________
fipy mailing list
[email protected]
http://www.ctcms.nist.gov/fipy
  [ NIST internal ONLY: https://email.nist.gov/mailman/listinfo/fipy ]

Reply via email to