On 10 Sep 2003 04:22:55 -0700, Andrea wrote:
> Hello Fortran Gurus,In what form do you need the indices? Will a logical array help? There are
> I'm not an expert with fortran, but I would like to ask 2
> 1) Is there a fortran function/subroutine that returns the indices of
> a vector (matrix) X that are non-zero? (for whom that know matlab,
> like the "find" function).
lots of ways to use such arrays in vector operations.
integer, parameter :: n = 5
flag = a /= 0.0 ! the "/=" operator is sometimes spelled ".ne."
print *, flag
end program bittest
This program prints
T F T F F
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.