Closed sasrigais closed 1 year ago
Thanks. I checked the code in class SubRegion:
def elements(self):
"""return elements of this subregion"""
return [e for s in self.superelements for e in s.elements]
def area(self):
"""return area of this subregion"""
return sum([e.area for e in self.elements()])
It seems correct to me. The for loop touches all superelements and elements is a field of superelements. Please tell me if I'm wrong.
Hi.
Yes, elements
is a field of superelements
. But I referred to class windings
, and there you need to call function elements()
of class subregion
in the for-loop, as subregion
has no field elements
.
Cheers Thomas
Oh. my bad. I got it. Thanks
Hi!
In line 1075 of isa7.py, there is a small typo. It should be
s.elements()
instead ofs.elemnts
, as elements is a function ofSubregion
, not a field...Regards Thomas