示例#1
0
    def __init__(self, *args, **kwargs):
        super(IInitialValueProblem, self).__init__(*args, **kwargs)
        TransientProblemMixin.__init__(self, *args, **kwargs)

        self._initial_value = None
        if "initial_value" in kwargs:
            self.initial_value = kwargs["initial_value"]
 def __str__(self):
     _outstr = super(TransientProblemMixinTest.ExampleProblem, self).__str__()
     _outstr += TransientProblemMixin.__str__(self)
     return _outstr
 def print_lines_for_log(self):
     _lines = super(TransientProblemMixinTest.ExampleProblem, self).print_lines_for_log()
     _lines.update(TransientProblemMixin.print_lines_for_log(self))
     return _lines
 def __init__(self, *args, **kwargs):
     super(TransientProblemMixinTest.ExampleProblem, self).__init__(*args, **kwargs)
     TransientProblemMixin.__init__(self, *args, **kwargs)
示例#5
0
 def __str__(self):
     _out = super(IInitialValueProblem, self).__str__()
     _out += TransientProblemMixin.__str__(self)
     _out += r", u({:.2f})={}".format(self.time_start, self.initial_value)
     return _out
示例#6
0
 def print_lines_for_log(self):
     _lines = super(IInitialValueProblem, self).print_lines_for_log()
     _lines.update(TransientProblemMixin.print_lines_for_log(self))
     _lines["Initial Value"] = "u({:.3f}) = {}".format(self.time_start, self.initial_value)
     return _lines