Subject: Re: Forall

From: [email-masked] (Min-You Wu)
Date: Wed, 24 Jun 92 22:13:10 EDT

> 
> Min-You Wu writes:
> > 
> > I agree that IF with INDENPENDENT doesn't work for this example because
> > of interactions between branches.   Let's find out how can we solve
> > this problem.  It seems Fortran D semantics is a good solution, however,
> > Fortran D semantics can only be apply to using *old* values.  Of course 
> > the above example is a good one for Fortran D semantics.  How about the 
> > following example?
> > 
> >  	FORALL ( I = 1:N )
> >           DO J = 1,N
> >    	    IF ( ABS(A(I)) < EPS ) THEN
> >  	      A(I) = 0.0
> >  	    ELSE
> >  	      A(I) = A(I-1) + A(I+1)
> >  	    END IF
> >           END DO
> >  	END FORALL
> 
> Please explain to me the purpose of the "DO J = 1,N" loop.
> 
> Joel
> 

Well, just make a code in which not only old values but also the new 
values assigned in FORALL are needed.

Min-You