My name is Kamran and I'm a computational scientist working in the plasma simulation group at the United Kingdom Atomic Energy Authority.

My current work involves developing and maintaining the in-house tokamak equilibrium modelling code FreeGSNKE. Our group has been successfully using FreeGSNKE for plasma scenario and magnetic control modelling on both MAST-U and STEP (see Research page).

I am interested in all sorts of mathematical modelling problems and often find myself working at the interface between applied and computational mathematics. I have particular interests in:

  • Tokamak MHD equilibrium modelling and control.
  • Numerical integration for ODEs/PDEs.
  • Surrogate modelling (e.g. Gaussian processes, neural networks).
  • Bayesian methods (e.g. data assimilation, optimisation, UQ).
  • Parallel-in-Time (PinT) methods.
  • High performance computing.
  • Multiscale/hybrid modelling problems.

Do get in contact if you'd like to discuss any of my research or are interested in collaboration!


Education
  • University of Warwick
    University of Warwick
    Ph.D. in Mathematics of Real-World Systems
    Sep. 2020 - Sep. 2023
  • University of Warwick
    University of Warwick
    MSc in Mathematics of Real-World Systems
    Sep. 2019 - Sep. 2020
  • University College London
    University College London
    MSc in Mathematical Modelling
    Sep. 2018 - Sep. 2019
  • University of Bath
    University of Bath
    BSc in Mathematics with Industrial Placement Year
    Sep. 2013 - Jul. 2017
Experience
  • United Kingdom Atomic Energy Authority (UKAEA)
    United Kingdom Atomic Energy Authority (UKAEA)
    Computational Scientist
    Oct. 2023 - Present
  • University of Warwick
    University of Warwick
    Graduate Teaching Assistant
    Oct. 2020 - Sep. 2023
  • Kings College London
    Kings College London
    Graduate Mathematics Tutor
    Oct. 2020 - Apr. 2021
  • UK Mathematics Trust
    UK Mathematics Trust
    Marking Volunteer
    Sep. 2017 - Sep. 2020
  • University of Bath
    University of Bath
    Summer Research Intern
    Jun. 2017 - Sep. 2017
  • University of Bath
    University of Bath
    Mathematics Tutor
    Sep. 2016 - Apr. 2017
  • ConocoPhillips Ltd.
    ConocoPhillips Ltd.
    Quantitative Market Risk Analyst
    Jul. 2015 - Jul. 2016
Selected Research
Real-time virtual circuits for plasma shape control via neural network emulators: dynamic validation in closed-loop simulations
Real-time virtual circuits for plasma shape control via neural network emulators: dynamic validation in closed-loop simulations

K. Pentland, A. Ross, N. C. Amorisco, P. Cavestany, T. Nunn, A. Agnello, G. K. Holt, C. Vincent

65th IEEE Conference on Decision and Control

Reliable confinement and stable performance of tokamak fusion plasmas require accurate real-time magnetic shape control. A promising route to reduced latency and increased flexibility in plasma control systems (PCS) is to emulate physics-based controllers using neural networks. In prior work, we have demonstrated that virtual circuits (VCs), which define the poloidal field coil current vectors able to modify each plasma shape parameter independently, can be accurately emulated with neural network models trained on a large library of simulated Grad-Shafranov equilibria. This enables magnetic controllers to accurately adapt to evolving plasma equilibria, in contrast to pre-set VC schedules whose performance degrades upon departure from their reference equilibria. Here, we investigate the performance and robustness of these emulators in closed-loop simulations using the FreeGSNKE Pulse Design Tool (FPDT): a framework that couples the FreeGSNKE evolutive equilibrium solver with a virtual PCS. The FPDT models the coupling between controllers, plasma current and shape response, and actuator constraints. Using the emulated VCs within the FPDT, we demonstrate effective in-silico control of MAST Upgrade (MAST-U) plasma scenarios and show that the emulators are robust in the presence of input measurement uncertainty and under different update frequencies. These results establish the viability of neural network emulated VCs for closed-loop plasma shape control, representing a key step toward real-time deployment in the MAST-U PCS.

Virtual circuits Neural network emulation Plasma control Pulse Design Tool FreeGSNKE MAST-U

Real-time virtual circuits for plasma shape control via neural network emulators: dynamic validation in closed-loop simulations

K. Pentland, A. Ross, N. C. Amorisco, P. Cavestany, T. Nunn, A. Agnello, G. K. Holt, C. Vincent

65th IEEE Conference on Decision and Control

Reliable confinement and stable performance of tokamak fusion plasmas require accurate real-time magnetic shape control. A promising route to reduced latency and increased flexibility in plasma control systems (PCS) is to emulate physics-based controllers using neural networks. In prior work, we have demonstrated that virtual circuits (VCs), which define the poloidal field coil current vectors able to modify each plasma shape parameter independently, can be accurately emulated with neural network models trained on a large library of simulated Grad-Shafranov equilibria. This enables magnetic controllers to accurately adapt to evolving plasma equilibria, in contrast to pre-set VC schedules whose performance degrades upon departure from their reference equilibria. Here, we investigate the performance and robustness of these emulators in closed-loop simulations using the FreeGSNKE Pulse Design Tool (FPDT): a framework that couples the FreeGSNKE evolutive equilibrium solver with a virtual PCS. The FPDT models the coupling between controllers, plasma current and shape response, and actuator constraints. Using the emulated VCs within the FPDT, we demonstrate effective in-silico control of MAST Upgrade (MAST-U) plasma scenarios and show that the emulators are robust in the presence of input measurement uncertainty and under different update frequencies. These results establish the viability of neural network emulated VCs for closed-loop plasma shape control, representing a key step toward real-time deployment in the MAST-U PCS.

Virtual circuits Neural network emulation Plasma control Pulse Design Tool FreeGSNKE MAST-U

Real-time virtual circuits for plasma shape control via neural network emulators
Real-time virtual circuits for plasma shape control via neural network emulators

A. Ross, G. K. Holt, K. Pentland, A. Agnello, N. C. Amorisco, P. Cavestany, A. Garrod, T. Nunn, C. Vincent, G. McArdle

arXiv

Reliable position and shape control in tokamak plasmas requires accurate real-time regulation of several strongly coupled shape parameters. The control vectors that disentangle these couplings, referred to as virtual circuits (VCs), enable independent shape parameter control for a specific Grad--Shafranov (GS) equilibrium. Numerical calculation of VCs is not currently feasible in real time, therefore VCs are usually computed prior to each experiment, using a small number of reference GS equilibria sampled along the desired scenario trajectory, with each VC used to control the plasma within a preset time interval. While effective near the reference equilibrium, this approach can lead to degraded performance as the plasma departs from the reference equilibrium and/or from the desired trajectory, and it complicates the design of robust control strategies for rapidly evolving plasma configurations. In this paper, we construct neural-network-based emulators of plasma shape parameters from which VCs can be derived, to provide the MAST Upgrade (MAST-U) plasma control system with state-aware VCs in real-time. To do this, we develop an extensive library of over a million simulated GS equilibria, covering a substantial portion of the MAST-U operational space. These emulators provide differentiable functions whose gradients can be rapidly computed, enabling the derivation of accurate VCs for real-time shape control. We perform extensive verification of the emulated VCs by testing whether they disentangle the control problem. The neural-network-based approach delivers high accuracy and orthogonality across a diverse range of equilibria. This work establishes the physical validity of emulated VCs as a scalable and general alternative to schedules of precomputed VCs.

Plasma control Virtual circuits Neural network emulators Grad-Shafranov MAST-U

Real-time virtual circuits for plasma shape control via neural network emulators

A. Ross, G. K. Holt, K. Pentland, A. Agnello, N. C. Amorisco, P. Cavestany, A. Garrod, T. Nunn, C. Vincent, G. McArdle

arXiv

Reliable position and shape control in tokamak plasmas requires accurate real-time regulation of several strongly coupled shape parameters. The control vectors that disentangle these couplings, referred to as virtual circuits (VCs), enable independent shape parameter control for a specific Grad--Shafranov (GS) equilibrium. Numerical calculation of VCs is not currently feasible in real time, therefore VCs are usually computed prior to each experiment, using a small number of reference GS equilibria sampled along the desired scenario trajectory, with each VC used to control the plasma within a preset time interval. While effective near the reference equilibrium, this approach can lead to degraded performance as the plasma departs from the reference equilibrium and/or from the desired trajectory, and it complicates the design of robust control strategies for rapidly evolving plasma configurations. In this paper, we construct neural-network-based emulators of plasma shape parameters from which VCs can be derived, to provide the MAST Upgrade (MAST-U) plasma control system with state-aware VCs in real-time. To do this, we develop an extensive library of over a million simulated GS equilibria, covering a substantial portion of the MAST-U operational space. These emulators provide differentiable functions whose gradients can be rapidly computed, enabling the derivation of accurate VCs for real-time shape control. We perform extensive verification of the emulated VCs by testing whether they disentangle the control problem. The neural-network-based approach delivers high accuracy and orthogonality across a diverse range of equilibria. This work establishes the physical validity of emulated VCs as a scalable and general alternative to schedules of precomputed VCs.

Plasma control Virtual circuits Neural network emulators Grad-Shafranov MAST-U

The FreeGSNKE Pulse Design Tool (FPDT): a computational framework for evolutive plasma scenario and control design
The FreeGSNKE Pulse Design Tool (FPDT): a computational framework for evolutive plasma scenario and control design

K. Pentland, N. C. Amorisco, A. Ross, P. Cavestany, T. Nunn, A. Agnello, G. K. Holt, G. McArdle, C. Vincent, J. Buchanan, S. J. P. Pamela

Plasma Physics and Controlled Fusion

We present the FreeGSNKE Pulse Design Tool (FPDT), an open-source, Python-based computational framework that enables in silico testing and predictive design of tokamak plasma scenarios and control strategies. The FPDT couples the FreeGSNKE evolutive equilibrium solver with a virtual Plasma Control System (PCS) containing modular and customisable controllers. Given a set of user-defined waveforms and control parameters, the virtual PCS uses feedback and feedforward control to modulate plasma current, position, and shape, while adhering to machine safety limits on poloidal field coil currents and voltages. The resulting framework allows simulation of the controlled dynamic evolution of plasma equilibria, along with the currents in both active poloidal field coils and passive conducting structures, under the assumption of axisymmetry. The FPDT can be used to develop plasma scenarios, test control schemes, calibrate control parameters, and perform uncertainty quantification studies, thereby reducing iterative and expensive experimental testing on a physical tokamak. The FPDT is machine-agnostic and can be customised to implement different control algorithms tailored to the specific tokamak of interest. Here, we outline the overall framework and validate its performance on plasma discharges on the MAST Upgrade tokamak in the `flat-top' phase. We demonstrate excellent quantitative agreement between the FPDT simulations, the desired control waveforms, and the experimental shot data. With this extension to the FreeGSNKE open-source suite of codes we aim to encourage more reproducible and collaborative research in plasma modelling and control.

Pulse design tool Plasma control system Grad-Shafranov MHD equilibria FreeGSNKE MAST-U

The FreeGSNKE Pulse Design Tool (FPDT): a computational framework for evolutive plasma scenario and control design

K. Pentland, N. C. Amorisco, A. Ross, P. Cavestany, T. Nunn, A. Agnello, G. K. Holt, G. McArdle, C. Vincent, J. Buchanan, S. J. P. Pamela

Plasma Physics and Controlled Fusion

We present the FreeGSNKE Pulse Design Tool (FPDT), an open-source, Python-based computational framework that enables in silico testing and predictive design of tokamak plasma scenarios and control strategies. The FPDT couples the FreeGSNKE evolutive equilibrium solver with a virtual Plasma Control System (PCS) containing modular and customisable controllers. Given a set of user-defined waveforms and control parameters, the virtual PCS uses feedback and feedforward control to modulate plasma current, position, and shape, while adhering to machine safety limits on poloidal field coil currents and voltages. The resulting framework allows simulation of the controlled dynamic evolution of plasma equilibria, along with the currents in both active poloidal field coils and passive conducting structures, under the assumption of axisymmetry. The FPDT can be used to develop plasma scenarios, test control schemes, calibrate control parameters, and perform uncertainty quantification studies, thereby reducing iterative and expensive experimental testing on a physical tokamak. The FPDT is machine-agnostic and can be customised to implement different control algorithms tailored to the specific tokamak of interest. Here, we outline the overall framework and validate its performance on plasma discharges on the MAST Upgrade tokamak in the `flat-top' phase. We demonstrate excellent quantitative agreement between the FPDT simulations, the desired control waveforms, and the experimental shot data. With this extension to the FreeGSNKE open-source suite of codes we aim to encourage more reproducible and collaborative research in plasma modelling and control.

Pulse design tool Plasma control system Grad-Shafranov MHD equilibria FreeGSNKE MAST-U

Bayesian optimisation of poloidal field coil positions in tokamaks
Bayesian optimisation of poloidal field coil positions in tokamaks

T. Nunn, K. Pentland, V. Gopakumar, J. Buchanan

Physics of Plasmas

The tokamak is a world-leading concept for producing sustainable energy via magnetically-confined nuclear fusion. Identifying where to position the magnets within a tokamak, specifically the poloidal field (PF) coils, is a design problem which requires balancing a number of competing economic, physical, and engineering objectives and constraints. In this paper, we show that multi-objective Bayesian optimisation (BO), an iterative optimisation technique utilising probabilistic machine learning models, can effectively explore this complex design space and return several optimal PF coil sets. These solutions span the Pareto front, a subset of the objective space that optimally satisfies the specified objective functions. We outline an easy-to-use BO framework and demonstrate that it outperforms alternative optimisation techniques while using significantly fewer computational resources. Our results show that BO is a promising technique for fusion design problems that rely on computationally demanding high-fidelity simulations.

Bayesian optimisation Poloidal field coils Spherical tokamak MHD equilibria FreeGS

Bayesian optimisation of poloidal field coil positions in tokamaks

T. Nunn, K. Pentland, V. Gopakumar, J. Buchanan

Physics of Plasmas

The tokamak is a world-leading concept for producing sustainable energy via magnetically-confined nuclear fusion. Identifying where to position the magnets within a tokamak, specifically the poloidal field (PF) coils, is a design problem which requires balancing a number of competing economic, physical, and engineering objectives and constraints. In this paper, we show that multi-objective Bayesian optimisation (BO), an iterative optimisation technique utilising probabilistic machine learning models, can effectively explore this complex design space and return several optimal PF coil sets. These solutions span the Pareto front, a subset of the objective space that optimally satisfies the specified objective functions. We outline an easy-to-use BO framework and demonstrate that it outperforms alternative optimisation techniques while using significantly fewer computational resources. Our results show that BO is a promising technique for fusion design problems that rely on computationally demanding high-fidelity simulations.

Bayesian optimisation Poloidal field coils Spherical tokamak MHD equilibria FreeGS

Multiple solutions to the static forward free-boundary Grad-Shafranov problem on MAST-U
Multiple solutions to the static forward free-boundary Grad-Shafranov problem on MAST-U

K. Pentland, N. C. Amorisco, P. E. Farrell, C. J. Ham

Nuclear Fusion

The Grad-Shafranov (GS) equation is a nonlinear elliptic partial differential equation that governs the ideal magnetohydrodynamic equilibrium of a tokamak plasma. Previous studies have demonstrated the existence of multiple solutions to the GS equation when solved in idealistic geometries with simplified plasma current density profiles and boundary conditions. Until now, the question of whether multiple equilibria might exist in real-world tokamak geometries with more complex current density profiles and integral free-boundary conditions (commonly used in production-level equilibrium codes) has remained unanswered. In this work, we discover multiple solutions to the static forward free-boundary GS problem in the MAST-U tokamak geometry using the validated evolutive equilibrium solver FreeGSNKE and the deflated continuation algorithm. By varying the plasma current, current density profile coefficients, or coil currents in the GS equation, we identify and characterise distinct equilibrium solutions, including both deeply and more shallowly confined plasma states. We suggest that the existence of even more equilibria is likely prohibited by the restrictive nature of the integral free-boundary condition, which globally couples poloidal fluxes on the computational boundary with those on the interior. We conclude by discussing the implications of these findings for wider equilibrium modelling and emphasise the need to explore whether multiple solutions are present in other equilibrium codes and tokamaks, as well as their potential impact on downstream simulations that rely on GS equilibria.

Multiple solutions Grad-Shafranov MHD equilibria FreeGSNKE Deflated continuation MAST-U

Multiple solutions to the static forward free-boundary Grad-Shafranov problem on MAST-U

K. Pentland, N. C. Amorisco, P. E. Farrell, C. J. Ham

Nuclear Fusion

The Grad-Shafranov (GS) equation is a nonlinear elliptic partial differential equation that governs the ideal magnetohydrodynamic equilibrium of a tokamak plasma. Previous studies have demonstrated the existence of multiple solutions to the GS equation when solved in idealistic geometries with simplified plasma current density profiles and boundary conditions. Until now, the question of whether multiple equilibria might exist in real-world tokamak geometries with more complex current density profiles and integral free-boundary conditions (commonly used in production-level equilibrium codes) has remained unanswered. In this work, we discover multiple solutions to the static forward free-boundary GS problem in the MAST-U tokamak geometry using the validated evolutive equilibrium solver FreeGSNKE and the deflated continuation algorithm. By varying the plasma current, current density profile coefficients, or coil currents in the GS equation, we identify and characterise distinct equilibrium solutions, including both deeply and more shallowly confined plasma states. We suggest that the existence of even more equilibria is likely prohibited by the restrictive nature of the integral free-boundary condition, which globally couples poloidal fluxes on the computational boundary with those on the interior. We conclude by discussing the implications of these findings for wider equilibrium modelling and emphasise the need to explore whether multiple solutions are present in other equilibrium codes and tokamaks, as well as their potential impact on downstream simulations that rely on GS equilibria.

Multiple solutions Grad-Shafranov MHD equilibria FreeGSNKE Deflated continuation MAST-U

Validation of the static forward Grad-Shafranov equilibrium solvers in FreeGSNKE and Fiesta using EFIT++ reconstructions from MAST-U
Validation of the static forward Grad-Shafranov equilibrium solvers in FreeGSNKE and Fiesta using EFIT++ reconstructions from MAST-U

K. Pentland, N. C. Amorisco, O. El-Zobaidi, S. Etches, A. Agnello, G. K. Holt, A. Ross, C. Vincent, J. Buchanan, S. J. P. Pamela, G. McArdle, L. Kogan, G. Cunningham

Physica Scripta

In this paper, we are interested in solving the static forward Grad-Shafranov (GS) problem for free-boundary MHD equilibria. Our focus is on the validation of the static forward solver in the Python-based equilibrium code FreeGSNKE by solving equilibria from magnetics-only EFIT++ reconstructions of MAST-U shots. In addition, we also validate FreeGSNKE against equilibria simulated using the well-established MATLAB-based equilibrium code Fiesta. To do this, we develop a computational pipeline that allows one to load the same (a)symmetric MAST-U machine description into each solver, specify the required inputs (active/passive conductor currents, plasma profiles and coefficients, etc.) from EFIT++, and solve the GS equation for all available time slices across a shot. For a number of different MAST-U shots, we demonstrate that both FreeGSNKE and Fiesta can successfully reproduce various poloidal flux quantities and shape targets (e.g. midplane radii, magnetic axes, separatrices, X-points, and strikepoints) in agreement with EFIT++ calculations to a very high degree of accuracy.

MHD equilibria Grad-Shafranov FreeGSNKE Fiesta EFIT++ MAST-U

Validation of the static forward Grad-Shafranov equilibrium solvers in FreeGSNKE and Fiesta using EFIT++ reconstructions from MAST-U

K. Pentland, N. C. Amorisco, O. El-Zobaidi, S. Etches, A. Agnello, G. K. Holt, A. Ross, C. Vincent, J. Buchanan, S. J. P. Pamela, G. McArdle, L. Kogan, G. Cunningham

Physica Scripta

In this paper, we are interested in solving the static forward Grad-Shafranov (GS) problem for free-boundary MHD equilibria. Our focus is on the validation of the static forward solver in the Python-based equilibrium code FreeGSNKE by solving equilibria from magnetics-only EFIT++ reconstructions of MAST-U shots. In addition, we also validate FreeGSNKE against equilibria simulated using the well-established MATLAB-based equilibrium code Fiesta. To do this, we develop a computational pipeline that allows one to load the same (a)symmetric MAST-U machine description into each solver, specify the required inputs (active/passive conductor currents, plasma profiles and coefficients, etc.) from EFIT++, and solve the GS equation for all available time slices across a shot. For a number of different MAST-U shots, we demonstrate that both FreeGSNKE and Fiesta can successfully reproduce various poloidal flux quantities and shape targets (e.g. midplane radii, magnetic axes, separatrices, X-points, and strikepoints) in agreement with EFIT++ calculations to a very high degree of accuracy.

MHD equilibria Grad-Shafranov FreeGSNKE Fiesta EFIT++ MAST-U

Neural-Parareal: dynamically training neural operators as coarse solvers for time-parallelisation of fusion MHD simulations
Neural-Parareal: dynamically training neural operators as coarse solvers for time-parallelisation of fusion MHD simulations

S. J. P. Pamela, N. Carey, J. Brandstetter, R. Akers, L. Zanisi, J. Buchanan, V. Gopakumar, M. Hoelzl, G. Huijsmans, K. Pentland, T. James, G. Antonucci, The JOREK Team

Computer Physics Communications

In this paper, we developed the Neural-Parareal framework to enhance the efficiency of time-parallel simulations for fusion research by integrating neural operators that dynamically train as new data becomes available. This approach replaces traditional coarse-solvers with neural network surrogates, leading to progressively more accurate predictions and significant speed-ups in the parareal simulations. Our findings demonstrate the effective convergence of high-performance computing and artificial intelligence, advocating for their common use in digital engineering design.

Fourier neural operators Parallel-in-time Parareal High performance computing

Neural-Parareal: dynamically training neural operators as coarse solvers for time-parallelisation of fusion MHD simulations

S. J. P. Pamela, N. Carey, J. Brandstetter, R. Akers, L. Zanisi, J. Buchanan, V. Gopakumar, M. Hoelzl, G. Huijsmans, K. Pentland, T. James, G. Antonucci, The JOREK Team

Computer Physics Communications

In this paper, we developed the Neural-Parareal framework to enhance the efficiency of time-parallel simulations for fusion research by integrating neural operators that dynamically train as new data becomes available. This approach replaces traditional coarse-solvers with neural network surrogates, leading to progressively more accurate predictions and significant speed-ups in the parareal simulations. Our findings demonstrate the effective convergence of high-performance computing and artificial intelligence, advocating for their common use in digital engineering design.

Fourier neural operators Parallel-in-time Parareal High performance computing

All research