Skip to content

Conversation

@mlstowell
Copy link
Member

@mlstowell mlstowell commented Nov 8, 2024

Documentation for mfem/mfem#4567

@tzanio
Copy link
Member

tzanio commented Nov 10, 2024

ping: @Zane-Hays

@tzanio tzanio self-assigned this Nov 10, 2024
@tzanio tzanio mentioned this pull request Oct 6, 2025
14 tasks
Copy link
Contributor

@najlkin najlkin left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice reading, @mlstowell 👍


The Lorentz mini application approximates the trajectory of an individual
particle using the explicit Boris algorithm. The equations being solved track
the position and momentum of a particle with a given mass and charge.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

position (x) and momentum (p)...

\end{align}$$

The Boris algorithm, while not a symplectic method, provides long term accuracy
by conserving volume in phase space. The algorithm updates the position in a single step but splits the momentum update into multiple steps:
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

line wrap + ... multiple steps between time levels k and k+1


While equation \eqref{boris2} may appear to be implicit it is clearly a linear
equation so a small amount of algebra will produce an explicit, though more
messy and less intuitive, formula.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

messy -> cumbersome? 😄

### Lorentz Mini Application

The Lorentz mini application approximates the trajectory of an individual
particle using the explicit Boris algorithm. The equations being solved track
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It could be mentioned it track the particle in provided electric (E) and magnetic (B) fields.

$$\begin{align}
\frac{d\vec{x}}{dt} & = \frac{\vec{p}}{m} \\\\
\frac{d\vec{p}}{dt} & =
q\left(\E + \frac{1}{m}\vec{p}\times\B\right)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

E and B should be vectors

VisItDataCollection is provided. The command line option `-er` can be used
to set the root name of the data collection e.g. `-er Volta-AMR-Parallel`.
The field name within the data collection is assumed to be `E` unless
overridden with `-ef`. The cylce index is assumed to be 10 but this can be
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
overridden with `-ef`. The cylce index is assumed to be 10 but this can be
overridden with `-ef`. The cycle index is assumed to be 10 but this can be

#### Mini Application Features

**Electric Field:** The electric field is assumed to be zero unless a
VisItDataCollection is provided. The command line option `-er` can be used
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
VisItDataCollection is provided. The command line option `-er` can be used
VisIt data collection is provided. The command line option `-er` can be used

The user does not provide the MFEM object, but path to data, so should be rather written like this (and also we do not need to care about formatting of the class name)

index and processor rank can also be overridden if necessary.

**Magnetic Field:** The magnetic field is assumed to be zero unless a
VisItDataCollection is provided. The command line option `-br` can be used
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

the same as above ☝️

VisItDataCollection is provided. The command line option `-br` can be used
to set the root name of the data collection e.g. `-br Tesla-AMR-Parallel`.
The field name within the data collection is assumed to be `B` unless
overridden with `-bf`. The cylce index is assumed to be 10 but this can be
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
overridden with `-bf`. The cylce index is assumed to be 10 but this can be
overridden with `-bf`. The cycle index is assumed to be 10 but this can be

## Lorentz Miniapp: Particle Trajectory Calculation
<img class="floatright" src="../img/examples/lorentz.png">

This miniapp reads VisItDataCollection objects produced by applications such as
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

the same as above ☝️

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants