From 4ff45c6c3303e4318658882a3735a0f75dc37bc1 Mon Sep 17 00:00:00 2001 From: craig-warren Date: Tue, 19 Sep 2023 11:41:10 +0100 Subject: [PATCH] Tidied error message for PML kappamin check --- gprMax/pml.py | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/gprMax/pml.py b/gprMax/pml.py index 968eb809..6c6654e8 100644 --- a/gprMax/pml.py +++ b/gprMax/pml.py @@ -231,15 +231,14 @@ class PML: self.initialise_field_arrays() def check_kappamin(self): - """Checks that kappamin value for PMLCFS is not less than one. - It is the sum of all kappamin values, i.e. when a multi-pole PML is - used, that must not be less than one. + """Checks that the sum of all kappamin values, i.e. when a multi-pole + PML is used, is not less than one. """ - kappamin = 0 kappamin = sum(cfs.kappa.min for cfs in self.CFS) if kappamin < 1: - logger.exception(f"PML kappamin value(s) must sum to less than one.") + logger.exception(f"Sum of kappamin value(s) for PML is {kappamin} " + "and must be greater than one.") raise ValueError def initialise_field_arrays(self):