From 07a3f195edd2c6d2ac35eb918c7ce7bd088d54e1 Mon Sep 17 00:00:00 2001 From: Martin Bauer <martin.bauer@fau.de> Date: Thu, 5 Apr 2018 13:15:47 +0200 Subject: [PATCH] lbmpy notebook cleanup Part2 --- assignment_collection/simplificationstrategy.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/assignment_collection/simplificationstrategy.py b/assignment_collection/simplificationstrategy.py index fad227954..a9e9d0d61 100644 --- a/assignment_collection/simplificationstrategy.py +++ b/assignment_collection/simplificationstrategy.py @@ -113,7 +113,7 @@ class SimplificationStrategy(object): def print_assignment_collection(title, c): text = title if self.restrict_symbols: - text += "\n".join([str(e) for e in c.get(self.restrict_symbols)]) + text += "\n".join([str(e) for e in c.new_filtered(self.restrict_symbols).main_assignments]) else: text += (" " * 3 + (" " * 3).join(str(c).splitlines(True))) return text @@ -129,7 +129,8 @@ class SimplificationStrategy(object): def print_assignment_collection(title, c): text = '<h5 style="padding-bottom:10px">%s</h5> <div style="padding-left:20px;">' % (title, ) if self.restrict_symbols: - text += "\n".join(["$$" + sp.latex(e) + '$$' for e in c.get(self.restrict_symbols)]) + text += "\n".join(["$$" + sp.latex(e) + '$$' + for e in c.new_filtered(self.restrict_symbols).main_assignments]) else: # noinspection PyProtectedMember text += c._repr_html_() -- GitLab