% $Id: newsletter.tex,v 1.27 2025/12/27 18:05:59 rei Exp $
%\documentclass{article}
\documentclass[twocolumn]{article}
\setlength{\textwidth}{170mm}
\setlength{\oddsidemargin}{-7mm}
\setlength{\textheight}{220mm}
\setlength{\topmargin}{-8mm}
\newcommand{\yapjN}[4]{, ``#4,'' {\em Astrophys.\ J.\ }{\bf #2}, #3 (#1).}
\newcommand{\const}{{\rm const}  {}}
\def\half{{\textstyle{1\over2}}}

%\bibliographystyle{apalike}
\bibliographystyle{gGAF} %is checked in (say "make ln")
%\usepackage{bm,natbib,html,wrapfig,graphicx,multicol,color} %,etoollbox}  %setspace,tocloft}
\usepackage{bm,natbib,wrapfig,graphicx,multicol,color} %,etoollbox}  %setspace,tocloft}
\usepackage{hyperref}
\usepackage[anythingbreaks]{breakurl} %AB: is needed
\usepackage{xcolor, soul}
\usepackage{listings}
\usepackage{amssymb}
\usepackage{amsmath}

\graphicspath{{./fig/}{./png/}}
\thispagestyle{empty}
\input ../../jour_def
\newcommand{\Fig}[1]{Figure~\ref{#1}}
\newcommand{\Figs}[2]{Figures~\ref{#1} and \ref{#2}}
\def\red{\textcolor{red}}
\def\blue{\textcolor{blue}}
\newcommand{\yjourN}[5]{:~#1, ``#5,'' {\em #2} {\bf #3}, #4}
\newcommand{\bra}[1]{\langle #1\rangle}
\newcommand{\Eq}[1]{Eq.~(\ref{#1})}
\newcommand{\AAA}{\bm{A}}
\newcommand{\BB}{\bm{B}}
\newcommand{\kk}{\bm{k}}
\newcommand{\xx}{\bm{x}}
\newcommand{\ii}{{\rm i}}
\newcommand{\dd}{{\rm d} {}}
\newcommand{\nab}{{\bm{\nabla}}}
\newcommand{\Cou}{{\mbox{Cou}}}
\def\HM{H_{\rm M}}
\def\EM{E_{\rm M}}
\def\EEM{{\cal E}_{\rm M}}
\def\Pm{\mbox{\rm Pr}_{\rm M}}
\def\Rm{\mbox{\rm Re}_{\rm M}}
\def\Rey{\mbox{\rm Re}}
\def\urms{u_{\rm rms}}
\def\kf{k_{\rm f}}
%\newcommand{\Sec}[1]{Sect.~\ref{#1}}
\newcommand{\Sec}[1]{\S\ref{#1}}
\newcommand{\ymn}[5]{, ``#5,'' {\em Month. Not. Roy.\ Astron.\ Soc.\ }{\bf #2}, #3--#4 (#1).}

\title{The {\sc Pencil Code} Newsletter}
\author{Issue 2025/2}
\date{\today,~ $ $Revision: 1.27 $ $}
%\date{September 5, 2025,~ $ $Revision: 1.27 $ $}
\begin{document}
\maketitle

\renewcommand{\baselinestretch}{-.4}\normalsize
\tableofcontents
\renewcommand{\baselinestretch}{1}\normalsize

\vspace{5mm}

\noindent
We wish all readers a happy New Year 2026!

\begin{figure*}[t]\begin{center}
\includegraphics[width=\textwidth]{PCUM26}
\end{center}\caption[]{
Poster ad of the 22nd PCUM at the University of Alicante, Spain.
Photo credit: University of Alicante webpage and GetYourGuide. 
}\label{PCUM26}\end{figure*}

\section{PCUM 2026 in Alicante}

The 22nd PCUM will be organized by Clara Dehman at the University of Alicante, Spain; see Figure~\ref{PCUM26}.
A poll to determine the preferred week for the meeting is currently open; interested
participants are kindly invited to cast their vote at the following link:
\scriptsize
\url{https://docs.google.com/forms/d/e/1FAIpQLSddf3fDBfNivf9afTM37StIBoiEpTRwgNWvF1EQqcuzEZOS-A/viewform?usp=header}.
\normalsize
Further details regarding the schedule will be communicated later.
If there are questions, please check with Clara \texttt{<clara.dehman@ua.es>} via email.

\section{PCUM 2025 at CERN}
\label{PCUM2025}

The Pencil Code User Meeting (PCUM) 2025 was a great success combining
both a School on early Universe physics and gravitational waves.    %MR:why capitals here?
(first week, October 20--24) and the actual user meeting
(second week, October 27--31);
see \url{https://indico.cern.ch/event/1548935/} for the program,
group photos, slides of the talks, and their recordings.
On the technical side, one of the insights from the meeting concerned the
``Merge branch {\textquotesingle}master{\textquotesingle}'' commits;
%see \SS\ref{sec:master} below.
see \Sec{sec:linear-history} below.

Already during the first coding session, a new dark matter autotest was
constructed based on Wlad's earlier sample called 
\texttt{2d-tests/selfgrav-shearwave-dust-par}.
All that needed to be done was to include a scale factor $a(t)$ on the rhs of
the Poisson equation, expressed in \textit{supercomoving coordinates} as indicated by tildes,
which now reads\footnote{see Martel, H. \& Shapiro, P. R.\ymn{1998}{297}{467}
{485}{A convenient set of comoving cosmological variables and their application}}
\begin{equation}
\widetilde{\nabla}^2\widetilde{\phi}=6a\,\left(\frac{\widetilde{\rho}_\mathrm{tot}}{\rho_0}-1\right).
\end{equation}
The result shown in Figure~\ref{dark-matter} looks impressive
for a first trial.

%\section{Linear History and Git Usage on the Pencil Code Server}
%AB: shorter, to keep it on one line
\section{Linear History and Git Usage}
\label{sec:linear-history}

%IL: renaming section and changing text

%\section{Merge branch 'master'} \label{sec:master}

%The Pencil Code User Meeting 2025 has unanimously decided that ``Merge branch 
%{\textquotesingle}master{\textquotesingle}'' commits are undesired because 
%they change the linear history of the `master' branch. We would like now the 
%whole community to give their feedback on possible options how to prevent 
%these commits. One option is to block such commits on the server side, where 
%we would need to have a reliable solutions that is yet unknown. Another option 
%is to block such commits on the user's side, even though this might not be 
%fully reliable. The last option is to make this only a suggestion and not 
%block anything, which is remaining with the status quo. Please send your 
%feedback to any member of the Pencil Code Steering Committee. Thank you.

\noindent\textit{by Illa R.\ Losada}
\texttt{<illa.rivero.losada@gmail.com>}\\
{\scriptsize received 26 December 2025}\\

% IL
During the Pencil Code User Meeting 2025, we discussed at length recurring 
problems related to non-linear Git history on the \texttt{master} branch, in 
particular commits of the form \texttt{Merge branch `master'}.

These commits are not merely a stylistic concern. 
Due to the Pencil Code server supporting both Git and SVN access, such merges 
can lead to \emph{silent rewriting or loss of repository history}. 
This is a server-specific hazard that does not occur on pure Git servers and has
already caused real problems in the past.

The meeting consensus was that the primary mitigation should be \textbf{clear 
guidance and documentation}, rather than relying solely on technical enforcement 
mechanisms.

In particular, users are strongly encouraged to:

\begin{itemize}
  \item use \texttt{git pull --rebase} instead of plain \texttt{git pull},
  \item avoid merge commits on the \texttt{master} branch,
  \item use SVN directly if you are not comfortable with Git's rebase-based workflow.
\end{itemize}

These recommendations, along with a detailed explanation of the underlying 
problem, are now documented on the 
\href{https://pencil-code.readthedocs.io/en/latest/index.html}{Pencil Code ReadTheDocs} pages:
\begin{itemize}
  \item 
\href{https://pencil-code.readthedocs.io/en/latest/pcdevelopment/howtogit.html#history-rewriting-hazard-git-svn-server}{History Rewriting Hazard (Git + SVN Server)}
  \item 

\href{https://pencil-code.readthedocs.io/en/latest/pcdevelopment/howtogit.html#git-on-an-
svn-backed-server-a-post-mortem}{Git on an SVN-Backed Server: A Post-Mortem}
\end{itemize}

Community feedback is still welcome, especially regarding additional safeguards 
or workflow improvements. 
However, until reliable server-side blocking mechanisms are identified, the
current emphasis is on informed and careful usage.

Users are therefore encouraged to read the documentation carefully and to follow 
the recommended workflows when contributing to the Pencil Code repository.

{\it Added by the editors:} As a technical measure for making \texttt{git pull} without \texttt{--rebase} at least unlikely, applying \texttt{source sourcem.sh} now sets in \texttt{.git/config} \\
\texttt{
[pull] \\
\phantom{[pull]} rebase = true\\
}
and warns about \texttt{rebase = false} settings is branch-specific entries.

\begin{figure}[t]\begin{center}
\includegraphics[width=\columnwidth]{dark-matter}
\end{center}\caption[]{
First \textsc{Pencil Code} dark matter trial
during the coding session on Monday.
}\label{dark-matter}\end{figure}

\begin{figure}[t]\begin{center}
\includegraphics[width=\columnwidth]{window-view}
\end{center}\caption[]{
View toward the mountains to the left of Mont Blanc.
}\label{window-view}\end{figure}

%IL: adding new section
%\section{Python Postprocessing Meetings}
%AB: shorter, to keep it on one line
\section{Python Postproc Meetings}
\label{sec:python-postprocessing}

\noindent\textit{by Illa R.\ Losada}
\texttt{<illa.rivero.losada@gmail.com>}\\
{\scriptsize received 26 December 2025}\\

During the last Pencil Code User Meeting at CERN (see Sec.~\ref{PCUM2025}), 
we decided to resume periodic meetings focused on the development and usage of 
Python as a postprocessing tool for the Pencil Code.

Full information about past meetings, decisions, outcomes, and upcoming sessions 
can now be found on the 
\href{https://pencil-code.readthedocs.io/en/latest/python-meetings/python-index.
html}{Python Postprocessing Meetings} page.

As a follow-up, the first Python postprocessing meeting was held on
\href{https://pencil-code.readthedocs.io/en/latest/python-meetings/python-
pastmeetings.html#nov-26}{Nov 26}. 
During this meeting, the group discussed the meeting format and schedule, 
agreeing to hold Python postprocessing meetings every two months with
rotating organizers. 
Key topics included testing and automated code checks, library installation via 
pip, updating and centralizing tutorials in ReadTheDocs, and improving 
real-time simulation visualization in Jupyter notebooks. 
Several action items were assigned, such as uploading Pencil Code Python as a 
pip package, enhancing documentation, and standardizing data formats.

The next meeting is planned for January (exact date TBD). 
We encourage all members of the Pencil Code community to participate, contribute 
ideas, and share experiences with Python postprocessing.


%IL: adding new section
%\section{New ReadTheDocs Additions for the Pencil Code}
%AB: shorter, to keep it on one line
\section{New ReadTheDocs Additions}
\label{sec:rtd-new}

\noindent\textit{by Illa R.\ Losada}
\texttt{<illa.rivero.losada@gmail.com>}\\
{\scriptsize received 26 December 2025}\\

The {\sc Pencil Code} ReadTheDocs pages have recently been expanded with several 
autogenerated sections directly extracted from the source code, providing 
comprehensive reference material for developers and users alike.

\begin{itemize}
  \item \textbf{Fortran Modules:} Description of all Fortran files with 
filtering options for easy navigation. See the full list at 

\href{https://pencil-code.readthedocs.io/en/latest/code/sourceFortran/index.html
}{Fortran Modules}.

  \item \textbf{Startup and Run-time Parameters:} Detailed list of parameters 
with their placement in configuration files (e.g., \texttt{start.in}, 
\texttt{run.in}, \texttt{print.in}), the associated module, default values, and 
descriptions if available, with filtering options for quick lookup, see: 
  
\href{https://pencil-code.readthedocs.io/en/latest/code/tables/index.html}{
Startup and Run-time Parameters}.

  \item \textbf{Boundary Conditions:} Description of available boundary 
conditions per module, with explanations of their meaning and usage, see 
  
\href{https://pencil-code.readthedocs.io/en/latest/code/tables/boundary.html}{
Boundary Conditions}.

  \item \textbf{Bin Scripts:} List of executable scripts in the \texttt{bin} 
directory, with short descriptions of their functionality, see 

  \href{https://pencil-code.readthedocs.io/en/latest/code/tables/bin.html}{Bin 
Scripts}.
\end{itemize}

Additionally, the \textbf{Scientific Usage of the Pencil Code} page has been 
added, partly autogenerated to catalog publications making use of the code. 
The page includes references to journal articles and conference proceedings, 
classified by year and research topic. 
The primary applications lie in astrophysics, with additional work in 
meteorology and combustion. 
Explore the page here: 
\href{https://pencil-code.readthedocs.io/en/latest/intro/scientific.html}{
Scientific Usage of the Pencil Code}.

For guidance on how to add citations in the documentation, see the separate 
guide at 
\href{https://pencil-code.readthedocs.io/en/latest/dochowto/addcitations.html}{
Adding Citations}.

These additions make it significantly easier for users to explore the code 
structure, runtime options, and scientific impact of Pencil Code.



%\section{{\sc Pencil Code}-related PhD position in Hamburg Observatory}

\section{Relevant job opportunities}

\subsection{PhD at Hamburg Observatory}

We are looking for a PhD student to work on {\sc Pencil Code}
star-in-a-box simulations of intermediate mass stars in the pre-main
sequence phase as a part of the DFG project ``Fossil fields in Ap/Bp
stars: an origin from star formation and protostellar evolution'' in
Hamburg Observatory. The project is an international collaboration
involving Robi Banerjee (Hamburg Observatory), Dominik Schleicher
(Sapienza University, Rome), Petri K\"apyl\"a (Institute for Solar
Physics, Freiburg), and Daniele Galli (INAF Astrophysical Observatory
of Florence). The PhD candidate will work in Hamburg where
Prof.\ Banerjee will act as the formal supervisor, but the project
entails collaboration with and visits to all of the participating
institutes. We ask the senior members of the {\sc Pencil Code}
community to distribute the news to potentially interested students
especially if they already have experience in using the
code. Interested students should contact Petri K\"apyl\"a
({\tt <pkapyla@leibniz-kis.de>}) for more details.

\subsection{COSMOMAG postdoc positions}

Four postdoc positions are available, with deadline 20 January: two at CERN and LPENS, and two at Nordita:
\begin{enumerate}
%\item\url{https://academicjobsonline.org/ajo/jobs/31448}
\item\url{https://inspirehep.net/jobs/3094257}
\item\url{https://inspirehep.net/jobs/3094314}
\end{enumerate}
We would be grateful if you could forward this announcement to potentially interested candidates.
For details regarding the COSMOMAG project, see \url{https://cosmosimfrazza.eu/cosmomag}.
%\footnote{along with recent accouncements on
%\url{https://nordita.org/news/axel-brandenburg-awarded-erc-synergy-and-vr-grants-to-study-the-universes-first-microseconds/}.
%Following a similar style, the prestigious VR starting grant to
%Pencil Code user Oksana Iarygina was announced on
%\url{https://nordita.org/news/exploring-the-universes-earliest-moments-with-a-vr-starting-grant/}}.

\section{Announcements}

During 12--23 January 2026, there will be the Nordita Winter School 2026, which
is on Cosmological Magnetic Fields: Generation, Observation, and Modeling; see
\url{https://indico.fysik.su.se/event/8554/}.
While the deadline has now passed, there is still the possibility of online
participation via zoom on \url{https://stockholmuniversity.zoom.us/j/62081336983}.
The second week will feature lectures and exercises involving the
\textsc{Pencil Code}.
Teaching material is currently being assembled under the link
\url{https://norlx65.nordita.org/~brandenb/teach/PencilCode/COSMOMAG2026/}.

\section{Papers since September, 2025}

As usual, we look here at new papers that make use of the {\sc Pencil Code}.
Since the last newsletter of August 2025, six new papers have appeared    
on the arXiv, plus nine others, some of which had been just preprints and now have been published with a journal reference on ADS.
We list both here, altogether 16. %MR: not 15?
A browsable ADS list of all {\sc Pencil Code} papers can be found on:
\url{https://ui.adsabs.harvard.edu/public-libraries/iGR7N570Sy6AlhDMQRTe_A}.
If something is missing in those entries, you can also include it yourself in:
\url{https://github.com/pencil-code/pencil-code/blob/master/doc/citations/ref.bib},
or otherwise just email brandenb@nordita.org.
A compiled version of this file is available as
\url{https://github.com/pencil-code/website/blob/master/doc/citations.pdf},
where we also list a total of now 136 code comparison papers in the last
section ``Code comparison \& reference''.
Those are not included in our list below, nor among the now total number
of 764 research papers that use the {\sc Pencil Code}.

\nocite{
2025arXiv251026918G,%Ghosh+ "Can galactic magnetic fields diffuse into the voids?"
2025JApA...46...87S,%Singh+ "Combining local and global magnetohydrodynamic simulation frameworks to understand the evolution of coronal mass ejections"
2025arXiv251119508M,%Mtchedlidze "Simulated Rotation Measure Sky from Primordial Magnetic Fields"
2025ApJ...995...39B,%Baehr+ "On the Gravitational Collapse of Small Dust Grains in Self-gravitating Disk Structures"
2025arXiv251209177G,%Gurgenidze+ "Primordial magnetic field from chiral plasma instability with sourcing"
2025arXiv251209725E,%Elias-Lopez "Numerical simulations of astrophysical dynamos and applications to giant planets"
2025arXiv251211973S,%Skalidis+ "Residual energy in weakly compressible turbulence with a mean guide field"
2025arXiv251217770B,%Brandenburg+ "Magnetic field spreading from stellar and galactic dynamos into the exterior"
2025arXiv251217885G,%Gent+ "Asymptotic behaviour of galactic small-scale dynamos at modest magnetic Prandtl number"
2025PhFl...37j5163L,%Lipatnikov+Sabelnikov "A numerical study of velocity-pressure gradient and pressure-dilatation terms in transport equations for subfilter turbulent kinetic energy in premixed flames"
2025arXiv250921141Z,%Zhang+Brandenburg "Resistive Scaling in the Magnetic Helicity-Driven Inverse Cascade"
2025ApJ...993...22B,%Brandenburg "Magnetorotational instability in a solar mean-field dynamo"
2025ApJ...990..223B,%Brandenburg+Ntormousi "Magnetic Field Amplification during a Turbulent Collapse"
2025A&A...701A.185T,%Tschernitz+Bourdin "Kinematic viscosity in solar convection simulations"
2025arXiv250906173Q,%Qazi+ "Mathematical Aspects of Geophysical and Astrophysical Fluid Dynamics: Magnetic buoyancy instability in galaxies"
%
%2024arXiv240115860Z,%Zhou+Jingade "Correlation times of velocity and kinetic helicity fluctuations in nonhelical hydrodynamic turbulence"
%2024arXiv240416096D,%Dey+ "Spinning solar jets explained through the interplay between plasma sheets and vortex columns"
%
% outdated
%2023arXiv231109082K,%Kapyla "Effects of rotation and surface forcing on deep stellar convection zones"
%2023arXiv230705490Z,%Zhu+Shi "Helical and nonhelical (magneto-)Burgers turbulence: I. Compressibility reduction and beyond"
%2023arXiv230300911Y,%Yuvraj "On flame speed enhancement in turbulent premixed hydrogen-air flames during local flame-flame interaction"
%2022arXiv220606566M,%Masada+Sano "Rotational Dependence of Large-scale Dynamo in Strongly-stratified Convection: What Causes It?"
%2022arXiv220509261R,%Roper Pol "Gravitational waves from MHD turbulence at the QCD phase transition as a source for Pulsar Timing Arrays"
%2021arXiv210508287R,%Roper Pol "Gravitational radiation from MHD turbulence in the early universe"
}

\bibliography{ref}
\vspace{5mm}
\hrule
\vspace{2mm}
This {\sc Pencil Code} Newsletter was edited by
Axel Brandenburg {\tt <brandenb@nordita.org>}, Nordita, KTH Royal Institute of Technology and Stockholm University, SE-10691 Stockholm, Sweden;
and Matthias Rheinhardt {\tt <matthias.rheinhardt@aalto.fi>}, Department of Computer Science, Aalto University, PO Box 15400, FI-00076 Aalto, Finland.
See \url{http://www.nordita.org/~brandenb/pencil-code/newsletter} or
\url{https://github.com/pencil-code/website/tree/master/NewsLetters}
for the online version as well as back issues.

\end{document}
