Exemplo n.º 1
0
def ExactParametrizedFunctions_OfflineAndOnline(**kwargs):
    assert kwargs["stages"] in ("offline", ("offline", ), ("offline", "online"))
    if kwargs["stages"] == ("offline", "online"):
        # Keep exact parametrized functions evaluation both offline and online
        from rbnics.eim.problems.exact_parametrized_functions import ExactParametrizedFunctions
        return ExactParametrizedFunctions(**kwargs)
    else:
        # This exact decorator should do nothing. Indeed EIM/DEIM exact decorator will take
        # care of adding the ExactParametrizedFunctions decorator, and we should not add it again here
        def DoNothing(ParametrizedDifferentialProblem_DerivedClass):
            return ParametrizedDifferentialProblem_DerivedClass
        return DoNothing
Exemplo n.º 2
0
def ExactEIMAlgorithm(**kwargs):
    # Enable exact parametrized functions evaluation both offline and online
    from rbnics.eim.problems.exact_parametrized_functions import ExactParametrizedFunctions
    kwargs["stages"] = ("offline", "online")
    return ExactParametrizedFunctions(**kwargs)