486 |
|
return; |
487 |
|
|
488 |
|
} |
489 |
+ |
|
490 |
+ |
RealType EAM::getSuggestedCutoffRadius(AtomType* at1, AtomType* at2) { |
491 |
+ |
if (!initialized_) initialize(); |
492 |
+ |
|
493 |
+ |
RealType cut = 0.0; |
494 |
+ |
|
495 |
+ |
map<AtomType*, EAMAtomData>::iterator it; |
496 |
+ |
|
497 |
+ |
it = EAMMap.find(at1); |
498 |
+ |
if (it != EAMMap.end()) { |
499 |
+ |
EAMAtomData data1 = (*it).second; |
500 |
+ |
cut = data1.rcut; |
501 |
+ |
} |
502 |
+ |
|
503 |
+ |
it = EAMMap.find(at2); |
504 |
+ |
if (it != EAMMap.end()) { |
505 |
+ |
EAMAtomData data2 = (*it).second; |
506 |
+ |
if (data2.rcut > cut) |
507 |
+ |
cut = data2.rcut; |
508 |
+ |
} |
509 |
+ |
|
510 |
+ |
return cut; |
511 |
+ |
} |
512 |
|
} |
513 |
|
|