diff options
author | blendoit <blendoit@gmail.com> | 2019-10-06 15:14:53 -0700 |
---|---|---|
committer | blendoit <blendoit@gmail.com> | 2019-10-06 15:14:53 -0700 |
commit | 8202fe7e323b3f2ade911a828d4737b6ab34689f (patch) | |
tree | a1c58b913d5c527e2b640c9dc6260ef74bee493f /evaluator.py | |
parent | bdf09276e757675e9c9d7874b46bdffdb137e3b8 (diff) |
Before Evaluator in-depth rewrite
Diffstat (limited to 'evaluator.py')
-rw-r--r-- | evaluator.py | 79 |
1 files changed, 44 insertions, 35 deletions
diff --git a/evaluator.py b/evaluator.py index afbde9c..aac7f61 100644 --- a/evaluator.py +++ b/evaluator.py @@ -13,49 +13,58 @@ import matplotlib.pyplot as plt class Evaluator: - """Performs structural evaluations for the airfoil passed as argument.""" - def __init__(self, aircraft): - # Evaluator knows all geometrical info from evaluated airfoil - self.airfoil = self.get_airfoil(aircraft) - self.spars = self.get_spars(aircraft) - self.stringers = self.get_stringers(aircraft) - # Lift - self.lift_rectangular = [] - self.lift_elliptical = [] - self.lift_total = [] - # Drag - self.drag = [] - # centroid - self.centroid = [] + """Performs structural evaluations on aircrafts. + Individual aircrafts must claim an Evaluator object as parent.""" + def __init__(self): + self.aircrafts = [] + # # Evaluator knows all geometrical info from evaluated airfoil + # self.airfoil = self.get_airfoil(aircraft) + # self.spars = self.get_spars(aircraft) + # self.stringers = self.get_stringers(aircraft) + # # Lift + # self.lift_rectangular = [] + # self.lift_elliptical = [] + # self.lift_total = [] + # # Drag + # self.drag = [] + # # centroid + # self.centroid = [] # Inertia terms: self.I_ = {'x': 0, 'z': 0, 'xz': 0} def __str__(self): return type(self).__name__ - def get_airfoil(self, aircraft): - """Get data of spars belonging to aircraft.""" + def update(self): + """Get all aircrafts' data.""" try: - pass + print(self.aircrafts) except: - pass - pass - - def get_spars(self, aircraft): - """Get data of spars belonging to aircraft.""" - try: - pass - except: - pass - pass - - def get_stringers(self, aircraft): - """Get data of spars belonging to aircraft.""" - try: - pass - except: - pass - pass + print("failed!") + + # def get_airfoil(self, aircraft): + # """Get data of spars belonging to aircraft.""" + # try: + # pass + # except: + # pass + # pass + + # def get_spars(self, aircraft): + # """Get data of spars belonging to aircraft.""" + # try: + # pass + # except: + # pass + # pass + + # def get_stringers(self, aircraft): + # """Get data of spars belonging to aircraft.""" + # try: + # pass + # except: + # pass + # pass def info_print(self, round): """Print all the component's evaluated data to the terminal.""" |