matmul trouble
- From: "Wade Ward" <invalid@xxxxxxxxxxxx>
- Date: Sun, 8 Jul 2007 16:29:01 -0400
I'm trying to decide from first principles how to represent the input when
you read in a square matrix with a read (*,*).
program maine2
integer :: x(3,3), z(3,3)
write (*,'(a)',advance='no') 'Give me 9 ints: '
read(*,*) x
z=matmul(x,x)
write (*,*) x, z
end program maine2
I'm puzzled that this should turn into a runtime error with 123456789 as an
input. You'd think the usual culprit would be inappropriately-sized arrays,
but it's hard to go wrong on that count with square matrices. Ideas?
--
Wade Ward
.
- Follow-Ups:
- Re: matmul trouble
- From: dpb
- Re: matmul trouble
- From: George Schroeder
- Re: matmul trouble
- Prev by Date: On writing negative zero - with or without sign
- Next by Date: Re: How old is the average Fortran programmer?
- Previous by thread: On writing negative zero - with or without sign
- Next by thread: Re: matmul trouble
- Index(es):