NVIDIA/AMGX

Right-hand-side of Poisson examples should be changed

Ouverte

#30 ouverte le 31 mai 2018

 (4 commentaires) (0 réaction) (0 personne assignée)Cuda (186 forks)auto 404
enhancementgood first issue

Métriques du dépôt

Stars
 (679 étoiles)
Métriques de merge PR
 (Métriques PR en attente)

Description

AMGX ships with many nice sample programs, including simple implementation of Poisson-like equations. Currently, the charge function (e.g. in A x = b, the array b) is set to 1.d0 everywhere.

This is a poor choice, since integrating a constant over larger and large volumes gives you an exponentially growing solution. As a consequence, the sample cases have terrible convergence rates and do not scale as the problem size is increased.

I suggest a better choice: set b = sin( 2 * pi * x / Lx ) * sin( 2 * pi * y / Ly ) * sin( 2 * pi * z / Lz ), which satisfies either periodic or Dirichlet boundary conditions. This is more representative of the use of a Poisson solver.

Guide contributeur