Commit 15d11511 authored by Jakob Knollmüller's avatar Jakob Knollmüller
Browse files

modification of DOFDistributor for unstructured domain

parent c84329d5
Pipeline #94861 failed with stages
in 5 minutes and 21 seconds
......@@ -73,10 +73,14 @@ class DOFDistributor(LinearOperator):
if partner.scalar_dvol is not None:
wgt = np.bincount(dofdex.val.ravel(), minlength=nbin)
wgt = wgt*partner.scalar_dvol
elif partner.dvol is not None:
dvol = Field.from_raw(partner, partner.dvol).val
wgt = np.bincount(dofdex.val.ravel(),
minlength=nbin, weights=dvol)
wgt = np.bincount(dofdex.val.ravel(), minlength=nbin)
# for UnstructuredDomain
# The explicit conversion to float64 is necessary because bincount
# sometimes returns its result as an integer array, even when
# floating-point weights are present ...
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment