Skip to content

Commit

Permalink
* Correct wrong conversions in models, #78
Browse files Browse the repository at this point in the history
  • Loading branch information
MBaranskiEBC committed Jun 7, 2020
1 parent f99a22b commit b579364
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions pyDMPC/ControlFramework/Modeling.py
Original file line number Diff line number Diff line change
Expand Up @@ -308,7 +308,8 @@ def __init__(self, sys_id):

def predict(self):
self.states.outputs = [[self.modifs.linear_model_factors[0] * self.states.inputs[0] +
self.modifs.linear_model_factors[1] * self.states.commands[0]]]
self.modifs.linear_model_factors[1] * self.states.commands[0] +
self.modifs.linear_model_offsets[0]]]

class Integrator(Model):

Expand All @@ -333,8 +334,8 @@ def __init__(self, sys_id):
def predict(self):
import functions.fuzzy as fuz
self.states.outputs = [[self.states.inputs[0]]]
self.states.set_points = fuz.control(self.states.state_vars[0],
self.states.state_vars[1])
self.states.set_points = [fuz.control(self.states.state_vars[0],
self.states.state_vars[1])]

class StateSpace(Model):

Expand Down

0 comments on commit b579364

Please sign in to comment.