Skip to content

Commit f35540b

Browse files
committed
faster cofactor
1 parent bf81795 commit f35540b

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

src/TensorAlgebra/Functions.jl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ end
1717
Calculate the cofactor of a matrix.
1818
"""
1919
function cof(A::TensorValue)
20-
return det(A)*inv(A')
20+
0.5A×A
2121
end
2222

2323

0 commit comments

Comments
 (0)