Ticket #1448 (closed: fixed)

Opened 10 years ago

Last modified 5 years ago

Bug in NormaliseToCurrent(): Divide by zero

Reported by: Nick Draper Owned by: Roman Tolchenov
Priority: major Milestone: Iteration 24
Component: Keywords:
Cc: Blocked By:
Blocking: Tester: Sofia Antony

Description

From Steve King:

There is a little issue with the NormaliseToCurrent() function in that it will happily attempt to divide by zero if the proton charge in the run is zero (which can happen if the beam is down and a run is ended)!

Can this be trapped please! Just returning zero or a negative number would be enough!

Actually perhaps gracefully failing the algorithm may be the best answer. Check what the current behaviour is

Change History

comment:1 Changed 10 years ago by Roman Tolchenov

  • Status changed from new to accepted

comment:2 Changed 10 years ago by Roman Tolchenov

(In [5504]) Throws the domain_error if the current is zero. re #1448

comment:3 Changed 10 years ago by Roman Tolchenov

  • Status changed from accepted to verify

comment:4 Changed 10 years ago by Nick Draper

  • Resolution set to fixed

fill in missing resolution

comment:5 Changed 10 years ago by Sofia Antony

  • Status changed from verify to verifying
  • Tester set to Sofia Antony

comment:6 Changed 10 years ago by Sofia Antony

  • Status changed from verifying to closed

comment:7 Changed 5 years ago by Stuart Campbell

This ticket has been transferred to github issue 2295

Note: See TracTickets for help on using tickets.