class SymmetricSystem(System): """ A symmetric system""" def __init__(self, elements, quadrule, meshevents, boundarytags): self.basis = Basis(elements) meshevents(self.basis) indexinfo = processIndices(self.basis, boundarytags) System.__init__(self, quadrule, meshevents, self.basis, self.basis, indexinfo, indexinfo) self.elements = elements def systemMatrix(self, deriv): return super(SymmetricSystem, self).processSystem(*it.tee(self.basis.getElementValues(self.refquadpoints,deriv), 2))
def __init__(self, elements, quadrule, meshevents, boundarytags): self.basis = Basis(elements) meshevents(self.basis) indexinfo = processIndices(self.basis, boundarytags) System.__init__(self, quadrule, meshevents, self.basis, self.basis, indexinfo, indexinfo) self.elements = elements