HB2014 10-14 November, 2014 Ingo Hofmann · 10-14 November, 2014 Ingo Hofmann GSI/TUD Darmstadt...

21
1 Grid Noise and Entropy Growth in PIC Codes HB2014 10-14 November, 2014 Ingo Hofmann GSI/TUD Darmstadt HB2014

Transcript of HB2014 10-14 November, 2014 Ingo Hofmann · 10-14 November, 2014 Ingo Hofmann GSI/TUD Darmstadt...

Page 1: HB2014 10-14 November, 2014 Ingo Hofmann · 10-14 November, 2014 Ingo Hofmann GSI/TUD Darmstadt HB2014 • Theory overview • Grid and particle collisions in 3d and 2d (bunches +

1

Grid Noise and Entropy Growth in PIC Codes

HB2014

10-14 November, 2014

Ingo Hofmann

GSI/TUD Darmstadt

HB2014

Page 2: HB2014 10-14 November, 2014 Ingo Hofmann · 10-14 November, 2014 Ingo Hofmann GSI/TUD Darmstadt HB2014 • Theory overview • Grid and particle collisions in 3d and 2d (bunches +

• Theory overview

• Grid and particle collisions in 3d and 2d

(bunches + FODO)

• Noise and rms entropy in equilibrium

• Application to resonant/unstable processes

• Conclusions

2HB2014

Acknowledgments:

O. Boine-Frankenheim (co-worker)

J. Struckmeier (discussions)

Page 3: HB2014 10-14 November, 2014 Ingo Hofmann · 10-14 November, 2014 Ingo Hofmann GSI/TUD Darmstadt HB2014 • Theory overview • Grid and particle collisions in 3d and 2d (bunches +

Motivation

3 papers give basis for „equilibrium“ beams:

1. Theory: J. Struckmeier, Part. Acc. (1994) & Phys. Rev. E (1996) & PRSTAB (2000)

2. 3d-simulation: I. Hofmann and O. Boine-Frankenheim, to be published in PRSTAB (2014)

3. 2d-simulation: O. Boine-Frankenheim et al. NIM (2014)

Current study extends equilibrium discussion to (typical) dynamical phenomena

(mismatch, resonances ...)

- are above noise concepts useful?

3HB2014

Why do we study collisions and noise in high intensity simulation?

� „usual“ approach: let us increase N, grid rsolution, time steps � convergence

� in linacs so far we have lived well with this – questions arise for error studies

(1000‘s of linacs) with „low“ N (~105)

� in circular machines 100.000‘s of turns – cross-check resonance trapping with

space charge (noise-free simulations by G. Franchetti)

� CERN space charge workshop April 2013 triggered off new interest ..

Page 4: HB2014 10-14 November, 2014 Ingo Hofmann · 10-14 November, 2014 Ingo Hofmann GSI/TUD Darmstadt HB2014 • Theory overview • Grid and particle collisions in 3d and 2d (bunches +

EntropyLiouville - infinite resolution – coarse graining

4

• Liouville: exact areas in 2d, 4d, 6d phase space

invariant for Hamiltonian flow – no growth of „infinite

resolution“ entropy

• How break this?

• for „finite resolution“ self-consistent space charge

potential on a grid (as in PIC) exactly Hamiltonian

flow broken � growth of entropy

• for exactly resolved motion of directly interacting

particles (collisions) in 6d:− collisions break Hamiltonian flow in 6d � growth of

entropy− „infinite resolution“ entropy in 6Nd phase space still

invariant � Gibbs introduced coarse graining ofphase space to obtain entropy growth

Liouville

HB2014

( ) [ ]

cell aover averaged is

)(ln)()(

ρ

ρρρ Γ−= ∫ dXXkXSCG

Page 5: HB2014 10-14 November, 2014 Ingo Hofmann · 10-14 November, 2014 Ingo Hofmann GSI/TUD Darmstadt HB2014 • Theory overview • Grid and particle collisions in 3d and 2d (bunches +

Poisson solver grid & noise

5

Grid induced noise:

• not included in original „collisional“ approach of Struckmeier

• assume several sources:• non-Liouvillean effect by fluctuating charges on grid• focussing modulation „fast“• coherent flow vs. incoherent „temperature“

Averaging charges over cells: � loss of Hamiltonian character of phase

space flow � ���� growth of entropy

PIC: replaces infinite resolution charge

density by “grid distribution”

Phase space remains infinitely resolved

HB2014

area weigthing

Is there a practically useful „reduced“ definition of entropy?

Page 6: HB2014 10-14 November, 2014 Ingo Hofmann · 10-14 November, 2014 Ingo Hofmann GSI/TUD Darmstadt HB2014 • Theory overview • Grid and particle collisions in 3d and 2d (bunches +

“Reduced” approach for beams:J. Struckmeier suggested (1994 ff) to start from Fokker-Planck

Equation in 6d phase space space

� Assuming Markov process for collisions of charged particles: dynamical friction

� no correlation between several particles

� memory extinction

� friction and diffusion terms

6

collisional interaction

"beyond" Hamiltonian

flow in 6d

{ } { }∑∑

==−

−=

∂∂

∂+

∂≡

=

∂+

∂+

∂=

3

1,

223

1

;

3

1

),(

ji

ij

jii

iif

iLiouNon

LiouNoni i

i

i

i

ftpDpp

mfp

pt

f

t

f

p

fp

x

fx

t

f

dt

df

r

&&

βδ

δ

δ

δform second order

moments

Page 7: HB2014 10-14 November, 2014 Ingo Hofmann · 10-14 November, 2014 Ingo Hofmann GSI/TUD Darmstadt HB2014 • Theory overview • Grid and particle collisions in 3d and 2d (bunches +

Second order moments of Vlasov – FP equation���� rms based (emittance, "temperature", ...)

7

( )

( )( )

( )( )

0≥

−+

−+

−=≥

−=

−=

−=

=≡≡≡

== ∑=

yz

yz

zx

zx

yx

yx

fzyx

yx

yx

fyx

y

xfy

x

y

fx

ii

i

ieq

i

ii

TT

TT

TT

TT

TT

TTk

ds

d

TT

TTk

ds

d

sT

sTk

ds

d

sT

sTk

ds

d

mkTDD

TTx

s

mc

kT

222

222

2

22

22

ffff;if

3

12

2

22

)()()(

3

2ln 6din or 0

)(ln

)increasing one ,decreasing (one 1ln 1ln

relation)(Einstein /D /ck ; ;

3

1 ;

εεεεε

εε

γββγβββ

ε

γβ

( )

( ) ( ).2

21

3322

2;

2

'

'

322

2

2

2'2'22

22

−−

−=

=−≡

∂= ∫

γβ

ε

βγ

β

γβε

βε

τ

c

D

x

s

cEx

x

xxEx

mc

qs

ds

d

x

ctsxxxxs

dt

fxx

dt

d

ii

i

iif

ii

i

ii

iii

i

iiiii

ii negligible transient effects associated with initially non-matched self-fields

(I. Hofmann and J. Struckmeier, Part. Acc.1987)

Page 8: HB2014 10-14 November, 2014 Ingo Hofmann · 10-14 November, 2014 Ingo Hofmann GSI/TUD Darmstadt HB2014 • Theory overview • Grid and particle collisions in 3d and 2d (bunches +

Resulting in an rms entropy law

8

tioned)(equiparti if ,0

0)()()(

3

1

lnS

222

,6

,66

zyx

zy

zy

zx

zx

yx

yx

frmsd

zyxrmsdzyxd,rms

TTT

TT

TT

TT

TT

TT

TTkS

ds

d

===

−+

−+

−=

≡≡ εεεεεεε

heuristic justification:

• emittances ~ "probabilities" in phase space

• � product of probabilities for "independent" events

• entropies should be additive for ~ decoupled probabilities (� ln)

• � coupling between degrees of freedom only on microscopic level

• should be non-decreasing

• rms approximation – no higher order correlations resolved !!!

never decreasing – under the assumptions of its validity!

Page 9: HB2014 10-14 November, 2014 Ingo Hofmann · 10-14 November, 2014 Ingo Hofmann GSI/TUD Darmstadt HB2014 • Theory overview • Grid and particle collisions in 3d and 2d (bunches +

9HB2014

TRACEWIN simulations: matched equilibrium

• spherical bunch:

• k0x,y,z=60o and εz=εxy

• kx,y,z=32o/32o/32o (xyz Poisson solver)

• 1000 cells as reference base

• no acceleration – only RF gaps

ε6d ~ sin (matched) equilibrium beam

N=4000 ���� statistical noise

~ quadratic current dependence

„Confirms“ ε6d – as rms entropy concept

ε6d

Page 10: HB2014 10-14 November, 2014 Ingo Hofmann · 10-14 November, 2014 Ingo Hofmann GSI/TUD Darmstadt HB2014 • Theory overview • Grid and particle collisions in 3d and 2d (bunches +

∆ε∆ε∆ε∆ε6d/εεεε6d growth as function of # grid cells nc

HB2014 10

nc = 8:

• 16 cells within +/- 3.5 σ• outside of 3.5 σ boundary

analytical approximation

grid dominated- not resolving Gaussian profile - collision dominated

- charge ~1/N -

1 particle / cell

optimum

Minimizing rms entropy growth � determine optimum grid/particle resolution

Fully isotropic (spherical) bunch

ε6d

Page 11: HB2014 10-14 November, 2014 Ingo Hofmann · 10-14 November, 2014 Ingo Hofmann GSI/TUD Darmstadt HB2014 • Theory overview • Grid and particle collisions in 3d and 2d (bunches +

Anisotropy and grid effect���� fits to theory with IGN and kf

* fitted to data

11

IA=0

• symmetrical external focussing

k0x,y,z=60o

• variable εz/εxy

kx,y,z=60o�33o

HB2014

ε6d

Page 12: HB2014 10-14 November, 2014 Ingo Hofmann · 10-14 November, 2014 Ingo Hofmann GSI/TUD Darmstadt HB2014 • Theory overview • Grid and particle collisions in 3d and 2d (bunches +

Comparison of 3d with 2d results

HB2014 12

FODO 3d - TraceWinFODO 2d - Patric

A. B. Langdon, Effect of the spatial grid in simulation plasmas, J. Comput. Phys. (1970)

� Artificial heating if grid is too coarse: (Debye length)

Source: O. Boine-Frankenheim et al., NIM 2014 finer grid

nc: 12 8 4

converging? (3d!)

grid heating

grid heating

ε6dε6d

In 2d enhanced collisions if grid too fine � larger N

Page 13: HB2014 10-14 November, 2014 Ingo Hofmann · 10-14 November, 2014 Ingo Hofmann GSI/TUD Darmstadt HB2014 • Theory overview • Grid and particle collisions in 3d and 2d (bunches +

From matched equilibrium beams���� mismatched, resonances, ....

1. Can we apply our models of noise vs. N and/or nc to

dynamical situations with resonant effects? Use for

optimization?

2. Are there transient/resonant/unstable phenomena, which

require a more refined measure for noise/entropy than

ε6d,rms?

3. Do we need more theory efforts, or are phemenological

studies the only way?

HB2014 13

Page 14: HB2014 10-14 November, 2014 Ingo Hofmann · 10-14 November, 2014 Ingo Hofmann GSI/TUD Darmstadt HB2014 • Theory overview • Grid and particle collisions in 3d and 2d (bunches +

Non-stationary (non-equilibrium) beams- fast emittance exchange on 2kz-2kxy=0 resonance (space charge octupole)

-

HB2014 14

ε6d

ε6dεxy

εz

εxy

εz

N=105

N=103

• k0x,y,z=60/60/60o and εεεεz/εεεεxy=2

• kx,y,z=26o/26o/35o fast emittance exchange: ~ few plasma periods

nc=6

noise driven exchange

exchange practically unaffected by noise

Page 15: HB2014 10-14 November, 2014 Ingo Hofmann · 10-14 November, 2014 Ingo Hofmann GSI/TUD Darmstadt HB2014 • Theory overview • Grid and particle collisions in 3d and 2d (bunches +

Mismatched beams ���� halo formation

HB2014 15

chose large MM factor in x,y and z & N=105

ε6dε6d

MM=1 MM=1.6

linear growth =noise

coherent

noise

Page 16: HB2014 10-14 November, 2014 Ingo Hofmann · 10-14 November, 2014 Ingo Hofmann GSI/TUD Darmstadt HB2014 • Theory overview • Grid and particle collisions in 3d and 2d (bunches +

Mismatch ���� halo ~ 50 turns

HB2014 16

ε99.9%

N=128.000

fast conversion into halo � noise has no effect on this!

Page 17: HB2014 10-14 November, 2014 Ingo Hofmann · 10-14 November, 2014 Ingo Hofmann GSI/TUD Darmstadt HB2014 • Theory overview • Grid and particle collisions in 3d and 2d (bunches +

Crossing of space charge driven resonancesk0xy=900����600 / 500 cells

HB2014 17

ε6d ε6d

k0xy

Loss (%) on aperture

no tune ramp

Page 18: HB2014 10-14 November, 2014 Ingo Hofmann · 10-14 November, 2014 Ingo Hofmann GSI/TUD Darmstadt HB2014 • Theory overview • Grid and particle collisions in 3d and 2d (bunches +

HB2014 18

128 k particles, nc=4-6: find 4 „identical“ islands pushed outwards

nc=6

εx,53%

Crossing of 900 (4th order) space charge drivenresonance k0x=1050����880 / 1000 cells (k0y=1050 fixed)

Page 19: HB2014 10-14 November, 2014 Ingo Hofmann · 10-14 November, 2014 Ingo Hofmann GSI/TUD Darmstadt HB2014 • Theory overview • Grid and particle collisions in 3d and 2d (bunches +

HB2014 19

cont‘d crossing k0x=1050 ���� 880 /1000 cells

nc=12

ε6dεx,53%

128 k particles, nc=7-12: find breaking of four-fold symmetry > 500 cells

envelope instability (h=2) on top of h=4?

nc<6

Page 20: HB2014 10-14 November, 2014 Ingo Hofmann · 10-14 November, 2014 Ingo Hofmann GSI/TUD Darmstadt HB2014 • Theory overview • Grid and particle collisions in 3d and 2d (bunches +

HB2014 20

Summary: crossing k0x=1050 � 880 /1000 cells

nc

∆εx,53%

question: why more growth for finer grid, if additional mode is

only 2nd order?

N=105

Page 21: HB2014 10-14 November, 2014 Ingo Hofmann · 10-14 November, 2014 Ingo Hofmann GSI/TUD Darmstadt HB2014 • Theory overview • Grid and particle collisions in 3d and 2d (bunches +

Summary

� 3 d noise by grid well represented by rms entropy in equilibrium

beam

� Grid heating (nc<5) or collisional heating (nc>10) for small/large

number of grid cells nc � optimum nc for given N

� Anisotropy effect in „good“ agreement with theory

� Dynamical problems:

� our noise modelling seems irrelevant for fast processes – „no“effectof noise

� slow resonance crossing: retrieve noise dependence on grid, but different for island trapping � much increased halo for larger nc ?

� � needs more work especially towards resonance (collective)

effects

HB2014 21