MCPcopy Create free account
hub / github.com/NGSolve/ngsolve / NonZeroPattern

Method NonZeroPattern

fem/coefficient_matrix.cpp:947–960  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

945 { return Array<shared_ptr<CoefficientFunction>>({ c1 } ); }
946
947 virtual void NonZeroPattern (const class ProxyUserData & ud,
948 FlatVector<AutoDiffDiff<1,NonZero>> values) const override
949 {
950 int hd = Dimensions()[0];
951 c1->NonZeroPattern (ud, values);
952
953 for (int i = 0; i < hd; i++)
954 for (int j = 0; j < hd; j++)
955 {
956 int ii = i*hd+j;
957 int jj = j*hd+i;
958 values(ii) = values(ii)+values(jj); // logical or
959 }
960 }
961
962 virtual void NonZeroPattern (const class ProxyUserData & ud,
963 FlatArray<FlatVector<AutoDiffDiff<1,NonZero>>> input,

Callers

nothing calls this directly

Calls 2

DimensionsFunction · 0.85
NonZeroPatternMethod · 0.45

Tested by

no test coverage detected