Transcription

1 VIII SIMPÓSIO DE ESPECIALISTAS EM PLANEJAMENTO DA OPERAÇÃO E EXPANSÃO ELÉTRICA VIII SEPOPE 9 a 3 de mao de May, 9 th to 3 rd Brasíla (DF) Brasl VIII SYMPOSIUM OF SPECIALISTS IN ELECTRIC OPERATIONAL AND EXPANSION PLANNING IP 7 Applcaton of Parallel Programmng for Desgn of Concrete Encased Groundng Electrode S. VISACRO F.* M. H. M. VALE M. A. S. BIRCHAL LATER - Groundng and Interference Lab. LPAD - Hgh Performance Processng Lab. LRC Lghtnng Research Center UFMG - Federal Unversty of Mnas Geras - Brazl SUMMARY Ths work presents a study of the possbltes for applcaton of parallel processng to the desgn of groundng systems, comprsng concrete encased electrodes. It shows the present state of the studes that are beng carred out at LRC, concernng concrete encased electrode problem. Prevously, a groundng model had been developed and mplemented wth sequental programmng paradgm. The natural parallelsm of the nvolved tasks and the large tmeconsumng characterstc of sequental processng for ths knd of applcaton justfy the use of hgh performance computaton. Ths work shows the advantages of explorng parallel processng possbltes for generaton of a geometrc coeffcent matrx, whch descrbes the basc relatons among currents and potentals at the groundng system. Dfferent software mplementaton possbltes are evaluated for a parallel program approach to solve the concrete encased electrode problem. KEYWORDS Parallel Processng, Hgh Performance Processng, Concrete Encased Groundng Electrodes, Parallel Programmng Groundng Desgn Tool.. INTRODUCTION The applcaton of hgh performance programmng technques for soluton of Electrc Power Systems problems has been ncreasng. Partcularly, parallel processng presents very promsng perspectves when heavy computaton s requred. It may consst n a feasble alternatve for soluton of several large-scale problems, whch are not well condtoned for a sequental approach. Despte ts potentalty n engneerng software development, parallel algorthm phlosophy s qute dfferent from that adopted by sequental programs. Ths pcture has been motvatng the authors to research parallel algorthms for Electrcal Engneerng applcaton n LPAD Laboratory, UFMG. Also, a specfc tool for parallel software mplementaton (CPAR) s beng developed n USP. Ths work presents nvestgatons regardng the applcaton of parallel processng to the Desgn of Concrete Encased Groundng Electrodes. The large scale computatonal effort requred for calculatons and the nherent parallelsm of the desgn tasks for ths specfc problem have justfed such research. Regardng parallel processng, groundng desgn allows dfferent approaches, whch are beng evaluated by the authors. Some of them are dscussed n ths text. Ths work s specfcally dedcated to mprove the performance of the tasks nvolved n the calculaton of a large dmenson (or order) matrx, correspondng to a lnear system of equatons. Ths matrx, provded by the model, descrbes the basc relatons among currents and potentals of the groundng system elements.. CONCRETE ENCASED ELECTRODES Groundng system s an mportant element of electrcal systems. In a very smplfed way, ts basc functon could be consdered to provde a conductve connecton between electrcal plant and sol. Such system s bascally composed by three components: () groundng electrodes (any metallc body bured n sol), () cables and connectons (whch provde electrcal contnuty between electrodes and electrcal plant) and (3) surroundng sol (element where current derved from electrcal plant s dspersed) []. * Lghtnng Research Center, Federal Unversty of Mnas Geras (UFMG), Av. Antôno Carlos Pampulha Belo Horzonte - MG - Brazl - phone/fax:

2 Durng several years, the metallc parts of hydraulc systems were employed as an alternatve groundng system. Ths practce was consdered to be a worthwhle complementary soluton for reducng the groundng mpedance of ndustral and resdental electrcal plants. Several years ago, around the 6's, a strong trend has begun for substtuton of metallc components of hydraulc systems by nsulatng materal (PVC). Snce then, the prevous practce was almost vanshed and new solutons were needed for assurng mprovement of groundng system performance. Ths has justfed the present practce of connectng earthng termnatons to metallc components of re-nforced concrete, whch may be present n buldng foundatons. Such system s commonly called "concrete encased groundng electrodes". Though such practce seems to be very effcent for several applcatons, the quanttatve evaluaton of groundng performance for ths knd of system s not a smple task. The electrode s encased nto concrete and, so, there s a non-drect contact among electrodes and sol, provded by concrete envelope. The low resstvty and hygroscopc propertes of ths materal may sgnfcantly nfluence groundng behavor. The correspondng confguraton (Fgure ) presents certan complextes, usually assocated to the presence of three dfferent materals (conductor, concrete and sol) and to ts usual non-regular geometry. Estrutura Metalc Structure Metálca 3. PROBLEM MODELING AND FORMULATION Fgure llustrates the basc elements nvolved n modelng concrete encased electrodes: a rectangular concrete block bured n horzontal poston n the sol and comprsng a cylndrcal electrode nsde t. The flow of electrc current nto the sol through the conductve electrode establshes an electrc feld n the regon nsde the concrete block and n ts vcntes. The computaton of such feld may be performed, consderng Smlarty Prncple, by means of equvalent surface elements of electrc charge (correspondng to current elements) postoned at electrode surface. The presence of ar (sem-nfnte nature of sol) may be taken nto account by means of a block mage (ncludng electrode). The dscontnuty sol-concrete may be consdered by postonng other equvalent surface elements of electrc charge at the concrete boundary. heght ε y z x r A coel hblo ρ c length ρ s sol A Solo Sol Neutral Conductor Condutor Neutro (Loop) (Loop) Junção Metalc metálca forced forçada jon Re-nforced Ferragem do steel concreto bars Concrete foundaton foot wdth Fgure - Basc Groundng Confguraton Equaton (E.) ndcates the Electrc Potental V (n reference to a remote dstance), whch s establshed by the current flow to the sol through electrode. ηs = = ds (E.) V V r r. 4πε S In the prevous ntegraton, S represents all the surfaces that contan charge elements (electrode surface + concrete-sol nterface), r s the poston of any pont over S, whose charge densty s η s, and r s the poston of any pont at electrode surface. Due to Current Contnuty Prncple, the followng relaton s observed at the boundary surfaces between concrete block and sol: J = J E = ( E, (E.) ns nc ns ρ s ρ c ) nc Fgure - Concrete Encased Groundng Confguraton Ths pcture has stmulated the authors to nvestgate and to develop a computatonal tool, whch should be able to perform the necessary calculatons for such knd of groundng desgn. The confguraton of the problem, wth the conductor and concrete surface lmtng borders, suggested the employment of the boundary element approach to model groundng system. where: J ns s the normal component of current densty n the sol, J nc s the normal component n the concrete, Ens and E nc are the correspondng electrc feld ntensty and ρ S e ρ C are respectvely sol and concrete resstvtes. On the other hand, the followng boundary condton s observed at the nterface between sol and concrete:

4 concrete by them) and the current, whch flows from concrete surface. In the algorthmc form, the groundng desgn nvolves the soluton of a set of lnear equaton, such as: Ax = b (E.3) where, x: Charge Densty Vector (η ); A: Charge Coeffcent Matrx, determned by eq. (E.); b: Vector of the Electrode Electrc Potental (V). Usually, groundng desgn nvolves the analyss of dfferent prelmnary confguratons. For each one of them, a system of lnear equatons such as (E.3) s composed and solved. Groundng resstance and potental dstrbuton over sol surface are found n each case. These parameters are employed for analyzng the performance of each confguraton and for determnng ts mprovement for achevng an optmzed soluton. Fgure 3 shows the flowchart wth the basc steps for groundng desgn, whch was employed n ths work. Begn New Confguraton Matrx A Constructon Ax=b Soluton V ks and R Calculaton Groundng Analyss Yes Change Confguraton? V rs : Potental over sol surface R: Groundng resstance No Fnal Desgn End Fgure 3 Flowchart: Steps of Desgn Procedure It s mmedately dentfed the possblty of applyng parallel processng n two stages of the desgn procedure: (a) Composton of matrx A (ncludng calculaton of ts elements); (b) Soluton of the lnear system Ax=b. Both possbltes are compatble and may be explored smultaneously. A program can work n parallel wth the matrx A calculaton, once ths stage represents a most sgnfcant challenge. Also, such applcaton presents a remarkable parallelsm for procedural tasks, whch are very tme-consumng for sequental algorthm verson. Concernng such parallelsm, all matrx elements may be ndependently calculated. Matrx A s a full matrx and, due to the complexty of expressons employed for determnng each one of ts elements, the calculaton s not trval and the sequental procedure s very tme-consumng. 5. PRELIMINARY RESEARCH The LATER s research related wth concrete encased groundng electrodes led to the development of a sequental program for the calculaton of groundng resstance and potentals over sol surface. Such potentals are establshed durng current flow through groundng electrodes due to any abnormal electrc system condton (shortcrcut etc). Such program [3] demonstrated the possblty of the numerc algorthms mplementaton for desgn and calculatons of the encased groundng electrodes. However, the tmng nvolved on the calculaton, encourage the searchng of parallel possbltes that could provde better performances. Later, one frst parallel mplementaton was developed [4], for the problem, as a result of a cooperaton among the teams of LATER, LPAD and USP. In such verson, the buld of the load coeffcents matrx was parallelzed. Ths s a very computng resource consumng phase. To perform ths parallelzaton, the orgnal C++ sequental code was ported to the Cpar language [5]. Ths s a parallel verson of the C language, that extents the C language and mplements the parallel program paradgm wth shared varables. The frst results [4] are transcrbed to the table. They demonstrate that the use of parallelsm s really able to ncrease the calculaton performance, meanngfully, when comparng the parallel and the sequental results. Ths gan s observed through the Speedup analyss, S (E.4), that s the relaton between the sequental and the parallel executon tmes [6]. sequental tme executon Speedup = (E.4) parallel tme executon These prelmnary results have motvated the authors for further developments ntend to enhance the groundng model performance. The reducton of tme processng could make t feasble the model applcaton for very complex groundng confguratons, n concrete encased groundng electrode problems. Table - Speedup Analyss A sze Sequental proc. 3 proc. 4 proc. 5 T=65 T=33 S=,97 T=4 S=,75 T= S=,95 T=63 T=8 S=,99 T=57 S=,83 T=53 S=3,8 T=658 T=33 S=,99 T=9 S=,87 T=7 S=3,8 3 T= 85 T=563 S=,9 T=39 S=,78 T=34 S=3,9 5 T=5 55 T=4349 S=3,57 T: Processng tme (s) S: Speedup 4

5 6. CONSIDERING NEW POSSIBILITIES The development strategy of a parallel computatonal tool nvolves the analyss of nnumerous aspects. Before startng parallel algorthms concepton t s extremely mportant to decde about the computatonal envronment, n a consstent way (parallel hardware archtecture, programmng language, message passng lbrares etc.). The parallel programmng can be mplemented n clusters of workstatons or mcrocomputers and, also, n supercomputers (dedcated to numerc processng). In the frst case, local area networks (LANs) are used, n addton to software, whch s responsble for communcaton of dstrbuted process among the varous network machnes. In second case, dedcated computers, wth several processors, are used. The processors are nterconnected by hgh speed nternal busses, that promote communcaton among the dstrbuted processes. Though clusters, also known as Parallel Vrtual Machnes, are much less faster then supercomputers, ther cost s sgnfcantly lower. Yet, they can provde very sgnfcant speedups. Up to the moment, the researches carred out n LRC use very specal parallel hardware archtecture facltes: a Parallel Vrtual Machne (composed by a cluster of mcrocomputers, n LPAD) and two dfferent parallel machnes n CENAPAD (Brazlan Hgh Performance Computaton Center, at Unversty Campus). These parallel machnes correspond to a shared (3 processors) and a dstrbuted (48 processors) memory archtectures. There are many lbrares to extend conventonal programmng languages for applcaton of parallel programmng paradgm n the soluton of numercal problems that demand great computatonal effort. The choce depends on the avalable archtectures and how the dstrbuton software wll be. Although Cpar language utlzaton had shown to be promsng, the evaluaton of other alternatves was consdered, n a more accessble code portablty perspectve. The use of well known languages s able to make easer the software producton process and to short the tme delay for upgrade and new verson. In many cases, one can develop suffcent portable software that can be executed n clusters and also n supercomputers, dependng only on source-code complaton. In ths paper, the authors nvestgaton regardng groundng parallel computaton concerns the selecton of the best adequate parallel envronment to be adopted. In ths way, dfferent development platform characterstcs are beng analyzed, as descrbed bellow. 6. PVM PVM (Parallel Vrtual Machne) [7] s a lbrary of functons that mplements means of message passng over a heterogeneous computer network. It creates a parallel vrtual machne, whch s able to execute parallel programs over a dstrbuted envronment. PVM extents C or Fortran functon set, addng parallel facltes. PVM can be executed over many dfferent archtectures, from mcrocomputer to supercomputers. Ths feature turns t a very portable opton. It s a de facto standard, as t sn t a real one n the strct meanng of the term, but t s mantaned by the PVM group. It s an open software and ts present verson (3.4) may be drectly obtaned from Internet. PVM has obtaned satsfactory performance n ts mplementatons and has been known as one of the good optons among the parallel exstent possbltes. 6. MPI MPI (Message-passng Interface) [8] s a message passng standard nterface. It s developed as an effort for standardzaton of message passng possbltes. There are many dfferent mplementatons of the MPI functons, whch have mplemented the MPI standard partally or totally. Some of these mplementatons are MPICH, WMPI and LAM. 6.3 WMPI Ths MPI mplementaton was developed n 988 and follows the MPI.. standard. It s based on MPICH, another MPI mplementaton, extendng t wth some new functons. WMPI was developed for Wn3 platform, beng very consstent under ths. It can be a good choce when workng wth Wndows, but can t be easly ported to other operatonal systems. It means that, to mantan code portablty, only standard C or Fortran languages may be used, n order to make code recomplaton possble on other systems that run some other knd of the MPI mplementatons. 6.4 MPICH MPICH s an open and free MPI mplementaton. It totally contemplates the MPI. standard and partally, the MPI.. MPICH can be executed n Wndows and n Lnux, over a large range of hardware archtectures, supercomputers ncluded. These facts turn MPICH nto a very versatle MPI opton. As usual, code can be wrtten n C or Fortran. MPICH s one of the most promsng MPI standard mplementatons, due to ts portng capabltes. It s, by now, one of the better optons that can be found when mplementng software n MPI. 6.5 LAM LAM (Local Area Multcomputer) s a programmng envronment of parallel applcatons under Unx local network. It s an open and free MPI mplementaton and can be executed over heterogeneous Unx networks. Ths fact excludes the LAM s use under Wndows and sometmes makes ts use no attractve. 6.6 JAVA Java s one of most recent and promsng of the new generaton languages. It s based on C and C++, 5

7 VIII SEPOPE 9 a 3 de mao de May, 9 th to 3 rd Brasíla (DF) Brasl VIII SIMPÓSIO DE ESPECIALISTAS EM PLANEJAMENTO DA OPERAÇÃO E EXPANSÃO ELÉTRICA VIII SYMPOSIUM OF SPECIALISTS IN ELECTRIC OPERATIONAL AND EXPANSION PLANNING IP 8 OBJECT ORIENTED MATRIX STRUCTURE FOR THE DEVELOPMENT OF COMPUTING TOOLS IN ELECTRIC POWER SYSTEMS Marcelo Neujahr Agostn * Ildemar Cassana Decker * João Marco Francschett Ferrera * Agunaldo Slvera e Slva ** * LabPlan ** Labspot Department of Electrcal Engneerng Federal Unversty of Santa Catarna - UFSC, SC, Brazl Abstract: In ths work a class structure for the representaton of large sparse matrces s presented. The structure characterstcs facltate operatons such as the access to matrx elements, basc operatons wth matrces and vectors and the soluton of lnear systems. The work s part of a comprehensve project that ams the development of an object orented structure to represent electrc power systems (EPS), allowng the ntegrated development of computng tools for the electrc utltes. The use and extenson of the proposed structure s facltated by the applcaton of the Objected Orented Desgn Patterns n ts development. The C++ language s used n the mplementaton and the portablty and generalty s enhanced by the use of templates and contaners of the Standard Template Lbrary (STL). For the soluton of lnear systems, the structure allows the use of several methods through ther encapsulaton as soluton strateges. In the paper several results concernng the soluton of large-scale lnear systems are presented. These results show that the proposed structure allows the use of lbrares and specalzed methods for the development of prototypes and computng tools for the electrcal ndustry wthout losng performance, whle preservng the objected orented paradgm. Keywords: Power System Modelng, Object Orented Modelng, Large Scale Sparse Lnear Systems.. INTRODUCTION The Brazlan electrc ndustry s n a transton from a vertcally ntegrated state-owned to a market-drven compettve structure, n the generaton and commercalzaton of the electrc energy. In ths new envronment, there s a demand for modern and relable computng tools for the system analyss and desgn, n whch the relevant techncal and economcal characterstcs can * LabPlan - UFSC, Campus Unverstáro, Trndade CEP 884-9, Floranópols, SC, Brasl E-mal: ** On leave at BIPS, Brunel Unversty, UK. be effcently represented n an ntegrated form. The fast changng scenaro faced by the electrc utltes as a result of the new envronment, new avalable equpments and technques must be contemplated n the update of these tools [],[]. Modern paradgms n software engneerng, such as Object Orented Modelng (OOM), can lead to a new approach n the development of software tools for the electrcal ndustry. The OOM ams the development of flexble software, easly mantanable, wth a hgh degree of reusablty, sutable to be developed by several people [3],[4]. As a consequence, an object orented structure, representng the characterstcs of an electrc power system (EPS), s adequate to respond to the heavy demands n terms of software n the modern electrc ndustry []. Such structure allows the ntegrated development of computatonal tools, a more agle mantenance and consequently cost reducton [5]. A large number of power system applcatons requre the repettve soluton of large-scale sparse lnear systems. Therefore, an effcent representaton and soluton of lnear systems, s of fundamental mportance n the development of computatonal tools for the electrcal ndustry [6]. As part of a major effort towards the development of a generc OOM of power systems, ths work proposes a modelng and mplementaton of a computatonal structure to deal wth matrces, facltatng the development of effcent object orented (OO) computng tools for the electrc ndustry. Ths s a basc but fundamental step to buld a class structure that wll allow the mplementaton of methods of analyss and synthess [],[5]. The proposed structure allows the effcent mplementaton of compact storage of sparse matrces and lnear system solutons. The class structure s flexble so as to put no restrctons to any method used for the soluton of the lnear system. The ncluson of new methods

8 s facltated by ther encapsulaton n classes, usng the desgn pattern Strategy. Ths ensures that a change n the method can be acheved n executon tme. Furthermore, basc operators such as matrx addton, subtracton, multplcaton and dvson, are overloaded for the proposed classes, makng easy ther use for sparse matrces. Hgh performance and well-tested specalzed lbrares, developed usng conventonal desgn technques, have been used by the electrc ndustry for a long tme. However ther concept may be ncompatble wth the OOM phlosophy. The proposed structure allows that these methods or lbrares be encapsulated as strateges, ensurng hgh performance n the soluton of large-scale sparse systems whle keepng the paradgm of the OO desgn. The operators () e [] are also overloaded makng the access to matrx elements transparent to the user. The structure kernel s mplemented n the C++ programmng language [7],[8], and all classes are mplemented as templates, ensurng ther utlzaton for any data type, such as real, complex, or user defned types (n x n matrx blocks, for nstance [9]). Contaners avalable n the Standard Template Lbrary (STL) are used for the storage of dfferent element types nsde the classes, ensurng an adequate computatonal performance and portablty of the software. The structure s desgned and mplemented usng concepts of OOM and the Unfed Modelng Language (UML). Desgn Patterns play a key role n the development of the structure, renforcng the features of reusablty, easy mantenance and upgrade of the package. The use of effcent mplementaton technques ensures an adequate performance. Ths paper s organzed as follows. In Secton a bref revew of the OOM s presented. The general OO structure used to represent the power systems s dscussed n Secton 3 so as to stuate the present work n ts context. In Secton 4 the proposed structure s presented. The class model and the applcaton of the desgn pattern Strategy as a concept tool for the structure as well as the way n whch the soluton of lnear systems s dealt wth n the structure, are detaled n ths secton. In Secton 5, results that assess the computng performance of the structure, are presented. Fnally, the conclusons are presented n Secton 6.. OBJECT ORIENTED MODELING The Object Orented Modelng (OOM) can be defned as a software desgn technque n whch the desgn clarty and organzaton are based on a clear and effcent representaton of the real world (applcaton doman) to facltate the software development and mantenance [3]. In the OOM the data structure takes precedence. Ths approach allows a stable base to the desgn development process and unfes the whole desgn through the concept of object. Encapsulated objects, wth publc nterfaces whch hde ther prvate nternal structures, are protected from sde effects n future software mantenance or extensons. The object s the essental entty n the OOM and has attrbutes (ts own features) and methods (the way t manpulates ts attrbutes). Durng the desgn tme, the classes are defned, whch defne each object type. Each object s an nstance of a specfc class. Classes (or objects) relate through assocatons (or lnks). Lnks are nstances of assocatons as objects are nstances of classes. Classes are assocated among themselves, that s, objects are lnked to other objects [3]. Composton and nhertance are specal forms of assocaton. When an object s formed by the combnaton of other objects, then t s a case of combnaton. The mechansm of nhertance allows that a class, called descendent (derved or subclass) nhert the characterstcs of another class, called base or superclass. Another property of the OOM s polymorphsm, whch allows the overloadng of operatons and methods, so that the same operaton (or method) carry out dfferent procedures, when appled to dfferent objects [3]... Desgn Patterns Recently a new concept has been ganng a larger acceptance n the objected orented desgn, the Desgn Patterns [4]. They are class structure patterns, whch were establshed by ther recurrence n many object orented desgns. In [4] 3 of these patterns, whch have been used and tested by the authors and other desgners for several years, are dentfed. The use of these patterns n object orented desgn meets one of the key concepts n OOM that s structure reusablty. Ther applcaton ensures modularty and extensblty to the desgn. When a desgn pattern s used, the desgner can be assured that a well-tested structure employed n many other projects n the past s beng used. 3. APPLICATION TO EPS The tradtonal technques appled to the development of computng tools for power systems lack some desrable features to face the current challenges set by a fast changng envronment. These technques, based on structured desgn methods and procedural languages, am prmarly hgh computng performance and not clarty and flexblty of the desgn and the resultng code. As a result, sometmes the data structure tends to be fragle, and senstve to code mantenance. As an alternatve to overcome these problems, works have been proposed applyng OOM to the development of computng tools n power systems n areas such as dstrbuton systems [], dynamc smulaton [] and power flow [], []. In [] and [5] the authors propose generc class structures to represent power systems, whch allow the mplementaton of methodologes for the analyss and synthess n an ntegrated envronment,

9 for the development of power system computng tools. A smlar work s presented n []. In [3] the authors apply the concept of desgn patterns to the representaton of power system elements. 3.. Applcaton to the Soluton of Lnear Systems Several works were prevously publshed applyng OOM to the problem of solvng lnear systems [6], [9], [4], [5], [9]. In [9] the authors present a new methodology for solvng lnear systems n whch the objects are created to accommodate elements of the same degree, ncreasng the performance of the orderng process. In reference [6] a new set of classes for sparse and symmetrc lnear systems s proposed, the soluton beng based on drect methods. The results show that the computatonal performance usng an OOM approach s compettve wth the tradtonal approach based on structured desgn methods and procedural languages. Furthermore, the authors emphasze the dffculty to choose a partcular method for generc lnear systems snce the adequacy of a partcular method depends on the matrx type. As a result, ths reference, as the other references above, uses specfc solutons for the consdered lnear systems. However, snce these solutons are usually avalable as lbrares, alteraton n a code that uses one of these lbrares, to solve a dversty of lnear system types, can be cumbersome from a user pont of vew. 4. PROPOSED STRUCTURE The man goal of the proposed object orented structure s the storage and effcent handlng of large scale sparse matrces. To that end, the class SparseMatrx was created, as shown n Fgure. The storage of the matrx elements s carred out by usng the contaners of the Standard Template Lbrary (STL), of the C++ programmng language [7]. The classes vector<t>, valarray<t> and map<t,t> are used. In ths way two mportant attrbutes of the STL, portablty and computng performance, are ncorporated n the structure. The class SparseMatrx s formed by a vector of n ordered lsts (attrbute nln), where each ordered lst stores pars <nt,t>, whch represent the nonzero elements of each matrx row (column - nt, and value - T). An attrbute (flagsym) ndcates f the matrx s symmetrc or asymmetrc. If the matrx s symmetrc, only the nonzero elements above the dagonal are stored. Ths flag must be nformed when the matrx s created or dmensoned and ts default value s asymmetrc (). The dagonal elements are stored n a vector of the type valarray<t> (dag). Rectangular matrces can also be stored by ths class. In ths case the vector dag stores the elements n whch = j, and the remanng nonzero elements are stored n the lsts of vector nln. The nternal storage structure of SparseMatrx s shown n Fgure. The operators () e [] are overloaded n the class SparseMatrx, allowng drect access to ts elements. An auxlary class (Pos_Mat) was created to help to search for the matrx elements, by the use of these operators. A method called Get_Elem_Next (,j) allows that the matrx be searched to access ts nonzero elements. Ths method returns the matrx entry dentfed by the coordnates,j; f the element s zero (and therefore does not exst n the structure), the next nonzero entry n row s returned, and the value of the varable j s updated wth the column of the returned entry. Dagonal entres are not returned. In ths way, t s possble to do an effcent search n the compact storage structure of the matrx, traversng only the nonzero elements. Fgure - Class SparseMatrx 3

10 Fgure - Internal Storage Structure of the SparseMatrx Class The structure classes are all mplemented as templates, addng generalty n the use of the package. As a result, t allows the storage and handlng of any type of sparse matrces, rangng from the standard types as double or complex (the last one s defned n the STL) to new user defned types, such as block structured matrces [9]. 4.. Soluton of Lnear Systems The soluton of lnear systems s supported by the proposed structure by the use of the desgn pattern Strategy. In ths pattern, several forms to execute a specfc task are encapsulated n dfferent classes, called strateges, whch work under the control of the man class (called context). A user n ths structure nforms to the context class whch strategy should be used n the soluton of a task and from ths moment onwards nteracts only wth the context class whch passes to the current strategy the commands for the executon of the task. The pattern structure s presented n Fgure 3. The pattern adds to the project several mportant features such as ndependence between the strateges, that s, new strateges can be added later to the project, wthout the need of modfcatons n the orgnal classes. Another feature s the possblty of dynamc changes between strateges n executon tme, whch s not possble usng nhertance, an alternatve form of encapsulatng dfferent methods to perform the same task. The pattern strategy s appled n the proposed structure by makng the class SparseMatrx a context, wth several strateges for the soluton of lnear systems. The class dagram s shown n Fgure 4, n whch the class LS_Strategy s the base for all strateges, declarng an nterface between them and ther context. A user, that s, a class or functon, whch has a matrx represented by the class SparseMatrx, defnes the strategy to be used through the method Set_strategy(). From ths moment on, the startng of the method Solve_LnSys() belongng to the class SparseMatrx trggers the process of soluton of the lnear system formed by the matrx and by an ndependent vector suppled by a method parameter. The soluton s stored n a vector also suppled by a method parameter. New solutons, usng a new soluton method for the lnear system, can be obtaned by callng Set_strategy() for the new strategy. Fgure 4 llustrates the class LS_Strategy, as the base for all strateges of soluton of lnear systems. The class has a unque attrbute dm, whch represents the dmenson of the system to be solved. Three methods form the strateges nterface: Intalze(), Set_Val() and Solve(). The method Intalze() ntalzes the strategy, confgurng t to perform the tasks related to the lnear system. Ths method s started by the method Set_strategy() of SparseMatrx, n the moment a strategy s attrbuted to a matrx. The method Set_Val() attrbutes values to a possble nternal storage structure for each strategy. It s called each tme an attrbuton to an element of Sparse- Matrx s performed. The method Solve() starts the process of lnear system solvng, and s called by the method Solve_LnSys() n context. Fgure 3 - Pattern Strategy 4

11 orderng or factorzaton, for nstance, are necessary, n a process that nvolves the repeated soluton of a system. Fgure 4 - Strategy Appled to the Soluton of Lnear Systems 4... Desgn of a Soluton Strategy The three methods prevously descrbed form the nterface between the strateges and ther context and are declared as abstract methods n the LS_Strategy base class. Therefore, they are defned n each strategy accordng to a partcular scheme. The methods are protected so that the external classes have no access to the strateges. The strateges are derved classes from the LS_Strategy class. The strateges can contan specalzed structures for the storage of sparse matrces accordng to the soluton methodology mplemented by the partcular strategy. The class SparseMatrx mplements a smple compact storage, not assocated to any partcular soluton method for lnear systems. The only requrement s to store, n an effcent way, sparse matrces. When these specalzed structures exst, the methods Intalze() and Set_Val() can be used for the ntalzaton and mantenance of ths structure. When a strategy s attrbuted to a matrx, the matrx calls the method Intalze(), ndependently f the attrbuton was done before or after the matrx fllng. To each new attrbuton to elements of a matrx represented by an object of type SparseMatrx, the method Set_Val() of LS_Strategy s called. Each strategy mplements these methods so that the nternal structures are kept. The process of solvng a lnear system can be dvded n several steps, accordng to the soluton method. For nstance, for drect methods, usually there are the steps of orderng, factorzaton and substtuton. The control of the sequence n whch the steps are called must be the responsblty of the strategy, whch must know f a new 5. COMPUTATIONAL EXPERIMENTS The computng performance of the proposed structure was assessed by solvng two sparse symmetrc lnear systems wth dmenson. These systems were randomly generated by MATLAB. The frst system s hghly sparse, wth 767 nonzero elements. Defnng the densty of a matrx as the rato between the number of nonzero elements and the square of ts dmenson, the frst matrx has a densty of.9 x -4. Ths s comparable to the densty of the bus admttance matrx of a power system wth an average connectvty of,8 by node. The second system s denser than the frst, wth 94 nonzero elements, leadng to a densty of 4.76 x -4, comparable to an average connectvty of 8,5. Two methods for the soluton of lnear systems were mplemented: the Zollenkopf B-factorzaton method [6] and a strategy usng a drect method for the soluton of symmetrc lnear systems based on LU factorzaton of symmetrc matrces [7], [8]. The performance of the structure was compared to the performance of the SPOOLES lbrary [9], usng a mnmum number of operatons for the soluton of the lnear system (the fastest way to solve a lnear system). The SPOOLES lbrary, desgned usng concepts of OOM and mplemented n C, was used ether drectly or as an encapsulated strategy for soluton of lnear systems. The results are presented n Table. The platform was an AMD K7 Athlon GHz, 56Mb RAM, wth the LI- NUX operatng system (dstrbuton Mandrake 7.) and the compler was the GCC, verson The codes were compled usng the frst optmzaton level (-O). Table - CPU Tmes n the Soluton of Lnear Systems Lnear Proposed Structure System Zollenkopf LU Fat. SPOOLES SPOOLES,67s,4s,9s,9s 49,63s,93s,49s,49s For the frst system the performance of the Zollenkopf B-factorzaton method (,67s) was 5% superor to the SPOOLES lbrary (,9s). The LU factorzaton for symmetrc systems presented the best performance (,4s), beng 8% faster than the SPOOLES lbrary n solvng ths lnear system. The performance of the structure, when the strategy that encapsulates the SPOOLES lbrary s used, s the same as when ths lbrary was drectly used outsde the proposed structure. Table also shows the performance for the soluton of the second, denser, lnear system. The best performance n ths case was acheved by the soluton method that uses the SPOOLES lbrary. Agan the proposed structure wth the strategy that encapsulates the 5

14 VIII SEPOPE 9 a 3 de mao de May, 9 th to 3 rd Brasíla (DF) Brasl VIII SIMPÓSIO DE ESPECIALISTAS EM PLANEJAMENTO DA OPERAÇÃO E EXPANSÃO ELÉTRICA VIII SYMPOSIUM OF SPECIALISTS IN ELECTRIC OPERATIONAL AND EXPANSION PLANNING IP 9 A NEW APPROACH TO NONLINEAR PROGRAMMING APPLIED IN THE RESOLUTION OF THE OPTIMAL POWER FLOW PROBLEM L. C. T. Nunes ELEKTRO BRAZIL E. A. Belat * G. R. M. Da Costa EESC USP Abstract Ths paper presents a new approach that mproves the performance of the Newton's method for resoluton of the optmal power flow problem (OPF). The OPF s an mportant tool of analyss operaton and plannng of electrc system power, t s used n studes of voltage nstablty, maxmum loadng, analyss of "spot prce", among others. Ths approach treats the nequalty constrants of the reactve power by nteror pont method and the others by penalty functon. The frst order necessary condtons for optmalty are reached by Newton's method, and by updatng the barrer parameters assocated wth sources of reactve power and penalty terms assocated wth the others nequalty constrants. The effectveness of the proposed approach has been examned by solvng the 3-bus and 8-bus systems. Keywords: Nonlnear Programmng, Optmal Reactve Dspatch, Power System and Newton s Method. INTRODUCTION The OPF s a problem that optmzes a lnear or nonlnear objectve functon, wth lnear and nonlnear constrants. It s a no-convex and statc problem, whch calculates a optmal group of varables of state of the electrc network, startng from load data and of the parameters of the system, so that determne the optmal operaton pont. Carpenter proposed t n the early 6s based on the economc dspatch problem []. In the last few years, practcally all researches of development of new approaches to solvng the OPF problem consdered one of the technques of nteror pont varant as [-5]. Ths s justfed by ts effcency and easness of mplementaton. However, these varants have presented a long tme of processng n the convergence process and a seres of numerc problems when a lot of constrants are near ther lmts. Another very used method was Newton s, whch was proposed by [6] that n spte of ts lmtatons s stll consderng as one of the most effcent and robust approaches known. The ablty of the Newton s method n mnmzng the objectve functon of OPF problem n few teratons, once known the nequalty constrants actve n the soluton, t s enough for us to gve contnuty n ths research n search of the mprovement of ts performance. The man dffculty of the Newton s method s the dentfcaton of the actve nequalty constrants n the soluton, that are the sources of reactve power n the reactve control bus. A relable and effcent process wthout the necessty of specalzed knowledge to dentfy them was not developed yet. In ths paper a new approach to solvng the OPF s descrbed, where t s tred to explore the best characterstcs of the nteror pont and Newton s methods. The nequalty constrants, reactve power njecton, are handled by nteror pont method and the other constrants of equalty and nequalty are handled as n [6]. The paper s organzed as followng: Frst, the OPF problem s explaned; after that a revew of optmzaton methods s descrbed; then, the new approach s shown; the results of comparatve tests are reported and fnally, some concludng comments are made. OPTIMAL POWER FLOW FORMULATION The optmal power flow problem can be presented as: Mnmze f (x) subject to g (x) = Where: h (x) x j mn x x =,,..., m < n max j =,,..., p n x R s the vector of state varables; (x) () f s real power loss n transmsson; g (x) = s the set of power flow equatons; h(x) s the set of lmts on state varables and power system functonal constrants. The state varable vector, x, represents the voltage magntude, phase angles, LTC s taps and phase shfter s control angles. The objectve functon, f (x), can assume dfferent forms, for example, the actve power losses n transmsson, the actve power cost of dspatchable generators. The equalty constrants, Edmarco Antono Belat LOSEP EESC USP; Post Offce Box: São Carlos SP Brazl

20 VIII SEPOPE 9 a 3 de mao de May, 9 th to 3 rd Brasíla (DF) Brasl VIII SIMPÓSIO DE ESPECIALISTAS EM PLANEJAMENTO DA OPERAÇÃO E EXPANSÃO ELÉTRICA VIII SYMPOSIUM OF SPECIALISTS IN ELECTRIC OPERATIONAL AND EXPANSION PLANNING IP THE USE OF THE GEOMETRIC OPTIMIZATION MODEL TO SOLVE THE ENVIRONMENTAL UNIT COMMITMENT PROBLEM Maro Lllo-Saavedra * Claudo Roa-Sepúlveda * Maurco Canales & Bors Pavez-Lazo * Electrc Engneerng Department, Unversty of Concepcón, P.O. Box 6-C, Concepcón, Chle & Molecular Bology Department, Unversty of Concepcón, P.O. Box 6-C, Concepcón, Chle * Abstract. Ths paper proposes the use of a model based on the geometrc optmsaton (GO) technque of molecular systems to solve the Unt Commtment Problem (UC) wth envronmental constrants. To acheve ths, the unts are modelled as artfcal molecules where each atom of those molecules defnes a generatve unt operaton state. To obtan the geometrc optmsaton and hence the optmsaton of the entre generatng set, Smulated Annealng (SA) technque, as an optmsaton tool, s selected. The whole model s devsed n ths paper by havng a contnuous characterstc rather than the classcal formulaton of UC. A prelmnary applcaton to a 5-unt test system for 4 hour of operaton subject to techncal restrctons, ntal condtons and envronmental constrants to each generatve unt s shown. Keywords: Unt Commtment (UC), Smulated Annealng (SA), Molecular Geometrc Optmsaton (GO) and Computng Bology.. INTRODUCTION In electrc energy system plannng, there s a problem of a common and fundamental objectve that s pursued: a maxmum utlsaton of electrc energy at a mnmum cost. The UC belongs to ths knd of problem. Its soluton has been boarded prncpally through classcal technques based on methods such as the lagrangean relaxaton and the lnear programmng [,]. Those methods decompose the problem n smple outlnes of unts over the whole tme horzon n whch ts executon tme vares lnearly wth the problem. Another well-known method s the mert order lst. Ths method lnearzes the objectve functon n dfferent sectons to fnd the system margnal cost consderng all possble unts. Ths method presents the nconvenent that the objectve functon needs to be lnear and the results are not necessarly closed to the absolute mnmum. The utlsaton of ths method mposes to the objectve functon to be of a lnear type and beng contnuously dfferentable. Furthermore, classcal technques must be adjusted to nclude power system and techncal restrctons such as mnmum up and down tmes. For those reasons, the lookng for new optmsaton technques based on alternatve to tradtonal concepts takes mportance lke those presented n [3-7]. Another mportant pont n solvng the UC s the sze of the soluton unverse. Ths s a strong lmtaton that must be consdered to get good results n the applcaton of the tradtonal methods. The applcaton of methods requrng the need to generate grd solutons such as a Taboo Search and Genetc Algorthm produce the known hgh computatonal costs that a combnatoral nature problem mples. Ths proposal attempts to solve de UC problem subject to techncal and envronmental constrants through a tool that mtates the molecules geometrc optmsaton to get ts mnmum energy state [8,]. Ths can be reached through the mnmsaton of forces nteractng between the dfferent atoms that compose molecules of a partcular system, gettng a state wth a mnmum energy cost. Ths paper proposes an UC model mapped onto a molecular confguraton wth contnuous characterstcs appled to a 5-generatng unt test system and a study tme horzon of 4 hour. The objectve of ths paper s to demonstrate the vablty of ths proposal and the use of SA to acheve the molecular and hence power system optmal value.

On the Optmal Control of a Cascade of Hydro-Electrc Power Statons M.C.M. Guedes a, A.F. Rbero a, G.V. Smrnov b and S. Vlela c a Department of Mathematcs, School of Scences, Unversty of Porto, Portugal;

Vson Mouse Saurabh Sarkar a* a Unversty of Cncnnat, Cncnnat, USA ABSTRACT The report dscusses a vson based approach towards trackng of eyes and fngers. The report descrbes the process of locatng the possble

An Alternatve Way to Measure Prvate Equty Performance Peter Todd Parlux Investment Technology LLC Summary Internal Rate of Return (IRR) s probably the most common way to measure the performance of prvate

What s Canddate Samplng Say we have a multclass or mult label problem where each tranng example ( x, T ) conssts of a context x a small (mult)set of target classes T out of a large unverse L of possble

Multple-Perod Attrbuton: Resduals and Compoundng Our revewer gave these authors full marks for dealng wth an ssue that performance measurers and vendors often regard as propretary nformaton. In 1994, Dens

Secton B9: Zener Dodes When we frst talked about practcal dodes, t was mentoned that a parameter assocated wth the dode n the reverse bas regon was the breakdown voltage, BR, also known as the peak-nverse

MeshCurrent Method The meshcurrent s analog of the nodeoltage method. We sole for a new set of arables, mesh currents, that automatcally satsfy KCLs. As such, meshcurrent method reduces crcut soluton to

REVIEW OF RISK MANAGEMENT CONCEPTS LOSS DISTRIBUTIONS AND INSURANCE Loss and nsurance: When someone s subject to the rsk of ncurrng a fnancal loss, the loss s generally modeled usng a random varable or

Module LOSSLESS IMAGE COMPRESSION SYSTEMS Lesson 3 Lossless Compresson: Huffman Codng Instructonal Objectves At the end of ths lesson, the students should be able to:. Defne and measure source entropy..

Learnng Objectves 9.1 The Cumulatve Sum Control Chart 9.1.1 Basc Prncples: Cusum Control Chart for Montorng the Process Mean If s the target for the process mean, then the cumulatve sum control chart s

A GENERAL APPROACH FOR SECURITY MONITORING AND PREVENTIVE CONTROL OF NETWORKS WITH LARGE WIND POWER PRODUCTION Helena Vasconcelos INESC Porto hvasconcelos@nescportopt J N Fdalgo INESC Porto and FEUP jfdalgo@nescportopt

Lnear Crcuts Analyss. Superposton, Theenn /Norton Equalent crcuts So far we hae explored tmendependent (resste) elements that are also lnear. A tmendependent elements s one for whch we can plot an / cure.

4.02 Quz Solutons Fall 2004 Multple-Choce Questons (30/00 ponts) Please, crcle the correct answer for each of the followng 0 multple-choce questons. For each queston, only one of the answers s correct.

HE DISRIBUION OF LOAN PORFOLIO VALUE * Oldrch Alfons Vascek he amount of captal necessary to support a portfolo of debt securtes depends on the probablty dstrbuton of the portfolo loss. Consder a portfolo