コード例 #1
0
ファイル: qopwilson.c プロジェクト: jcosborn/qll
void
packD(Layout *l, real *x, QDP_DiracFermion *yy)
{
  QDP_Lattice *lat = QDP_get_lattice_D(yy);
  real *y = QDP_expose_D(yy);
  fromQDP_F(x, l, y, lat, 24, 3);
  QDP_reset_D(yy);
}
コード例 #2
0
ファイル: qopwilson.c プロジェクト: jcosborn/qll
void
unpackD(Layout *l, QDP_DiracFermion *xx, real *y)
{
  QDP_Lattice *lat = QDP_get_lattice_D(xx);
  real *x = QDP_expose_D(xx);
  toQDP_F(x, lat, y, l, 24, 3);
  QDP_reset_D(xx);
}
コード例 #3
0
ファイル: check-cg.c プロジェクト: usqcd-software/clover
static void
f_writer(const int pos[4], int c, int d, int re_im, double v, void *env)
{
    int n = QDP_node_number(pos);
    int i = QDP_index(pos);
    QDP_DiracFermion *f = (QDP_DiracFermion *)env;
    QLA_DiracFermion *df = QDP_expose_D(f);

    assert(n == self);
    if (re_im == 0) {
        QLA_real(QLA_elem_D(df[i], c, d)) = v;
    } else {
        QLA_imag(QLA_elem_D(df[i], c, d)) = v;
    }
    QDP_reset_D(f);
}
コード例 #4
0
ファイル: check-cg.c プロジェクト: usqcd-software/clover
static double
f_reader(const int pos[NDIM], int c, int d, int re_im, void *env)
{
    QLA_Real xx;
    int n = QDP_node_number(pos);
    int i = QDP_index(pos);
    QDP_DiracFermion *f = (QDP_DiracFermion *)env;
    QLA_DiracFermion *df = QDP_expose_D(f);

    assert(n == self);
    if (re_im == 0) {
        QLA_r_eq_Re_c(xx, QLA_elem_D(df[i], c, d));
    } else {
        QLA_r_eq_Im_c(xx, QLA_elem_D(df[i], c, d));
    }
    QDP_reset_D(f);
    return xx;
}