/* This is the header file for functions that allow to perform vector calculus with complex four-vectors */ #ifndef fvec_h #define fvec_h #include #include #include typedef struct FVEC { dcomplex fv[4]; } fvec; typedef struct SPINOR_MAT { dcomplex sm[4][4]; } spinor_mat; typedef struct SPINOR { dcomplex s[4]; } spinor; fvec V4ini(dcomplex t, vec r); fvec V4zero(); void V4echo( fvec a); fvec V4add(fvec a, fvec b); fvec V4sub(fvec a, fvec b); dcomplex V4mul( fvec a, fvec b); fvec V4conjg( fvec a); fvec V4Rmul( fvec a, double b); fvec V4Cmul( fvec a, dcomplex b); double metric(int mu, int nu); double antisymm_epsilon(int ka, int la, int mu, int nu); spinor_mat SMadd(spinor_mat a, spinor_mat b); spinor_mat SMsub(spinor_mat a, spinor_mat b); spinor_mat SMRmul(spinor_mat a, double z); spinor_mat SMCmul(spinor_mat a, dcomplex z); spinor_mat SMmul(spinor_mat a, spinor_mat b); spinor_mat SMmul3(spinor_mat a, spinor_mat b, spinor_mat c); spinor_mat SMmul4(spinor_mat a, spinor_mat b, spinor_mat c, spinor_mat d); spinor_mat SMmul5(spinor_mat a, spinor_mat b, spinor_mat c, spinor_mat d, spinor_mat e); spinor_mat dirac_gamma(int mu); spinor_mat dirac_gamma5(); spinor_mat dirac_sigma(int mu, int nu); spinor_mat unit_spinor_mat(); spinor_mat zero_spinor_mat(); spinor_mat fvec_slash(fvec a); spinor spinor_pos(vec p, double mass, double sproj); spinor spinor_pos_xaxis(vec p, double mass, double sproj); spinor spinor_pos_yaxis(vec p, double mass, double sproj); spinor spinor_hel(vec p, double hel); spinor spinor_anti_hel(vec p, double hel); spinor spinor_part_hel(vec p, double mass, double hel); spinor spinor_antipart_hel(vec p, double mass, double hel); spinor spinor_adj(spinor a); dcomplex spinleft_mat_spinright(spinor l, spinor_mat m, spinor r); #endif