(self, heap)
| 10 | class npALE(PyNumProc): |
| 11 | |
| 12 | def Do(self, heap): |
| 13 | print ("ALE - Laplace") |
| 14 | |
| 15 | pde = self.pde |
| 16 | |
| 17 | d = pde.gridfunctions["def"] |
| 18 | d.Set(CoefficientFunction((2*y*(1-y)*x*(1-x),(3*y*(1-y)*x*(1-x))))) |
| 19 | pde.Mesh().SetDeformation (d) |
| 20 | |
| 21 | u = pde.gridfunctions["u"] |
| 22 | # first test: |
| 23 | # u.Set(VariableCF("x")) |
| 24 | |
| 25 | |
| 26 | v = pde.spaces["v"] |
| 27 | a = pde.bilinearforms["a"] |
| 28 | f = pde.linearforms["f"] |
| 29 | |
| 30 | a.Assemble() |
| 31 | f.Assemble() |
| 32 | inv = a.mat.Inverse(v.FreeDofs()) |
| 33 | |
| 34 | u.vec.data = inv * f.vec |
| 35 | |
| 36 | |
| 37 |
no test coverage detected