introduction to pyheadtail · model of beam and accelerator we have a beam in some initial state we...

19
January 2015 USPAS - PyHEADTAIL 1/19 Introduction to PyHEADTAIL

Upload: others

Post on 30-Jul-2020

1 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: Introduction to PyHEADTAIL · Model of beam and accelerator We have a beam in some initial state We want to transform this beam to some final state What is a beam? – A collection

January 2015 USPAS - PyHEADTAIL 1/19

Introduction to PyHEADTAIL

Page 2: Introduction to PyHEADTAIL · Model of beam and accelerator We have a beam in some initial state We want to transform this beam to some final state What is a beam? – A collection

USPAS - PyHEADTAIL 2/19

What is PyHEADTAIL?● PyHEADTAIL is a macroparticle tracking code designed

specifically to simulate collective effects in circular accelerators

Page 3: Introduction to PyHEADTAIL · Model of beam and accelerator We have a beam in some initial state We want to transform this beam to some final state What is a beam? – A collection

USPAS - PyHEADTAIL 3/19

How does PyHEADTAIL work?

● H_ltm: linear transfer map

– Chromaticity

– Amplitude detuning

– ...

● H_kick: collective interaction

– Wakefields

– Electron cloud

– Feedback

– Space-charge

– ...

H_kickH_kickH_kick

H_ltm H_ltm

● PyHEADTAIL is a macroparticle tracking code designed specifically to simulate collective effects in circular accelerators

Page 4: Introduction to PyHEADTAIL · Model of beam and accelerator We have a beam in some initial state We want to transform this beam to some final state What is a beam? – A collection

USPAS - PyHEADTAIL 4/19

A real world example● Load Python

packages and modules

Page 5: Introduction to PyHEADTAIL · Model of beam and accelerator We have a beam in some initial state We want to transform this beam to some final state What is a beam? – A collection

USPAS - PyHEADTAIL 5/19

A real world example● Load Python

packages and modules

● Build linear periodic transfer maps

Page 6: Introduction to PyHEADTAIL · Model of beam and accelerator We have a beam in some initial state We want to transform this beam to some final state What is a beam? – A collection

USPAS - PyHEADTAIL 6/19

A real world example● Load Python

packages and modules

● Build linear periodic transfer maps

● Add (collective) kick elements

Space charge

Page 7: Introduction to PyHEADTAIL · Model of beam and accelerator We have a beam in some initial state We want to transform this beam to some final state What is a beam? – A collection

USPAS - PyHEADTAIL 7/19

A real world example● Load Python

packages and modules

● Build linear periodic transfer maps

● Add (collective) kick elements

RF Systems

Page 8: Introduction to PyHEADTAIL · Model of beam and accelerator We have a beam in some initial state We want to transform this beam to some final state What is a beam? – A collection

USPAS - PyHEADTAIL 8/19

A real world example● Load Python

packages and modules

● Build linear periodic transfer maps

● Add (collective) kick elements

Resonator andresistive wall wakes

Page 9: Introduction to PyHEADTAIL · Model of beam and accelerator We have a beam in some initial state We want to transform this beam to some final state What is a beam? – A collection

USPAS - PyHEADTAIL 9/19

A real world example● Load Python

packages and modules

● Build linear periodic transfer maps

● Add (collective) kick elements

E-cloud

Free

Quad

Dipole

Page 10: Introduction to PyHEADTAIL · Model of beam and accelerator We have a beam in some initial state We want to transform this beam to some final state What is a beam? – A collection

USPAS - PyHEADTAIL 10/19

A real world example● Load Python

packages and modules

● Build linear periodic transfer maps

● Add (collective) kick elements

Other element,yet unspecified

Page 11: Introduction to PyHEADTAIL · Model of beam and accelerator We have a beam in some initial state We want to transform this beam to some final state What is a beam? – A collection

USPAS - PyHEADTAIL 11/19

A real world example● Load Python

packages and modules

● Build linear periodic transfer maps

● Add (collective) kick elements

Monitors

Bunch monitorParticle monitor

Page 12: Introduction to PyHEADTAIL · Model of beam and accelerator We have a beam in some initial state We want to transform this beam to some final state What is a beam? – A collection

USPAS - PyHEADTAIL 12/19

A real world example● Load Python

packages and modules

● Build linear periodic transfer maps

● Add (collective) kick elements

● Place beam

Bunch

Page 13: Introduction to PyHEADTAIL · Model of beam and accelerator We have a beam in some initial state We want to transform this beam to some final state What is a beam? – A collection

USPAS - PyHEADTAIL 13/19

A real world example● Load Python

packages and modules

● Build linear periodic transfer maps

● Add (collective) kick elements

● Place beam

Bunch

Push hereand have fun!

Page 14: Introduction to PyHEADTAIL · Model of beam and accelerator We have a beam in some initial state We want to transform this beam to some final state What is a beam? – A collection

Model of beam and accelerator

● We have a beam in some initial state● We want to transform this beam to some final state● What is a beam?

– A collection of particles

– A set of generalized coordinates

– A set of canonically conjugate momenta

● What is an accelerator?– A collection of elements that modifies a subset of beam attributes

● We continuously (periodically) pass the beam through the accelerator, changing the beam attributes – our job is design the accelerator in order to balance the change of attributes to our favour

Page 15: Introduction to PyHEADTAIL · Model of beam and accelerator We have a beam in some initial state We want to transform this beam to some final state What is a beam? – A collection

USPAS - PyHEADTAIL 15/19

PyHEADTAIL workflow

Particle beam Accelerator

● Particlenumber● Charge● Mass

Phase spacecoordinates

Maps Collective effects:

● Wakfields● Electron clouds● Space charge● Feedback● ...

Track

update

call method

insert

Page 16: Introduction to PyHEADTAIL · Model of beam and accelerator We have a beam in some initial state We want to transform this beam to some final state What is a beam? – A collection

USPAS - PyHEADTAIL 16/19

PyHEADTAIL workflow

Particle beam Accelerator

● Particlenumber● Charge● Mass

Phase spacecoordinates

Maps Collective effects:

● Wakfields● Electron clouds● Space charge● Feedback● ...

Track

update

call method

insert

PyHEADTAIL modules● Independent● Maintainable● Extendible

Page 17: Introduction to PyHEADTAIL · Model of beam and accelerator We have a beam in some initial state We want to transform this beam to some final state What is a beam? – A collection

USPAS - PyHEADTAIL 17/19

PyHEADTAIL workflow

● Select the collective kick elements that we would like to treat and position them along the ring

● Connect all kick elements with linear transfer maps

Create objects

Import moduleswe would like to use

Track

for i in xrange(nturns):for m in map:

m.track(bunch)

Postprocess

Build maps

Page 18: Introduction to PyHEADTAIL · Model of beam and accelerator We have a beam in some initial state We want to transform this beam to some final state What is a beam? – A collection

USPAS - PyHEADTAIL 18/19

Summary

● What is PyHEADTAIL and how does it work?● We have shown a real world example● We have learned about the PyHEADTAIL

workflow

Page 19: Introduction to PyHEADTAIL · Model of beam and accelerator We have a beam in some initial state We want to transform this beam to some final state What is a beam? – A collection

January 2015 USPAS - PyHEADTAIL 19/19

THE END