Intel® Fortran Compiler
Build applications that can scale for the future with optimized code designed for Intel® Xeon® and compatible processors.

Funny error in CVF!

gsfantos
Beginner
594 Views
Hi there,
In a CVF program I have implemented the following in a subroutine where the integer MRVE is imported
INTEGER::MRVE
REAL(8)::Dam(3*MRVE)
Dam=-1.0D+000

DO i=1,MRVE
IF (Dam(3*i-2)<=0.0) Dam(3*i-2)=0.0D+00
IF (Dam(3*i-1)<=0.0) Dam(3*i-1)=0.0D+00
IF (Dam(3*i)<=0.0) Dam(3*i)=0.0D+00
END DO
the funny thing is that it gives me the following error , where when I am cancelling the {IF} operations it runs withou any problem!!!
forrtl: severe (161): Program Exception - array bounds exceeded
Image PC Routine Line Source
MC.ex 00429149 Unknown Unknown Unknown
MC.ex 004242E6 Unknown Unknown Unknown
MC.ex 0042D3E7 Unknown Unknown Unknown
MC.ex 004366A2 Unknown Unknown Unknown
MC.ex 0047B599 Unknown Unknown Unknown
MC.ex 0046F6F4 Unknown Unknown Unknown
kernel32.dll 7C816D4F Unknown Unknown Unknown
Does anyone have any idea?
Thanks in advance
0 Kudos
1 Reply
gsfantos
Beginner
594 Views

Hi there again,

I found it guys, sorry for the trouble. There was something wrong with the things after the IF's statements

Thanks again

0 Kudos
Reply