Date post: | 22-Oct-2014 |
Category: |
Documents |
Upload: | thomas-wolf |
View: | 155 times |
Download: | 0 times |
SCILAB TOOLBOX FOR POWER SYSTEMS ANALYSYS
User’s Guide
SCILAB TOOLBOX FOR
POWER SYSTEMS ANALYSIS
Version 0.4
December 2005
User’s Guide
Alexander Céspedes [email protected]
Colombia2005
1
SCILAB TOOLBOX FOR POWER SYSTEMS ANALYSYS
User’s Guide
Contents
1. - Introduction 3
2. - Installation 3
3. - Running the programs 4
4. - Building data files 5
5. - Additional Options for the toolbox 10
6. - Files Summary 11
7. - Bibliography 11
2
SCILAB TOOLBOX FOR POWER SYSTEMS ANALYSYS
User’s Guide
USER’S GUIDE
1. INTRODUCTION
The Power System Analysis toolbox developed in Scilab is composed, like most simulation
software, by simple steps for its installation and execution with “key steps” for obtaining an
optimal use. Therefore, it is necessary to show the user, through this guide, the procedure to
follow.
2. INSTALLATION
The toolbox works under any operating system running the Scilab environment (Windows
and Linux). It is advise to use processors equal or upper to PENTIUM II (or their
equivalents).
For the installation, you must to follow these steps:
• Step 1: Under Windows, you must run the Scilab program.
• Step 2: Move the toolbox files to the Path of Scilab.
• Step 3: In the Scilab window, use the function “Change Directory”; the direct access is:
File/Change Directory/ “Directory name or folder name”.
• Step 4: Please, load the Analysis functions of the toolbox executing the function
“Loader” of the following way: File/Exec/ “Cargador”. If the procedure is correct, in
the screen appears the next message: “PROGRAMAS DE ANALISIS DE SISTEMAS DE
POTENCIA CARGADOS”.
• Step 5: Now, you have the analysis programs ready to execute.
3
SCILAB TOOLBOX FOR POWER SYSTEMS ANALYSYS
User’s Guide
3. RUNNING THE PROGRAMS
With the programs of the toolbox ready to execute, you have the possibility to run the
example cases and watch the different analysis and results that you can get.
For running each function of the toolbox, you only need to call the analysis function that
you require and between parentheses to introduce the case name for study. For instance, if
you need to analise a 5-buses power system (toolbox example), you can use a load flow
program by Newton-Raphson method; it is enough to write the following command in the
prompt of Scilab:
newton_raphson (‘caso5’),
Immediately, the program will be executed showing the results in the screen.
The analysis functions that the program includes are shown next:
• For Load Flow:
newton_raphson ( );
gauss_seidel ( );
• For Economic Dispatch:
despacho1 ( ); //Don’t consider the system losses
despacho2 ( ); //Consider the system losses
• For Short-Circuit:
cortocircuito ( ); //Requires the voltage and power values
4
SCILAB TOOLBOX FOR POWER SYSTEMS ANALYSYS
User’s Guide
• For Transient Stability:
euler_mod ( ); //Uses the Euler modified method
runge_kutta ( ); //Uses the 4th order Runge-Kutta method
trapezoidal ( ); //Uses the trapezoidal integration technique
The example cases in the toolbox are the following:
’caso5’ // 5-buses system
’caso9’ // 9-buses system
4. BUILDING DATA FILES
Though the toolbox includes pre-loaded data files, the user can build his/her own data files
modifying the existing files or making new files with the objective to analyze power
systems with different number of nodes.
The pre-loaded 5-buses (caso5) case has a data file based on arrays and the initialization of
several independent variables used by the analysis programs. The picture 1 shows an
example about this case. You can see in this picture that the file is composed by arrays of
data that allow the system composition; in this case, you have the buses array and the
system branches array, though it is necessary more information that will be mentioned in
the next section.
5
SCILAB TOOLBOX FOR POWER SYSTEMS ANALYSYS
User’s Guide
Picture.1. Example of the information file, case5 (5 buses pre-load system)
The way to build a data file for a power system is showed next:
• Step 1: open the programs editor in the Scilab environment. In the menu bar, you can
see the word “Editor” (version 2.7 or upper). If you apply this function, a new window
appears showing the following information:
Picture.2. Editor in Scilab screen
6
SCILAB TOOLBOX FOR POWER SYSTEMS ANALYSYS
User’s Guide
• Step 2: In the editor, you should introduce the system data. In case that you have a
Scilab version previous to the Scilab 2.7, you can work with a text editor (Notepad,
WordPad or Word). The data must be introduce in array format like it is showed in the
next picture (Picture 3).
Picture.3. Data array in the 5 nodes example
In the picture 3 you can see that the data array is built it in the same way used to introduce
an array in the Scilab environment, that is, it starts with the array name followed of the
symbols “=” “[“ these limit the assignment and beginning of the array respectively. Then,
the data are introduced, the columns are separated with a space between data and the rows
trough the symbol “;” (see the branches matrix in the picture 3). Finally, in the matrix you
must use the “]” symbol follow of “;”. You can use the data file of the case 5 as a reference
to limit the data of others cases that you want build.
7
SCILAB TOOLBOX FOR POWER SYSTEMS ANALYSYS
User’s Guide
• Step 3: when all the data of the power system has been transfered to the file, you must
save the file. In this case the toolbox read the file only with the name of the application,
that is, it doesn’t require a specific extension. For instance, if you need to save the data
file of a 20-buses power system, then you can follow the next command: File/Save As/,
afterwards appear a window with the files (see picture 4). In this window you must
introduce the name file with you desire identify the study case but don’t specify the
extension (save as “All files (*.*)”), as showed in the picture 4.
Picture.4. Scilab editor window to save files
• Step 4: If you require to apply all analysis programs of the toolbox (recommended) you
must make the following data matrix:
barras //Contents the information of the system nodes
ramas // Contents the information of the system lines
gen // Contents the information of the system buses generators
genest // Contents the transient information of the system generators
coef // Contents the information of the system coefficients B
Z1 //Topology data of system positive sequence
Z2 // Topology data of system negative sequence
Z0 // Topology data of system cero sequence
8
SCILAB TOOLBOX FOR POWER SYSTEMS ANALYSYS
User’s Guide
• Step 5: with the data array loaded, you only must introduce some values of variables
that the programs could use at the moment of its execution. In the picture 5, you can
see some of these variables.
Picture.5. Pre-load variables of the data file case 5
The variables list that you can pre-load in the data file are shown next:
alfa //Acceleration factor, recommended between 1.2 y 1.6 (Gauss-Seidel).
Epsilon //Minimal margin of error for load flow programs.
base //Basic power of the system in MVA.
factor //Multiplicity factor of the system coefficients B.
lambda //Initial value of the system incremental cost (for economic dispatch).
epsilon // Minimal margin of error for the economic dispatch programs.
j=sqrt(-1); //Variable j like complex variable validation.
fasor=-0.5+j*0.866; //Operation fasor for the sequence networks (shorcircuit).
barfa //Pre-design bus faulted (shortcircuit).
b y b1 //Start and ending buses in the faulted line (stability).
Tmax y dt //Analysis maxim time [s] and increment time (stability).
Sw y f //Switch time [s] and system frequency [Hz] (stability).
9
SCILAB TOOLBOX FOR POWER SYSTEMS ANALYSYS
User’s Guide
5. ADDITIONAL OPTIONS OF THE TOOLBOX
The analysis functions that you can execute and the flexibility in the creation and reading of
the data files with the toolbox has some of the advantages that the Scilab environment
offers for make additional operations. These options are:
• Individual execution of the auxiliary functions: as Ybarra( ) and Zbarra( ), this functions
can be execute separated in the same way that the main functions (see the numeral 3), in
case the user only requires to build the admittances and/or impedances matrix for a
specific system.
• Visualization or execution of variables stored: if the user needs specific information of
variables (arrays, vectors, internal functions) related to the package programs, the user
can use the command screen visualization by only introducing the name of the variable
that he/she requires.
• New analysis functions or routines integration: the toolbox also allows adding new
functions. The procedure is to introduce a function in Scilab (see the Scilab manual)
and if this function is based on some implemented algorithm, you must add the
implemented code and of course, to invoke it at the moment of execution when it is
needed. If it is a new function, it can be executed as a new functions file with its
respective executables codes.
10
SCILAB TOOLBOX FOR POWER SYSTEMS ANALYSYS
User’s Guide
6. FILES SUMMARY
The follow is the summary of files integrated to the toolbox:
• Documentation files
README (LÉAME)
manual.pdf
• Access data files
caso5 //Pre-design power system of 5 buses
• Functions files used by the algorithms
auxiliar.sci
cargador.sci
cortocircuito.sci
despacho.sci
estabilidad.sci
flujodecarga.sci
7. RECOMMENDED BIBLIOGRAPHY
• INTRODUCTION TO SCILAB. Scilab Group. Institut National de Recherche en
Informatique et Automatique (INRIA). Manuales On-line. 2003.
• JIMENEZ J, Andrés. Scilab. Computación numérica bajo Linux y Windows (PDF).
Universidad de Cadiz. España. 2001.
• MANUAL INTRODUCTORIO A SCILAB Y SCICOS. Grupo de Investigación en
Control Industrial (GICI). Escuela de Ingeniería Eléctrica y Electrónica. Universidad
del Valle. Cali. 2000.
• MORA E, Hector Manuel. Introducción a Scilab. Universidad Nacional de Colombia.
Departamento de Matemáticas. Bogotá. 2001.
11