MCPcopy Create free account
hub / github.com/data61/MP-SPDZ / IsDiag

Function IsDiag

FHE/Matrix.cpp:144–152  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

142
143
144bool IsDiag(const matrix& A)
145{
146 int i,j,r=A.size(),c=A[0].size();
147 for (i=0; i<r; i++)
148 { for (j=0; j<c; j++)
149 { if (i!=j && A[i][j]!=0) { return false; } }
150 }
151 return true;
152}
153
154bool IsIdent(const matrix& A)
155{

Callers 1

SNF_StepFunction · 0.85

Calls 1

sizeMethod · 0.45

Tested by

no test coverage detected