CN114077787A - Automatic PSCAD model element parameter setting method - Google Patents

Automatic PSCAD model element parameter setting method Download PDF

Info

Publication number
CN114077787A
CN114077787A CN202111223678.2A CN202111223678A CN114077787A CN 114077787 A CN114077787 A CN 114077787A CN 202111223678 A CN202111223678 A CN 202111223678A CN 114077787 A CN114077787 A CN 114077787A
Authority
CN
China
Prior art keywords
file
name
parameter
ini
configuration file
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
CN202111223678.2A
Other languages
Chinese (zh)
Other versions
CN114077787B (en
Inventor
黎涛
郑琼玲
刘松
韩坚
肖纯
李剑
黄华
彭翔
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
State Power Grid Jiangxi Electric Power Co ltd Pingxiang Power Supply Branch
State Grid Corp of China SGCC
Original Assignee
State Power Grid Jiangxi Electric Power Co ltd Pingxiang Power Supply Branch
State Grid Corp of China SGCC
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by State Power Grid Jiangxi Electric Power Co ltd Pingxiang Power Supply Branch, State Grid Corp of China SGCC filed Critical State Power Grid Jiangxi Electric Power Co ltd Pingxiang Power Supply Branch
Priority to CN202111223678.2A priority Critical patent/CN114077787B/en
Publication of CN114077787A publication Critical patent/CN114077787A/en
Application granted granted Critical
Publication of CN114077787B publication Critical patent/CN114077787B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F30/00Computer-aided design [CAD]
    • G06F30/20Design optimisation, verification or simulation

Abstract

The invention discloses a method for automatically setting elements of a PSCAD model, which comprises an ini configuration file of the elements and a flow of automatically setting the elements of the PSCAD model. The invention can enable a user to get rid of a complex parameter setting panel of the PSCAD model element, can quickly and accurately automatically complete the setting of the PSCAD model element parameter according to the operation steps, and can reuse the ini configuration file, thereby quickly setting the parameters of other element instances of the same type.

Description

Automatic PSCAD model element parameter setting method
Technical Field
The invention relates to a method for quickly setting elements of a PSCAD model, belonging to the technical field of digital simulation of an electric power system.
Background
PSCAD is a digital simulation software widely used in power systems. A rich component library is provided in PSCAD, including: simple passive components, complex control modules, motors, FACTS devices, wiring, etc.
The power system is simulated by using PSCAD, and the general flow is as follows:
1) drawing a simulation electric power system which is the same as the actual electric power system in a drawing area by using corresponding elements in a PSCAD element library according to the main wiring diagram of the actual electric power system;
2) setting parameter values for corresponding elements in the simulation power system according to the collected parameter values of the elements in the actual power system;
3) creating related control elements and monitoring elements to control the triggering of the fault and monitor the signals of interest;
4) compiling and debugging the simulation power system until no error exists;
5) and starting to operate the simulation power system and checking an operation result.
In the above process of performing power system simulation using the PSCAD, after the power system simulation model is drawn, parameters are set for corresponding elements in the simulation system one by one according to each collected element parameter. The process is a very critical step in simulation, is relatively troublesome and is prone to errors.
Because of different elements, the number of parameters is different, and a few parameters is more than a few parameters, and the number of parameters is nearly hundreds. For a component with nearly hundreds of parameters, a user often collects only a few key parameters of the component, and when setting parameter values for the component, the user needs to find out the positions of the key parameters from a large number of parameters of the component and fill the positions with the parameter values, and other parameters often use default values. The method for manually searching the parameters and then manually filling the parameters has the advantages of large workload, low efficiency, fussy operation process and high possibility of errors.
Disclosure of Invention
Aiming at the problems existing in the PSCAD model element parameter setting in the prior art, the invention provides the automatic PSCAD model element parameter setting method which simplifies the PSCAD model element parameter setting process, reduces the parameter setting workload, improves the parameter setting efficiency and reduces the error probability of parameter setting.
The technical scheme adopted by the technical problem to be solved by the invention is as follows: a PSCAD model element parameter automatic setting method comprises the following working processes:
1) a user first specifies a directory containing configuration files for all elements; then appointing a preset PSCAD model file name;
2) acquiring a file list of all configuration files with the extension name of 'ini' under the directory;
3) opening a PSCAD model file specified by a user;
4) for each ini configuration file in the file list, the following operations are carried out:
reading a file name of an ini configuration file, and extracting 'element instance id' in a file basic name;
opening an ini configuration file, and recording as: reading all parameter names and parameter values in a paramlist section by using a current configuration file;
searching an element with an id value of 'element instance id' in the PSCAD model file, and recording as: a current element;
and fourthly, recording the name of each parameter as: a current parameter name; and parameter values, noted as: a current parameter value; searching all sub-elements of < param > ' of the current element, and finding the sub-element with the attribute of ' name ' equal to the name of the current parameter; then setting the value attribute of the sub-element as the current parameter value;
completing the processing of each parameter one by one, and then closing the current configuration file;
5) completing the operation of each ini configuration file in the file list one by one according to the previous step, and then closing the PSCAD model file;
the ini configuration file is specifically designed as follows:
a: filename of configuration file:
the basic name (basename) of the file should be named according to the following mode: "< element type > - < element instance id >", the tip brackets in the file name and the content in the tip brackets should be replaced with the actual content;
"< element type >" is a description of the type of the PSCAD model element, and is used only for user's own mnemonic, and the "PSCAD model element parameter auto-setup" program does not process this field. The user can name himself according to own habits so as to prompt the user which model element parameter list is stored in the configuration file. Such as: the user may describe the wind turbine model as either a "wind turbine" or a "wind turbine". When in use, the user replaces the name of the element type by the user at the position of < element type > in the ini file name.
"< element instance id >" is the id number of a certain element in the PSCAD model file preset by the user, and the user must acquire the id number from the PSCAD model file and then replace the "< element instance id >" in the ini file name. The "PSCAD model component parameter auto-setup" program reads this id number and searches for a component whose id number is that value in the PSCAD model file.
The file extension is: ". ini";
b: file content of the configuration file:
the content of the configuration file only comprises 1 section, and the name of the section is 'paramlist';
the section "paramlist" includes a series of "keys" and "values", wherein the "keys" represent parameter names, and the "values" represent parameter values;
ini profile of the elements as shown in fig. 2: the file name of the ini configuration file is: ini, the file content of the ini configuration file contains a "paramlist" section; the section contains a series of parameters and their values in the format: "parameter name = parameter value", each parameter occupies one row independently.
In conclusion, the beneficial effects of the invention are as follows:
(1) the parameter setting process of the elements of the PSCAD model is simplified; a user does not need to perform parameter setting operation in a complex parameter panel of a model element any more, and instead, element parameters are filled in a simple ini configuration file; the software of 'PSCAD model element parameter automatic setting' can automatically complete the rest element parameter setting work;
(2) the parameter setting workload of the PSCAD model element is reduced; the user does not need to search preset parameter positions in the model file item by item, and the software for automatically setting the PSCAD model element parameters can replace the user to search the parameters and fill in parameter values;
(3) the parameter setting efficiency of the PSCAD model element is improved; the original operation of manually setting the element parameters is changed into the operation of automatically setting the element parameters by software;
(4) the error probability of the parameter setting of the elements of the PSCAD model is reduced; the complicated element parameter setting work is easy to make mistakes when manually set, and after the software of 'PSCAD model element parameter automatic setting' is automatically completed, when the software is debugged reliably and has no errors, the work can not make mistakes;
(5) the ini configuration file of the element can be multiplexed conveniently, and all parameter values in the current ini configuration file can be set into the new element quickly only by modifying the element instance id in the file name of the ini configuration file to be the id of the new element.
Drawings
FIG. 1 is a flow chart of a method for automatically setting parameters of a PSCAD model according to the present invention, in which the automatic setting of parameters of a doubly-fed wind turbine is taken as an example,
figure 2 is an ini profile of an element according to the invention,
fig. 3 is an ini configuration file of the element doubly-fed wind turbine according to the present invention.
Detailed Description
In order to make the technical solutions of the present invention better understood by those skilled in the art, the present invention is described in further detail below with reference to the accompanying drawings.
The following detailed description will be given taking the automatic setting of parameters of the doubly-fed wind turbine and other components as an example:
1) preparing an ini configuration file of the doubly-fed wind turbine.
Firstly, filling all collected parameters of the doubly-fed fan into an ini configuration file according to a format of 'parameter name = parameter value', wherein each parameter has an exclusive 1 line. As shown in fig. 2, the doubly-fed wind turbine ini configuration file is a filled doubly-fed wind turbine ini configuration file.
And secondly, opening the PSCAD model file by the user, finding the double-fed fan element and checking the id value of the double-fed fan element. Its id value is filled in the "element instance id" field in the filename of the ini configuration file.
2) An ini profile for the other elements is prepared.
The ini profiles of the other elements in the model are prepared following the previous step.
3) And placing all prepared ini configuration files in the same folder.
4) The user uses the "PSCAD model element parameter automatic setting" method.
The user selects an ini profile directory button to designate the folder in which all ini profiles are placed in the previous step.
Secondly, the user selects the preset PSCAD model file and designates the PSCAD model file with preset parameters.
Executing 'starting to set the element parameters of the PSCAD model', and executing the automatic parameter setting process of the element.
5) The user observes the progress bar of the 'automatic setting of the element parameters of the PSCAD model' program, and when the progress bar reaches 100%, the automatic setting of all the element parameters is completed.
Taking the automatic setting of the parameters of the doubly-fed wind turbine as an example, the process of automatically setting the element parameters of the PSCAD model is explained in detail as follows:
1) and software acquires an ini configuration file of the doubly-fed wind turbine. The file name is read and the value of the "element instance id" field in the file name (noted: compInstID) is obtained. Taking the ini configuration file of the "doubly-fed wind turbine" shown in fig. 3 as an example, the value of the "element instance id" field obtained by the software is as follows: 1968805311.
2) search for the element in the PSCAD model file with the "id" attribute value equal to compInstID (noted: tarElement). Taking the model file of the 'doubly-fed wind turbine' as an example, the element searched by the software is a < User > element.
3) Reading the content of the ini configuration file, and acquiring all parameter lists in the para section. Taking the ini configuration file of the "doubly-fed wind turbine" shown in fig. 2 as an example, the parameter list acquired by the software is as follows:
Name=WTG
Pbase=2.5
Vbase=0.69
OMEG=50.0 [Hz]
TRN=0.3
4) the next parameter in the parameter list is read (parameter name: paramName, parameter values noted: paramValue). Taking the ini configuration file of the "doubly-fed wind turbine" shown in fig. 3 as an example, after the first parameter is read, the paramName is: name, paramValue is: and (4) a WTG.
5) Searching all < param > sub-elements of the tarElement element, finding a < param > sub-element with the Name attribute equal to paramName, and then setting the value attribute of the < param > sub-element as paramValue.
6) And 4, continuing to process the next parameter until all the parameters in the ini configuration file are processed.
7) And turning to the step 1, continuously processing the next ini configuration file until all the ini configuration files in the configuration file folder are processed.
The ini profiles of the elements can be easily multiplexed. Taking the ini configuration file of the doubly-fed wind turbine as an example, a specific implementation mode of multiplexing the ini configuration file is described in detail. After the model parameters of the doubly-fed wind turbine with the id of 1968805311 in the PSCAD model file are set by using the ini configuration file of the doubly-fed wind turbine, the parameters in the ini configuration file of the doubly-fed wind turbine can be set to a new doubly-fed wind turbine only by replacing the id numbers of other doubly-fed wind turbines in the PSCAD model file with the '1968805311' in the filename of the ini configuration file of the doubly-fed wind turbine and then re-executing the 'PSCAD model element parameter automatic setting' method.
Those of skill would further appreciate that the various illustrative components and algorithm steps described in connection with the embodiments disclosed in this patent can be implemented as electronic hardware, computer software, or combinations of both, and that the various illustrative components and steps have been described above generally in terms of their functionality in order to clearly illustrate this interchangeability of hardware and software. Whether such functionality is implemented as hardware or software depends upon the particular application and design constraints imposed on the implementation. Skilled artisans may implement the described functionality in varying ways for each particular application, but such implementation decisions should not be interpreted as causing a departure from the scope of the present invention.
The steps of a method or algorithm described in connection with the embodiments disclosed in this patent may be embodied directly in hardware, in a software module executed by a processor, or in a combination of the two. A software module may reside in Random Access Memory (RAM), memory, Read Only Memory (ROM), electrically programmable ROM, electrically erasable programmable ROM, registers, hard disk, a removable disk, a CD-ROM, or any other form of storage medium known in the art.
The above description is only a preferred embodiment of the present invention, and it should be noted that, for those skilled in the art, it is possible to make various modifications and changes without departing from the technical principle of the present invention, and these modifications and changes should be considered as the protection scope of the present invention.

Claims (1)

1. A method for automatically setting elements of a PSCAD model is characterized in that: the working process is as follows:
1) a user first specifies a directory containing configuration files for all elements; then appointing a preset PSCAD model file name;
2) acquiring a file list of all configuration files with the extension name of 'ini' under the directory;
3) opening a PSCAD model file specified by a user;
4) for each ini configuration file in the file list, the following operations are carried out:
reading a file name of an ini configuration file, and extracting 'element instance id' in a file basic name;
opening an ini configuration file, and recording as: reading all parameter names and parameter values in a paramlist section by using a current configuration file;
searching an element with an id value of 'element instance id' in the PSCAD model file, and recording as: a current element;
and fourthly, recording the name of each parameter as: a current parameter name; and parameter values, noted as: a current parameter value; searching all sub-elements of < param > ' of the current element, and finding the sub-element with the attribute of ' name ' equal to the name of the current parameter; then setting the value attribute of the sub-element as the current parameter value;
completing the processing of each parameter one by one, and then closing the current configuration file;
5) completing the operation of each ini configuration file in the file list one by one according to the previous step, and then closing the PSCAD model file;
the ini configuration file is specifically designed as follows:
a: filename of configuration file:
the basic names (basenames) of the files are named according to the following modes: "< element type > - < element instance id >", the tip brackets in the file name and the content in the tip brackets should be replaced with the actual content;
the < element type > "is the description of the element type of the PSCAD model, and is only used for the user to remember by himself, and when the PSCAD model is used, the user replaces the < element type >" in the ini file name with the name of the element type;
"< element instance id >" is the id number of a certain element in the PSCAD model file preset by the user, and the user must acquire the id number from the PSCAD model file and then replace the "< element instance id >" in the ini file name;
the file extension is: ". ini";
b: file content of the configuration file:
the content of the configuration file only comprises 1 section, and the name of the section is 'paramlist';
the section "paramlist" includes a series of "keys" and "values", wherein the "keys" represent parameter names, and the "values" represent parameter values;
the file name of the ini configuration file is: ini, the file content of the ini configuration file contains a "paramlist" section; the section contains a series of parameters and their values in the format: "parameter name = parameter value", each parameter occupies one row independently.
CN202111223678.2A 2021-10-21 2021-10-21 Automatic parameter setting method for PSCAD model element Active CN114077787B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202111223678.2A CN114077787B (en) 2021-10-21 2021-10-21 Automatic parameter setting method for PSCAD model element

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202111223678.2A CN114077787B (en) 2021-10-21 2021-10-21 Automatic parameter setting method for PSCAD model element

Publications (2)

Publication Number Publication Date
CN114077787A true CN114077787A (en) 2022-02-22
CN114077787B CN114077787B (en) 2024-04-16

Family

ID=80283424

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202111223678.2A Active CN114077787B (en) 2021-10-21 2021-10-21 Automatic parameter setting method for PSCAD model element

Country Status (1)

Country Link
CN (1) CN114077787B (en)

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103838921A (en) * 2014-02-13 2014-06-04 华北电力大学(保定) PSCAD-EMTDC simulation model automatic generation method
US20160224702A1 (en) * 2015-01-30 2016-08-04 State Grid Corporation Of China Method of calculating voltage and power of large-scaled photovoltaic power plant
CN106407515A (en) * 2016-08-31 2017-02-15 哈尔滨工程大学 Electrical virtual experiment method based on PC platform
US20200257660A1 (en) * 2016-03-30 2020-08-13 Consoli Limited Object model generation

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103838921A (en) * 2014-02-13 2014-06-04 华北电力大学(保定) PSCAD-EMTDC simulation model automatic generation method
US20160224702A1 (en) * 2015-01-30 2016-08-04 State Grid Corporation Of China Method of calculating voltage and power of large-scaled photovoltaic power plant
US20200257660A1 (en) * 2016-03-30 2020-08-13 Consoli Limited Object model generation
CN106407515A (en) * 2016-08-31 2017-02-15 哈尔滨工程大学 Electrical virtual experiment method based on PC platform

Also Published As

Publication number Publication date
CN114077787B (en) 2024-04-16

Similar Documents

Publication Publication Date Title
EP3165984B1 (en) An event analysis apparatus, an event analysis method, and an event analysis program
JP2007536640A (en) Method and apparatus for modifying process control data
CN105629180A (en) Test method, test device and controller
CN104063519B (en) BPA power grid data analyzing and managing method and system based on EXCEL
WO2007086101A1 (en) Plant control system and method of specifying primary-factor for interlock
CN114077787A (en) Automatic PSCAD model element parameter setting method
RU2294015C2 (en) Method for automatic modeling of system for controlling process and system for controlling process
CN107272443A (en) A kind of control method and device for controlled system
CN110011853A (en) It is a kind of to check method and device towards multi-platform and cluster cross faults
CN111211928A (en) Network data acquisition system based on big data processing
CN106774205A (en) Central monitoring equipment and fan monitoring method of intelligent wind power plant
CN110989515B (en) Configuration file generation method, device, equipment and readable storage medium
CN110956283B (en) Method and system for matching SCD file with soft pressing plate
CN107153408B (en) A kind of filtering method of fired power generating unit DCS data
CN106844437A (en) BPA simulation calculation treating method and apparatus
JP6782187B2 (en) Plant operation monitoring device and plant operation monitoring method
CN109597638A (en) The method and device of data processing, equipment linkage is solved based on real-time computing engines
CN117194501B (en) DCS trend measurement point jump logic configuration method, system, equipment and medium
CN116562857B (en) Equipment full life cycle operation and maintenance management system and method
CN109871214A (en) Program code generation method, device, computer equipment and storage medium
CN113094338B (en) Data comparison method, system, device and medium
CN104882910A (en) Wind power penetration limit determination method based on peak-regulating balance constraint
CN111786380B (en) Method and system for searching new energy interlocking off-line path of power system
CN108804490B (en) Intelligent inquiry system for satellite test historical data
CN109714210B (en) New energy station communication configuration method, device, equipment and storage medium

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant