QUDA
1.0.0
|
#include <stdio.h>
#include <stdlib.h>
#include <math.h>
#include <string.h>
#include <type_traits>
#include "quda.h"
#include "test_util.h"
#include "misc.h"
#include "hisq_force_reference.h"
Go to the source code of this file.
Classes | |
struct | fcomplex |
struct | dcomplex |
struct | fsu3_matrix |
struct | fsu3_vector |
struct | dsu3_matrix |
struct | dsu3_vector |
struct | fanti_hermitmat |
struct | danti_hermitmat |
struct | fhalf_wilson_vector |
struct | dhalf_wilson_vector |
Macros | |
#define | CADD(a, b, c) |
#define | CMUL(a, b, c) |
#define | CSUM(a, b) { (a).real += (b).real; (a).imag += (b).imag; } |
#define | CMULJ_(a, b, c) |
#define | CMUL_J(a, b, c) |
#define | CONJG(a, b) { (b).real = (a).real; (b).imag = -(a).imag; } |
#define | Pmu tempmat[0] |
#define | Pnumu tempmat[1] |
#define | Prhonumu tempmat[2] |
#define | P7 tempmat[3] |
#define | P7rho tempmat[4] |
#define | P5 tempmat[5] |
#define | P3 tempmat[6] |
#define | P5nu tempmat[3] |
#define | P3mu tempmat[3] |
#define | Popmu tempmat[4] |
#define | Pmumumu tempmat[4] |
#define | Qmu tempmat[7] |
#define | Qnumu tempmat[8] |
#define | Qrhonumu tempmat[2] |
Functions | |
template<typename su3_matrix > | |
su3_matrix * | get_su3_matrix (int gauge_order, su3_matrix *p, int idx, int dir) |
template<typename su3_matrix > | |
static void | su3_adjoint (su3_matrix *a, su3_matrix *b) |
template<typename su3_matrix > | |
static void | adjoint_su3_matrix (su3_matrix *a) |
template<typename su3_matrix , typename anti_hermitmat > | |
static void | make_anti_hermitian (su3_matrix *m3, anti_hermitmat *ah3) |
template<typename anti_hermitmat , typename su3_matrix > | |
static void | uncompress_anti_hermitian (anti_hermitmat *mat_antihermit, su3_matrix *mat_su3) |
template<typename su3_matrix , typename Float > | |
static void | scalar_mult_sub_su3_matrix (su3_matrix *a, su3_matrix *b, Float s, su3_matrix *c) |
template<typename su3_matrix , typename Float > | |
static void | scalar_mult_add_su3_matrix (su3_matrix *a, su3_matrix *b, Float s, su3_matrix *c) |
template<typename su3_matrix , typename Float > | |
static void | scale_su3_matrix (su3_matrix *a, Float s) |
template<typename su3_matrix , typename su3_vector > | |
static void | mult_su3_mat_vec (su3_matrix *a, su3_vector *b, su3_vector *c) |
template<typename su3_matrix , typename su3_vector > | |
static void | mult_adj_su3_mat_vec (su3_matrix *a, su3_vector *b, su3_vector *c) |
template<typename su3_vector , typename su3_matrix > | |
static void | su3_projector (su3_vector *a, su3_vector *b, su3_matrix *c) |
template<typename su3_vector , typename Real > | |
static void | scalar_mult_add_su3_vector (su3_vector *a, su3_vector *b, Real s, su3_vector *c) |
template<typename su3_matrix > | |
static void | print_su3_matrix (su3_matrix *a) |
template<typename su3_matrix > | |
static void | matrix_mult_nn (su3_matrix *a, su3_matrix *b, su3_matrix *c) |
template<typename su3_matrix > | |
static void | matrix_mult_an (su3_matrix *a, su3_matrix *b, su3_matrix *c) |
template<typename su3_matrix > | |
static void | matrix_mult_na (su3_matrix *a, su3_matrix *b, su3_matrix *c) |
template<typename su3_matrix > | |
static void | matrix_mult_aa (su3_matrix *a, su3_matrix *b, su3_matrix *c) |
template<typename su3_matrix , typename anti_hermitmat , typename Float > | |
static void | update_mom (anti_hermitmat *momentum, int dir, su3_matrix *sitelink, su3_matrix *staple, Float eb3) |
template<typename half_wilson_vector , typename su3_matrix > | |
static void | u_shift_hw (half_wilson_vector *src, half_wilson_vector *dest, int dir, su3_matrix *sitelink) |
template<typename half_wilson_vector , typename su3_matrix > | |
static void | shifted_outer_prod (half_wilson_vector *src, su3_matrix *dest, int dir) |
template<typename half_wilson_vector , typename su3_matrix > | |
static void | forward_shifted_outer_prod (half_wilson_vector *src, su3_matrix *dest, int dir) |
template<typename half_wilson_vector , typename su3_matrix > | |
static void | computeLinkOrderedOuterProduct (half_wilson_vector *src, su3_matrix *dest, int gauge_order) |
template<typename half_wilson_vector , typename su3_matrix > | |
static void | computeLinkOrderedOuterProduct (half_wilson_vector *src, su3_matrix *dest, size_t nhops, int gauge_order) |
void | computeLinkOrderedOuterProduct (void *src, void *dst, QudaPrecision precision, int gauge_order) |
void | computeLinkOrderedOuterProduct (void *src, void *dst, QudaPrecision precision, size_t nhops, int gauge_order) |
template<typename half_wilson_vector , typename su3_matrix > | |
static void | shiftedOuterProduct (half_wilson_vector *src, su3_matrix *dest) |
template<typename half_wilson_vector , typename su3_matrix > | |
static void | forwardShiftedOuterProduct (half_wilson_vector *src, su3_matrix *dest) |
void | computeHisqOuterProduct (void *src, void *dest, QudaPrecision precision) |
template<typename su3_matrix > | |
static void | u_shift_mat (su3_matrix *src, su3_matrix *dest, int dir, su3_matrix *sitelink) |
template<typename half_wilson_vector , typename anti_hermitmat , typename Real > | |
static void | add_3f_force_to_mom (half_wilson_vector *back, half_wilson_vector *forw, int dir, Real coeff[2], anti_hermitmat *momentum) |
template<typename Real , typename half_wilson_vector , typename anti_hermitmat > | |
static void | side_link_3f_force (int mu, int nu, Real coeff[2], half_wilson_vector *Path, half_wilson_vector *Path_nu, half_wilson_vector *Path_mu, half_wilson_vector *Path_numu, anti_hermitmat *mom) |
template<typename Real , typename su3_matrix , typename anti_hermitmat > | |
static void | add_force_to_momentum (su3_matrix *back, su3_matrix *forw, int dir, Real coeff, anti_hermitmat *momentum) |
template<typename Real , typename su3_matrix , typename anti_hermitmat > | |
static void | side_link_force (int mu, int nu, Real coeff, su3_matrix *Path, su3_matrix *Path_nu, su3_matrix *Path_mu, su3_matrix *Path_numu, anti_hermitmat *mom) |
template<typename su3_matrix > | |
static void | set_identity_matrix (su3_matrix *mat) |
template<typename su3_matrix > | |
static void | set_identity (su3_matrix *matrices, int num_dirs) |
template<typename Real , typename su3_matrix , typename anti_hermitmat > | |
void | do_color_matrix_hisq_force_reference (Real eps, Real weight, su3_matrix *temp_xx, Real *act_path_coeff, su3_matrix *sitelink, anti_hermitmat *mom) |
template<typename Real , typename su3_matrix , typename anti_hermitmat , typename half_wilson_vector > | |
void | do_halfwilson_hisq_force_reference (Real eps, Real weight, half_wilson_vector *temp_x, Real *act_path_coeff, su3_matrix *sitelink, anti_hermitmat *mom) |
void | halfwilson_hisq_force_reference (float eps, float weight, void *act_path_coeff, void *temp_x, void *sitelink, void *mom) |
void | halfwilson_hisq_force_reference (double eps, double weight, void *act_path_coeff, void *temp_x, void *sitelink, void *mom) |
void | color_matrix_hisq_force_reference (float eps, float weight, void *act_path_coeff, void *temp_xx, void *sitelink, void *mom) |
Variables | |
int | Z [4] |
int | V |
int | Vh |
#define CADD | ( | a, | |
b, | |||
c | |||
) |
Definition at line 17 of file hisq_force_reference.cpp.
#define CMUL | ( | a, | |
b, | |||
c | |||
) |
Definition at line 19 of file hisq_force_reference.cpp.
Referenced by matrix_mult_nn(), mult_adj_su3_mat_vec(), and mult_su3_mat_vec().
#define CMUL_J | ( | a, | |
b, | |||
c | |||
) |
Definition at line 28 of file hisq_force_reference.cpp.
Referenced by matrix_mult_na(), and su3_projector().
#define CMULJ_ | ( | a, | |
b, | |||
c | |||
) |
Definition at line 24 of file hisq_force_reference.cpp.
Referenced by matrix_mult_an().
#define CONJG | ( | a, | |
b | |||
) | { (b).real = (a).real; (b).imag = -(a).imag; } |
Definition at line 31 of file hisq_force_reference.cpp.
Referenced by adjoint_su3_matrix(), mult_adj_su3_mat_vec(), and su3_adjoint().
#define CSUM | ( | a, | |
b | |||
) | { (a).real += (b).real; (a).imag += (b).imag; } |
Definition at line 21 of file hisq_force_reference.cpp.
Referenced by mult_adj_su3_mat_vec(), and mult_su3_mat_vec().
#define P3 tempmat[6] |
Definition at line 714 of file hisq_force_reference.cpp.
Referenced by do_color_matrix_hisq_force_reference(), and do_halfwilson_hisq_force_reference().
#define P3mu tempmat[3] |
Definition at line 716 of file hisq_force_reference.cpp.
Referenced by do_color_matrix_hisq_force_reference(), and do_halfwilson_hisq_force_reference().
#define P5 tempmat[5] |
Definition at line 713 of file hisq_force_reference.cpp.
Referenced by do_color_matrix_hisq_force_reference(), and do_halfwilson_hisq_force_reference().
#define P5nu tempmat[3] |
Definition at line 715 of file hisq_force_reference.cpp.
Referenced by do_color_matrix_hisq_force_reference(), and do_halfwilson_hisq_force_reference().
#define P7 tempmat[3] |
Definition at line 711 of file hisq_force_reference.cpp.
Referenced by do_color_matrix_hisq_force_reference(), and do_halfwilson_hisq_force_reference().
#define P7rho tempmat[4] |
Definition at line 712 of file hisq_force_reference.cpp.
Referenced by do_color_matrix_hisq_force_reference(), and do_halfwilson_hisq_force_reference().
#define Pmu tempmat[0] |
Definition at line 708 of file hisq_force_reference.cpp.
Referenced by do_color_matrix_hisq_force_reference(), and do_halfwilson_hisq_force_reference().
#define Pmumumu tempmat[4] |
Definition at line 718 of file hisq_force_reference.cpp.
#define Pnumu tempmat[1] |
Definition at line 709 of file hisq_force_reference.cpp.
Referenced by do_color_matrix_hisq_force_reference(), and do_halfwilson_hisq_force_reference().
#define Popmu tempmat[4] |
Definition at line 717 of file hisq_force_reference.cpp.
#define Prhonumu tempmat[2] |
Definition at line 710 of file hisq_force_reference.cpp.
Referenced by do_color_matrix_hisq_force_reference(), and do_halfwilson_hisq_force_reference().
#define Qmu tempmat[7] |
Definition at line 720 of file hisq_force_reference.cpp.
Referenced by do_color_matrix_hisq_force_reference(), and do_halfwilson_hisq_force_reference().
#define Qnumu tempmat[8] |
Definition at line 721 of file hisq_force_reference.cpp.
Referenced by do_color_matrix_hisq_force_reference(), and do_halfwilson_hisq_force_reference().
#define Qrhonumu tempmat[2] |
Definition at line 722 of file hisq_force_reference.cpp.
Referenced by do_color_matrix_hisq_force_reference(), and do_halfwilson_hisq_force_reference().
|
static |
Definition at line 562 of file hisq_force_reference.cpp.
References GOES_BACKWARDS, make_anti_hermitian(), OPP_DIR, scalar_mult_add_su3_matrix(), su3_projector(), uncompress_anti_hermitian(), V, and Vh.
Referenced by side_link_3f_force().
|
static |
Definition at line 639 of file hisq_force_reference.cpp.
References GOES_BACKWARDS, make_anti_hermitian(), matrix_mult_na(), OPP_DIR, scalar_mult_add_su3_matrix(), uncompress_anti_hermitian(), V, and Vh.
Referenced by do_color_matrix_hisq_force_reference(), do_halfwilson_hisq_force_reference(), and side_link_force().
|
static |
Definition at line 91 of file hisq_force_reference.cpp.
References CONJG, and su3_matrix< real >::e.
void color_matrix_hisq_force_reference | ( | float | eps, |
float | weight, | ||
void * | act_path_coeff, | ||
void * | temp_xx, | ||
void * | sitelink, | ||
void * | mom | ||
) |
Definition at line 1162 of file hisq_force_reference.cpp.
References do_color_matrix_hisq_force_reference().
void computeHisqOuterProduct | ( | void * | src, |
void * | dest, | ||
QudaPrecision | precision | ||
) |
Definition at line 512 of file hisq_force_reference.cpp.
References forwardShiftedOuterProduct(), and QUDA_SINGLE_PRECISION.
|
static |
Definition at line 437 of file hisq_force_reference.cpp.
References get_su3_matrix(), hw, neighborIndexFullLattice(), su3_projector(), and V.
Referenced by computeLinkOrderedOuterProduct(), and hisq_force_init().
|
static |
Definition at line 456 of file hisq_force_reference.cpp.
References get_su3_matrix(), hw, neighborIndexFullLattice(), su3_projector(), and V.
void computeLinkOrderedOuterProduct | ( | void * | src, |
void * | dst, | ||
QudaPrecision | precision, | ||
int | gauge_order | ||
) |
Definition at line 475 of file hisq_force_reference.cpp.
References computeLinkOrderedOuterProduct(), and QUDA_SINGLE_PRECISION.
void computeLinkOrderedOuterProduct | ( | void * | src, |
void * | dst, | ||
QudaPrecision | precision, | ||
size_t | nhops, | ||
int | gauge_order | ||
) |
Definition at line 485 of file hisq_force_reference.cpp.
References computeLinkOrderedOuterProduct(), and QUDA_SINGLE_PRECISION.
void do_color_matrix_hisq_force_reference | ( | Real | eps, |
Real | weight, | ||
su3_matrix * | temp_xx, | ||
Real * | act_path_coeff, | ||
su3_matrix * | sitelink, | ||
anti_hermitmat * | mom | ||
) |
Definition at line 750 of file hisq_force_reference.cpp.
References add_force_to_momentum(), GOES_FORWARDS, mu, OPP_DIR, P3, P3mu, P5, P5nu, P7, P7rho, Pmu, Pnumu, Prhonumu, Qmu, Qnumu, Qrhonumu, scalar_mult_add_su3_matrix(), set_identity(), side_link_force(), sites_on_node, u_shift_mat(), and V.
Referenced by color_matrix_hisq_force_reference().
void do_halfwilson_hisq_force_reference | ( | Real | eps, |
Real | weight, | ||
half_wilson_vector * | temp_x, | ||
Real * | act_path_coeff, | ||
su3_matrix * | sitelink, | ||
anti_hermitmat * | mom | ||
) |
Definition at line 936 of file hisq_force_reference.cpp.
References add_force_to_momentum(), GOES_FORWARDS, mu, OPP_DIR, P3, P3mu, P5, P5nu, P7, P7rho, Pmu, Pnumu, Prhonumu, Qmu, Qnumu, Qrhonumu, scalar_mult_add_su3_matrix(), set_identity(), shifted_outer_prod(), side_link_force(), sites_on_node, u_shift_mat(), and V.
Referenced by halfwilson_hisq_force_reference().
|
static |
Definition at line 409 of file hisq_force_reference.cpp.
References GOES_FORWARDS, hw, neighborIndexFullLattice(), OPP_DIR, su3_projector(), and V.
Referenced by forwardShiftedOuterProduct().
|
static |
Definition at line 505 of file hisq_force_reference.cpp.
References forward_shifted_outer_prod(), and V.
Referenced by computeHisqOuterProduct().
su3_matrix* get_su3_matrix | ( | int | gauge_order, |
su3_matrix * | p, | ||
int | idx, | ||
int | dir | ||
) |
Definition at line 66 of file hisq_force_reference.cpp.
References errorQuda, QUDA_MILC_GAUGE_ORDER, and QUDA_QDP_GAUGE_ORDER.
Referenced by computeLinkOrderedOuterProduct().
void halfwilson_hisq_force_reference | ( | float | eps, |
float | weight, | ||
void * | act_path_coeff, | ||
void * | temp_x, | ||
void * | sitelink, | ||
void * | mom | ||
) |
Definition at line 1138 of file hisq_force_reference.cpp.
References do_halfwilson_hisq_force_reference().
void halfwilson_hisq_force_reference | ( | double | eps, |
double | weight, | ||
void * | act_path_coeff, | ||
void * | temp_x, | ||
void * | sitelink, | ||
void * | mom | ||
) |
Definition at line 1150 of file hisq_force_reference.cpp.
References do_halfwilson_hisq_force_reference().
|
static |
Definition at line 104 of file hisq_force_reference.cpp.
References su3_matrix< real >::e.
Referenced by add_3f_force_to_mom(), add_force_to_momentum(), and update_mom().
|
static |
Definition at line 320 of file hisq_force_reference.cpp.
References matrix_mult_na(), and su3_adjoint().
|
static |
Definition at line 281 of file hisq_force_reference.cpp.
References CMULJ_, and su3_matrix< real >::e.
Referenced by u_shift_mat().
|
static |
Definition at line 302 of file hisq_force_reference.cpp.
References CMUL_J, and su3_matrix< real >::e.
Referenced by add_force_to_momentum(), and matrix_mult_aa().
|
static |
Definition at line 261 of file hisq_force_reference.cpp.
References CMUL, and su3_matrix< real >::e.
Referenced by u_shift_mat().
|
static |
Definition at line 203 of file hisq_force_reference.cpp.
References CMUL, CONJG, CSUM, and su3_matrix< real >::e.
Referenced by u_shift_hw().
|
static |
Definition at line 188 of file hisq_force_reference.cpp.
References CMUL, CSUM, and su3_matrix< real >::e.
Referenced by u_shift_hw().
|
static |
Definition at line 244 of file hisq_force_reference.cpp.
References su3_matrix< real >::e.
|
static |
Definition at line 163 of file hisq_force_reference.cpp.
References su3_matrix< real >::e.
Referenced by add_3f_force_to_mom(), add_force_to_momentum(), do_color_matrix_hisq_force_reference(), and do_halfwilson_hisq_force_reference().
|
static |
Definition at line 230 of file hisq_force_reference.cpp.
|
static |
Definition at line 150 of file hisq_force_reference.cpp.
References su3_matrix< real >::e.
Referenced by update_mom().
|
static |
Definition at line 175 of file hisq_force_reference.cpp.
References su3_matrix< real >::e, and quda::s.
|
static |
Definition at line 742 of file hisq_force_reference.cpp.
References set_identity_matrix(), and V.
Referenced by do_color_matrix_hisq_force_reference(), and do_halfwilson_hisq_force_reference().
|
static |
Definition at line 729 of file hisq_force_reference.cpp.
References su3_matrix< real >::e.
Referenced by set_identity().
|
static |
Definition at line 387 of file hisq_force_reference.cpp.
References GOES_FORWARDS, hw, neighborIndexFullLattice(), OPP_DIR, su3_projector(), and V.
Referenced by do_halfwilson_hisq_force_reference(), and shiftedOuterProduct().
|
static |
Definition at line 498 of file hisq_force_reference.cpp.
References OPP_DIR, shifted_outer_prod(), and V.
|
static |
Definition at line 612 of file hisq_force_reference.cpp.
References add_3f_force_to_mom(), GOES_FORWARDS, and OPP_DIR.
|
static |
Definition at line 676 of file hisq_force_reference.cpp.
References add_force_to_momentum(), GOES_FORWARDS, and OPP_DIR.
Referenced by do_color_matrix_hisq_force_reference(), and do_halfwilson_hisq_force_reference().
|
static |
Definition at line 81 of file hisq_force_reference.cpp.
References CONJG, and su3_matrix< real >::e.
Referenced by matrix_mult_aa().
|
static |
Definition at line 220 of file hisq_force_reference.cpp.
References CMUL_J, and su3_matrix< real >::e.
Referenced by add_3f_force_to_mom(), computeLinkOrderedOuterProduct(), forward_shifted_outer_prod(), and shifted_outer_prod().
|
static |
Definition at line 355 of file hisq_force_reference.cpp.
References GOES_FORWARDS, hw, mult_adj_su3_mat_vec(), mult_su3_mat_vec(), neighborIndexFullLattice(), OPP_DIR, and V.
|
static |
Definition at line 527 of file hisq_force_reference.cpp.
References GOES_FORWARDS, mat(), matrix_mult_an(), matrix_mult_nn(), neighborIndexFullLattice(), OPP_DIR, and V.
Referenced by do_color_matrix_hisq_force_reference(), and do_halfwilson_hisq_force_reference().
|
static |
Definition at line 121 of file hisq_force_reference.cpp.
References su3_matrix< real >::e.
Referenced by add_3f_force_to_mom(), add_force_to_momentum(), and update_mom().
|
static |
Definition at line 329 of file hisq_force_reference.cpp.
References make_anti_hermitian(), mult_su3_na(), scalar_mult_sub_su3_matrix(), uncompress_anti_hermitian(), and V.
int V |
Definition at line 27 of file test_util.cpp.
Referenced by add_3f_force_to_mom(), add_force_to_momentum(), computeLinkOrderedOuterProduct(), do_color_matrix_hisq_force_reference(), do_halfwilson_hisq_force_reference(), forward_shifted_outer_prod(), forwardShiftedOuterProduct(), set_identity(), shifted_outer_prod(), shiftedOuterProduct(), u_shift_hw(), u_shift_mat(), and update_mom().
int Vh |
Definition at line 28 of file test_util.cpp.
Referenced by add_3f_force_to_mom(), and add_force_to_momentum().
int Z[4] |
Definition at line 26 of file test_util.cpp.