Hi Ray, it works perfectly. Thank you very much!
Em seg., 13 de jun. de 2022 às 19:31, Ray Daniel Zimmerman <r...@cornell.edu> escreveu: > When running a power flow the voltage at swing and PV buses is controlled > by the VG column of the corresponding generator in the gen matrix, not by > the VM column in bus. Setting the corresponding mpc.gen(slack_gen_index, > VG) to the desired value in your loop should accomplish what you are > looking for. > > Ray > > > On Jun 13, 2022, at 2:18 PM, João Marcelo Amaral <jmtama...@coppe.ufrj.br> > wrote: > > Hi, my name is João Amaral. I am a researcher from the Alternative Energy > Laboratory (LAFAE) in COPPE/UFRJ, Brazil. > > We are working in the modelling of a Wind Farm using Matpower in Matlab > and we are trying to compare field measures with the results from the > program. For this we are using a "For Loop" and setting different levels of > Active and Reactive Power in the PQ buses. > > To increase our precision we are trying to change the Swing Bus Voltage > level inside the "For Loop" but we have not seen any changes. We are trying > to set the parameters like the Power References but we do not know if we > are setting something wrong. Below there is an image of part of the code. > > <image.png> > > My question is: Is it possible to change this voltage level inside the > loop? > > The only way that we see any change is when we change the Base Voltage in > the modelling file, but not in the Iterative Loop. > > Best regards, > -- > *João Amaral* > > >