Flow
- class Flow.Flow(flow_type=None, n=None, weight=None)[source]
Defines a Flow object.
The Flow class computes anisotropic flow. For this it needs a list of Particle objects, as it is returned from the Oscar or Jetscape classes.
- Parameters:
- flow_type:
“ReactionPlane”, “EventPlane”, “ScalarProduct”, “QCumulants”, “LeeYangZeros”, “PCA”
- n: int
Integer for the n-th flow harmonic
- weight: str
String defining the weights in the calculation of the Q vectors. Options are “pt”, “pt2”, “ptn”, “rapidity”. There is no effect for the ReactionPlane method.
Examples
1>>> from Oscar import Oscar 2>>> from Flow import Flow 3>>> 4>>> OSCAR_FILE_PATH = [Oscar_directory]/particle_lists.oscar 5>>> 6>>> # Oscar object containing all events 7>>> oscar = Oscar(OSCAR_FILE_PATH) 8>>> 9>>> # Perform particle / detector cuts 10>>> charged_particles = oscar.charged().pseudorapidity(0.5).particle_objects_list() 11>>> 12>>> flow = Flow(flow_type="EventPlane",n=2,weight="pt2") 13>>> flow_val = flow.integrated_flow(oscar)
- Attributes:
- integrated_flow_: complex
Value of the integrated flow.
- integrated_flow_err_: complex
Value of the integrated flow error.
- differential_flow_: list
List of the differential flow.
- differential_flow_err_: list
List of the differential flow error.
Methods
integrated_flow:
Returns the integrated flow.
differential_flow:
Returns the differential flow.
- Flow.integrated_flow(particle_data)[source]
Compute the integrated anisotropic flow.
- Parameters:
- particle_data: list
List with lists for each event containing Particle objects.
- Returns:
- integrated_flow_: complex / real
Value of the integrated flow.
- Flow.differential_flow(particle_data, bins, flow_as_function_of)[source]
Compute the differential anisotropic flow.
- Parameters:
- particle_data: list
List with lists for each event containing Particle objects.
- bins: list
List with bin boundaries for the differential quantity.
- flow_as_function_of: string
Differential variable: ‘pt’, ‘rapidity’, ‘pseudorapidity’.
- Returns:
- integrated_flow_: list
List containing the differential flow.