Print warning if margin greater than 4 83/4783/2
authorJim Phillips <jim@ks.uiuc.edu>
Wed, 7 Nov 2018 18:30:39 +0000 (12:30 -0600)
committerJim Phillips <jim@ks.uiuc.edu>
Wed, 7 Nov 2018 19:53:22 +0000 (13:53 -0600)
There are legitimate reasons for large margins, but the user should
be made aware of the consequences of increasing it unnecessarily.

Change-Id: Iacf9b216199d2c6a639bcfa611af2734fa1b0f3c

src/SimParameters.C

index 671ff89..f19db39 100644 (file)
@@ -4852,6 +4852,12 @@ if ( openatomOn )
                                                        << "\n" << endi;
 
    iout << iINFO << "MARGIN                 " << margin << "\n";
+   if ( margin > 4.0 ) {
+      iout << iWARN << "MARGIN IS UNUSUALLY LARGE AND WILL LOWER PERFORMANCE\n";
+      BigReal f = patchDimension/(patchDimension-margin);
+      f *= f*f;
+      iout << iWARN << "MARGIN INCREASED PATCH VOLUME BY A FACTOR OF " << f << "\n";
+   }
 
    if ( splitPatch == SPLIT_PATCH_HYDROGEN ) {
       iout << iINFO << "HYDROGEN GROUP CUTOFF  " << hgroupCutoff << "\n";