source: Powering Procedure and Acceptance Criteria for the 13 kA Dipole Circuits, MP3 Procedure, <ahref="https://edms.cern.ch/document/874713">https://edms.cern.ch/document/874713</a>
%% Cell type:markdown id: tags:
# Analysis Assumptions
- We consider standard analysis scenarios, i.e., all signals can be queried. If a signal is missing, an analysis can raise a warning and continue or an error and abort the analysis.
- It is recommended to execute each cell one after another. However, since the signals are queried prior to analysis, any order of execution is allowed. In case an analysis cell is aborted, the following ones may not be executed (e.g. I_MEAS not present).
# Plot Convention
- Scales are labeled with signal name followed by a comma and a unit in square brackets, e.g., I_MEAS, [A].
- If a reference signal is present, it is represented with a dashed line.
- If the main current is present, its axis is on the left. Remaining signals are attached to the axis on the right. The legend of these signals is located on the lower left and upper right, respectively.
- The grid comes from the left axis.
- The title contains timestamp, circuit name, and signal name allowing to re-access the signal.
- The plots assigned to the left scale have colors: blue (C0) and orange (C1). Plots presented on the right have colors red (C2) and green (C3).
- Each plot has an individual time-synchronization mentioned explicitly in the description.
- If an axis has a single signal, then the color of the label matches the signal's color. Otherwise, the label color is black.
In order to perform the analysis of a FPA in an RB circuit please:
1. Select circuit name (e.g., RB.A12)
2. Choose start and end time
3. Choose analysis mode (Automatic by default)
Once these inputs are provided, click 'Find FGC PM entries' button. This will trigger a search of the PM database in order to provide a list of timestamps of FGC events associated with the selected circuit name for the provided period of time. Select one timestamp from the 'FGC PM Entries' list to be processed by the following cells.
**Note that 24 hours is the maximum duration of a single PM query for an event. To avoid delays in querying events, please restrict your query duration as much as possible.**
Table below provides timestamps ordered achronologically and represents the sequence of events that occurred in the analyzed circuit. Only the first PIC timestamp from the logging DB is reported. Note that for iQPS and nQPS only the very first PM timestamp is reported. Tables with all iQPS and nQPS PM timestamps are presented in the section dedicated to magnet quench protection analysis. The table also contains a time difference in milliseconds from the first trigger event, from the FGC and PIC trigger times.
In short, the following criteria should be kept:
- The PC PM (FGC, lhc_self) timestamp is expected within QPS PM timestamp +/-40 ms.
- Time delay between PIC and EE at an odd (RR or UJ) point is 100±50 ms.
- Time delay between PIC and EE at an even (UA) point is 600±50 ms.
warnings.warn(f"The time difference between PIC and EE ODD is not within the given range_value {value_range_ee_odd}.PIC :{min(timestamp_pic)} and EE_ODD {timestamp_ee_odd}")
warnings.warn(f"The time difference between PIC and EE EVEN is not within the given range_value {value_range_ee_even}.PIC :{min(timestamp_pic)} and EE_EVEN {timestamp_ee_even}")
```
%% Cell type:markdown id: tags:
## 3.2. Reference
Table below contains the reference event timestamps of signals used for comparison to the analyzed FPA. The reference comes as the last succesfull PNO.b2 HWC test.
- Show warning if the two PIC timestamps (ODD and EVEN) differ by more than a 1 ms. (PIC)
%% Cell type:code id: tags:
``` python
rb_analysis.analyze_pic(timestamp_pic)
```
%% Cell type:markdown id: tags:
# 6. Power Converter
## 6.1. Analysis of the Power Converter Main Current
This analysis module displays the main current of the power converter (I_MEAS) compared to the one obtained from the reference FPA (HWC PNO.b2 test with opening of EE systems and without magnet quench).
*ANALYSIS*:
- The evolution of the characteristic time $\tau$ of an exponential decay $f(t)$ is obtained as
Naturally, this formula only applies to exponential decayed characterised by a time constant. Nonetheless, for pseudo-exponential decays, this formula gives a notion of the change of the characteristic time $\tilde{\tau}$. For a circuit we compute the time-varying characteristic time as
- Characteristic time of pseudo-exponential decay of I_MEAS from t=1 to 120 s: 90 s< Tau <110 s
*PLOT*:
- The main power converter current (analyzed and reference) on the left axis, I_MEAS
- The characteristic time calculated for the main current (reference and actual) on the right axis, -I_MEAS/dI_MEAS_dt
The actual characteristic time contains steps, which indicate a quenching magnet (decrease of circuit inductance); note that for the reference one the steps are not present. Timing of PIC abort, FGC timestamp, and the maximum current are reported next to the graph.
- t = 0 s corresponds to the respective (analyzed and reference) FGC timestamps.
|DQAMCNMB_PMSTD |iQPS, DQQDL |100 mV |10 ms discrimination |U_QS0 |Old QPS. Detection of quench in one aperture based upon voltage difference between both apertures in same magnet U_QS0 >10 ms above threshold, otherwise discriminator is reset|
|DQAMCNMB_PMHSU |iQPS, nQPS |-|-|-|Firing of quench heaters by quench protection. Generation of PM buffers sometimes happens even if there is no heater firing.|
|DQAMGNSRB (slow sampling rate), DQAMGNSRB_PMREL (fast sampling rate) |nQPS, DQQDS |500 mV * |>20 ms moving average +1 ms discrimination |U_DIODE |New QPS. Detection of quench in both apertures based upon comparing voltage across the magnet (bypass diode) from 3 magnets in same half-cell and one reference from adjacent half-cell. 50Hz notch moving average filter (20ms worst case). The signals in the 2 classes are identical, only the sampling rate differs. The data with the slow sampling rate is no longer generated as they can be found in the logging database. The recording of data is usually triggered during a FPA, depending on current in circuit, and always when a symmetric quench occurs. The PM buffers are only sent if the DQAMGNS crate trips (what ever the reason).|
|DQAMGNSRB |nQPS, DQQBS| 4 mV | >10 s moving average | U_RES |New QPS. Busbar protection. The signal is not compensated for inductive voltage during ramp.|
|DQAMGNDRB_EVEN, DQAMGNDRB_ODD |iQPS, DQQDC |1 mV, 100 mV |1 s |U_HTS, U_RES |Old QPS. Leads protection. U_HTS is for the high temperature superconducting leads, and U_RES is for the room temperature leads.|
|DQAMGNDRB_EVEN, DQAMGNDRB_ODD |iQPS, DQQDB |+200 V | -50 V | U_BB1, U_BB2 |Old QPS. U_BB1 is the total voltage across the sector. U_BB2 is the voltage across the energy extraction (EE)|
|DQAMSNRB |-|-|-|-|Opening of energy extraction (EE) switches during fast power abort (FPA). 2 EE switches per sector. One for "even" points (EE2). One for "odd" points (EE1).|
*: It was 800 mV before LS1. After LS1 we changed it to 300 or 400 mV. During the training after LS1 we increased it to 500 mV.
%% Cell type:markdown id: tags:
## 8.1. Plot of Voltage Across All Magnets (U_DIODE_RB)
*PLOT*:
t = 0 s corresponds to the PM timestamp of the FGC
First plot (global)
- the power converter current on the left axis, I_MEAS
- diode voltage on the right axis, U_DIODE_RB
Second plot (zoom)
- the power converter current on the left axis, I_MEAS
- calculates the current at which a quench occured by finding the timestamp of the current dataframe (i_meas_df) closest to the quench time and the curresponding value of current - I_MEAS_quench
- compute the time difference (in milliseconds) from the first quench - dt_quench
## 8.3. Analysis of Quench Detection Voltage and Logic Signals for Quenched Magnets
%% Cell type:markdown id: tags:
*ANALYSIS*:
- finds the first timestamp, t_st_magnet_ok, for which the ST_MAGNET_OK signal is False indicating that the quench detection signal U_QS0 is outside of the +/- 100/200 mV threshold.
- for t > t_st_magnet_ok, finds the first timestamp, t_st_nqd0 for which the ST_NQD0 signal is False indicating that the U_QS0 signal is outside of the +/- 100/200 mV threshold for more than the 10 ms discrimination time. This signifies quench detection and results in triggering quench heaters;
- finds U_QS0 value at the moment of quench detection, u_ST_NQD0 = U_QS0(t=t_st_nqd0);
- if the minimum value of the absolute value of U_QS0 is above greater than 100 ms, then find the start time of a quench, t_start_quench, as a moment at which U_QS0 value is 10 mV greater than its initial value. Otherwise, the start time of a quench is set to 0 s;
- finds U_QS0 value, u_start_quench, at the moment of quench start as u_start_quench = U_QS0(t=t_start_quench);
- the slope of the quench detection signals is calculated as du_dt = (u_ST_NQD0 - u_start_quench) / (t_st_nqd0 - t_start_quench);
- the quench detection signal polarity is taken as the sign of its slope;
- the delay of the quench heaters triggering, t_delay_qh_trigger, is assumed to be the negative value of t_st_magnet_ok, t_delay_qh_trigger = -t_st_magnet_ok;
Determine source of QH trigger for nQPS signals in PM:
- calculates nQPS differences for the symmetric quench detection;
- selects only the differences that involve the quenched magnet and exclude already quenched magnets in the cell;
- for t in [-0.2 s, t_st_magnet_ok] take the maximum value of voltage difference;
- if the maximum is above 1V (considering sun glasses active from t = 0 s) and the time of maximum is less than t_st_magnet_ok, than the QH system was triggered by nQPS, otherwise iQPS;
- it is assumed that the first training quench was detected by iQPS;
*PLOT*:
t = 0 s corresponds to the PM timestamp of the QDS (iQPS or nQPS)
Upper left (iQPS analog signals)
- the quench detection voltage on the left axis, U_QS0;
- voltage across the first and the second aperture on the right axis, respectively, U_1 and U_2;
- the green box denotes an envelope of the +/- 100/200 mV quench detection threshold;
- the orange box denotes an envelope of the rise of the quench signal from its start until reaching the threshold;
Lower left (iQPS digital signals)
- the quench detection voltage on the left axis, U_QS0;
- digital quench detection signals, ST_MAGNET_OK, ST_NQD0;
- the green box denotes an envelope of the +/- 100/200 mV quench detection threshold;
- the orange box denotes an envelope of the rise of the quench signal from its start until reaching the threshold;
Upper right (nQPS analog signals)
For PM signals (global view)
- the diode voltages used by the nQPS crate for quench detection on the left axis, U_DIODE_RB and U_REF_N1;
For NXCALS signals (global view)
- the diode voltages used by the nQPS crate for quench detection on the left axis, U_DIODE_RB and U_REF_N1;
Lower right (nQPS analog signals)
For PM signals (difference view)
- the differences of diode voltages (containing the quenched magnet; in case the signals are missing, the plot is not displayed) used by the nQPS crate for quench detection on the left axis, U (Calculated U_DIODE and U_REF_N1 differences);
- the green box denotes an envelope of 1 V quench detection threshold (assuming active 'sun glasses') before the iQPS quench detection. If the nQPS difference goes outside of the envelope, it means that the quench was detected by nQPS.
For NXCALS signals (zoomed view)
- the diode voltages used by the nQPS crate for quench detection on the left axis, U_DIODE_RB and U_REF_N1;
Note: The iQPS threshold can be changed in the cell below before you run it. Now it is 0.2.
**NB: It is not a reason to fail and flag the circuit! It is just a subject to be discussed and to pay an attention.**
*ANALYSIS*:
- calculates diode lead resistance from voltage difference between board A and B and current;
NB: The offset for an inintial (not quenched) U_DIODE_RB is not yet compensated!
Note: Offset compensation is implemented in General QPS Browser from Labview MP3-tools (just in case).
*CRITERIA*
- if the maximum resistance is above 50 uOhm, then raise a warning;
- if the maximum resistance is above 150 uOhm, then raise an alarm;
*PLOT*:
Upper PM (Input view)
- the main power converter current on the left axis, IAB.I_A;
- quenched magnet voltage from two boards, U_DIODE_A, U_DIODE_B. The difference between both signals is the diode lead voltage;
- reference nQPS board voltage on the right axis, U_REF_N1;
- displayed on the left only if a quench occured no later than 2 seconds after the FGC PM timestamp;
- t = 0 s corresponds to the PM timestamp of the nQPS;
Lower PM (Output view)
- the main power converter current on the left axis, IAB.I_A;
- the calculated diode lead resistance on the right axis, R_DIODE_LEADS;
- diplayed on the left only if a quench occured no later than 2 seconds after the FGC PM timestamp;
- t = 0 s corresponds to the PM timestamp of the nQPS;
Upper CALS (Input view)
- the main power converter current on the left axis, I_MEAS;
- quenched magnet voltage from two boards is saved as a single signal, U_DIODE_RB. The two signals are stored by means of value toggling between board A and board B. The difference between both sub-signals is the diode lead voltage;
- t = 0 s corresponds to the PM timestamp of the iQPS;
Lower CALS (Output view)
- the main power converter current on the left axis, I_MEAS
- the calculated diode lead resistance on the right axis, R_DIODE_LEADS;
- t = 0 s corresponds to the PM timestamp of the iQPS;
rb_analysis.results_table[['Circuit Name','Date (FGC)','Time (FGC)','I_Q_circ','I_Q_M','R_DL_max','I at R_DL_max']]
```
%% Cell type:markdown id: tags:
## 8.6. General view of Voltage Feelers (nQPS)
Every nQPS crate (54 per circuit) has one Voltage Feeler card, so about every 3rd magnet has an earth leakage aqcuisition. It can help to localize the problem in case of an earth fault in the circuit. The simulations on some use cases had been done by STEAM-team (links?).
*Voltage Feeler STATUS*:
- if the voltage of a voltage feeler is equal to 0 V, then it means that the corresponding card is disabled;
- if the voltage of a voltage feeler is equal to -2000 V, then it means that the corresponding card is not communicating;
- otherwise it is OK;
*PLOT*:
t = 0 s corresponds to the PM timestamp of the FGC
First plot (global)
- the power converter current on the left axis, I_MEAS;
- earth voltage on the right axis, U_EARTH_RB;
Second plot (zoom)
- the power converter current on the left axis, I_MEAS;
print('Wait {} seconds to query EE temperature and status signals'.format(3*3600-time_diff))
```
%% Cell type:code id: tags:
``` python
ifnotfgc_pm_search.is_automatic_mode():
rb_analysis.results_table['FPA Reason']=get_expert_decision('Reason for FPA: ',['QPS trip','Converter trip','EE spurious opening','Spurious heater firing','Busbar quench','Magnet quench','HTS current lead quench','RES current lead overvoltage','No quench','Unknown'])