FORTRAN - Error 112 Run-time Error

  • Fortran
  • Thread starter Athos_F
  • Start date
  • #1
1
0

Main Question or Discussion Point

I have strange situation where a code that generaly seems to work fine at times gives a error message.

Basicly I run simulations on a lattice model, and have experience no problems for small system, but when I go to larger systems (meaning that the simulation takes aprox. 15 min) I sometimes get into problem. To average my results I run each simulation a given number of times, and it seems that in around 0.5 % of the time my largest model gives the following error.

Run-time Error
*** Error 112, Reference to undefined variable, array element or function result (/UNDEF).

The line it conects to the problem is well defined, and should not be the problem.

Anyone know way?
 

Answers and Replies

  • #2
This error indicates that you are trying to use elemnts of an array without assigning a value for them. Double check the array sizes .

Also I would recommend initializing all your variables (including arrays) at the begininig of your simulation.
 

Related Threads on FORTRAN - Error 112 Run-time Error

Replies
5
Views
2K
Replies
8
Views
11K
Replies
8
Views
3K
  • Last Post
Replies
1
Views
2K
  • Last Post
Replies
3
Views
906
  • Last Post
Replies
17
Views
748
  • Last Post
Replies
12
Views
5K
  • Last Post
Replies
13
Views
6K
Replies
2
Views
19K
Replies
5
Views
899
Top