Project

General

Profile

Necessary Maintenance #18137

The method geo::GeometryCore::WirePitch() with two wires as argument should be removed

Added by Gianluca Petrillo about 3 years ago. Updated about 2 years ago.

Status:
Closed
Priority:
Normal
Assignee:
Paul Russo
Category:
Geometry
Target version:
-
Start date:
11/07/2017
Due date:
% Done:

0%

Estimated time:
Experiment:
-
Duration:

Description

The method geo::GeometryCore::WirePitch() allows the optional specification of two wire numbers.
  • the implicit assumption, pervasive of most of geometry code related to wires and tested in the standard geometry test, of even wire spacing makes it unnecessary to know which wires we are looking for the pitch of
  • the current implementation of this method also relies on this assumption
  • furthermore, the current implementation assumes that the two wires are consecutive, i.e. it does not really return their distance, but just the pitch between single wires
  • in short, the current implementation always returns the fixed wire pitch as reported by geo::PlaneGeo

Given that this implementation fulfills the current needs, we should make it official and have this method not accept wire numbers any more.
This will be a breaking change and if some code does specify the two wire numbers, it will have to be checked (it may be either unnecessarily specifying them, or it may be buggy -- no other possibility given the current implementation).

Associated revisions

Revision 28f587f3 (diff)
Added by Tingjun Yang over 2 years ago

Change WirePitch interface, issue #18137.

History

#1 Updated by Gianluca Petrillo about 3 years ago

  • Subject changed from The method @geo::GeometryCore::WirePitch()@ with two wires as argument should be removed to The method geo::GeometryCore::WirePitch() with two wires as argument should be removed

#2 Updated by Lynn Garren about 3 years ago

  • Status changed from New to Assigned
  • Assignee set to Gianluca Petrillo

#3 Updated by Katherine Lato over 2 years ago

  • Assignee changed from Gianluca Petrillo to Paul Russo

#4 Updated by Lynn Garren over 2 years ago

  • Tracker changed from Bug to Necessary Maintenance
  • Occurs In deleted (v06_55_00)

#5 Updated by Paul Russo over 2 years ago

  • Status changed from Assigned to Resolved

Done. The necessary changes to user code are:

Change calls from:

geo::Length_t geo::GeometryCore::WirePitch(geo::PlaneID const& planeid, unsigned wire1 = 0, unsigned wire2 = 1) const;
geo::Length_t geo::GeometryCore::WirePitch(unsigned wire1 = 0, unsigned wire2 = 1, unsigned plane = 0, unsigned tpc = 0, unsigned cryostat = 0) const;
double geo::TPCGeo::WirePitch(unsigned wire1 = 0, unsigned wire2 = 1, unsigned plane = 0) const;

to calls to:

geo::Length_t geo::GeometryCore::WirePitch(geo::PlaneID const& planeid) const;
geo::Length_t geo::GeometryCore::WirePitch(unsigned plane = 0, unsigned tpc = 0, unsigned cryostat = 0) const;
double geo::TPCGeo::WirePitch(unsigned plane = 0) const;

That is, the two wire arguments must be deleted.

This was released in v06_79_00.

#6 Updated by Katherine Lato about 2 years ago

  • Status changed from Resolved to Closed

Also available in: Atom PDF