mphparticle
Evaluate expressions on particle and ray trajectories.
Syntax
pd = mphparticle(model)
pd = mphparticle(model,'expr',{e1,...,en},...)
Description
mphparticle(model) returns particle position and particle velocity at all time steps stored in the first particle dataset.
mphparticle(model,'expr',{e1,...,en},...) returns particle position, particle velocity and expressions e1,..., en evaluated on particle trajectories.
The function mphparticle accepts the following property/value pairs:
on | off
The returned value pd is a structure with the following content
Note: mphparticle only evaluates expressions using particle and ray datasets.
Example
Load the model trapped_protons from the Applications Libraries:
model = mphopen('trapped_protons');
Extract the particle positions and particle velocities along the computed trajectories at every time steps stored in the model:
pd = mphparticle(model)
Evaluate the mirror point latitude (Lm) and the particle equatorial pitch angle (Ea) at t = 0.7 sec., extract only the data:
pd = mphparticle(model,'dataset','dset2',...
'expr',{'Lm','Ea*180/pi'},'t',0.7,'dataonly','on')
See also
mpheval, mphevalpoint, mphint2, mphinterp, mphray