Nur auf Docsity: Lade Optimization Structure modeled in Comsol Multiphysics software to simulate silanes and sol und mehr Grafiken und Mindmaps als PDF für Agrarbiologie herunter!
Optimization Module
User’s Guide
C o n t a c t I n f o r m a t i o n
Visit the Contact COMSOL page at www.comsol.com/contact to submit general
inquiries, contact Technical Support, or search for an address and phone number. You can
also visit the Worldwide Sales Offices page at www.comsol.com/contact/offices for
address and contact information.
If you need to contact Support, an online request form is located at the COMSOL Access
page at www.comsol.com/support/case. Other useful links include:
- Support Center: www.comsol.com/support
- Product Download: www.comsol.com/product-download
- Product Updates: www.comsol.com/support/updates
- COMSOL Blog: www.comsol.com/blogs
- Discussion Forum: www.comsol.com/community
- Events: www.comsol.com/events
- COMSOL Video Gallery: www.comsol.com/video
- Support Knowledge Base: www.comsol.com/support/knowledgebase
Part number: CM
O p t i m i z a t i o n M o d u l e U s e r ’ s G u i d e
© 1998–2018 COMSOL
Protected by patents listed on www.comsol.com/patents, and U.S. Patents 7,519,518; 7,596,474; 7,623,991; 8,457,932; 8,954,302; 9,098,106; 9,146,652; 9,323,503; 9,372,673; and 9,454,625. Patents pending. This Documentation and the Programs described herein are furnished under the COMSOL Software License Agreement (www.comsol.com/comsol-license-agreement) and may be used or copied only under the terms of the license agreement. COMSOL, the COMSOL logo, COMSOL Multiphysics, COMSOL Desktop, COMSOL Server, and LiveLink are either registered trademarks or trademarks of COMSOL AB. All other trademarks are the property of their respective owners, and COMSOL AB and its subsidiaries and products are not affiliated with, endorsed by, sponsored by, or supported by those trademark owners. For a list of such trademark owners, see www.comsol.com/trademarks. Version: COMSOL 5.
4 | C O N T E N T S
- C O N T E N T S |
- Optimization Module Overview C h a p t e r 1 : I n t r o d u c t i o n
- What Can the Optimization Module Do?.
- Where Do I Access the Documentation and Application Libraries?
- Optimization Theory C h a p t e r 2 : O p t i m i z a t i o n a n d S e n s i t i v i t y T h e o r y
- Basic Optimization Concepts
- Optimization Problem Formulation
- PDE-Constrained Optimization
- Theory for the Sensitivity Interface
- About Sensitivity Analysis
- Sensitivity Problem Formulation
- Theory for Stationary Sensitivity Analysis.
- Theory for Time-Dependent Sensitivity
- Specification of the Objective Function
- Choosing a Sensitivity Method
- Postprocessing Sensitivities
- Issues to Consider Regarding the Control Variables
- Issues to Consider Regarding the Objective Function
- Issues to Consider Regarding Constraints
- Theory for Topology Optimization
- About the Density Model
- The Helmholtz Filter
- Tanh Projection
- Penalization
- Summary
- References
- Adding an Optimization Interface C h a p t e r 3 : T h e O p t i m i z a t i o n I n t e r f a c e
- The Optimization Interface
- Least-Squares Objective
- Value Column
- Time Column
- Parameter Column
- Coordinate Column.
- Ignored Column
- Integral Objective (Point Sum Objective)
- Probe Objective
- Integral Inequality Constraint (Point Sum Inequality Constraint)
- Pointwise Inequality Constraint
- Control Variable Field
- Control Variable Bounds
- Global Objective
- Global Least-Squares Objective
- Global Inequality Constraint
- Global Control Variables
- Topology Optimization
- Introduction
- Density Model
- The Sensitivity Interface C h a p t e r 4 : T h e S e n s i t i v i t y I n t e r f a c e
- Integral Objective
- Probe Objective
- Control Variable Field
- Global Objective
- Global Control Variables
- The Optimization Study C h a p t e r 5 : T h e O p t i m i z a t i o n S o l v e r s
- The Parameter Estimation Study
- About the Optimization Solvers
- About Derivative-Free Solvers.
- About Gradient-Based Solvers.
- The Coordinate Search Solver.
- The Monte Carlo Solver
- The Nelder-Mead Solver
- The BOBYQA Solver
- The COBYLA Solver
- The SNOPT Solver
- The MMA Solver
- The Levenberg-Marquardt Solver.
- About Optimality Tolerances
- About Constraint Handling
- References for the Optimization Solvers
- The Optimization Solver
- Advanced Solver Properties
- SNOPT Solver Properties
- MMA Solver Properties
- Glossary of Terms C h a p t e r 6 : G l o s s a r y
I n t r o d u c t i o n
Welcome to the Optimization Module User’s Guide. The capabilities of the
Optimization Module can be used in conjunction with any combination of other
COMSOL products. This guide is a supplement to the COMSOL Multiphysics
Reference Manual. In this section is a short Optimization Module Overview.
8 | C H A P T E R 1 : I N T R O D U C T I O N
Optimization Module Overview
What Can the Optimization Module Do?
The Optimization Module can be used throughout the COMSOL product family —
it provides a general interface for calculating optimal solutions to engineering
problems. Any model inputs, be it geometric dimensions, part shapes, material
properties, or material distribution, can be treated as control variables, and any model
output can be an objective function.
Simulation is a powerful tool in science and engineering for predicting the behavior of
physical systems, particularly those governed by partial differential equations. In many
cases a single or a few simulations are not enough to provide sufficient understanding
of a system. Two important classes of problems whose resolution relies on a more
systematic exploratory process are:
- Design problems where the problem is to find the values of control variables or
design variables that yield the best performance of a model, quantified by means of
an objective function. Problems of this kind arise, for example, in structural
optimization, antenna design, and process optimization.
- Inverse problems , and in particular parameter estimation in multiphysics models,
where the problem is to reliably determine the values of a set of parameters that
provide simulated data which best matches measured data. Such problems arise in,
for example, geophysical imaging, nondestructive testing, and biomedical imaging.
Curve fitting also belongs to this category.
Problems of the above types can often be formulated more generally as optimization
problems. The Optimization interface and Optimization study step in COMSOL
Multiphysics are useful for solving design problems as well as inverse problems and
parameter estimation.
O P T I M I Z A T I O N A L G O R I T H M S
There are three optimization algorithms for gradient-based optimization available in
the module. The first algorithm is based on the SNOPT code developed by Philip E.
Gill of the University of California San Diego, and Walter Murray and Michael A.
Saunders of Stanford University. When using SNOPT, the objective function can have
any form and any constraints can be applied. The algorithm uses a gradient-based
optimization technique to find optimal designs and when the underlying PDE is
10 | C H A P T E R 1 : I N T R O D U C T I O N
A number of internet resources have more information about COMSOL, including
licensing and technical information. The electronic documentation, topic-based (or
context-based) help, and the application libraries are all accessed through the
COMSOL Desktop.
T H E D O C U M E N T A T I O N A N D O N L I N E H E L P
The COMSOL Multiphysics Reference Manual describes the core physics interfaces
and functionality included with the COMSOL Multiphysics license. This book also has
instructions about how to use COMSOL Multiphysics and how to access the
electronic Documentation and Help content.
Opening Topic-Based Help
The Help window is useful as it is connected to the features in the COMSOL Desktop.
To learn more about a node in the Model Builder, or a window on the Desktop, click
to highlight a node or window, then press F1 to open the Help window, which then
displays information about that feature (or click a node in the Model Builder followed
by the Help button ( ). This is called topic-based (or context) help.
If you are reading the documentation as a PDF file on your computer,
the blue links do not work to open an application or content
referenced in a different guide. However, if you are using the Help
system in COMSOL Multiphysics, these links work to open other
modules, application examples, and documentation sets.
To open the Help window:
- In the Model Builder , Application Builder , or Physics Builder click a node or
window and then press F1.
- On any toolbar (for example, Home , Definitions , or Geometry ), hover the
mouse over a button (for example, Add Physics or Build All ) and then
press F1.
- From the File menu, click Help ( ). - In the upper-right corner of the COMSOL Desktop, click the Help ( )
button.
O P T I M I Z A T I O N M O D U L E O V E R V I E W | 11
Opening the Documentation Window
T H E A P P L I C A T I O N L I B R A R I E S W I N D O W
Each model or application includes documentation with the theoretical background
and step-by-step instructions to create a model or app. The models and applications
are available in COMSOL Multiphysics as MPH files that you can open for further
investigation. You can use the step-by-step instructions and the actual models as
templates for your own modeling. In most models, SI units are used to describe the
relevant properties, parameters, and dimensions, but other unit systems are available.
Once the Application Libraries window is opened, you can search by name or browse
under a module folder name. Click to view a summary of the model or application and
its properties, including options to open it or its associated PDF document.
To open the Help window:
- In the Model Builder or Physics Builder click a node or window and then
press F1.
- On the main toolbar, click the Help ( ) button. - From the main menu, select Help>Help.
To open the Documentation window:
- Press Ctrl+F1. - From the File menu select Help>Documentation ( ).
To open the Documentation window:
- Press Ctrl+F1. - On the main toolbar, click the Documentation ( ) button. - From the main menu, select Help>Documentation.
The Application Libraries Window in the COMSOL Multiphysics
Reference Manual.
O P T I M I Z A T I O N M O D U L E O V E R V I E W | 13
COMSOL Video Gallery www.comsol.com/video
Support Knowledge Base www.comsol.com/support/knowledgebase
14 | C H A P T E R 1 : I N T R O D U C T I O N
16 | C H A P T E R 2 : O P T I M I Z A T I O N A N D S E N S I T I V I T Y T H E O R Y
Optimization Theory
This section contains theory useful for understanding and applying The Optimization
Interface and The Optimization Study. Topics explained in this section are:
- Basic Optimization Concepts - Optimization Problem Formulation - PDE-Constrained Optimization
Basic Optimization Concepts
In general there are three fundamental parts of an optimization problem — the control
variables , the objective function and, optionally, constraints.
The optimization problem is to find the value of the control variables that minimizes
(or maximizes) the objective function, subject to a number of constraints. The
constraints collectively define a set, the feasible set , of permissible values for the control
variables.
The Optimization Study together with The Optimization Interface provide a
framework for specifying and solving general optimization problems. The objective
function and constraints can depend indirectly on the control variables via the solution
of a multiphysics model. See PDE-Constrained Optimization.
Optimization Problem Formulation
The Optimization Module is built around a general single-objective minimization
problem formulation. The Optimization Study node transforms maximization as well
as multi-objective minimax and maximin problems internally to the canonical
minimization form.
T H E G E N E R A L O P T I M I Z A T I O N P R O B L E M
The most general formulation of an optimization problem can be written as
min
Q ( ξ)
ξ ∈ C
O P T I M I Z A T I O N T H E O R Y | 17
Here, the control variables are denoted by ξ, the scalar-valued objective function by Q ,
and the feasible set is denoted by C. Assuming sufficient continuity, the feasible set can
be expressed as a set of — possibly very nonlinear — inequality constraints
where G is a vector-valued function ( G is scalar-valued in case of a single constraint).
C L A S S I C A L O P T I M I Z A T I O N
In classical optimization , Q and G are given explicitly as closed-form expressions of
the control variables ξ. However, design problems and parameter estimation problems
often result in objective functions Q and constraints G that are not explicitly
expressible as closed-form expressions of the control variables ξ.
PDE-Constrained Optimization
In multiphysics modeling, it is often desirable to let control variables parameterize the
problem and seek to optimize a function of the PDE solution. The objective function
is therefore a function of both the control variables and the PDE solution, which is in
turn a function of the control variables. The multiphysics problem is a PDE, which
after discretization is represented as a system of equations L ( u (ξ), ξ) = 0 , where u is the
PDE solution and ξ the control variables.
The complete PDE-constrained optimization problem to be solved by one of the
optimization algorithms in the Optimization Module adds the PDE problem as an
equality constraint to the general optimization problem:
It is advantageous to separate those constraints in G that are defined as explicit
expressions of ξ only ( design constraints ) from those that mix u and ξ ( performance
constraints ). The former group can further be divided into simple bounds , which set
C ={ξ : lb ≤ G (ξ ) ≤ub}
For vectorial quantities, the inequality defining C is to be interpreted
component-wise and lb and ub are the corresponding vectors containing
the upper and lower bounds.
min
Q u ( ( ξ) ξ, )
L u ( (ξ ) ξ, ) = 0
^ lb^ ≤ G u (^^ (^ ξ) ξ, )^ ≤ub
O P T I M I Z A T I O N T H E O R Y | 19
probe point used for the point evaluation explicitly in a Probe Objective node under
an Optimization interface.
- Q int ,k is an integral contribution to the objective function Q. It is an integral
objective so its definition is restricted to a set of geometric entities of the same
dimension. Use an Integral Objective node under an Optimization interface to
specify an integrand and a select a set of domains, boundaries, edges or points over
which to integrate. For a point selection, the integration reduces to a summation.
Several global, probe, and integral contributions can be defined in separate nodes
under an Optimization interface. In such cases, the total global, probe, and integral
contribution is given as the sum of the contributions. If you specify one or more
objectives directly in the Optimization study step, these are also added to the sum.
S P E C I F I C A T I O N O F C O N S T R A I N T S
The full nonlinear set of constraints lb ≤ G ( u (ξ), ξ) ≤ ub in the general
PDE-constrained optimization problem, Equation 2-2, are separated into three
groups:
The first row above contains the general implicit constraints, or performance
constraints in the case of a design problem. These are given in terms of expressions
involving both the solution variables u and control variables ξ. The second row
constitutes the explicit constraints — or design constraints — which are those
lb P ≤ P ( ξ , u ) ≤ub P
lbΨ ≤Ψ ξ( ) ≤ubΨ
lb b ≤ξ ≤ub b
20 | C H A P T E R 2 : O P T I M I Z A T I O N A N D S E N S I T I V I T Y T H E O R Y
constraints given by explicit expressions only in the control variables ξ. The last row
contains the control variable bounds
The Optimization interface differentiates between the following constraints (in the
description that follows, n denotes the dimension of the multiphysics model): control
variable bounds, pointwise inequality constraints, integral inequality constraints, and
global inequality constraints, each of which are described below
- Bounds or control variable bounds are inequality constraints setting lower and
upper bounds directly on each control variable degree of freedom. Hence, bound
constraints correspond to constraints of the form lb ≤ ξ ≤ ub. They are handled
efficiently by all solvers that support them and in many cases improve solver stability
and efficiency.
- Pointwise inequality constraints are inequality constraints involving an explicit
expression in terms of the control variables. The constraint sets lower and upper
bounds on the expression for node points in a set of geometric entities of the same
dimension.
- Global inequality constraints set upper and lower bounds on a general global
expression, possibly involving both the control variables and the PDE solution.
Apart from the specification of bounds, a global inequality constraint is identical to
a Global Objective.
- Integral inequality constraints set upper and lower bounds on an integral of an
expression, possibly involving the PDE solution and control variables, over a set of
The reason for this subdivision is computational. Each evaluation of an
implicit constraint requires an up-to-date solution of the multiphysics
solution u. The gradient-based optimization methods also require a
complete sensitivity evaluation, which is computationally demanding, see
Choosing a Sensitivity Method in the COMSOL Multiphysics Reference
Manual.
Explicit constraints, in contrast, can be computed without updating the
multiphysics solution. They can, however, be nonlinear, making it
difficult for the optimization methods to follow an active constraint.
Control variable bounds are the least expensive to handle, since when
active, the optimization solver can essentially just exclude the
corresponding control variable.