Streamer fluid modeling - An overview of ARCoS
1.0
|
All functions related to the mapping of whatever variable (densities, electric field...) from one tree into another. More...
#include <stdlib.h>
#include <stdio.h>
#include <math.h>
#include "cstream.h"
#include "grid.h"
#include "interpol2.h"
#include "mapper.h"
#include "proto.h"
#include "species.h"
Go to the source code of this file.
Macros | |
#define | MAX_MAPPERS 32 |
With this, we limit the number of mappers. | |
Functions | |
static void | map_same (mapper_t **mappers, grid_t *source, grid_t *target, int ntheta, int r0, int z0, int r1, int z1) |
The level of the source and target grids is the same. | |
static void | map_interpol (mapper_t **mappers, grid_t *source, grid_t *target, int ntheta, int r0, int z0, int r1, int z1, int level_diff) |
The source grid is coarser than the target grid. | |
static void | interpol_inner (mapper_t **mappers, grid_t *source, grid_t *target, int pr, int pz, int ntheta, interpol_t **interpols, int *extend_r, int *extend_z) |
Calculates all the points in a target grid, finer than a source grid that are interpolated from a stencil centered at pr, pz in the source grid. | |
static void | map_coarsen (mapper_t **mappers, grid_t *source, grid_t *target, int ntheta, int r0, int z0, int r1, int z1, int level_diff) |
The target grid is coarser than the source grid. | |
void | map_grid (mapper_t **mappers, grid_t *source, grid_t *target, int ntheta, int copy, int interpol, int coarsen, int s_buff, int t_buff) |
Maps two grids. | |
void | map_grid_r (mapper_t **mappers, grid_t *source, grid_t *target, int ntheta, int copy, int interpol, int coarsen, int s_buff, int t_buff) |
Recursive version of map_grid. | |
void | map_trees_r (mapper_t **mappers, grid_t *source, grid_t *target, int ntheta, int copy, int interpol, int coarsen, int s_buff, int t_buff) |
Double-recursive version: | |
All functions related to the mapping of whatever variable (densities, electric field...) from one tree into another.
Here the relevant data structure is defined by mapper_t, which tells us what functions should we call to perform copying, interpolation and coarsening from one grid into another (not neccesarily ofthe same type).
Definition in file mapper.c.
#define MAX_MAPPERS 32 |
|
static |
Calculates all the points in a target grid, finer than a source grid that are interpolated from a stencil centered at pr, pz in the source grid.
interpol_xxx are interpolation objects that can thus be reused. extend_r and extend_z are here because one call to interpol_inner can actually set (1 << level_diff + 1) fine grid points, but the boundaries are shared with the next/previous call.
In the first call in a row/column, we set all the points, since the right/lower boundary is not shared.
Definition at line 251 of file mapper.c.