Git Product home page Git Product logo

lfa-lab's People

Contributors

hrittich avatar jonas-schmitt avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

Forkers

beauof z7198185

lfa-lab's Issues

Restriction and Interpolation for Systems of Equations

Hi,

as there is already support for systems of equations with the the SystemNode class, it should be also possible to define restriction and interpolation operators that can be applied to a system. It is although not obvious to me how to do this.

As a concrete example consider the following biharmonic system:

from lfa_lab import *

fine = Grid(2, [1.0, 1.0])
coarse = fine.coarse((2, 2))

# Create a poisson operator.
L = gallery.poisson_2d(fine)
Z = L.matching_zero()
A = system([[L, Z], [operator.from_stencil([((0, 0), -1)], fine), L]])
R = gallery.fw_restriction(fine, coarse)
P = gallery.ml_interpolation(fine, coarse)
A_c = R * A * P # does obviously not work
A_c = system([[R, R * Z], [R * Z, R]]) * A * system([[P, Z * P], [Z * P, P]]) # does not work either
A_c.symbol()

How can one for example define the Galerkin coarse grid operator for this system?

gallery_test.py broken

This particular test seems to be broken:

======================================================================
ERROR: test_fw_restriction_2 (gallery_test.GalleryTest)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "lfa-lab/test/gallery_test.py", line 62, in test_fw_restriction_2
    s = fw_restriction_stencil(grid)
TypeError: fw_restriction_stencil() takes exactly 2 arguments (1 given)

======================================================================
ERROR: test_fw_restriction_3 (gallery_test.GalleryTest)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "lfa-lab/test/gallery_test.py", line 74, in test_fw_restriction_3
    s = fw_restriction_stencil(grid)
TypeError: fw_restriction_stencil() takes exactly 2 arguments (1 given)

======================================================================
ERROR: test_ml_interpolation_2 (gallery_test.GalleryTest)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "lfa-lab/test/gallery_test.py", line 29, in test_ml_interpolation_2
    s = ml_interpolation_stencil(grid)
TypeError: ml_interpolation_stencil() takes exactly 2 arguments (1 given)

======================================================================
ERROR: test_ml_interpolation_3 (gallery_test.GalleryTest)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "lfa-lab/test/gallery_test.py", line 40, in test_ml_interpolation_3
    s = ml_interpolation_stencil(grid)
TypeError: ml_interpolation_stencil() takes exactly 2 arguments (1 given)

----------------------------------------------------------------------

Best way to compute h-ellipticity?

(This is a support question not a bug or other real issue.)

Suppose I define an operator but not a smoother (splitting):

from lfa_lab import *                                                              
fine = Grid(2, [1.0/32, 1.0/32])                                                   
L = gallery.poisson_2d(fine)

I want the h-ellipticity as defined by Trottenberg et al seciton 4.7, i.e. E_h(L) = min(|lshigh|) / max(|ls|) where ls is the symbol of L and lshigh is the symbol over the high-frequency modes.

I can imagine various awkward methods for computing E_h(L) but I wonder what you would suggest?

PS Just found your nice library!

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.