How to use the dmsh.Stretch function in dmsh

To help you get started, we’ve selected a few dmsh examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github nschloe / dmsh / test / test_stretch.py View on Github external
def test(show=True):
    geo = dmsh.Stretch(dmsh.Rectangle(-1.0, +2.0, -1.0, +1.0), [1.0, 1.0])
    X, cells = dmsh.generate(geo, 0.3, show=show, tol=1.0e-3)

    ref_norms = [1.9391178579025609e02, 1.5890693098212086e01, 2.6213203435596428e00]
    assert_norm_equality(X.flatten(), ref_norms, 1.0e-2)
    return X, cells