# Questions tagged [grid]

For questions about solving numerical problems by evaluating over a discrete grid of points in the problem domain.

49 questions
Filter by
Sorted by
Tagged with
38 views

### Multigrid/Two-grid method restriction and prolongation of residual

Starting from the problem $Au=f$, I'm not sure that I understand why a coarse grid solution is implemented on the coarse grid residual $r_c^{(k)}=P^Tr^{(k)}$, with $r^{(k)}=f-Au^{(k)}$ and $P^T$ ...
36 views

### An explanation of 2delta waves on non-staggered grids

While looking into the difference between staggered and collocated grids, I came across an effect called $2\Delta x$-oscillations, which happen on non-staggered grids, but not on staggered grids. This ...
51 views

1 vote
85 views

1 vote
424 views

### Finite Volume Polar Discretization: Lengths

Given a uniform polar grid, as in the figure below: and a FV discretization of a gradient for example: $\frac{\partial p}{\partial \varphi} = 0$ $\Delta r \frac{p_e - p_w}{\Delta \varphi} = 0$ My ...
• 128
179 views

### How to optimally choose points for multivariable Hermite interpolation?

I have a multi-variate, continuous function $f$ from $R^n$ to $R$, which I can query for its output for any input. I would like to create interpolation polynomial for it. In one-dimensional case ...
• 193
1 vote
930 views

### Finite Difference Grid Spacing and Scaling

I have been exploring finite differences and heat transfer using the 2D heat equation to further expand my knowledge. So far I think it is going well. I am running into some confusion around grid ...
• 11
1 vote
3k views

### Is there an advantage of using a staggered grid over a regular one when combined with high order methods?

The title says is all. This question is in the contest of an incompressible Navier-Stokes solver. Specifically, I am currently working on a new solver while referring myself to an older code for ...
• 317
913 views

### Interpolation of velocities on staggered grid (in PIC)

Edit: (copying from my comment) Let's consider the inverse problem when I need to transfer velocities from particles to the grid (inverse bilinear interpolation). How'd I transfer a particle's x-...
• 185
1 vote
158 views

### C1 continuous spline on regular 2D-grid with quadratic 1D cuts

I want some scalar spline function defined on regular 2D grid $F(x,y)$ with continuous first derivative which is easy to intersect with arbitrary ray/line ${\vec l}(t) = (c_x t,c_y t,c_z t)$. ...
134 views

### Alternative to messy grid node indexing within multiple layers of loops

Recently,I dive into a set of somehow ancient Fortran codes and try to fully understand them. A large fraction of these codes are multiple layers of loops over many state variable dimensions, which ...
• 131
1 vote
633 views

### 3-dimensional plotting with nonuniform grids

I have 3 variables I am considering: time (t), 1-dimensional space (x), and intensity (I). I would like to plot the intensity in the z-axis as a function of t and x (the latter two variables would ...
• 518
2k views

### Contour plot interpolation recommendation

I am not sure if my question is on topic or not and if not please let me know. I have regularly spaced gridded data(output of a weather forecast simulation software) and I have latitude and ...
• 215
1 vote
134 views

### Finding boundary intersection points with Cartesian grid?

I would like to find the intersection points e.g. $M_x$ and $M_y$ as in the attached figure. The boundary (solid line) is defined by the Lagrangian points. I am working in C++ (basic - medium ...
• 25
1 vote
93 views

### Common nodes in two FEM grids

There are two independent tetrahedral FEM grids. Second grid is subset of the first. By subset, I mean: nodes from the second grid are exactly in the same positions as some nodes from the first grid. ...
1k views

### Generating a non-uniform grid

I am interested in generating a 1D non-uniform grid on the interval [0, L] with N points, where a region of width $\sigma$ and ...
• 265
997 views

I would like to code for a quadtree type meshing but don't know how to do. If anyone can help or can share any starting code?
• 25
11k views

### Dynamically ending ODE integration in SciPy

I have a light ray moving through space-time, i.e. a curve in $\mathbb{R}^4$, parametrized by some variable λ. The exact trajectory, i.e. the coordinate functions $x^μ(λ)$ of the curve are given by ...
• 243
67 views

### Should I use bestman2 or dcache CLIs (srmping, srmls, etc..)

I am fairly new to using SRM, and I am wondering if I should be using srm CLI tools (srmping, srmls, srmcp, etc..) provided by dcache, or bestman2 counter parts (srm-ping, srm-ls). I used to think ...
1 vote
265 views

### How to compute the weight matrix for tomography applications?

I am trying to compute the weight matrix for a set of straight ray paths through a reconstruction region. Ideally, I would like to be able to do this for both a rectangular grid region, where each ...
• 113
34 views

### How can I discover / access various SE (storage elements) in GlideinWMS environment?

I am submitting jobs to Open Science Grid from a glidein-wms enabled submit hosts such as osg-xsede. I'd like to stage some data on SE nearest to osg-xsede submit host, then distribute data to various ...
2k views

### Python: Grid with step control ODE solver

I have a problem in physics formulated via an ODE. Now I like to solve it numerically using Pythons scipy.integrate and the therein complex_ode. I figured out how and it works but now I like to ...
• 267
1 vote
297 views

### Ray tracer : create an uniform grid [closed]

I wrote a simple ray tracer, and now I try to implement an uniform grid. There is a lot of documentation on how to traverse the grid, but I don't know how to construct the grid. I have my uniform ...
• 11
1 vote