ZeroDivisionError: float division

Trace: File "/home/s0575124/star/version_5.02/wall_wave/base_refinement/test.py", line 19, in ? test.cycle() File "/home/s0575124/programming/python/fifthwave/trunk/flightdeck.py", line 324, in cycle if self._cur_job.status != 9: self.analyse(sim_dat_point) File "/home/s0575124/programming/python/fifthwave/trunk/flightdeck.py", line 283, in analyse comparison() File "/home/s0575124/programming/python/fifthwave/trunk/fifthwave.py", line 1016, in __call__ self.update_metrics(current_time, self._sim_wave) File "/home/s0575124/programming/python/fifthwave/trunk/fifthwave.py", line 940, in update_metrics metric_pair[0](time, methodtocall()) File "/home/s0575124/programming/python/fifthwave/trunk/fifthwave.py", line 330, in wavelength w_length = self.linear_cross(crossing_list[2], zero) \ File "/home/s0575124/programming/python/fifthwave/trunk/fifthwave.py", line 350, in linear_cross m = (y2 - y1) / (x2 - x1)

Details

Id: b04d91f42cdd101788e814730f0e1d31aa18746c
Type: bugfix
Creation time: 2010-11-16 14:00
Creator: Mathew Topper <mathew.topper@...>
Release: 0.2 (released 2011-02-09)
Component: fifthwave.py
Status: closed : fixed fixed

Issue log

2010-11-16 16:33 Mathew Topper <mathew.topper@...> closed with disposition fixed
Problem was in OneD_Wave_Form.crossings where it was not checking if the zero crossing node was a repeat of the last node (ie a duplicate). This was causing the zero division when looking for the zero crossing. It might be that this has messed up which side it checks for the zero crossing on in TwoD_Wave_Form.linear_cross but at least it's safer now.
2010-11-16 14:00 Mathew Topper <mathew.topper@...> created