diff --git a/chunkie/+chnk/chunkerkerneval_smooth.m b/chunkie/+chnk/chunkerkerneval_smooth.m index 41320c3..c3c83e8 100644 --- a/chunkie/+chnk/chunkerkerneval_smooth.m +++ b/chunkie/+chnk/chunkerkerneval_smooth.m @@ -61,7 +61,7 @@ % flag targets that are within 1e-14 of sources % these are automatically ignored by the fmm and % in chunkermat corrections -if ~strcmpi(imethod,'fmm') +if ~(strcmpi(imethod,'fmm') && isempty(flag)) flagslf = chnk.flagself(targinfo.r, chnkr.r, 1e-14*diam); if isempty(flagslf) selfzero = sparse(opdims(1)*size(targinfo.r(:,:),2), ... @@ -76,6 +76,9 @@ selfzero = sparse(flagslftarg,flagslfsrc, 1e-300, ... opdims(1)*size(targinfo.r(:,:),2), opdims(2)*chnkr.npt); end +else + selfzero = sparse(opdims(1)*size(targinfo.r(:,:),2), ... + opdims(2)*chnkr.npt); end if strcmpi(imethod,'direct') diff --git a/devtools/test/chunkermatapplyTest.m b/devtools/test/chunkermatapplyTest.m index 3cd14f4..4894d37 100644 --- a/devtools/test/chunkermatapplyTest.m +++ b/devtools/test/chunkermatapplyTest.m @@ -13,7 +13,6 @@ cparams = []; cparams.eps = 1.0e-4; -cparams.nover = 3; pref = []; pref.k = 16; narms = 5;