Analysis Software
Documentation for sPHENIX simulation software
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
TPCRateLayered.m File Reference

Go to the source code of this file.

Typedefs

using myColorMap = colormap
 

Functions

 myColorMap (1,:)
 
 colormap (myColorMap)
 
id bitPerHit ()
 
id DAMCompressionFactor ()
 
MinEtaRingBCO< TargetEta double ()
 
 figure ('name','PerEventData','PaperPositionMode','auto',... 'position',[100, 0, 2400, 800])
 
 subplot (1, 2, 1) imagesc(zBCO(1
 
 RRing (:, 1)
 
 plot ([10 maxZ+10],[0 tan(acos(tanh(TargetEta)))*maxZ],'k--')
 
 set (gca,'YDir','normal')
 
 set (gca,'YLim',[0, 80])
 
 set (gca,'XLim',[0, 110]) box on grid on daspect([1 1 1]) xlabel('|z|position(cm)'
 
 ylabel ('R position(cm)','FontSize', 14)
 
 title (sprintf('FEE data(bit) per MB collision per|z|-R bin, total=%.1f Mbit', sum(sum(dataBitRingBCO))/1e6),'FontSize', 16)
 
 subplot (1, 2, 2) imagesc(zBCO(1
 
 ylabel ('R position','FontSize', 14)
 
 title (sprintf('FEE data(bit) after DAM acceptance filtering, total=%.1f Mbit', sum(sum(dataBitRingBCOAfterMask))/1e6),'FontSize', 16)
 
 SaveCavas ('TPCRateLayered', gcf)
 
Event stream display figure ('name','DataStream','PaperPositionMode','auto',... 'position',[100, 0, 2400, 800])
 
 xlabel ('BCO bin(100 ns)','FontSize', 14)
 
 ylabel ('Radial layer number','FontSize', 14)
 
 title (sprintf('FEE data input to DAM.Rate=%.0f Gbps @%.0f kHz Collision,%.0f kHz Trigger%.0f us Drift',...sum(sum(DataBCO))/TimeSpan/1e9, full_rate/1e3, trig_rate/1e3, trigger_window *1e6),'FontSize', 16)
 
 plot ([i, i+PerTriggerBCO],[-3-3], 'r-', 'LineWidth', 2) plot([i
 
[i i],[-1 nRing],'k--','LineWidth', 2 plot ()
 
 plot ([i, i+PerTriggerBCO],[-1-1], 'k-', 'LineWidth', 2) end end subplot(2
 
 imagesc (PlotThrottleDataBCO)
 
 title (sprintf('DAM data output:Throttled data rate=%.0f Gbps, Triggered data rate=%.0f Gbps ',...ThrottleDataRate *DAMCompressionFactor/1e9,...TriggerDataRate *DAMCompressionFactor/1e9...),'FontSize', 16)
 
'name','DataStream1D','PaperPositionMode','auto',...
'position',[100, 0, 2400, 800] 
figure ()
 
 subplot (2, 1, 1) bar(PlotDataBCO(nRing
 
 ylabel ('Data in last TPC layer(bit/BCO)','FontSize', 14)
 
 plot ([i, i+PerTriggerBCO],[-.15-.15].*y_max, 'r-', 'LineWidth', 1) plot([i
 
 plot ([i, i+PerTriggerBCO],[-.1-.1].*y_max, 'k-', 'LineWidth', 1) end end subplot(2
 
 bar (PlotThrottleDataBCO(nRing,:), 1)
 
 sum (DataRadialLayerRate((8+1):(8+16)))/8
 
 sum (DataRadialLayerRate((8+1+16):(8+16+16)))/12].../12/2
 
 sum (DataRadialLayerRate((16+1):(16+16)))/8
 
 sum (DataRadialLayerRate((16+1+16):(16+16+16)))/12].../12/2
 
sectors and two sides else assert (0)
 
end FEE Data Rate Plot figure ('name','FEEDataRate','PaperPositionMode','auto',... 'position',[100, 0, 800, 400])
 
 bar (FEEDataRate/1e9)
 
 xlabel ('Module Number','FontSize', 16)
 
 ylabel ('Average data rate per FEE(Gbps)','FontSize', 16)
 
 title (sprintf('FEE data input to DAM.Total=%.0f Gbps @%.0f kHz Collision,%.0f kHz Trigger%.0f us Drift',...sum(sum(DataBCO))/TimeSpan/1e9, full_rate/1e3, trig_rate/1e3, trigger_window *1e6),'FontSize', 12)
 
 SaveCavas (SaveName, gcf)
 
 nPileUpTrig (iTrig)
 
end nPileUpRnd (i-PerTriggerBCO+1)
 
end figure ('name','nPileUp','PaperPositionMode','auto',... 'position',[100, 0, 2000, 800])
 
 xlabel ('Number of collisions in TPC drift window','FontSize', 14)
 
 ylabel ('Count per bin','FontSize', 14)
 
 title (sprintf('Collision trigger:<#collision in TPC window >=%.2f @%.0f kHz Collision,%.0f us Drift',...mean(nPileUpTrig),...full_rate/1e3, trigger_window *1e6),'FontSize', 16)
 
 title (sprintf('Random trigger:<#collision in TPC window >=%.2f @%.0f kHz Collision,%.0f us Drift',...mean(nPileUpRnd),...full_rate/1e3, trigger_window *1e6),'FontSize', 16)
 
 fprintf ('Throttled event/total=%.3f;Throttled data/total=%.3f;Triggered event/total=%.3f;Triggered data/total==%.3f\n',...%n_recorded/n, recorded_data/n, n_triggered./n, triggered_data/n)
 
 fprintf ('------------\n')
 
 fprintf ('full_rate=%.0f kHz;trig_rate=%.0f kHz;trigger_window=%.1f us;Time span=%.3f s\n',...full_rate/1e3, trig_rate/1e3, trigger_window *1e6, TimeSpan)
 
 fprintf ('per event effective track=%.0f, per event FEE data=%.0f bits, total FEE data rate=%.0f Gbps\n',...mean(sum(dEtaRingBCO, 2)*180 *2), sum(sum(dataBitRingBCO)), sum(sum(DataBCO))/TimeSpan/1e9)
 
 fprintf ('Trigger rate *drift window=%.2f;Full rate *drift window=%.2f;Trigger rate/full rate=%.2f(input)/%.2f(MC);\n',...trig_rate *trigger_window, full_rate *trigger_window, trig_rate/full_rate, sum(TriggerBCO)/sum(CollisionBCO))
 
 fprintf ('throttled data/total=%.3f;Triggered data/total=%.3f;throttled/trigger=%.3f;Triggered data/Per event data=%.3f\n',...ThrottleDataRate/TotalDataRate,...TriggerDataRate/TotalDataRate,...ThrottleDataRate/TriggerDataRate,...sum(sum(DataBCO.*TriggerAcceptBCO))./(sum(sum(dataBitRingBCOAfterMask)).*sum(TriggerBCO))...)
 
 sum (sum(DataBCO.*TriggerAcceptBCO))./(sum(sum(dataBitRingBCOAfterMask)).*sum(CollisionBCO))...fprintf('throttled data rate
 
 fprintf ('throttled event/total=%.3f;Triggered event/total==%.3f;throttled/trigger=%.3f\n',...%recorded_data/n, triggered_data/n, recorded_data/triggered_data)
 

Variables

Inputs n = 1000
 
 full_rate = 100e3
 
 trig_rate = 15e3
 
 trigger_window = 18e-6
 
 TargetEta = 1.1
 
 nRing = 40
 
 SaveName = sprintf('TPCRateLayered_%.0fHzCol_%.0fHzTrig_%.0fusDrift_nRing%d',full_rate,trig_rate,trigger_window*1e6, nRing)
 
Generic constants minR = 30
 
 maxR = 78
 
 maxZ = 105
 
 dNdeta = 2 * 180 * 2
 
 Repacking
 
 clustering
 
compression BCO = 10e6
 
 DataPlotRangeBCO =10000
 
 TimeSpan = n/full_rate
 
 TimeSpanBCO = int64(TimeSpan*BCO)
 
 TriggerBCO = poissrnd(trig_rate/BCO, TimeSpanBCO, 1)'
 
 CollisionBCO =poissrnd((full_rate - trig_rate)/BCO ,TimeSpanBCO, 1)' + TriggerBCO
 
Per triggger PerTriggerBCO = int64(trigger_window * BCO)
 
 RRing = repmat(linspace(minR, maxR, nRing )',1,PerTriggerBCO)
 
 zBCO = repmat(linspace(maxZ, 0, PerTriggerBCO),nRing,1)
 
 MinEtaRingBCO = atanh( (zBCO - 10) ./ sqrt((zBCO - 10).^2 + RRing.^2) )
 
 dEtaRingBCO = atanh( (zBCO + maxZ/double(PerTriggerBCO) ) ./ sqrt((zBCO + maxZ/double(PerTriggerBCO) ).^2 + RRing.^2) ) - atanh( zBCO ./ sqrt(zBCO.^2 + RRing.^2) )
 
 dataBitRingBCO = bitPerHit .* dNdeta .* dEtaRingBCO
 
 dataBitRingBCOAfterMask = dataBitRingBCO.*TriggerMask
 
 __pad0__
 
 c = colorbar
 
hold on
 
 FontSize = 14
 
c Label String = 'FEE data (bit) per MB collision per |z|-R bin (integrated over z-sign and azimuth)'
 
 __pad1__
 
Run the DAQ DataBCO = conv2(CollisionBCO,dataBitRingBCO)
 
 TriggerAcceptBCO = conv2(TriggerBCO,TriggerMask)
 
 ThrottleAcceptBCO = double(TriggerAcceptBCO>0)
 
 PlotDataBCO = DataBCO(:,1:DataPlotRangeBCO)
 
 PlotThrottleDataBCO = DataBCO(:,1:DataPlotRangeBCO).*ThrottleAcceptBCO(:,1:DataPlotRangeBCO)
 
 TotalDataRate = sum(sum(DataBCO))/TimeSpan
 
 TriggerDataRate = sum(sum(DataBCO.*TriggerAcceptBCO))/TimeSpan
 
 ThrottleDataRate = sum(sum(DataBCO.*ThrottleAcceptBCO))/TimeSpan
 
for i
 
 gcf
 
 __pad2__
 
 ylim = get(gca,'YLim')
 
 y_max = ylim(2)
 
FEE Data Rate DataRadialLayerRate = sum(DataBCO, 2) / TimeSpan
 
Collision pile up histogram nPileUpTrig = zeros( sum(TriggerBCO(PerTriggerBCO+1:(TimeSpanBCO-PerTriggerBCO))) ,1)
 
 nPileUpRnd = zeros( TimeSpanBCO - 2*PerTriggerBCO ,1)
 
 iTrig = 1
 
 __pad3__
 
 __pad4__
 
Triggered data rate = %.0f Gbps\n'
 
Triggered data ThrottleDataRateDAMCompressionFactor
 

Typedef Documentation

Definition at line 8 of file TPCRateLayered.m.

View newest version in sPHENIX GitHub at line 8 of file TPCRateLayered.m

Function Documentation

sectors and two sides else assert ( )
bar ( PlotThrottleDataBCO(nRing,:)  ,
 
)

Referenced by testing::internal::TEST(), and testing::gmock_matchers_test::TEST().

+ Here is the caller graph for this function:

bar ( FEEDataRate/  1e9)
id bitPerHit ( )
virtual
colormap ( myColorMap  )
id DAMCompressionFactor ( )
virtual
MinEtaRingBCO < TargetEta double ( )
virtual

Referenced by PHG4TpcDetector::add_geometry_node(), MakeActsGeometry::addActsTpcSurfaces(), TrkrHitv2::addEnergy(), approx(), Fe55::BaLiC(), Bias::Bias(), Polygon::calculate_centroid(), Polyhedron::calculate_centroid(), SDeltaPtCutStudy::CalculateRejectionFactors(), calculateWeights(), CBfitter(), ccbb(), centrality_newplotbg_newsupp(), Acts::detail_lt::TrackStateProxy< trajectory_t, M, ReadOnly >::chi2(), InttClusterizer::ClusterLadderCells(), InttClusterizer::ClusterLadderCellsRaw(), PHG4EPDDetector::construct_block(), PHG4SpacalPrototypeDetector::Construct_LightGuide(), PHG4SpacalPrototype4Detector::Construct_LightGuide(), PHG4FullProjTiltedSpacalDetector::Construct_LightGuide(), PHG4InttDetector::ConstructIntt(), PHG4EICMvtxDetector::ConstructMvtx_Layer(), PHG4MvtxDetector::ConstructMvtx_Layer(), genfit::MeasurementCreator::create(), crossterms(), cs_time(), ratio_cut_partition::cutratio(), Acts::CylinderVolumeBounds::CylinderVolumeBounds(), PHG4InttDigitizer::DigitizeLadderCells(), DivideCanvas(), HybridHadronization::DoHadronization(), genfit::EventDisplay::drawEvent(), FFT::DTrans(), EMCalTowerRingStudy(), hcal::evLoop(), ExploreTTrees(), fakee_invmass(), Fe55::Fe55(), FFT::FFT(), FillCalHist(), FillRawHist(), Square::find_outside(), PHG4CylinderGeomv4::find_segment_center(), PHG4CylinderGeomv4::find_strip_center(), CylinderGeomIntt::find_strip_center_localcoords(), CylinderGeomIntt::find_strip_index_values(), fit_vs_directcount(), Ohit::FitX(), Fun4AllPythia(), PHTruthClustering::G4ClusterSize(), SvtxTruthEval::G4ClusterSize(), G__STACalorimeterCharacterization_Dict_194_0_12(), Matter::generate_vac_z(), Matter::generate_vac_z_w_M(), PHG4CylinderGeom_Spacalv1::get_azimuthal_distance(), PHG4CylinderGeom_Spacalv3::geom_tower::get_position_fraction_x_in_sub_tower(), PHG4CylinderGeom_Spacalv3::geom_tower::get_position_fraction_y_in_sub_tower(), PHG4CylinderGeom_Spacalv2::get_sec_azimuthal_width(), PHG4CylinderGeom_Spacalv3::geom_tower::get_sub_tower_ID_x(), PHG4CylinderGeom_Spacalv3::geom_tower::get_sub_tower_ID_y(), getBinPosition(), SecondaryVertexFinder::getCircleXYTrack(), fullRunningMean::getMean(), pseudoRunningMean::getMean(), STrackMatcherComparator::GetNewTreeHists(), Eventplaneinfov1::GetPsi(), EpFinder::GetPsiInRange(), MakeActsGeometry::getTpcHitSetKeyFromCoords(), PHG4CylinderGeom_Spacalv1::init_default_sector_map(), TpcSimpleClusterizer::is_in_sector_boundary(), PHG4TpcPadBaselineShift::is_in_sector_boundary(), TpcClusterizer::is_in_sector_boundary(), PHG4CylinderGeom_Spacalv3::load_demo_sector_tower_map4(), look_purity(), main(), Proto4ShowerCalib::MakeAna(), newplotbg_newsupp(), newplotbg_newsupp_2021(), newplotbg_newsupp_2022(), newplotbg_newsupp_2022_60pct(), PHG4InnerHcalSteppingAction::NoHitSteppingAction(), PHG4OHCalSteppingAction::NoHitSteppingAction(), Acts::detail_lt::TrackStateProxy< trajectory_t, M, ReadOnly >::pathLength(), plotembed_vscent(), plotpirej(), Fe55::PlotXlines(), PktSizeMon::Print(), process_event(), TpcPrototypeClusterizer::process_event(), TpotMon::process_event(), EventPlaneReco::process_event(), MicromegasClusterizer::process_event(), TPCGemGainCalb::process_event(), PHG4MvtxHitReco::process_event(), PHG4InttHitReco::process_event(), PHG4MicromegasHitReco::process_event(), sPHAnalysis::process_event_pairs(), PairMaker::process_event_test(), PktSizeMon::putmapinhisto(), EpInfo::Range(), ratio_cut_partition::ratio_of_node_A2B(), ratio_cut_partition::ratio_of_node_B2A(), MvtxAlign::ReadAlignmentParFile(), Hydroinfo_MUSIC::readHydroData(), HybridHadronization::recomb(), EpFinder::Results(), HybridHadronization::set_spacetime_for_pythia_hadrons(), MakeActsGeometry::setPlanarSurfaceDivisions(), fm_partition::shuffle_vector(), RawTowerDigitizer::simple_photon_digitization(), SimX::Simulator(), HybridHadronization::stringprep(), Svtx_Cells(), TEST(), testing::gmock_generated_actions_test::TEST(), Acts::detail_vmt::VectorMultiTrajectoryBase::Statistics::toStream(), tower_in_ring(), TpcClusterMover::TpcClusterMover(), TPCEventDisplay(), TPCEventDisplay_Updated(), TPCEventDisplay_Updated_BCO(), TrackCaloDist(), TrackClusterEnergy(), MvtxStandaloneTracking::TrackFitXY(), MvtxStandaloneTracking::TrackFitZY(), PHG4TpcPadPlaneReadout::UpdateInternalParameters(), PHG4InnerHcalSteppingAction::UserSteppingAction(), PHG4OHCalSteppingAction::UserSteppingAction(), and ActsExamples::VertexPerformanceWriter::writeT().

figure ( 'name ,
'PerEventData'  ,
'PaperPositionMode ,
'auto ,
... 'position  
)
Event stream display figure ( 'name ,
'DataStream'  ,
'PaperPositionMode ,
'auto ,
... 'position  
)
'name','DataStream1D','PaperPositionMode','auto', ... 'position',[100,0,2400,800] figure ( )
virtual
end FEE Data Rate Plot figure ( 'name ,
'FEEDataRate'  ,
'PaperPositionMode ,
'auto ,
... 'position  
)
end figure ( 'name ,
'nPileUp'  ,
'PaperPositionMode ,
'auto ,
... 'position  
)
fprintf ( 'Throttled event total = %.3f;Throttled data/total=%.3f;Triggered event/total=%.3f;Triggered data/total==%.3f\n',
...%n_recorded n,
recorded_data n,
n_triggered./  n,
triggered_data n 
)
fprintf ( '------------\n )
fprintf ( full_rate = %.0f kHz;trig_rate=%.0f kHz;trigger_window=%.1f us;Time span=%.3f s\n',
...full_rate 1e3,
trig_rate 1e3,
trigger_window 1e6,
TimeSpan   
)
fprintf ( 'per event effective  track = %.0f,
per event FEE  data = %.0f bits,
total FEE data  rate = %.0f Gbps\n',
  meansum(dEtaRingBCO, 2)*180 *2,
sum(sum(dataBitRingBCO))  ,
sum(sum(DataBCO))/TimeSpan 1e9 
)
fprintf ( 'Trigger rate *drift  window = %.2f;Full rate *drift window=%.2f;Trigger rate/full rate=%.2f(input)/%.2f(MC);\n',
...trig_rate trigger_window,
full_rate trigger_window,
trig_rate full_rate,
sum(TriggerBCO)/sum(CollisionBCO  
)
fprintf ( 'throttled data total = %.3f;Triggered data/total=%.3f;throttled/trigger=%.3f;Triggered data/Per event data=%.3f\n',
...ThrottleDataRate TotalDataRate,
...TriggerDataRate TotalDataRate,
...ThrottleDataRate TriggerDataRate,
...sum(sum(DataBCO.*TriggerAcceptBCO))./(sum(sum(dataBitRingBCOAfterMask)).*sum(TriggerBCO))  ... 
)
fprintf ( 'throttled event total = %.3f;Triggered event/total==%.3f;throttled/trigger=%.3f\n',
...%recorded_data n,
triggered_data n,
recorded_data triggered_data 
)
imagesc ( PlotThrottleDataBCO  )
myColorMap ( ,
 
)
end nPileUpRnd ( i-PerTriggerBCO 1)
nPileUpTrig ( iTrig  )
plot ( 'k--'  )
plot ( 'r-'  ,
'LineWidth'  ,
 
)
[i i], [-1 nRing],'k--','LineWidth',2 plot ( )
staticvirtual

Definition at line 244 of file usm.C.

View newest version in sPHENIX GitHub at line 244 of file usm.C

References AtoB, c2, cd(), cs_all, cs_off, Draw(), Acts::UnitConstants::e, file, fs_off, line, MakeDCA2DResolution(), MakeEfficiency(), MakeEfficiencyFast(), MakePtResolution(), MakeTH1F(), myText(), run_number, SetLineColor(), SetLineWidth(), SetMaximum(), SetOptStat(), SetsPhenixStyle(), tcsn, tDQ(), tfsn, and tMap().

+ Here is the call graph for this function:

plot ( 'k-'  ,
'LineWidth'  ,
 
)
plot ( [-.15 -.15] .*  y_max,
'r-'  ,
'LineWidth'  ,
 
)
plot ( [-.1 -.1] .*  y_max,
'k-'  ,
'LineWidth'  ,
 
)
RRing ( ,
 
)
SaveCavas ( 'TPCRateLayered'  ,
gcf   
)
SaveCavas ( SaveName  ,
gcf   
)
set ( gca  ,
'YDir'  ,
'normal'   
)
set ( gca  ,
'YLim'   
)
set ( gca  ,
'XLim'   
)
subplot ( ,
,
 
)
subplot ( ,
,
 
)
subplot ( ,
,
 
)
sum ( DataRadialLayerRate((8+1):(8+16))  )

Referenced by Acts::WeightedComponentReducerLoop::absoluteMomentum(), AnalyticFieldModel::AnalyticFieldModel(), approx(), Average(), gbl::BorderedBandMatrix::bandOfAVAT(), BOOST_AUTO_TEST_CASE(), Acts::Test::BOOST_AUTO_TEST_CASE(), BOOST_DATA_TEST_CASE(), calc_mxj(), genfit::calcAverageState(), calccorr(), TpcMon::calculateMedianAndStdDev(), Acts::WeightedComponentReducerLoop::charge(), trento::Event::compute_reduced_thickness(), computeSd(), Acts::WeightedComponentReducerLoop::cov(), ActsExamples::detail::NuclearInteractionParametrisation::cumulativePDGprobability(), deltas(), distance(), Draw_BDiJetImbalance(), ActsExamples::TrackFindingFromPrototrackAlgorithm::finalize(), FitVerticalScan(), PHG4Showerv1::get_edep(), PHG4Showerv1::get_eion(), get_invmass_smeared(), min_tree::get_min_tree_length(), PHG4Sector::Sector_Geometry::get_total_thickness(), Acts::GaussianGridTrackDensity< mainGridSize, trkGridSize >::getDensitySum(), Acts::AdaptiveGridTrackDensity< spatialTrkGridSize, temporalTrkGridSize >::getDensitySum(), PHActsInitialVertexFinder::getIVFTracks(), hLabHelper::hLabHelper(), langaufun(), check_end_of_file::main(), fix_pragma::main(), check_include_guards::main(), mask_pixels(), eic_dual_rich::mean_cherenkov_angle(), Acts::AtlasBetheHeitlerApprox< NComponents, PolyDegree >::mixture(), Acts::WeightedComponentReducerLoop::momentum(), nfits(), gbl::VMatrix::operator*(), Acts::WeightedComponentReducerLoop::pars(), PHmd5Stream(), plotembed_vscent(), ActsExamples::detail::NuclearInteractionParametrisation::prepareMomenta(), TemplateCreation::process_event(), PHG4MicromegasHitReco::process_event(), process_histos(), proj(), ps(), pybksb(), pyldcm(), pyreco(), Acts::WeightedComponentReducerLoop::qOverP(), genfit::tools::QR(), rebin_TH1D(), Resolution(), rms(), ActsFatras::NuclearInteraction::sampleMomenta(), eic_dual_rich::SD_cherenkov_angle(), stack::stack(), AnnularFieldSim::sum_field_at(), AnnularFieldSim::sum_full3d_field_at(), AnnularFieldSim::sum_local_field_at(), AnnularFieldSim::sum_nonlocal_field_at(), AnnularFieldSim::sum_phislice_field_at(), testing::internal::SumOverTestCaseList(), TEST_CASE(), Acts::WeightedComponentReducerLoop::time(), Acts::WeightedComponentReducerLoop::toVector3(), genfit::tools::transposedForwardSubstitution(), and zdc_calib().

sum ( DataRadialLayerRate((8+1+16):(8+16+16))  )
sum ( DataRadialLayerRate((16+1):(16+16))  )
sum ( DataRadialLayerRate((16+1+16):(16+16+16))  )
sum ( sum(DataBCO.*TriggerAcceptBCO )
title ( sprintf('FEE data(bit) per MB collision per|z|-R bin, total=%.1f Mbit', sum(sum(dataBitRingBCO))/1e6)  ,
'FontSize ,
16   
)
title ( sprintf('FEE data(bit) after DAM acceptance filtering, total=%.1f Mbit', sum(sum(dataBitRingBCOAfterMask))/1e6)  ,
'FontSize ,
16   
)
title ( sprintf('FEE data input to DAM.Rate=%.0f Gbps @%.0f kHz Collision,%.0f kHz Trigger%.0f us Drift',...sum(sum(DataBCO))/TimeSpan/1e9, full_rate/1e3, trig_rate/1e3, trigger_window *1e6)  ,
'FontSize ,
16   
)
title ( sprintf('DAM data output:Throttled data rate=%.0f Gbps, Triggered data rate=%.0f Gbps ',...ThrottleDataRate *DAMCompressionFactor/1e9,...TriggerDataRate *DAMCompressionFactor/1e9...)  ,
'FontSize ,
16   
)
title ( sprintf('FEE data input to DAM.Total=%.0f Gbps @%.0f kHz Collision,%.0f kHz Trigger%.0f us Drift',...sum(sum(DataBCO))/TimeSpan/1e9, full_rate/1e3, trig_rate/1e3, trigger_window *1e6)  ,
'FontSize ,
12   
)
title ( sprintf('Collision trigger:<#collision in TPC window >=%.2f @%.0f kHz Collision,%.0f us Drift',...mean(nPileUpTrig),...full_rate/1e3, trigger_window *1e6)  ,
'FontSize ,
16   
)
title ( sprintf('Random trigger:<#collision in TPC window >=%.2f @%.0f kHz Collision,%.0f us Drift',...mean(nPileUpRnd),...full_rate/1e3, trigger_window *1e6)  ,
'FontSize ,
16   
)
xlabel ( 'BCO bin(100 ns)'  ,
'FontSize ,
14   
)
xlabel ( 'Module Number'  ,
'FontSize ,
16   
)
xlabel ( 'Number of collisions in TPC drift window'  ,
'FontSize ,
14   
)
ylabel ( 'R position(cm)'  ,
'FontSize ,
14   
)
ylabel ( 'R position ,
'FontSize ,
14   
)
ylabel ( 'Radial layer number'  ,
'FontSize ,
14   
)
ylabel ( 'Data in last TPC layer(bit/BCO)'  ,
'FontSize ,
14   
)
ylabel ( 'Average data rate per FEE(Gbps)'  ,
'FontSize ,
16   
)
ylabel ( 'Count per bin'  ,
'FontSize ,
14   
)

Variable Documentation

__pad0__

Definition at line 82 of file TPCRateLayered.m.

View newest version in sPHENIX GitHub at line 82 of file TPCRateLayered.m

__pad1__

Definition at line 106 of file TPCRateLayered.m.

View newest version in sPHENIX GitHub at line 106 of file TPCRateLayered.m

__pad2__

Definition at line 226 of file TPCRateLayered.m.

View newest version in sPHENIX GitHub at line 226 of file TPCRateLayered.m

__pad3__

Definition at line 369 of file TPCRateLayered.m.

View newest version in sPHENIX GitHub at line 369 of file TPCRateLayered.m

__pad4__

Definition at line 380 of file TPCRateLayered.m.

View newest version in sPHENIX GitHub at line 380 of file TPCRateLayered.m

compression BCO = 10e6

Definition at line 50 of file TPCRateLayered.m.

View newest version in sPHENIX GitHub at line 50 of file TPCRateLayered.m

c = colorbar

Definition at line 83 of file TPCRateLayered.m.

View newest version in sPHENIX GitHub at line 83 of file TPCRateLayered.m

clustering

Definition at line 48 of file TPCRateLayered.m.

View newest version in sPHENIX GitHub at line 48 of file TPCRateLayered.m

CollisionBCO =poissrnd((full_rate - trig_rate)/BCO ,TimeSpanBCO, 1)' + TriggerBCO

Definition at line 58 of file TPCRateLayered.m.

View newest version in sPHENIX GitHub at line 58 of file TPCRateLayered.m

Triggered data ThrottleDataRate TriggerDataRate * DAMCompressionFactor

Definition at line 414 of file TPCRateLayered.m.

View newest version in sPHENIX GitHub at line 414 of file TPCRateLayered.m

Run the DAQ DataBCO = conv2(CollisionBCO,dataBitRingBCO)

Definition at line 133 of file TPCRateLayered.m.

View newest version in sPHENIX GitHub at line 133 of file TPCRateLayered.m

dataBitRingBCO = bitPerHit .* dNdeta .* dEtaRingBCO

Definition at line 71 of file TPCRateLayered.m.

View newest version in sPHENIX GitHub at line 71 of file TPCRateLayered.m

dataBitRingBCOAfterMask = dataBitRingBCO.*TriggerMask

Definition at line 74 of file TPCRateLayered.m.

View newest version in sPHENIX GitHub at line 74 of file TPCRateLayered.m

DataPlotRangeBCO =10000

Definition at line 51 of file TPCRateLayered.m.

View newest version in sPHENIX GitHub at line 51 of file TPCRateLayered.m

FEE Data Rate DataRadialLayerRate = sum(DataBCO, 2) / TimeSpan

Definition at line 300 of file TPCRateLayered.m.

View newest version in sPHENIX GitHub at line 300 of file TPCRateLayered.m

dEtaRingBCO = atanh( (zBCO + maxZ/double(PerTriggerBCO) ) ./ sqrt((zBCO + maxZ/double(PerTriggerBCO) ).^2 + RRing.^2) ) - atanh( zBCO ./ sqrt(zBCO.^2 + RRing.^2) )

Definition at line 70 of file TPCRateLayered.m.

View newest version in sPHENIX GitHub at line 70 of file TPCRateLayered.m

dNdeta = 2 * 180 * 2

Definition at line 46 of file TPCRateLayered.m.

View newest version in sPHENIX GitHub at line 46 of file TPCRateLayered.m

Referenced by DrawTPCDataStreamEmulator().

c Label FontSize = 14

Definition at line 95 of file TPCRateLayered.m.

View newest version in sPHENIX GitHub at line 95 of file TPCRateLayered.m

full_rate = 100e3

Definition at line 14 of file TPCRateLayered.m.

View newest version in sPHENIX GitHub at line 14 of file TPCRateLayered.m

gcf

Definition at line 217 of file TPCRateLayered.m.

View newest version in sPHENIX GitHub at line 217 of file TPCRateLayered.m

for i
Initial value:
if (TriggerBCO(i) >0)
plot([i i], [-3 nRing],'r--','LineWidth',2)

Definition at line 164 of file TPCRateLayered.m.

View newest version in sPHENIX GitHub at line 164 of file TPCRateLayered.m

iTrig = 1

Definition at line 348 of file TPCRateLayered.m.

View newest version in sPHENIX GitHub at line 348 of file TPCRateLayered.m

MinEtaRingBCO = atanh( (zBCO - 10) ./ sqrt((zBCO - 10).^2 + RRing.^2) )

Definition at line 68 of file TPCRateLayered.m.

View newest version in sPHENIX GitHub at line 68 of file TPCRateLayered.m

n = 1000

Definition at line 13 of file TPCRateLayered.m.

View newest version in sPHENIX GitHub at line 13 of file TPCRateLayered.m

nPileUpRnd = zeros( TimeSpanBCO - 2*PerTriggerBCO ,1)

Definition at line 346 of file TPCRateLayered.m.

View newest version in sPHENIX GitHub at line 346 of file TPCRateLayered.m

Collision pile up histogram nPileUpTrig = zeros( sum(TriggerBCO(PerTriggerBCO+1:(TimeSpanBCO-PerTriggerBCO))) ,1)

Definition at line 345 of file TPCRateLayered.m.

View newest version in sPHENIX GitHub at line 345 of file TPCRateLayered.m

sectors and two sides elseif nRing = 40

Definition at line 35 of file TPCRateLayered.m.

View newest version in sPHENIX GitHub at line 35 of file TPCRateLayered.m

hold on

Definition at line 85 of file TPCRateLayered.m.

View newest version in sPHENIX GitHub at line 85 of file TPCRateLayered.m

Referenced by mg_open_listening_socket(), and mg_set_non_blocking_mode().

Per triggger PerTriggerBCO = int64(trigger_window * BCO)

Definition at line 63 of file TPCRateLayered.m.

View newest version in sPHENIX GitHub at line 63 of file TPCRateLayered.m

PlotDataBCO = DataBCO(:,1:DataPlotRangeBCO)

Definition at line 137 of file TPCRateLayered.m.

View newest version in sPHENIX GitHub at line 137 of file TPCRateLayered.m

PlotThrottleDataBCO = DataBCO(:,1:DataPlotRangeBCO).*ThrottleAcceptBCO(:,1:DataPlotRangeBCO)

Definition at line 138 of file TPCRateLayered.m.

View newest version in sPHENIX GitHub at line 138 of file TPCRateLayered.m

Repacking

Definition at line 48 of file TPCRateLayered.m.

View newest version in sPHENIX GitHub at line 48 of file TPCRateLayered.m

RRing = repmat(linspace(minR, maxR, nRing )',1,PerTriggerBCO)

Definition at line 65 of file TPCRateLayered.m.

View newest version in sPHENIX GitHub at line 65 of file TPCRateLayered.m

SaveName = sprintf('TPCRateLayered_%.0fHzCol_%.0fHzTrig_%.0fusDrift_nRing%d',full_rate,trig_rate,trigger_window*1e6, nRing)

Definition at line 38 of file TPCRateLayered.m.

View newest version in sPHENIX GitHub at line 38 of file TPCRateLayered.m

c Label String = 'FEE data (bit) per MB collision per |z|-R bin (integrated over z-sign and azimuth)'

Definition at line 97 of file TPCRateLayered.m.

View newest version in sPHENIX GitHub at line 97 of file TPCRateLayered.m

TargetEta = 1.1

Definition at line 32 of file TPCRateLayered.m.

View newest version in sPHENIX GitHub at line 32 of file TPCRateLayered.m

ThrottleAcceptBCO = double(TriggerAcceptBCO>0)

Definition at line 135 of file TPCRateLayered.m.

View newest version in sPHENIX GitHub at line 135 of file TPCRateLayered.m

ThrottleDataRate = sum(sum(DataBCO.*ThrottleAcceptBCO))/TimeSpan

Definition at line 142 of file TPCRateLayered.m.

View newest version in sPHENIX GitHub at line 142 of file TPCRateLayered.m

TimeSpan = n/full_rate

Definition at line 53 of file TPCRateLayered.m.

View newest version in sPHENIX GitHub at line 53 of file TPCRateLayered.m

TimeSpanBCO = int64(TimeSpan*BCO)

Definition at line 54 of file TPCRateLayered.m.

View newest version in sPHENIX GitHub at line 54 of file TPCRateLayered.m

TotalDataRate = sum(sum(DataBCO))/TimeSpan

Definition at line 140 of file TPCRateLayered.m.

View newest version in sPHENIX GitHub at line 140 of file TPCRateLayered.m

trig_rate = 15e3

Definition at line 15 of file TPCRateLayered.m.

View newest version in sPHENIX GitHub at line 15 of file TPCRateLayered.m

trigger_window = 18e-6

Definition at line 16 of file TPCRateLayered.m.

View newest version in sPHENIX GitHub at line 16 of file TPCRateLayered.m

TriggerAcceptBCO = conv2(TriggerBCO,TriggerMask)

Definition at line 134 of file TPCRateLayered.m.

View newest version in sPHENIX GitHub at line 134 of file TPCRateLayered.m

TriggerBCO = poissrnd(trig_rate/BCO, TimeSpanBCO, 1)'

Definition at line 57 of file TPCRateLayered.m.

View newest version in sPHENIX GitHub at line 57 of file TPCRateLayered.m

TriggerDataRate = sum(sum(DataBCO.*TriggerAcceptBCO))/TimeSpan

Definition at line 141 of file TPCRateLayered.m.

View newest version in sPHENIX GitHub at line 141 of file TPCRateLayered.m

y_max = ylim(2)

Definition at line 232 of file TPCRateLayered.m.

View newest version in sPHENIX GitHub at line 232 of file TPCRateLayered.m

Referenced by DrawTower_EMCTrigEff(), DrawTower_EMCTrigEff_SlideingWindow2(), Martini::getMomentumTransfer(), and Summary().

ylim = get(gca,'YLim')

Definition at line 231 of file TPCRateLayered.m.

View newest version in sPHENIX GitHub at line 231 of file TPCRateLayered.m

zBCO = repmat(linspace(maxZ, 0, PerTriggerBCO),nRing,1)

Definition at line 66 of file TPCRateLayered.m.

View newest version in sPHENIX GitHub at line 66 of file TPCRateLayered.m