Commit 4c46d015 authored by Jorn Baayen's avatar Jorn Baayen

ModelicaMixin: Clean up.

parent 2c9a8418
This diff is collapsed.
......@@ -90,6 +90,15 @@ class TestProblemNonConvex(TestProblem):
return {'u': Timeseries(self.times(), self.u_seed)}
class TestProblemScaled(TestProblem):
def variable_nominal(self, variable):
if variable.startswith('x'):
return 0.5
return super().variable_nominal(variable)
class TestProblemConstrained(TestProblem):
def constraints(self, ensemble_member):
......@@ -321,9 +330,7 @@ class TestModelicaMixin(TestCase):
class TestModelicaMixinScaled(TestModelicaMixin):
def setUp(self):
self.problem = TestProblem()
self.problem._nominals['x'] = 0.5
self.problem._nominals['x_delayed'] = self.problem._nominals['x']
self.problem = TestProblemScaled()
self.results = self.problem.extract_results()
self.tolerance = 1e-6
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment