Optimizing Memory Usage in Fortran Code

Published:

Author: DownFly

Reducing Memory Usage in get_n_compute_maxes_p1.f90

Memory Usage Changes

  • dist_tab (n_centers_integrals, n_max_batch_size)
    • Removed
  • dir_tab (3, n_centers_integrals, n_max_batch_size)
    • Removed
  • dist_tab_sq (n_centers_integrals, n_max_batch_size)
    • Reduced dimensions to dist_tab_sq(n_centers_integrals)
    • Changed to allocate memory dynamically

Precision Comparison

 gidx - gidx’gidx - lidxgidx - lidx’
H201.33E-141.07E-14
H2O02.345E-121.927E-12
RBDminiRunningRunningRunning