48
Newton’s Method Newton’s Method for Monte-Carlo Based Residuals C. T. Kelley NC State University tim [email protected] Joint with Jeff Willert, Dana Knoll, Ryosuke Park, Xiaojun Chen Supported by CASL, LANL, ARO, NSF CUNY, New York, April 25, 2013 C. T. Kelley Newton’s Method CUNY: New York, 2013 1 / 43

Newton's Method for Monte-Carlo Based Residuals€¦ · Newton’s Method Newton’s Method for Monte-Carlo Based Residuals C. T. Kelley NC State University tim [email protected] Joint

  • Upload
    others

  • View
    3

  • Download
    0

Embed Size (px)

Citation preview

Page 1: Newton's Method for Monte-Carlo Based Residuals€¦ · Newton’s Method Newton’s Method for Monte-Carlo Based Residuals C. T. Kelley NC State University tim kelley@ncsu.edu Joint

Newton’s Method

Newton’s Method for Monte-Carlo BasedResiduals

C. T. KelleyNC State University

tim [email protected]

Joint with Jeff Willert, Dana Knoll, Ryosuke Park,Xiaojun Chen

Supported by CASL, LANL, ARO, NSF

CUNY, New York, April 25, 2013

C. T. Kelley Newton’s Method CUNY: New York, 2013 1 / 43

Page 2: Newton's Method for Monte-Carlo Based Residuals€¦ · Newton’s Method Newton’s Method for Monte-Carlo Based Residuals C. T. Kelley NC State University tim kelley@ncsu.edu Joint

Newton’s Method

Outline

1 Collaborators

2 Newton’s Method

3 Newton-MC

4 JFNK-MC

5 Neutron Transport Equation

6 Results

7 Conclusions

C. T. Kelley Newton’s Method CUNY: New York, 2013 2 / 43

Page 3: Newton's Method for Monte-Carlo Based Residuals€¦ · Newton’s Method Newton’s Method for Monte-Carlo Based Residuals C. T. Kelley NC State University tim kelley@ncsu.edu Joint

Newton’s Method

Collaborators

Collaborators

Jeff Willert, NCSU

Dana Knoll, Ryosuke Park, LANL

Xiaojun Chen, Hong Kong Poly

C. T. Kelley Newton’s Method CUNY: New York, 2013 3 / 43

Page 4: Newton's Method for Monte-Carlo Based Residuals€¦ · Newton’s Method Newton’s Method for Monte-Carlo Based Residuals C. T. Kelley NC State University tim kelley@ncsu.edu Joint

Newton’s Method

Newton’s Method

Notation

Objective: find a solution of

F (u) = 0

where F : RN → RN .We write F = (f1, . . . , fN)T . The Jacobian matrix F ′ is

(F ′)ij = ∂fi/∂uj

C. T. Kelley Newton’s Method CUNY: New York, 2013 4 / 43

Page 5: Newton's Method for Monte-Carlo Based Residuals€¦ · Newton’s Method Newton’s Method for Monte-Carlo Based Residuals C. T. Kelley NC State University tim kelley@ncsu.edu Joint

Newton’s Method

Newton’s Method

Newton’s Method

Transition from current point uc to new one u+.

u+ = uc − F ′(uc)−1F (uc).

Interpretation: u+ is the root of the local linear model at uc

Lc(u) = F (uc) + F ′(uc)(u − uc)

C. T. Kelley Newton’s Method CUNY: New York, 2013 5 / 43

Page 6: Newton's Method for Monte-Carlo Based Residuals€¦ · Newton’s Method Newton’s Method for Monte-Carlo Based Residuals C. T. Kelley NC State University tim kelley@ncsu.edu Joint

Newton’s Method

Newton’s Method

Convergence Theory for Exact Linear Solves

Standard Assumptions (SA):

F (u∗) = 0

F ′(u∗) is nonsingular.

F ′(u) is Lipschitz continuous with Lipschitz constant γ

‖F ′(u)− F ′(u′)‖ ≤ γ‖u − u′‖

C. T. Kelley Newton’s Method CUNY: New York, 2013 6 / 43

Page 7: Newton's Method for Monte-Carlo Based Residuals€¦ · Newton’s Method Newton’s Method for Monte-Carlo Based Residuals C. T. Kelley NC State University tim kelley@ncsu.edu Joint

Newton’s Method

Newton’s Method

Convergence Theory: I

Theorem: SA + Good Data (‖e0‖ small) implies that

‖e+‖ = O(‖ec‖2).

Here e = u − u∗.So the iteration converges.

C. T. Kelley Newton’s Method CUNY: New York, 2013 7 / 43

Page 8: Newton's Method for Monte-Carlo Based Residuals€¦ · Newton’s Method Newton’s Method for Monte-Carlo Based Residuals C. T. Kelley NC State University tim kelley@ncsu.edu Joint

Newton’s Method

Newton’s Method

Errors in Function and Jacobian

Theorem: SA + Good Data + Small Perturbations imply that if

u+ = uc + s

‖(F ′(uc) + ∆(uc))−1s + (F (uc) + ε(uc))‖ ≤ ηc‖(F (uc) + ε(uc))‖

then

‖e+‖ = O(‖ec‖2 + (‖∆(uc)‖+ ηc)‖ec‖+ ‖ε(uc)‖).

So the iteration converges up to the resolution of the residual F .

C. T. Kelley Newton’s Method CUNY: New York, 2013 8 / 43

Page 9: Newton's Method for Monte-Carlo Based Residuals€¦ · Newton’s Method Newton’s Method for Monte-Carlo Based Residuals C. T. Kelley NC State University tim kelley@ncsu.edu Joint

Newton’s Method

Newton’s Method

The problem here is different

Evaluations of F , F ′, . . . have Monte Carlo (MC) components, so

You have a variance estimate, but . . .

No bounds on errors in functions/Jacobians

Severe error accumulation in methods like matrix-freeNewton-GMRES

C. T. Kelley Newton’s Method CUNY: New York, 2013 9 / 43

Page 10: Newton's Method for Monte-Carlo Based Residuals€¦ · Newton’s Method Newton’s Method for Monte-Carlo Based Residuals C. T. Kelley NC State University tim kelley@ncsu.edu Joint

Newton’s Method

Newton-MC

MC-based Data for Newton: Notation

NMC (NJMC ) is the number of trails for the function (Jacobian

or Jacobian-vector product).

F (u,NMC ) an outcome for the residual F (u).

J(u,NJMC ) an outcome for the Jacobian F ′(u).

Jp(u, v ,NJMC ) an outcome for the product F ′(u)v .

C. T. Kelley Newton’s Method CUNY: New York, 2013 10 / 43

Page 11: Newton's Method for Monte-Carlo Based Residuals€¦ · Newton’s Method Newton’s Method for Monte-Carlo Based Residuals C. T. Kelley NC State University tim kelley@ncsu.edu Joint

Newton’s Method

Newton-MC

Consistency: Matrix-Based Methods

There are functions cF and cJ such that for δ > 0

Prob

(‖F (u)− F (u,NMC )‖ > cF (δ)√

NMC

)< δ,

and

Prob

‖F ′(u)− J(u,NJMC )‖ > cJ(δ)√

NJMC

< δ.

C. T. Kelley Newton’s Method CUNY: New York, 2013 11 / 43

Page 12: Newton's Method for Monte-Carlo Based Residuals€¦ · Newton’s Method Newton’s Method for Monte-Carlo Based Residuals C. T. Kelley NC State University tim kelley@ncsu.edu Joint

Newton’s Method

Newton-MC

Algorithmic Idea

Increase NMC as the iteration progressesto refine quality of solution.

Leave NJMC alone.

Speedup in nonlinear iteration not worth it.

Will this iteration converge?

Probably!

C. T. Kelley Newton’s Method CUNY: New York, 2013 12 / 43

Page 13: Newton's Method for Monte-Carlo Based Residuals€¦ · Newton’s Method Newton’s Method for Monte-Carlo Based Residuals C. T. Kelley NC State University tim kelley@ncsu.edu Joint

Newton’s Method

Newton-MC

Algorithmic Idea

Increase NMC as the iteration progressesto refine quality of solution.

Leave NJMC alone.

Speedup in nonlinear iteration not worth it.

Will this iteration converge? Probably!

C. T. Kelley Newton’s Method CUNY: New York, 2013 12 / 43

Page 14: Newton's Method for Monte-Carlo Based Residuals€¦ · Newton’s Method Newton’s Method for Monte-Carlo Based Residuals C. T. Kelley NC State University tim kelley@ncsu.edu Joint

Newton’s Method

Newton-MC

Newton-MC Algorithm

Newton-MC(u,NMC ,NJMC ,Ninc , η, τr , τa)

Evaluate RMC = F (u,NMC ); τ ← τr‖RMC‖+ τa.while ‖RMC‖ > τ do

Compute J(u,NJMC )

Find s which satisfies‖J(u,NJ

MC )s + F (u,NMC )‖ ≤ η‖F (u,NMC )‖.u ← u + sEvaluate RMC = F (u,NMC );NMC ← NincNMC

end while

C. T. Kelley Newton’s Method CUNY: New York, 2013 13 / 43

Page 15: Newton's Method for Monte-Carlo Based Residuals€¦ · Newton’s Method Newton’s Method for Monte-Carlo Based Residuals C. T. Kelley NC State University tim kelley@ncsu.edu Joint

Newton’s Method

Newton-MC

Tracking Theorem: Assumptions

Standard Assumptions for Newton

Exact (no MC) Newton iteration xNn Initial iterate good enough and η small enough so that‖eNn+1‖ ≤ rN‖eNn ‖

We do not try to drive ηn → 0. Not practical with an MC-basedresidual.

C. T. Kelley Newton’s Method CUNY: New York, 2013 14 / 43

Page 16: Newton's Method for Monte-Carlo Based Residuals€¦ · Newton’s Method Newton’s Method for Monte-Carlo Based Residuals C. T. Kelley NC State University tim kelley@ncsu.edu Joint

Newton’s Method

Newton-MC

Tracking Theorem

Given integer K , ω ∈ (0, 1), and r ∈ (rN , 1), there are NMC , NJMC ,

and Ninc , such that with probability (1− ω) for all 1 ≤ n ≤ K , theiteration produced by Algorithm Newton-MC satisfies

‖en‖ ≤ rn‖e0‖,

and there is KF (depending only on F and u∗) such that

‖F (un)‖ ≤ KF rn‖F (u0)‖.

C. T. Kelley Newton’s Method CUNY: New York, 2013 15 / 43

Page 17: Newton's Method for Monte-Carlo Based Residuals€¦ · Newton’s Method Newton’s Method for Monte-Carlo Based Residuals C. T. Kelley NC State University tim kelley@ncsu.edu Joint

Newton’s Method

Newton-MC

Tracking is not Convergence

You only see a high probability of error/residual reduction,

and only for a fixed (K ) number of iterations.

You have to manage NMC to get even that.

And it gets stranger . . .

C. T. Kelley Newton’s Method CUNY: New York, 2013 16 / 43

Page 18: Newton's Method for Monte-Carlo Based Residuals€¦ · Newton’s Method Newton’s Method for Monte-Carlo Based Residuals C. T. Kelley NC State University tim kelley@ncsu.edu Joint

Newton’s Method

JFNK-MC

Consistency: Matrix-Free Krylov Methods

Residual Consistency

Prob

(‖F (u)− F (u,NMC )‖ > cF (δ)√

NMC

)< δ,

plus

Prob

‖F ′(u)v − Jp(u, v ,NJMC )‖ > cJv (δ)√

NJMC

< δ.

C. T. Kelley Newton’s Method CUNY: New York, 2013 17 / 43

Page 19: Newton's Method for Monte-Carlo Based Residuals€¦ · Newton’s Method Newton’s Method for Monte-Carlo Based Residuals C. T. Kelley NC State University tim kelley@ncsu.edu Joint

Newton’s Method

JFNK-MC

Bad Idea for Algorithm

Terminate inner iteration when the Monte Carlo Inexact NewtonCondition (INC-MC) holds:

‖Jp(u, s,NJMC ) + F (uc ,NMC )‖ ≤ η‖F (uc ,NMC )‖,

and obtain a nice tracking theorem.Just like normal inexact Newton. What could go wrong?

C. T. Kelley Newton’s Method CUNY: New York, 2013 18 / 43

Page 20: Newton's Method for Monte-Carlo Based Residuals€¦ · Newton’s Method Newton’s Method for Monte-Carlo Based Residuals C. T. Kelley NC State University tim kelley@ncsu.edu Joint

Newton’s Method

JFNK-MC

But there’s a problem

You call the mat-vec with every Krylov iteration.There is no Jacobian behind that mat-vec.

The accuracy is low.

Errors accumulate rapidly.

This is a big deal (Simoncini-Szyld 03–07)

Their solution: very high accuracy for early KrylovsWe can’t do that; MC simulation too costly.

One solution: Take Youngman’s Method, please.Doctor, it hurts when I take too many Krylovs.

C. T. Kelley Newton’s Method CUNY: New York, 2013 19 / 43

Page 21: Newton's Method for Monte-Carlo Based Residuals€¦ · Newton’s Method Newton’s Method for Monte-Carlo Based Residuals C. T. Kelley NC State University tim kelley@ncsu.edu Joint

Newton’s Method

JFNK-MC

But there’s a problem

You call the mat-vec with every Krylov iteration.There is no Jacobian behind that mat-vec.

The accuracy is low.

Errors accumulate rapidly.

This is a big deal (Simoncini-Szyld 03–07)

Their solution: very high accuracy for early KrylovsWe can’t do that; MC simulation too costly.

One solution:

Take Youngman’s Method, please.Doctor, it hurts when I take too many Krylovs.

C. T. Kelley Newton’s Method CUNY: New York, 2013 19 / 43

Page 22: Newton's Method for Monte-Carlo Based Residuals€¦ · Newton’s Method Newton’s Method for Monte-Carlo Based Residuals C. T. Kelley NC State University tim kelley@ncsu.edu Joint

Newton’s Method

JFNK-MC

But there’s a problem

You call the mat-vec with every Krylov iteration.There is no Jacobian behind that mat-vec.

The accuracy is low.

Errors accumulate rapidly.

This is a big deal (Simoncini-Szyld 03–07)

Their solution: very high accuracy for early KrylovsWe can’t do that; MC simulation too costly.

One solution: Take Youngman’s Method,

please.Doctor, it hurts when I take too many Krylovs.

C. T. Kelley Newton’s Method CUNY: New York, 2013 19 / 43

Page 23: Newton's Method for Monte-Carlo Based Residuals€¦ · Newton’s Method Newton’s Method for Monte-Carlo Based Residuals C. T. Kelley NC State University tim kelley@ncsu.edu Joint

Newton’s Method

JFNK-MC

But there’s a problem

You call the mat-vec with every Krylov iteration.There is no Jacobian behind that mat-vec.

The accuracy is low.

Errors accumulate rapidly.

This is a big deal (Simoncini-Szyld 03–07)

Their solution: very high accuracy for early KrylovsWe can’t do that; MC simulation too costly.

One solution: Take Youngman’s Method, please.

Doctor, it hurts when I take too many Krylovs.

C. T. Kelley Newton’s Method CUNY: New York, 2013 19 / 43

Page 24: Newton's Method for Monte-Carlo Based Residuals€¦ · Newton’s Method Newton’s Method for Monte-Carlo Based Residuals C. T. Kelley NC State University tim kelley@ncsu.edu Joint

Newton’s Method

JFNK-MC

But there’s a problem

You call the mat-vec with every Krylov iteration.There is no Jacobian behind that mat-vec.

The accuracy is low.

Errors accumulate rapidly.

This is a big deal (Simoncini-Szyld 03–07)

Their solution: very high accuracy for early KrylovsWe can’t do that; MC simulation too costly.

One solution: Take Youngman’s Method, please.Doctor, it hurts when I take too many Krylovs.

C. T. Kelley Newton’s Method CUNY: New York, 2013 19 / 43

Page 25: Newton's Method for Monte-Carlo Based Residuals€¦ · Newton’s Method Newton’s Method for Monte-Carlo Based Residuals C. T. Kelley NC State University tim kelley@ncsu.edu Joint

Newton’s Method

JFNK-MC

So don’t take too many Krylovs!

H. Youngman

C. T. Kelley Newton’s Method CUNY: New York, 2013 20 / 43

Page 26: Newton's Method for Monte-Carlo Based Residuals€¦ · Newton’s Method Newton’s Method for Monte-Carlo Based Residuals C. T. Kelley NC State University tim kelley@ncsu.edu Joint

Newton’s Method

JFNK-MC

Limitations of Youngman’s Method

Need a good preconditioner → low Krylov count is ok.

You don’t know how low, in general.Our example has the compactness properties you want.

Must impose a hard limit on Krylov count and hope it’senough.

Theory is cleanest with GMRES as the Krylov solver.

C. T. Kelley Newton’s Method CUNY: New York, 2013 21 / 43

Page 27: Newton's Method for Monte-Carlo Based Residuals€¦ · Newton’s Method Newton’s Method for Monte-Carlo Based Residuals C. T. Kelley NC State University tim kelley@ncsu.edu Joint

Newton’s Method

JFNK-MC

Jacobian-Free Newton-Krylov-MC (JFNK-MC)

JFNK-MC(u,NMC ,NJMC ,Ninc , η,KL,KR , τr , τa)

Evaluate RMC = F (u,NMC ); τ ← τr‖RMC‖+ τa.while ‖RMC‖ > τ do

Use GMRES(KL) with at most KR − 1 restarts to find s.Terminate the Krylov iteration when INC-MC holds or afterKL × KR linear iterations.u ← u + sNMC ← Ninc ∗ NMC ;Evaluate RMC = F (u,NMC )

end while

C. T. Kelley Newton’s Method CUNY: New York, 2013 22 / 43

Page 28: Newton's Method for Monte-Carlo Based Residuals€¦ · Newton’s Method Newton’s Method for Monte-Carlo Based Residuals C. T. Kelley NC State University tim kelley@ncsu.edu Joint

Newton’s Method

JFNK-MC

Tracking Theorem for JFNK-MC

Assumptions:

Assumptions for first tracking theorem, PLUS

At most KL Krylovs needed to get INC for exact iteration.

No breakdown (premature termination) in GMRES iteration.

Conclusion: Same.

C. T. Kelley Newton’s Method CUNY: New York, 2013 23 / 43

Page 29: Newton's Method for Monte-Carlo Based Residuals€¦ · Newton’s Method Newton’s Method for Monte-Carlo Based Residuals C. T. Kelley NC State University tim kelley@ncsu.edu Joint

Newton’s Method

Neutron Transport Equation

Region of Interest: Heterogeneous

From CASL Image Gallery

C. T. Kelley Newton’s Method CUNY: New York, 2013 24 / 43

Page 30: Newton's Method for Monte-Carlo Based Residuals€¦ · Newton’s Method Newton’s Method for Monte-Carlo Based Residuals C. T. Kelley NC State University tim kelley@ncsu.edu Joint

Newton’s Method

Neutron Transport Equation

Neutron Transport Equation: Ia

Notation:

D ⊂ R3, r = (x , y , z)T ∈ D

Ω ∈ S2

ψ(r ,E , Ω) angular flux of Neutrons at

space: location rmomentum: direction Ω and energy E ≥ 0

Boundary conditions on incoming flux.

C. T. Kelley Newton’s Method CUNY: New York, 2013 25 / 43

Page 31: Newton's Method for Monte-Carlo Based Residuals€¦ · Newton’s Method Newton’s Method for Monte-Carlo Based Residuals C. T. Kelley NC State University tim kelley@ncsu.edu Joint

Newton’s Method

Neutron Transport Equation

Neutron Transport Equation: Ib

This is a high-dimensional problem:

One space dimension is 3D (space+direction+energy)

Two space dimensions is 5D (space+ 2 × direction + energy)

Three space dimensions is 6D (space+2 × direction+energy)

Why does one space dimension lead to a continuum of directions?Stay tuned.

C. T. Kelley Newton’s Method CUNY: New York, 2013 26 / 43

Page 32: Newton's Method for Monte-Carlo Based Residuals€¦ · Newton’s Method Newton’s Method for Monte-Carlo Based Residuals C. T. Kelley NC State University tim kelley@ncsu.edu Joint

Newton’s Method

Neutron Transport Equation

MC vs Deterministic

Solutions in 3D are non-smooth

Fine grids (in 6D!) are needed to resolve the solution.Angular grids produce artifacts in vacuum regions.Poorly scaled problems (shielding) can’t be done well at all.

MC addresses these things, but . . .

MC is slowMC needs tuning for do its best.

Hybrid methods seem to solve some of the problems.

C. T. Kelley Newton’s Method CUNY: New York, 2013 27 / 43

Page 33: Newton's Method for Monte-Carlo Based Residuals€¦ · Newton’s Method Newton’s Method for Monte-Carlo Based Residuals C. T. Kelley NC State University tim kelley@ncsu.edu Joint

Newton’s Method

Neutron Transport Equation

Neutron Transport Equation: II

Simplifications: round 1

No time dependence.Solve time-independent problems to integrate in time.

Neglect fission sources.Methods don’t change much if we put them in.

C. T. Kelley Newton’s Method CUNY: New York, 2013 28 / 43

Page 34: Newton's Method for Monte-Carlo Based Residuals€¦ · Newton’s Method Newton’s Method for Monte-Carlo Based Residuals C. T. Kelley NC State University tim kelley@ncsu.edu Joint

Newton’s Method

Neutron Transport Equation

Neutron Transport Equation: III

Ω · ∇ψ(r ,E , Ω) + Σt(r ,E )ψ(r ,E , Ω)

= 14π

∫S2 dΩ′

∫∞0 dE ′Σs(r ,E ′ → E , Ω′ → Ω)ψ(r ,E ′, Ω′)

+q(r ,E , Ω)/4π,

Quantity of interest: scalar flux

φ(r ,E ) =

∫S2

ψ(r ,E , Ω′)dΩ′

C. T. Kelley Newton’s Method CUNY: New York, 2013 29 / 43

Page 35: Newton's Method for Monte-Carlo Based Residuals€¦ · Newton’s Method Newton’s Method for Monte-Carlo Based Residuals C. T. Kelley NC State University tim kelley@ncsu.edu Joint

Newton’s Method

Neutron Transport Equation

Neutron Transport Equation: III

Σt and Σs are transmission and scattering cross sections.They are ugly!

From CASL Image Gallery

C. T. Kelley Newton’s Method CUNY: New York, 2013 30 / 43

Page 36: Newton's Method for Monte-Carlo Based Residuals€¦ · Newton’s Method Newton’s Method for Monte-Carlo Based Residuals C. T. Kelley NC State University tim kelley@ncsu.edu Joint

Newton’s Method

Neutron Transport Equation

Solution Methods: two of many

SN : Faster and easier to analyze

quadrature in angle,differences/elements/volumes in space,piecewise constant in Energy (multi-group approximation).Yet another problem with deterministic computing.Solve with standard linear (or nonlinear!!) solvers.

Monte-Carlo (MC): Slower with better results

No meshes in angle/energyNeutron ensemble randomly scatters via scattering/energycross sectionsAccumulate fluxes (and other angular moments) at the end.

C. T. Kelley Newton’s Method CUNY: New York, 2013 31 / 43

Page 37: Newton's Method for Monte-Carlo Based Residuals€¦ · Newton’s Method Newton’s Method for Monte-Carlo Based Residuals C. T. Kelley NC State University tim kelley@ncsu.edu Joint

Newton’s Method

Neutron Transport Equation

More Simplification

This is too much, so we simplify again to

Monoenergetic (no E )

Isotropic (no Ω′ → Ω)

One space dimension

You can learn a lot from even this simple case.

C. T. Kelley Newton’s Method CUNY: New York, 2013 32 / 43

Page 38: Newton's Method for Monte-Carlo Based Residuals€¦ · Newton’s Method Newton’s Method for Monte-Carlo Based Residuals C. T. Kelley NC State University tim kelley@ncsu.edu Joint

Newton’s Method

Neutron Transport Equation

Transport Equation in 1-D

µ∂ψ

∂x(x , µ) + ψ(x , µ) =

c(x)

2

∫ 1

−1ψ(x , µ′) dµ′ + q(x)/2,

Boundary Conditions:

ψ(0, µ) = ψl(µ), µ > 0;ψ(τ, µ) = ψr (µ), µ < 0.

C. T. Kelley Newton’s Method CUNY: New York, 2013 33 / 43

Page 39: Newton's Method for Monte-Carlo Based Residuals€¦ · Newton’s Method Newton’s Method for Monte-Carlo Based Residuals C. T. Kelley NC State University tim kelley@ncsu.edu Joint

Newton’s Method

Neutron Transport Equation

µ = cos(θ)

C. T. Kelley Newton’s Method CUNY: New York, 2013 34 / 43

Page 40: Newton's Method for Monte-Carlo Based Residuals€¦ · Newton’s Method Newton’s Method for Monte-Carlo Based Residuals C. T. Kelley NC State University tim kelley@ncsu.edu Joint

Newton’s Method

Neutron Transport Equation

Nonlinear Diffusion Acceleration (NDA): Step 1

Nonlinear compact fixed point problem for φ.Transport sweep: Given input φLO , solve the high-order problem

µ∂ψ

∂x(x , µ) + ψ(x , µ) =

c(x)

2φLO(x) + q(x)/2

Then compute the high-order flux

φHO(x) =

∫ 1

−1ψ(x , µ′) dµ′

and current

JHO(x) =

∫ 1

−1µ′ψ(x , µ′) dµ′ ≡ M1ψ

computing ψ only once for bothC. T. Kelley Newton’s Method CUNY: New York, 2013 35 / 43

Page 41: Newton's Method for Monte-Carlo Based Residuals€¦ · Newton’s Method Newton’s Method for Monte-Carlo Based Residuals C. T. Kelley NC State University tim kelley@ncsu.edu Joint

Newton’s Method

Neutron Transport Equation

Nonlinear Diffusion Acceleration (NDA): Step 2

Define

D =JHO + 1

3dφHO

dx

φHO.

The low-order nonlinear equation for φLO is F(φLO) = 0, where

F(φ) =d

dx

[−1

3

dx

]+ (1− c)φ+

d

dx

[D(φHO , JHO)φ

]with boundary conditions φLO = φHO .Equivalent to original formulation!

C. T. Kelley Newton’s Method CUNY: New York, 2013 36 / 43

Page 42: Newton's Method for Monte-Carlo Based Residuals€¦ · Newton’s Method Newton’s Method for Monte-Carlo Based Residuals C. T. Kelley NC State University tim kelley@ncsu.edu Joint

Newton’s Method

Neutron Transport Equation

Preconditioner

Preconditioner inverts

Lw =d

dx

[−1

3

dw

dx

]+ (1− c)w + D(φHO , JHO)

dw

dx

with correct boundary conditions to solve linearized problem forthe Newton step.This linearized problem is a compact fixed point problem.

C. T. Kelley Newton’s Method CUNY: New York, 2013 37 / 43

Page 43: Newton's Method for Monte-Carlo Based Residuals€¦ · Newton’s Method Newton’s Method for Monte-Carlo Based Residuals C. T. Kelley NC State University tim kelley@ncsu.edu Joint

Newton’s Method

Neutron Transport Equation

NDA Hybrid Method

Solve the high-order problem with Monte Carlo for φ and J

better results + higher costBUT we are asking MC to solve a fixed source problemno scattering is good + GPU Friendly.

Solve the low-order problem in a standard way

Resolve a few details

C. T. Kelley Newton’s Method CUNY: New York, 2013 38 / 43

Page 44: Newton's Method for Monte-Carlo Based Residuals€¦ · Newton’s Method Newton’s Method for Monte-Carlo Based Residuals C. T. Kelley NC State University tim kelley@ncsu.edu Joint

Newton’s Method

Neutron Transport Equation

Analytic Jacobian-Vector Product

If we plan to replace the transport sweep with a MC simulation,then

A finite difference Jacobian is a problem

Accuracy is roughly square root of function accuracy at bestMC accuracy will be low and expressed probabilistically

So the only hope for us is an analytic Jacobian-vector product:

chain rule + linear dependence of φHO and JHO on φLO .cost of mat-vec is one extra MC transport sweep.

C. T. Kelley Newton’s Method CUNY: New York, 2013 39 / 43

Page 45: Newton's Method for Monte-Carlo Based Residuals€¦ · Newton’s Method Newton’s Method for Monte-Carlo Based Residuals C. T. Kelley NC State University tim kelley@ncsu.edu Joint

Newton’s Method

Results

Example

Physical parameters:

c = .99; τ = 10; q = .5;

Old Way: Beat GMRES to death and

NMC = 106, 108, 1010

New Way:NMC ← NMC/2

with each iteration

C. T. Kelley Newton’s Method CUNY: New York, 2013 40 / 43

Page 46: Newton's Method for Monte-Carlo Based Residuals€¦ · Newton’s Method Newton’s Method for Monte-Carlo Based Residuals C. T. Kelley NC State University tim kelley@ncsu.edu Joint

Newton’s Method

Results

Iteration History: Old Way

0 20 40 60 80 100 12010 3

10 2

10 1

100

101Nonlinear Residual v. Function Evaluations

Function Evaluations

Non

linea

r Res

idua

l

Run 1: 106

Run 2: 108

Run 3: 1010

C. T. Kelley Newton’s Method CUNY: New York, 2013 41 / 43

Page 47: Newton's Method for Monte-Carlo Based Residuals€¦ · Newton’s Method Newton’s Method for Monte-Carlo Based Residuals C. T. Kelley NC State University tim kelley@ncsu.edu Joint

Newton’s Method

Results

Iteration History: New Way KL = 10,KR = 1, η = .01

106

107

108

109

1010

1011

10−2

10−1

100

101

Residual Histories

Total Accumulated Histories

Non

linear

Resid

ual

C. T. Kelley Newton’s Method CUNY: New York, 2013 42 / 43

Page 48: Newton's Method for Monte-Carlo Based Residuals€¦ · Newton’s Method Newton’s Method for Monte-Carlo Based Residuals C. T. Kelley NC State University tim kelley@ncsu.edu Joint

Newton’s Method

Conclusions

Conclusions

Tracking theorems for Newton-MC

Watch out for linear solver errors

Examples from neutronics simulations

C. T. Kelley Newton’s Method CUNY: New York, 2013 43 / 43