Skip to content

Commit

Permalink
BiSpinor multiplication fix for GPU (#64)
Browse files Browse the repository at this point in the history
Just a tiny fix for multiplication of BiSpinor * AdjointBiSpinor on GPU. The
general dot product doesn't work on the GPU.
  • Loading branch information
AntonReinhard authored May 27, 2024
1 parent 7020dc7 commit 4b22825
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/dirac_tensors.jl
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ Tensor product of an adjoint with a standard bi-spinor resulting in a scalar.
"""
function mul(aBS::AdjointBiSpinor, BS::BiSpinor)::ComplexF64
return transpose(aBS) * BS
return aBS.el1 * BS.el1 + aBS.el2 * BS.el2 + aBS.el3 * BS.el3 + aBS.el4 * BS.el4
end
@inline *(aBS::AdjointBiSpinor, BS::BiSpinor) = mul(aBS::AdjointBiSpinor, BS::BiSpinor)

Expand Down

0 comments on commit 4b22825

Please sign in to comment.