on optimal control of a free surface flow+/uploads/main/vortrag_ihp... · 2012-02-25 · problem...

Post on 02-Aug-2020

5 Views

Category:

Documents

0 Downloads

Preview:

Click to see full reader

TRANSCRIPT

On Optimal Control of a Free Surface FlowProblem Statement, Optimization Approach, FreeFem++ Realization

Sabine Repke

Fraunhofer ITWM / TU Kaiserslautern, Germany

Short Communication on Applications of FreeFem++

FreeFem++ Workshop at IHP, ParisSeptember 14 & 15, 2009

Problem Statement Optimization Approach FreeFem++ Realization

Motivation

Film Casting Process

Polymer melt is extruded through a flat die.

The molten film is stretched and cooled and is finally rolledup by a rotating chill role.

On Optimal Control of a Free Surface Flow Sabine Repke

Problem Statement Optimization Approach FreeFem++ Realization

Motivation

Film Casting Process

Polymer melt is extruded through a flat die.

The molten film is stretched and cooled and is finally rolledup by a rotating chill role.

x

y

z

On Optimal Control of a Free Surface Flow Sabine Repke

Problem Statement Optimization Approach FreeFem++ Realization

Motivation

Film Casting Process

Polymer melt is extruded through a flat die.

The molten film is stretched and cooled and is finally rolledup by a rotating chill role.

x

y

z

x

y

z

On Optimal Control of a Free Surface Flow Sabine Repke

Problem Statement Optimization Approach FreeFem++ Realization

Motivation

Film Casting Process

Polymer melt is extruded through a flat die.

The molten film is stretched and cooled and is finally rolledup by a rotating chill role.

x

y

z

x

y

z

inflow

free boundary

outflow

On Optimal Control of a Free Surface Flow Sabine Repke

Problem Statement Optimization Approach FreeFem++ Realization

Motivation

Film Casting Process

Polymer melt is extruded through a flat die.

The molten film is stretched and cooled and is finally rolledup by a rotating chill role.

x

y

z

x

y

z

inflow

free boundary

outflow

→Optimal controlof the free boundary

On Optimal Control of a Free Surface Flow Sabine Repke

Problem Statement Optimization Approach FreeFem++ Realization

Motivation

Film Casting Process

Polymer melt is extruded through a flat die.

The molten film is stretched and cooled and is finally rolledup by a rotating chill role.

x

y

z

inflow

free boundary

outflow

Optimal controlof the freeboundary

On Optimal Control of a Free Surface Flow Sabine Repke

Problem Statement Optimization Approach FreeFem++ Realization

Mathematical Model

inflow

Ω

free boundary Γ

outflow

air (pa)

x

y

On Optimal Control of a Free Surface Flow Sabine Repke

Problem Statement Optimization Approach FreeFem++ Realization

Mathematical Model

inflow

Ω

free boundary Γ

outflow

air (pa)

x

y

Stokes equations:

∇ · v = 0 in Ω,

∇ · TT = 0 in Ω,(

T = −pI+(

∇v + ∇vT) )

On Optimal Control of a Free Surface Flow Sabine Repke

Problem Statement Optimization Approach FreeFem++ Realization

Mathematical Model

inflow

Ω

free boundary Γ

outflow

air (pa)

x

y

Stokes equations:

∇ · v = 0 in Ω,

∇ · TT = 0 in Ω,(

T = −pI+(

∇v + ∇vT) )

Boundary conditions:

v − vin = 0 on inflow,

T · n = 0 on outflow,

On Optimal Control of a Free Surface Flow Sabine Repke

Problem Statement Optimization Approach FreeFem++ Realization

Mathematical Model

inflow

Ω

free boundary Γ

outflow

air (pa)

x

y

Stokes equations:

∇ · v = 0 in Ω,

∇ · TT = 0 in Ω,(

T = −pI+(

∇v + ∇vT) )

Boundary conditions:

v − vin = 0 on inflow,

T · n = 0 on outflow,

T · n + pan

v · n= 0

= 0

on freeboundary.

On Optimal Control of a Free Surface Flow Sabine Repke

Problem Statement Optimization Approach FreeFem++ Realization

Mathematical Model

inflow

Ω

free boundary Γ

outflow

air (pa)

x

y

Stokes equations:

∇ · v = 0 in Ω, (Ma)

∇ · TT = 0 in Ω, (Mo)(

T = −pI+(

∇v + ∇vT) )

Boundary conditions:

v − vin = 0 on inflow, (In)

T · n = 0 on outflow, (Out)

T · n + pan

v · n= 0 (Dyn)= 0 (Kin)

on freeboundary.

On Optimal Control of a Free Surface Flow Sabine Repke

Problem Statement Optimization Approach FreeFem++ Realization

Mathematical Model

inflow

Ω

free boundary Γ= (x , ψ(x))

outflow

air (pa)

x

y

Stokes equations:

∇ · v = 0 in Ω, (Ma)

∇ · TT = 0 in Ω, (Mo)(

T = −pI+(

∇v + ∇vT) )

Boundary conditions:

v − vin = 0 on inflow, (In)

T · n = 0 on outflow, (Out)

T · n + pan

v · n= 0 (Dyn)= 0 (Kin)

on freeboundary.

On Optimal Control of a Free Surface Flow Sabine Repke

Problem Statement Optimization Approach FreeFem++ Realization

Optimization Approach

Graph approach1: Model the free boundary Γ as

Γ = (x ,±ψ(x)) |x ∈ (0, 1).

The graph of the desired boundary is denoted by ±ψ.

1M. Hinze, S. Ziegenbalg: Optimal control of the free boundary in a two-phase Stefan problem

On Optimal Control of a Free Surface Flow Sabine Repke

Problem Statement Optimization Approach FreeFem++ Realization

Optimization Approach

Graph approach1: Model the free boundary Γ as

Γ = (x ,±ψ(x)) |x ∈ (0, 1).

The graph of the desired boundary is denoted by ±ψ.

Cost functional: (control: outer pressure pa(x))

J (ψ, pa) :=α

2

∫ 1

0

(

ψ − ψ)2

dx +β

2

∫ 1

0(pa)

2 dx

1M. Hinze, S. Ziegenbalg: Optimal control of the free boundary in a two-phase Stefan problem

On Optimal Control of a Free Surface Flow Sabine Repke

Problem Statement Optimization Approach FreeFem++ Realization

Optimization Approach

Graph approach1: Model the free boundary Γ as

Γ = (x ,±ψ(x)) |x ∈ (0, 1).

The graph of the desired boundary is denoted by ±ψ.

Cost functional: (control: outer pressure pa(x))

J (ψ, pa) :=α

2

∫ 1

0

(

ψ − ψ)2

dx +β

2

∫ 1

0(pa)

2 dx

Optimal Control Problem:

min J (ψ, pa) subject to (Ma), (Mo), (In), (Out), (Dyn), (Kin).

1M. Hinze, S. Ziegenbalg: Optimal control of the free boundary in a two-phase Stefan problem

On Optimal Control of a Free Surface Flow Sabine Repke

Problem Statement Optimization Approach FreeFem++ Realization

Lagrange Formalism

Lagrange function: L (ψ, pa, p, v, ζ1, ζ2, ζ3, ζ4,ζ5, ζ6) :=

J (ψ, pa) −

Ω(Ma)ζ1 dΩ −

Ω(Mo) · ζ2 dΩ −

On Optimal Control of a Free Surface Flow Sabine Repke

Problem Statement Optimization Approach FreeFem++ Realization

Lagrange Formalism

Lagrange function: L (ψ, pa, p, v, ζ1, ζ2, ζ3, ζ4,ζ5, ζ6) :=

J (ψ, pa) −

Ω(Ma)ζ1 dΩ −

Ω(Mo) · ζ2 dΩ −

inflow(In) · ζ3 dS

outflow(Out) · ζ4 dS −

On Optimal Control of a Free Surface Flow Sabine Repke

Problem Statement Optimization Approach FreeFem++ Realization

Lagrange Formalism

Lagrange function: L (ψ, pa, p, v, ζ1, ζ2, ζ3, ζ4,ζ5, ζ6) :=

J (ψ, pa) −

Ω(Ma)ζ1 dΩ −

Ω(Mo) · ζ2 dΩ −

inflow(In) · ζ3 dS

outflow(Out) · ζ4 dS −

Γ(Kin)ζ5 dS −

Γ(Dyn) · ζ6 dS

On Optimal Control of a Free Surface Flow Sabine Repke

Problem Statement Optimization Approach FreeFem++ Realization

Lagrange Formalism

Lagrange function: L (ψ, pa, p, v, ζ1, ζ2, ζ3, ζ4,ζ5, ζ6) :=

J (ψ, pa) −

Ω(Ma)ζ1 dΩ −

Ω(Mo) · ζ2 dΩ −

inflow(In) · ζ3 dS

outflow(Out) · ζ4 dS −

Γ(Kin)ζ5 dS −

Γ(Dyn) · ζ6 dS

Adjoint equation system:

δL(p)[p] = 0, δL(v)[v] = 0, δL(ψ)[ψ] = 0

On Optimal Control of a Free Surface Flow Sabine Repke

Problem Statement Optimization Approach FreeFem++ Realization

Lagrange Formalism

Lagrange function: L (ψ, pa, p, v, ζ1, ζ2, ζ3, ζ4,ζ5, ζ6) :=

J (ψ, pa) −

Ω(Ma)ζ1 dΩ −

Ω(Mo) · ζ2 dΩ −

inflow(In) · ζ3 dS

outflow(Out) · ζ4 dS −

Γ(Kin)ζ5 dS −

Γ(Dyn) · ζ6 dS

Adjoint equation system:

δL(p)[p] = 0, δL(v)[v] = 0, δL(ψ)[ψ] = 0

Gradient of reduced cost function:

δL(pa)[pa] = 0

On Optimal Control of a Free Surface Flow Sabine Repke

Problem Statement Optimization Approach FreeFem++ Realization

Adjoint System and Gradient of Reduced Cost Function

Adjoint system:

On Optimal Control of a Free Surface Flow Sabine Repke

Problem Statement Optimization Approach FreeFem++ Realization

Adjoint System and Gradient of Reduced Cost Function

Adjoint system:

Stokes equations:

∇ · v = 0 in Ω,

∇ · TT = 0 in Ω,(

T = −pI +(

∇v + ∇vT))

On Optimal Control of a Free Surface Flow Sabine Repke

Problem Statement Optimization Approach FreeFem++ Realization

Adjoint System and Gradient of Reduced Cost Function

Adjoint system:

Stokes equations: Boundary conditions:

∇ · v = 0 in Ω,

∇ · TT = 0 in Ω,(

T = −pI +(

∇v + ∇vT))

v = 0 on inflow,

T · n = 0 on outflow,

T · n − ψ · n = 0 on Γ,

On Optimal Control of a Free Surface Flow Sabine Repke

Problem Statement Optimization Approach FreeFem++ Realization

Adjoint System and Gradient of Reduced Cost Function

Adjoint system:

Stokes equations: Boundary conditions:

∇ · v = 0 in Ω,

∇ · TT = 0 in Ω,(

T = −pI +(

∇v + ∇vT))

v = 0 on inflow,

T · n = 0 on outflow,

T · n − ψ · n = 0 on Γ,

On Optimal Control of a Free Surface Flow Sabine Repke

Problem Statement Optimization Approach FreeFem++ Realization

Adjoint System and Gradient of Reduced Cost Function

Adjoint system:

Stokes equations: Boundary conditions:

∇ · v = 0 in Ω,

∇ · TT = 0 in Ω,(

T = −pI +(

∇v + ∇vT))

v = 0 on inflow,

T · n = 0 on outflow,

T · n − ψ · n = 0 on Γ,

α(

ψ − ψ)

+ (pa)x v1

+ (vx · (T + paI))1 − ψx v1 = 0 on Γ,(

pav1 − ψv1

)∣

(x ,ψ(x))= 0 for x = 1.

On Optimal Control of a Free Surface Flow Sabine Repke

Problem Statement Optimization Approach FreeFem++ Realization

Adjoint System and Gradient of Reduced Cost Function

Adjoint system:

Stokes equations: Boundary conditions:

∇ · v = 0 in Ω,

∇ · TT = 0 in Ω,(

T = −pI +(

∇v + ∇vT))

v = 0 on inflow,

T · n = 0 on outflow,

T · n − ψ · n = 0 on Γ,

α(

ψ − ψ)

+ (pa)x v1

+ (vx · (T + paI))1 − ψx v1 = 0 on Γ,(

pav1 − ψv1

)∣

(x ,ψ(x))= 0 for x = 1.

Gradient of reduced cost function:

J ′(pa) = βpa − n · v|(x ,ψ(x))

1 + (ψ′(x))2, x ∈ [0, 1]

On Optimal Control of a Free Surface Flow Sabine Repke

Problem Statement Optimization Approach FreeFem++ Realization

Optimization Algorithm

Result: optimal pa

Initialization of p(0)a ;

i = 0 (Iteration counter);

FWD: Forward step 0: computation of v(0), p(0), ψ(0) using p(0)a ;

repeati = i + 1;BWD: Solve the adjoint system;

GRD: Compute the gradient J ′(p(i−1)a ) =: −d (k);

SL: Compute the step length λk using e.g. Armijo rule;

UP: Update the control: p(i)a = p

(i−1)a + λ(k)d (k);

FWD: Forward step i: compute v(i), p(i), ψ(i) using p(i)a ;

until∥

∥J ′(p

(i−1)a )

∥< tol ;

On Optimal Control of a Free Surface Flow Sabine Repke

Problem Statement Optimization Approach FreeFem++ Realization

Reminder: Mathematical Model

inflow

Ω

free boundary Γ= (x , ψ(x))

outflow

air (pa)

x

y

Stokes equations:

∇ · v = 0 in Ω, (Ma)

∇ · TT = 0 in Ω, (Mo)(

T = −pI+(

∇v + ∇vT) )

Boundary conditions:

v − vin = 0 on inflow, (In)

T · n = 0 on outflow, (Out)

T · n + pan

v · n= 0 (Dyn)= 0 (Kin)

on freeboundary.

On Optimal Control of a Free Surface Flow Sabine Repke

Problem Statement Optimization Approach FreeFem++ Realization

Algorithm for Forward Problem (FWD)

Ansatz: split off the kinematic boundary condition v · n|Γ = 0

For a fixed domain solve Stokes equations with the remainingboundary conditions.

Use v · n|Γ = 0 to calculate the new boundary (ψ).

On Optimal Control of a Free Surface Flow Sabine Repke

Problem Statement Optimization Approach FreeFem++ Realization

Algorithm for Forward Problem (FWD)

Ansatz: split off the kinematic boundary condition v · n|Γ = 0

For a fixed domain solve Stokes equations with the remainingboundary conditions.

Use v · n|Γ = 0 to calculate the new boundary (ψ).

What is v · n|Γ = 0 in terms of ψ?

Γ = (x ,±ψ(x)) |x ∈ (0, 1)

tangential vector: (1 ψ′

(x))T, (1 − ψ′

(x))T

outward unit normal vector:

n|Γ =

(

−ψ′

(x)±1

)

1√

1 + ψ′(x)

2

On Optimal Control of a Free Surface Flow Sabine Repke

Problem Statement Optimization Approach FreeFem++ Realization

v · n = 0 ⇒ ODE for ψ

0!= v · n|Γ =

(

v1v2

)

Γ·(

−ψ′

(x)±1

)

1q

1+ψ′(x)

2

= 1q

1+ψ′(x)

2

(

− v1ψ′

(x) ± v2

)

⇒ ODE : ψ′

(x) = ± v2v1

(x ,±ψ(x)), ψ(0) = R

On Optimal Control of a Free Surface Flow Sabine Repke

Problem Statement Optimization Approach FreeFem++ Realization

v · n = 0 ⇒ ODE for ψ

0!= v · n|Γ =

(

v1v2

)

Γ·(

−ψ′

(x)±1

)

1q

1+ψ′(x)

2

= 1q

1+ψ′(x)

2

(

− v1ψ′

(x) ± v2

)

⇒ ODE : ψ′

(x) = ± v2v1

(x ,±ψ(x)), ψ(0) = R

Simplification:

We use the quantities of the last iteration step to compute the newboundary, i.e.

(ψ′

(x))(k) = ±v

(k−1)2

v(k−1)1

(x ,±ψ(k−1)(x))

, ψ(k)(0) = R

⇒ Simplified ODE can be solved by explicit integration.

On Optimal Control of a Free Surface Flow Sabine Repke

Problem Statement Optimization Approach FreeFem++ Realization

Algorithm to Solve FWD step i

Input: p(i)a as a function of x

k = 0 (iteration counter);Initial boundary ψ(0) (e.g. ψ(0) ≡ R) this yield Ω(0);FEM-Solve: use Ω(0) to compute v(0), p(0);repeat

k = k + 1;ODE Solve: use v(k−1) on ψ(k−1) to obtain ψ(k);move m = ψ(k−1) − ψ(k);Ω(k) =movemesh(Ω(k−1), [x , y − m]);FEM-Solve: use Ω(k) to compute v(k), p(k);

until max(v · n)< tol ;

v(i) := v(k), p(i) := p(k), ψ(i) := ψ(k);Output: v(i), p(i), ψ(i)

On Optimal Control of a Free Surface Flow Sabine Repke

Problem Statement Optimization Approach FreeFem++ Realization

Sample Step of Forward Algorithm

initial domain:

On Optimal Control of a Free Surface Flow Sabine Repke

Problem Statement Optimization Approach FreeFem++ Realization

Sample Step of Forward Algorithm

initial domain: velocity v:

On Optimal Control of a Free Surface Flow Sabine Repke

Problem Statement Optimization Approach FreeFem++ Realization

Sample Step of Forward Algorithm

initial domain: velocity v: deformation:

On Optimal Control of a Free Surface Flow Sabine Repke

Problem Statement Optimization Approach FreeFem++ Realization

Sample Step of Forward Algorithm

initial domain: velocity v: deformation: new domain:

On Optimal Control of a Free Surface Flow Sabine Repke

Problem Statement Optimization Approach FreeFem++ Realization

Numerical Results of Forward Problem

pa = 5:

On Optimal Control of a Free Surface Flow Sabine Repke

Problem Statement Optimization Approach FreeFem++ Realization

Numerical Results of Forward Problem

pa = 5: pa = 10:

On Optimal Control of a Free Surface Flow Sabine Repke

Problem Statement Optimization Approach FreeFem++ Realization

Numerical Results of Forward Problem

pa = 5: pa = 10: pa = 15:

On Optimal Control of a Free Surface Flow Sabine Repke

Problem Statement Optimization Approach FreeFem++ Realization

Numerical Results of Forward Problem

pa = 5: pa = 10: pa = 15: pa = 5sin(5(1 − x)):

On Optimal Control of a Free Surface Flow Sabine Repke

Problem Statement Optimization Approach FreeFem++ Realization

Conclusion

Conclusion:

Numerics with FreeFem++ work very well for the forwardproblem (due to movemesh and adaptmesh functions).

Adjoint equation system is comparably easy.

On Optimal Control of a Free Surface Flow Sabine Repke

Problem Statement Optimization Approach FreeFem++ Realization

Conclusion

Conclusion:

Numerics with FreeFem++ work very well for the forwardproblem (due to movemesh and adaptmesh functions).

Adjoint equation system is comparably easy.

Outlook:

Implementation of adjoint system and gradient method→ update of control might bring some difficulties.→ need method to convert discrete data from the boundaryinto a function of x .

On Optimal Control of a Free Surface Flow Sabine Repke

Problem Statement Optimization Approach FreeFem++ Realization

OutlookReminder: Adjoint System and Gradient of Reduced Cost Function

Adjoint system:

Stokes equations: Boundary conditions:

∇ · v = 0 in Ω,

∇ · TT = 0 in Ω,(

T = −pI +(

∇v + ∇vT))

v = 0 on inflow,

T · n = 0 on outflow,

T · n − ψ · n = 0 on Γ,

α(

ψ − ψ)

+ (pa)x v1

+ (vx · (T + paI))1 − ψx v1 = 0 on Γ,(

pav1 − ψv1

)∣

(x ,ψ(x))= 0 for x = 1.

Gradient of reduced cost function:

J ′(pa) = βpa − n · v|(x ,ψ(x))

1 + (ψ′(x))2, x ∈ [0, 1]

On Optimal Control of a Free Surface Flow Sabine Repke

top related