News & Info

  Technical Paper
   of the Month


  Application Note
   of the Month


  Doble Exchange

 

Tutorial: Using COMTRADE Files for Relay Testing

Jay Gosalia

Dennis Tierney

Doble Engineering Company

Introduction

Since the inception of the COMTRADE standard in 1991 (C37.111), only a small number of users were successful in using the playback of digital fault recorder data to analyze relay response to power system disturbances. The use of COMTRADE files for protection testing is still limited due to the users' lack of familiarity with the standard. A good understanding of the COMTRADE standard allows the user to easily create a new file, or modify an existing file, to test the protection.

The intent of this tutorial is to explain the basic structure of COMTRADE files and to familiarize the user with how to edit or create COMTRADE files for use in protection testing.

Overview

The user installs a Digital Fault Recorder (DFR) to capture power system events as they occur. The captured data is then used in the analysis of these events. As a result of the analysis, the user can make any necessary adjustments to the settings on the relays, breakers, transformers, etc. Captured data can also be used for the analysis of questionable operations, or non-operations, of protection schemes.

In the past, it was neither convenient nor cost effective to playback recorded data into the protection scheme to evaluate the protection performance. The test equipment and programming needed was the domain of the manufacturer. The user needed to request time from the manufacturer for the test and travel to the manufacturers site to perform the testing. Two factors inhibited the user from performing the tests themselves. First, the simulation equipment available was complicated and cost prohibitive to users. The second factor was the lack of a standard format for the data recording. Now, COMTRADE - an IEEE standard exists and modern microprocessor-based test instruments have become more affordable. They provide the user a means to playback the data to the relay and provide sufficient power to perform the tests. With standard data format and modern test instruments, the user is now able to test the complete protection scheme with the playback of actual power system events at the user's location.

Transient Testing

Transient testing provides the accurate simulation of power system events. It is an important tool the user has, to perform a thorough evaluation of protection scheme operation. Transient testing can be performed using the data created by an EMTP program or data recorded by DFRs. DFR records are generally not used for calibration testing. They are normally used for troubleshooting after a questionable operation or non-operation. Transient testing is generally used to:

  • Evaluate the scheme performance, or as an application test, to check the performance of the protection scheme under actual expected conditions.
  • Analyze the questionable operation, or non-operation, of the protection scheme during a power system disturbance.
  • Evaluate various protection scheme options to select the appropriate scheme for the intended application.

COMTRADE data files help the user to perform transient testing. Modern DFRs and digital protection can record power system events in a COMTRADE data format. It is also possible to create COMTRADE data files from simulation programs such as EMTP and ATP. All modern digital test instruments are suitable to replay power system events. The COMTRADE format is a collection of data around an event point, recorded at regular time intervals, to define the characteristics of voltage, current and the status of digital channels before, during, and after an event. This can be played back through digital test instruments, via a PC, to faithfully reproduce the stored data, point-by-point.

Summary: COMTRADE Standard

The standard defines an IBM-compatible PC DOS file format for storing waveforms, logical events and descriptive data. A set of COMTRADE files for a given event consists of three files with the following extensions:

  • *.DAT file; the data file
  • *.CFG file; the configuration file
  • *.HDR file (optional); the header file

The *.DAT file is the data file that contains the actual data samples of the recorded or simulated event. These are the digital time-tagged samples of the instantaneous values from both the analog and digital channels. The analog channels are generally voltages and currents, while the digital channels are typically the status of relay contacts. Digital channels have only two states: active or inactive, where each are represented by "1" (active) or "0" (inactive).

The structure of the data files is a series of rows and columns, similar to a spreadsheet. Each row represents a time-tagged sample. The number of columns in the data file depends upon the number of analog and digital channels included in the recording. The number of rows depends upon the sampling rate and the length of a record. If all the data values do not fit on the same line, they are continued without carriage return or line feed. The last value in the record is terminated with a carriage return or line feed.

Each row contains a separate column for the sample number, the time from the beginning of the record in microseconds, and one column for each digital and analog channel. For example, a row with six analog channels and one digital channel will have nine columns. Sequential sample rows are separated by carriage returns and line feed characters. A sample of ASCII data is shown in figure 1.

Figure 1

The data can be stored in either ASCII or Binary format. Data stored in ASCII format allows the user to view and analyze the data in a spreadsheet program of his choice. The spreadsheet can also be used to create COMTRADE data files. Binary data files should use the same structure as the ASCII files. Each data sample record for binary is arranged as follows:

  • Sample number: 4 bytes
  • Sample time: 4 bytes
  • Channel data: 2 bytes (analog)
  • Channel data: 2 bytes (status values of 16 digital inputs in each 16 bit word)

However, binary data is not easy to work with. If binary data is used, a suitable program must be employed to convert the binary data into ASCII format. ASCII data is readable and the user can easily view it using any text editor such as Windows Notepad or spreadsheet program.

The .CFG file acts as a translation guideline for the data files. It contains the information necessary to represent a power system event. It contains the following information:

  • Station name and identification
  • Total number of analog channels
  • Total number of digital channels
  • Data for each analog channel on a separate line
  • Data for each digital channel on a separate line
  • Line frequency
  • Sample rate and number of samples
  • Date and time of the first data point
  • Date and time for the trigger point
  • Data file type (ASCII or binary)

A typical configuration file is shown in figure 2.

Figure 2

Analog channel data contains information regarding the scaling of the analog data. For each analog channel, the details contain the following information:

  • Channel number
  • Channel name
  • Phase
  • Circuit
  • Units
  • Scaling (Factor "a")
  • Offset (Factor "b")
  • Skew
  • Minimum value of the data for the channel
  • Maximum value of the data for the channel
  • <CR/LF>

Typical data for the analog channel is shown in figure 3.

Figure 3

The data files and the configuration files are the mandatory files. The .HDR file is optional. The header file is a text file containing information on the event that is recorded on the .DAT file. It may contain information such as power system conditions before the disturbance, station, line, source of data, transformer details, number of disks required for the record, etc.

COMTRADE Data for Relay Testing

Digital Fault Recorders (DFRs), modern digital relays, simulation software such as EMTP and ATP can provide simulation data on power system events in COMTRADE format. This data can be used to play back events into the protection scheme using digital test instruments. In this paper, a case is described that shows how COMTRADE data can be used to evaluate relay performance. A step-by-step procedure is also described to assist the user in gaining an understanding of the procedure.

Effect of DC Offset on the Setting of a Time Overcurrent Relay

Almost all faults on the power system have some amount of DC offset in the fault current. This DC offset increases the peak value of the fault current. The amount of DC offset on the fault current depends on the fault inception angle. DC offset decays over a period of time, the length of which depends upon the time constant of the circuit that is defined by its resistance and inductance. A typical fault current waveform is shown in figure 4.

Figure 4

An Electro-mechanical relay's high-set element is susceptible to DC offset. Therefore, the setting for high-set pickup needs to be adjusted, taking the effect of DC offset into account. The effect of DC offset on static or microprocessor-based relays depends upon the design of the relay. If the relay filters out the DC offset and works only with the fundamental frequency component, the DC offset will have no affect on the relay setting. To understand how DC offset can affect the relay performance, the user should study the design of the relay and evaluate it by testing as follows. The circuit diagram used for this test is shown in figure 5.

 

Figure 5

Step 1:

Current that has a decaying DC offset has two components:

  1. The DC component, Idc, decays at a rate that follows the formula:
    Imax {e-Rt/L * Sin(
    µ-q )}
  2. The steady-state fundamental frequency component, Iac, equals:
    Imax *(sin
    wt+µ-q)

 

Note that the total current, I, at any time, t, is as per the formula shown below

I = Imax *sin (w t + µ - q ) -e -RT/L * sin (µ -q)}

Imax is the maximum value of the current. This is calculated as follows:

Imax = Vmax/ ½Z½, where Z is calculated as:

Z = Ö R2 + (wL)2 where R and L are the resistance and inductance, respectively, of the circuit

In the above example,

µ = the closing angle. It is the angle of the voltage when the switch is closed.

q = the angle of the circuit defined as: q = tan-1 (wL/R)

If the instantaneous value of the voltage is zero about to go positive when the switch is closed (t = 0), then µ = 0.

If the value of the voltage is at its maximum positive peak then µ = 90°.

If the switch is closed at the point where µ - q = + p /2, then the DC component has its maximum initial value. This is equal to the value of the maximum sinusoidal component. The DC component may have any value from zero to Imax, depending upon the instantaneous value of the voltage when the circuit is closed and the power factor of the circuit.

Step 2

  • Select the circuit parameters for the line under test.
  • Select the resistance and inductance of the line under test.
  • Select the number of samples.
  • Select the maximum steady-state fault current value. In this case, 5 amp.
  • Select the fault inception angle. In this case, -5° to get maximum offset.

A typical data sheet is shown below.

Using the formula in Step 1 and the variables defined above, the value of current for each sample point can be calculated. A typical spreadsheet is shown below.

Step 3

Now the data for each of the sample points is available. COMTRADE data samples must be an integer. The value of the data should be maximum 6-digit integer value. The data calculated in Step 1 must be converted to integer values. To do this, assume a 12-bit analog to digital converter is used to convert the analog signal to a digital sample. Also assume the minimum value of the sample is 0 and the maximum value to be 4095 (2^12-1).

From the value calculated in Step 2:

  1. Calculate the range of the sample by calculating (Imax - Imin).
  2. Assume the maximum data value in the range as 4095. (0 is the min and 4095 is the max)
  3. The multiplying factor to convert the analog value to an integer value is (Imax - Imin)/4095. This is the value "a".

Step 4

After determining the value for the multiplying factor "a", the offset factor "b" needs to be calculated. The value of "b" is the value that must be added to the value of any sample to return to the original value. Factor "b" can be calculated as follows:

  1. The instantaneous sample value in COMTRADE format is defined at ax+b, where X is the data value at any time, t.
  2. Minimum data value (x) assumed is 0 i.e. x=0 and ax=0. Therefore b = minimum analog sample value (sample value=ax+b).

Step 5

Using the value "a" and offset factor b, a separate spreadsheet can be created where the columns 1,2 and 3 are Sample number, Sample time and (Signal Value-b)/a, respectively. A typical spreadsheet is shown below.

Once the data is calculated, the spreadsheet is saved as a comma-delimited text file. The dialog box for "File Save As" is as shown in figure 6.

Figure 6

Step 6

The file will be saved with a .CSV extension. The file extension can be changed manually in Windows Explorer to a .DAT extension.

Step 7

Now the data is ready. The next step is to create a .CFG file. It may be simpler to use an existing configuration file and modify it to match the data in the data file. Figure 7,below, shows the spreadsheet for the configuration file for one current channel.

Figure 7

    • First line, Doble, 1998: indicates the station name and recording device ID
    • Second line, 1, 1A: indicates total number of channels, number of analog channels
    • Third line, 1,Phase Current, A, , A, 4.774E-03,-7.069E+00,0,0,4095: indicates the details of the analog channel. Some of the items on this line are calculated from the data values, where 4.774E-03 is the channel multiplier factor (a) and -7.069 E+00 is the channel offset adder (b).
    • Fourth line, 60: indicates the line frequency
    • Fifth line, 1: indicates the sample rate
    • Sixth line, 6000,2099: indicates the sampling rate and the last sample number
    • Seventh and eighth lines indicate the date and time stamp for the start and trigger points.
    • Ninth line, ASCII: indicates the file type of the data file

The spreadsheet for the configured data should be stored as an ASCII file with a .CFG extension. Save the configuration sheet as a comma-delimited (. CSV) file in MS-Excel. Then rename it with a .CFG extension using the same file name as the data file. Now the .DAT file and .CFG files are ready. They can be played back to observe the relay's response using a COMTRADE data playback program and a digital Power System Simulator.

By changing the values of line parameters (inductance and resistance), a fault initiation angle, series of COMTRADE files can be created. By playing this COMTRADE data into the relay with a digital Power System Simulator, the response of the relays to the DC offset can be evaluated. This exercise is very useful when a new overcurrent relay needs to be coordinated with a downstream relay of a different make or type.

Conclusion

The use of COMTRADE data allows users to simulate actual power system events using digital simulators to evaluate the protection performance. The use of a standard spreadsheet simplifies the generation of COMTRADE data. The spreadsheet can also be used to analyze the data. This facilitates the understanding of protection operation during power system events. When the suitability of various protection schemes needs to be examined, COMTRADE data files simplify the testing of "What-if" scenarios on the schemes. This helps the user to select the best scheme for the application.

Relay coordination between upstream and downstream overcurrent relays of different manufacturers or types is critical in the distribution circuit when changes to the systems are made. COMTRADE files assist the user in analyzing the response by simulating actual power system events. In the past, manufacturers were capable of performing simulated testing using EMTP software and a transient network analyzer for a particular application. However, these were performed at the users' request. Such simulations were only performed for the critical applications. All applications could not be simulated due to time and cost constraints.

Now, with the availability of digital Portable Power System Simulators and COMTRADE data, the user can simulate power system events easily, on site. The availability of affordable power system simulators allows the user to replay the DFR records at the site, at both ends of the line, using satellite synchronization. Such testing allows user to analyze the behavior of protection schemes for power system events.

References

  1. ANSI/IEEE C37.111.1991 Standard Common Format for Transient Data Exchange (COMTRADE) for Power Systems
  2. IEEE Special Publication # 96TP115-0 Relay Performance Testing, Power System Relaying Committee, Report of Working Group I 13.
  3. Using COMTRADE for Relay Testing and Fault Analysis Seminar, A.T. Giuliante
  4. Protection Scheme Testing Using a Power System Model, J.A. Jodice, Doble Engineering Company and A.T. Giuliante, ATG Exodus, International Conference of Doble Clients March 25-29, 1996.
  5. A New Philosophy for Protection Diagnostics, J.A. Jodice, Doble Engineering Company and A.T. Giuliante, ATG Exodus, Pennsylvania Electric Association Relay Committee, September 18, 1996.
  6. End-to-End Testing for Routine Maintenance, Cliff Tienken, Central Hudson Gas & Electric Corporation, Jay Gosalia, Doble Engineering Company and A.T. Giuliante, ATG Exodus, 1997 Annual Western Protective Relay Conference, October 21-23, 1997.

About The Authors

Jay Gosalia is presently working at Doble Engineering company as Protection Apparatus Product Manager. He has over 22 years of experience in the Power Engineering field, 17 of which have been dedicated to the development and marketing of Protective Relays. Prior to joining Doble Engineering, Jay was the U.S. Sales & Marketing Manager at GEC Alsthom T&D, Protection & Control Division for 13 years. Prior to GEC, Jay worked at ABB in the Circuit Breaker Division as a design and development engineer. Jay is an active member of the IEEE Power System Relaying Committee and has authored several technical papers on Protective Relays. He has a B.S. in Electrical Engineering and M.S. in Computer Science.

Dennis Tierney joined Doble Engineering Company as a Senior Application Engineer for the Relay Test Equipment Product Line in 1997. He has over 15 years of experience in the Power Engineering filed, five of which have been dedicated to Protective Relays. Before joining Doble Engineering, Dennis worked for the Salt River Project (SRP) in Arizona. At SRP, he worked as an Electrical Engineer in the Power System Protection Group, the Marketing Group, and the Controls Group. His duties in System Protection included fault studies and analysis, protection scheme design, relay settings and substation commissioning. Before SRP, Dennis worked for the Los Angeles Department of Water and Power as a High Voltage Direct Current Controls Engineer. Dennis is a member of the IEEE. He has a B. S. in Electrical Engineering from Arizona State.

Doble Engineering Company
Diagnostic Products and Services for the Electric Power Industry Since 1920


Home | About Doble | Customer Center | Products | Support | Services | Events | Contact Us | Site Map

Doble Engineering Company 85 Walnut St. Watertown, MA USA
Tel. +1 617.926.4900 Fax +1 617.926.0528
©2002 Doble Engineering Company All Rights Reserved