Relayer Guide
Relayer Guide
Binh Dam's
.NET RELAYER
Binh Dam's
.NET RELAYER
Contents
Product Background and Overview........................................................................3 Installation...............................................................................................................4 What's New in .NET Relayer 2.2?..........................................................................5 Navigating COMTRADE Files.................................................................................6 Simulating Relay Operation....................................................................................7 Plotting Data............................................................................................................9 Manipulating Plots.................................................................................................10 Plotting Formulas..................................................................................................11 Building Your Own Relay Functions......................................................................12 Advanced Prototyping...........................................................................................14 About the Provided Samples................................................................................17 Contact Information...............................................................................................18
Copyright June 2009, Q. Binh Dam. The .NET Relayer name and logo are trademarks of Q. Binh Dam.
Binh Dam's
.NET RELAYER
Copyright June 2009, Q. Binh Dam. The .NET Relayer name and logo are trademarks of Q. Binh Dam.
Binh Dam's
.NET RELAYER
Installation
Compatible software and operating systems: Windows 98, ME, NT4, 2000, XP (32-bit), Vista (32-bit), 7 (32-bit) .NET Framework versions 1.0, 1.1, 2.0, 3.0, 3.5, 4.0.
An installation program automatically configures the .NET Relayer software for immediate use on your computer. You may need administrator privileges to install the software on recent operating systems. If you downloaded the software in ZIP format, you need to extract the setup program from the ZIP file. The steps of the installation program are: 1. Welcome screen 2. License agreement 3. Install location selection 4. Program shortcuts (Desktop and Start Menu | Programs)
To uninstall .NET Relayer, use the Add/Remove Programs command from the Windows control panel.
Copyright June 2009, Q. Binh Dam. The .NET Relayer name and logo are trademarks of Q. Binh Dam.
Binh Dam's
.NET RELAYER
Corrected Issues
The grid appears underneath the plots in both plot editor and graphics copied to the clipboard. Transparent plot backgrounds appear in white instead of black and transparent plot areas appear in the same color as the background. Plots with data series containing NaN values, guesses are drawn in the plot area and shown in the trace window. The response time has been significantly improved when selecting all series in the data series editor and creating the corresponding plots.
Copyright June 2009, Q. Binh Dam. The .NET Relayer name and logo are trademarks of Q. Binh Dam.
Binh Dam's
.NET RELAYER
4 3 2
Copyright June 2009, Q. Binh Dam. The .NET Relayer name and logo are trademarks of Q. Binh Dam.
Binh Dam's
.NET RELAYER
Copyright June 2009, Q. Binh Dam. The .NET Relayer name and logo are trademarks of Q. Binh Dam.
Binh Dam's
.NET RELAYER
Copyright June 2009, Q. Binh Dam. The .NET Relayer name and logo are trademarks of Q. Binh Dam.
Binh Dam's
.NET RELAYER
Plotting Data
The .NET Relayer software has the capability to graphically represent data from COMTRADE files and data computed from relay simulations and other analyses. The steps to plot data are as follows: 1. Select the waveforms to plot from the Data Series window 2. To plot all waveforms against time, click Data | Plot | Plot Selected Series, or use the Plot toolbar button . Optionally, specify the destination editor.
3. To plot a family of waveforms, click Data | Plot | Plot Series Family. Plot families are drawn with shades of the same color. 4. To plot one waveform versus another (complex trajectories), click Data | Plot | X:<name1>; Y:<name2> 5. To plot a subset of certain waveforms against time, select the rows to plot and click Data | Plot | Plot Selected Rows (as shown in the illustration below).
2 3,4 1 5
Copyright June 2009, Q. Binh Dam. The .NET Relayer name and logo are trademarks of Q. Binh Dam.
Binh Dam's
.NET RELAYER
Manipulating Plots
The .NET Relayer software includes powerful plotting tools to achieve a wide range of displays: 1. Plot manager to select active displays and view/copy legend. The plot manager automatically appears upon plotting data for the first time. The plot manager can be activated using View | Plot Manager or from the toolbar. 2. Properties Window to modify plot attributes (line, color, transparency, limits, scale, offset, axes, title, symbols/glyphs). 3. Trace window that displays graph coordinates. To activate Trace for any waveform: 1. Click View | Show Cursors from the main menu. 2. Select the waveforms to trace from the Plot Manager and set the ShowCursor property to true. 3. A small square appears on each plot activated for cursor display, and coordinates are updated in the Trace window as you move the cursor. 4. Zoom tools to pan, focus on details or to return to graph overviews. 5. Easy setup of relay zones for visualizations (Plot | Setup Relay Zones). 6. Copy plots and legend to clipboard (Edit | Copy as Bitmap/Metafile).
6 4 1
5 2
Copyright June 2009, Q. Binh Dam. The .NET Relayer name and logo are trademarks of Q. Binh Dam.
10
Binh Dam's
.NET RELAYER
Plotting Formulas
.NET Relayer allows users to plot (mathematical) formulas to check if waveforms obey certain criteria. Mathematical plots are easy to create and configure: 1. Use the Plot menu to select which type of plot to insert: function plots, parametric plots, and polar plots. A plot is inserted and drawn with default settings. 2. Use the Split view (View | Split) to show the code editor side-by-side with the graphical display. 3. In the Code view, under Fragments, select Formula (XFormula or YFormula for parametric plots). 4. Type a return expression (C#). If private variables, initialization code, or external references are needed, or to change the language, see Advanced topics in this guide. 5. Click Compile | Compile Plot Group or use the toolbar button to apply changes. The plot editor is automatically updated with the new plots. 6. Mathematical plots can be manipulated the same way as waveform plots as described in Section: Manipulating Plots.
5 2
Copyright June 2009, Q. Binh Dam. The .NET Relayer name and logo are trademarks of Q. Binh Dam.
11
Binh Dam's
.NET RELAYER
3 4
3. From the Properties Window, edit the Arguments property.
Copyright June 2009, Q. Binh Dam. The .NET Relayer name and logo are trademarks of Q. Binh Dam.
12
Binh Dam's
.NET RELAYER
6. Initialize the output variables in the AnalysisInitializer section based on the length of the input arguments defined in Step 3.
7. In the Code section, write what each member of the output variables should be based on the input arguments. Note that the MemberwiseAnalysis property of the analyzer determines whether the code section is based on each sample or on the whole data series.
8. Click Compile | Compile QuickAnalyzer or use the toolbar button. You will be warned of any errors. If there are no errors, no message will be displayed, and you may proceed to next step. 9. To use the newly created QuickAnalyzer, return to the editor for an open COMTRADE file, and start an analysis. The QuickAnalyzer appears in the list of available analyzers/relay functions:
Copyright June 2009, Q. Binh Dam. The .NET Relayer name and logo are trademarks of Q. Binh Dam.
13
Binh Dam's
.NET RELAYER
Advanced Prototyping
Custom Variables and Methods
To add code for variables and methods, switch to Code View. Select (PlotX or QuickAnalyzer) > Declarations in the Fragment List, and add the code for variables and methods in the text editor. Since these variables and methods are in the same class than the plot or QuickAnalyzer to evaluate, you can use them directly without providing the fully qualified name of the variables and methods.
> Note: the Declarations fragment uses the namespace and imports provided in the Build Options properties.
Copyright June 2009, Q. Binh Dam. The .NET Relayer name and logo are trademarks of Q. Binh Dam.
14
Binh Dam's
.NET RELAYER
1. The Reference selector lists all assemblies referenced in the active document. mscorlib.dll is always referenced and does not appear in the references list. 2. The drop-down button just right of the Add/Browse button provides shortcuts to folders where common .NET libraries are located. Shortcuts point to the application directory, the document directory (if available) and the installation folder of the utilized .NET version. SourceFiles: Lists all files which contain source code used by the input. Useful to maintain some reusable source code without having to compile it in a library. The user interface for the source file selector is very similar to the Reference Selector. UserCode: Contains any additional class declarations you need. To edit the user
15
Copyright June 2009, Q. Binh Dam. The .NET Relayer name and logo are trademarks of Q. Binh Dam.
Binh Dam's
.NET RELAYER
code, display the Code Pane by clicking the Code view button, or by activating View | Code in the menu, and look for the BuildOptions | UserCode in the Fragments tree. See also Paragraph: Custom Class Declarations.
> Note: Code in the UserCode section should be ready to build as if it was a separate file, independently from any document code. Namespaces listed in the Imports property will apply to the user code section, but you must explicitly import the namespaces in the referenced source files.
Copyright June 2009, Q. Binh Dam. The .NET Relayer name and logo are trademarks of Q. Binh Dam.
16
Binh Dam's
.NET RELAYER
Copyright June 2009, Q. Binh Dam. The .NET Relayer name and logo are trademarks of Q. Binh Dam.
17
Binh Dam's
.NET RELAYER
Contact Information
The author may be contacted through the following means: Email: [email protected] Telephone: +1 404-384-9106 Product website: http://www.qbdam-labs.net/relayer.html
Submit feedback by using the web form located at: http://www.qbdam-labs.net/1_13_Contributions.html You may also access this web form from the software using Help | Send Feedback. Additional services for the .NET Relayer software may be arranged: On-site training may be arranged for a nominal fee. Extended support and software update notification to be provided with subscription.
Copyright June 2009, Q. Binh Dam. The .NET Relayer name and logo are trademarks of Q. Binh Dam.
18
Binh Dam's
Binh Dam's
.NET RELAYER