Documentation

Design Optimization Using Frequency-Domain Check Blocks (GUI)

This example shows how to optimize a design to meet frequency-domain requirements using the Response Optimization tool. Simulink® Control Design™ software must be installed to optimize a design to meet frequency-domain design requirements.

In this example, you specify the design requirements in a Check Bode Characteristics block. You optimize rectifier filter parameters to meet gain and bandwidth requirements by minimizing a custom objective.

Model Structure

The model sdorectifier includes the following blocks:

  • Full-Wave Rectifier block — An Abs block

  • Rectifier Filter subsystem — RLC filter implemented using integrator and gain blocks

  • Filter Design Requirements block — Check Bode Characteristics block that specifies the gain and bandwidth design requirements

Design Requirements

The design optimization problem has several objectives. The design must:

  • Have a –3 dB bandwidth of at least 2 Hz

  • Limit the gain across the frequency range 2 Hz – 60 Hz to at most 0 dB

  • Limit the gain above 60 Hz to at most –20 dB

  • Maximize the filter resistance R

  • Minimize the filter inductance L

The requirements ensure that the rectifier filter combination has minimal high frequency content, responds quickly to voltage changes, and limits filter currents.

Specify Design Requirements

  1. Open the Response Optimization tool for the model.

    sdotool('sdorectifier')
    

    The Bode plot 1 tab shows the gain and bandwidth requirements specified in the Filter Design Requirements block in the model. To see their values, double-click the block to open the Block Parameters dialog box, and select the Bounds tab.

  2. Specify a custom objective to minimize the filter inductance and maximize the resistance.

    The custom objective is already defined in the sdorectifier_cost function. The function accepts the design variables R and L and returns the objective to be minimized.

      Tip   Type edit sdorectifier_cost in the command line to view this function.

    1. In the New drop-down list, select Custom Requirement.

    2. Specify the following values in the Create Requirement window, and click OK:

      • In the Name edit box, enter MaxMinRL.

      • In the Type edit box, select Minimize the function output

      • In the Function edit box, enter @sdorectifier_cost. The optimization solver calls the specified function handle.

      A new requirement variable MaxMinRL is created, and appears in the Data area in the Response Optimization tool. The Iteration plot 1 tab shows the value of MaxMinRL at each iteration during the optimization.

Specify Design Variables

When you optimize the model response, the software modifies the design variable values to meet the design requirements.

  1. In the Design Variables Set drop-down list, select New.

    Select C, L, and R in the Create Design Variable Set window. Click to add the selected parameters to a design variables set.

  2. Specify the value range for each design variable, and click OK:

    • C in the range 1 µF–1 mF

    • L in the range 1–500 mH

    • R in the range 0.01–50 ohms

    A new variable DesignVars is created, and appears in the Data area of the Response Optimization tool.

Optimize Design

  1. To view the current response of the model, click Plot Model Response.

    The Bode plot 1 window in the Response Optimization tool shows that the model output goes out of the region bounded by the design requirement line segments.

    In the Voltage scope window, you see that the filter voltage signal overshoots its steady-state value and contains significant harmonic content.

  2. Click Optimize.

    The Optimization converged message in the Optimization Progress Report indicates that the optimization method found a solution to satisfy the filter bandwidth requirements.

    The harmonic content in the filter voltage signal is reduced from the initial design.

  3. Verify that the model meets the gain and bandwidth requirements.

    The plot displays the output of the last five iterations. The final response using the optimized parameter values appears as the thick blue line.

    The optimized response lies in the white region bounded by the design requirement line segments and thus meets the requirements.

  4. Click DesignVars in the Data area and view the updated values in the Variable Preview area.

    The optimized values of the design variables are automatically updated in the Simulink model.

See Also

Related Examples

Was this topic helpful?