mirror of
https://github.com/wassname/simpeg.git
synced 2026-07-10 01:56:12 +08:00
added mass matrix
This commit is contained in:
@@ -161,3 +161,23 @@ class DiffOperators(object):
|
||||
return locals()
|
||||
_edgeAve = None
|
||||
edgeAve = property(**edgeAve())
|
||||
|
||||
|
||||
|
||||
def getEdgeMassMatrix(h,sigma):
|
||||
# mass matix for products of edge functions w'*M(sigma)*e
|
||||
|
||||
Av = getEdgeToCellAverge(h)
|
||||
v = getVol(h)
|
||||
sigma = mkvc(sigma)
|
||||
|
||||
return sdiag(Av.T*(v*sigma))
|
||||
|
||||
def getFaceMassMatrix(h,sigma):
|
||||
# mass matix for products of edge functions w'*M(sigma)*e
|
||||
|
||||
Av = getFaceToCellAverge(h)
|
||||
v = getVol(h)
|
||||
sigma = mkvc(sigma)
|
||||
|
||||
return sdiag(Av.T*(v*sigma))
|
||||
Reference in New Issue
Block a user