Modeling a variable RL branch
6 visualizzazioni (ultimi 30 giorni)
Mostra commenti meno recenti
Hi,
I'm using simscape specialized power system to model an electrical circuit in AC :
I would like to simulate the losses on the line for different positions of the load. In order to do that I want to be able to change the parameters in the RL branches during the simulation.
I first tried to use these two blocks :
But because they are modelled as current sources, I cannot put them in series with the other RL elements of my model.
Then I tried to model a subsystem as in this topic : https://fr.mathworks.com/matlabcentral/answers/337443-how-to-model-a-variable-rl-branch?s_tid=ta_ans_results. But again it did not work because of the current source. The diagnostic viewer in simulink advised to put a resistor with a high value un parrallel with the current source but then the current was not able to flow to the load.
Is it possible to modify the RL branch block to make it tunnable during the simulaiton ? Or do you have any other suggestions to help me solve my problem ?
Thanks,
Paul
0 Commenti
Risposte (1)
Joel Van Sickel
il 3 Ago 2021
Hello Paul,
the easiest and most accurate approach would be to switch to using simscape core technology (use the blue variable resistor and blue variable inductor instead). The simscape solver is particularly useful for modelling variable parameter components. Alternatively, you can place snubber resistors (a large resistor that connects to ground). You would probably need to place one between the variable inductor and resistor, and maybe another between where the inductor connects to the line. Make them particularly large (so as to draw less than 1 percent current). This will unfortunately probably lead to an unstable or slow simulation. (the larger the snubber resistor, the more accurate, but the slower the model will run) You could also attempt to model the RL load as a controlled voltage source but I'm not sure how well that would work as the controlled current source is the ideal formulation for the equations.
If you can get away with discrete simulation runs, it would also be easier to run the simulation with one set of parameters, then run it again with a new set. This would be the fastest/easiest way while still using specialized technology. You can write a for loop in matlab and call the sim command and set new R and L variables for each run to sweep the full set of values.
Regards,
Joel
Vedere anche
Categorie
Scopri di più su Variable Initialization in Help Center e File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!