Get Help

Auto-suggest helps you quickly narrow down your search results by suggesting possible matches as you type.

Showing results for

- Community
- :
- PTC Mathcad
- :
- PTC Mathcad
- :
- Efficiency Optimization

Options

- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Mute
- Printer Friendly Page

Auto-suggest helps you quickly narrow down your search results by suggesting possible matches as you type.

Showing results for

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Notify Moderator

12-02-2020
12:41 AM

12-02-2020
12:41 AM

Efficiency Optimization

Hi Guys,

I have one question about how to use mathcad prime 6 to optimize two parameters in order to get a highest efficiency. For example, I have two variables A and B as input, and I already wrote one efficiency calculation file that using this two as variables, and output an fixed efficiency result. How can I use the optimization function in prime 6 that can help me get a highest efficiency (3D curve) when the two input A and B vary in a specific range?

If you have any examples, please let me know. Thanks.

Labels:

10 REPLIES 10

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Notify Moderator

12-02-2020
03:00 AM

12-02-2020
03:00 AM

Re: Efficiency Optimization

Please attach your Prime worksheet.

That should help us to help you.

Success!

Luc

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Notify Moderator

12-02-2020
12:22 PM

12-02-2020
12:22 PM

Re: Efficiency Optimization

Hi, attached is my calculation file for a set of fixed variables, such as switching frequency fs=15kHz and inductance Lpri=35uH.

And the final efficiency curve is showed in the second last section. Attached is the efficiency curve, but I can do one more step calculation. I can use only one value to represent the final optimization target, efficiency index.

For example, **CEC Efficiency** = 0.04 x Eff10% + 0.05 x Eff20% + 0.12 x Eff30% + 0.21 x Eff50% + 0.53 x Eff75%. (**California Energy Commission** (**CEC**) has proposed another weighting, which is now specified for some inverters used in the US.)

What I want to achieve is that I can vary the switching frequency into a specific range, such as 15kHz to 100kHz, and also specify Lpri ranging from 20uH to 100uH. Then I should be able to get a 3D matrix that has variable fs, Lpri as inputs and efficiency as output.

Hope you can take a look at this file. I know it's a bit complicated, but I can try to simplify the calculation algorithm. If you have any idea about how to use prime 6 to achieve this kind of optimization methodology, please let me know. Thanks.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Notify Moderator

12-02-2020
01:38 PM

12-02-2020
01:38 PM

Re: Efficiency Optimization

You should use one of the functions maximize() or minimize(). I guess in your case you want to maximize efficiency.

What you need is a function (yes, a function) that you want to optimize, e.g. Efficiency(fs,Lpri).

Then you can use a solve block to set constraints and use maximize.

I cannot find an optimization problem example in the help for Prime with more than one variable, so...

Here's an example (of a former Mathcad), that you should be able to build in Prime to gain experience, and then you should know what to do to rebuild your system for optimization:

Now comes the solve block:

Success!

Luc

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Notify Moderator

12-04-2020
12:14 AM

12-04-2020
12:14 AM

Re: Efficiency Optimization

Hi,

I draw a graph like the below, do you know how to generate a image with high resolution that I can use for publishing a paper?

Thanks.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Notify Moderator

12-04-2020
07:32 AM

12-04-2020
07:32 AM

Re: Efficiency Optimization

The lack of high resolution graphics in Mathcad has been a complaint before PTC bought it; I don't recall seeing a useful solution.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Notify Moderator

12-04-2020
01:31 PM

12-04-2020
01:31 PM

Re: Efficiency Optimization

Thanks.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Notify Moderator

12-04-2020
09:36 AM

12-04-2020
09:36 AM

Re: Efficiency Optimization

What do you (or the publishing paper) consider to be 'high resolution'?

Note that you can increase the size of the plot in Prime, make sure you remove the background grid, use a large computer screen (2560x1440 pixels is affordable currently) and grab the picture off the screen to a .PNG picture. When printed at a width of 6 inches, you get over 400 dpi (2560/6=427).

Other options are to save the graph data to a file and plot it with other software.

Success!

Luc

P.S. How's the optimization going?

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Notify Moderator

12-04-2020
01:40 PM

12-04-2020
01:40 PM

Re: Efficiency Optimization

Still working on the optimization.

"Other options are to save the graph data to a file and plot it with other software."

I tried to export my graph into excel and then use MATLAB to re-plot it, looks good.

But do you know what should I do if it's 3D graph (like the one attached below)? Do you have any example?

I know for the f(x,y) below, we can easily re-write the function and plot it using MATLAB, but what if it's a more complicated calculation result that can only generated by MathCAD?

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Notify Moderator

12-05-2020
08:54 AM

12-05-2020
08:54 AM

Re: Efficiency Optimization

"I know for the f(x,y) below, we can easily re-write the function and plot it using MATLAB, but what if it's a more complicated calculation result that can only generated by MathCAD?"

The Mathcad functions "CreateMesh" and "CreateSpace" both result in "three nested matrices." So the output of these is a data set of numbers; these could be exported to a file, read by the plotting software of your choice, and you're good to go!

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Notify Moderator

12-04-2020
03:21 PM

12-04-2020
03:21 PM

Re: Efficiency Optimization

Prime 5.0 and above have other plotting features that can make a nice looking graph. Or you can always export to excel or other plotting programs.