mirror of
https://github.com/paboyle/Grid.git
synced 2024-11-09 23:45:36 +00:00
Dirichlet changes
This commit is contained in:
parent
2594e3c230
commit
b52e8ef65a
@ -93,14 +93,14 @@ template<class Field> class FreeLaplacianStencil : public SparseMatrixBase<Field
|
|||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
typedef typename Field::vector_object siteObject;
|
typedef typename Field::vector_object siteObject;
|
||||||
typedef CartesianStencil<siteObject, siteObject, int> StencilImpl;
|
typedef CartesianStencil<siteObject, siteObject, SimpleStencilParams> StencilImpl;
|
||||||
|
|
||||||
GridBase *grid;
|
GridBase *grid;
|
||||||
StencilImpl Stencil;
|
StencilImpl Stencil;
|
||||||
SimpleCompressor<siteObject> Compressor;
|
SimpleCompressor<siteObject> Compressor;
|
||||||
|
|
||||||
FreeLaplacianStencil(GridBase *_grid)
|
FreeLaplacianStencil(GridBase *_grid)
|
||||||
: Stencil (_grid,6,Even,directions,displacements,0), grid(_grid)
|
: Stencil (_grid,6,Even,directions,displacements,SimpleStencilParams()), grid(_grid)
|
||||||
{ };
|
{ };
|
||||||
|
|
||||||
virtual GridBase *Grid(void) { return grid; };
|
virtual GridBase *Grid(void) { return grid; };
|
||||||
@ -168,7 +168,8 @@ public:
|
|||||||
typedef iImplDoubledGaugeField<Simd> SiteDoubledGaugeField;
|
typedef iImplDoubledGaugeField<Simd> SiteDoubledGaugeField;
|
||||||
typedef Lattice<SiteDoubledGaugeField> DoubledGaugeField;
|
typedef Lattice<SiteDoubledGaugeField> DoubledGaugeField;
|
||||||
|
|
||||||
typedef CartesianStencil<siteObject, siteObject, int> StencilImpl;
|
typedef CartesianStencil<siteObject, siteObject,SimpleStencilParams> StencilImpl;
|
||||||
|
SimpleStencilParams p;
|
||||||
|
|
||||||
GridBase *grid;
|
GridBase *grid;
|
||||||
StencilImpl Stencil;
|
StencilImpl Stencil;
|
||||||
@ -177,7 +178,7 @@ public:
|
|||||||
CovariantLaplacianStencil(GaugeField &Umu)
|
CovariantLaplacianStencil(GaugeField &Umu)
|
||||||
:
|
:
|
||||||
grid(Umu.Grid()),
|
grid(Umu.Grid()),
|
||||||
Stencil (grid,6,Even,directions,displacements,0),
|
Stencil (grid,6,Even,directions,displacements,p),
|
||||||
Uds(grid)
|
Uds(grid)
|
||||||
{
|
{
|
||||||
for (int mu = 0; mu < Nd; mu++) {
|
for (int mu = 0; mu < Nd; mu++) {
|
||||||
|
@ -31,7 +31,6 @@ Author: paboyle <paboyle@ph.ed.ac.uk>
|
|||||||
|
|
||||||
using namespace std;
|
using namespace std;
|
||||||
using namespace Grid;
|
using namespace Grid;
|
||||||
;
|
|
||||||
|
|
||||||
int main(int argc, char ** argv) {
|
int main(int argc, char ** argv) {
|
||||||
Grid_init(&argc, &argv);
|
Grid_init(&argc, &argv);
|
||||||
@ -80,7 +79,8 @@ int main(int argc, char ** argv) {
|
|||||||
Foo=lex;
|
Foo=lex;
|
||||||
}
|
}
|
||||||
|
|
||||||
typedef CartesianStencil<vobj,vobj,int> Stencil;
|
typedef CartesianStencil<vobj,vobj,SimpleStencilParams> Stencil;
|
||||||
|
SimpleStencilParams p;
|
||||||
for(int dir=0;dir<4;dir++){
|
for(int dir=0;dir<4;dir++){
|
||||||
for(int disp=0;disp<Fine._fdimensions[dir];disp++){
|
for(int disp=0;disp<Fine._fdimensions[dir];disp++){
|
||||||
|
|
||||||
@ -90,7 +90,7 @@ int main(int argc, char ** argv) {
|
|||||||
std::vector<int> directions(npoint,dir);
|
std::vector<int> directions(npoint,dir);
|
||||||
std::vector<int> displacements(npoint,disp);
|
std::vector<int> displacements(npoint,disp);
|
||||||
|
|
||||||
Stencil myStencil(&Fine,npoint,0,directions,displacements,0);
|
Stencil myStencil(&Fine,npoint,0,directions,displacements,p);
|
||||||
Coordinate ocoor(4);
|
Coordinate ocoor(4);
|
||||||
for(int o=0;o<Fine.oSites();o++){
|
for(int o=0;o<Fine.oSites();o++){
|
||||||
Fine.oCoorFromOindex(ocoor,o);
|
Fine.oCoorFromOindex(ocoor,o);
|
||||||
@ -183,8 +183,8 @@ int main(int argc, char ** argv) {
|
|||||||
std::vector<int> directions(npoint,dir);
|
std::vector<int> directions(npoint,dir);
|
||||||
std::vector<int> displacements(npoint,disp);
|
std::vector<int> displacements(npoint,disp);
|
||||||
|
|
||||||
Stencil EStencil(&rbFine,npoint,Even,directions,displacements,0);
|
Stencil EStencil(&rbFine,npoint,Even,directions,displacements,p);
|
||||||
Stencil OStencil(&rbFine,npoint,Odd,directions,displacements,0);
|
Stencil OStencil(&rbFine,npoint,Odd,directions,displacements,p);
|
||||||
|
|
||||||
Coordinate ocoor(4);
|
Coordinate ocoor(4);
|
||||||
for(int o=0;o<Fine.oSites();o++){
|
for(int o=0;o<Fine.oSites();o++){
|
||||||
|
Loading…
Reference in New Issue
Block a user