Please take a minute to review and accept our Terms of Use.
Welcome to the PLECS User Forum, where you can ask questions and receive answers from other members of the community.

Many technical questions regarding PLECS are answered on the Technical Solutions page of our website. Tutorial videos, specific application examples, and pre-recorded webinars are available on our YouTube page. Please follow us on LinkedIn for the latest Plexim news.

want to get the real-time power of the simulated single-phase AC circuit, just like the power meter

+1 vote
As the title, the probe only realizes the power display of the component. It is not possible to display the real-time power of the calculation of my current system. I want to detect the maximum value of the current current and voltage, and then calculate the result of the input power, but I don’t Know how it can be achieved.
asked Sep 29, 2018 by leo2018 (15 points)

I think I understand your question, but can you may be draw a simple block diagram of what you want to simulate and share a picture of it here?

the attachment is my circuit,and i want to let it be a close-loop using the power to control the Driving frequency,how to get it work?I am just a beginner of plecs.

1 Answer

0 votes
Hi Leo,

You can get a periodic maximum value by using a State Machine block or a C-script block. See the attached file. It uses a State Machine block to implement periodic maximum. May be you can use this as a starting point.

answered Oct 16, 2018 by Manu Parimi (363 points)
Hi Leo,

Instead of detecting peak values, for a more robust and a less complex solution, you can use a periodic average block. See the attached model.