PLUTO  4.4-patch2
Functions
particles_weights.c File Reference

Compute particle's weights needed for interpolation. More...

#include "pluto.h"

Functions

static void Particles_CheckWeights (double, double *, double, double, int)
 
void Particles_GetWeights (Particle *p, int *cell, double ***w, Grid *grid)
 

Detailed Description

While for Cartesian coordinates we follow the standard implementation, in POLAR and SPHERICAL coordinates,

Authors
A. Mignone (migno.nosp@m.ne@t.nosp@m.o.inf.nosp@m.n.it)
B. Vaidya (bvaid.nosp@m.ya@u.nosp@m.nito..nosp@m.it)
References
  • "A Particle Module for the PLUTO Code. III. Dust"
    Mignone et al, ApJS (2019) 233:38 [MFV2019]
Date
Apr 08, 2021

Function Documentation

◆ Particles_CheckWeights()

void Particles_CheckWeights ( double  xp,
double *  w1,
double  xL,
double  xR,
int  dir 
)
static

Check consistency of weights by numerical integration.

Parameters
[in]xpparticle coordinate
[in]*w1array of weights
[in]xLzone left boundary
[in]xRzone right boundary

◆ Particles_GetWeights()

void Particles_GetWeights ( Particle *  p,
int *  cell,
double ***  w,
Grid grid 
)

Compute particle weights such that

\[ q_p = \sum_{ij} w_{ij} Q_{ij} \]

Parameters
[in]ppointer to particle structure
[out]cella 3-element array containing the indices (i,j,k) of the grid cell that is closer and to the left of the particle.
[out]wa 3x3x3 array containing the weights
[in]grida pointer to an array of Grid structures