MCPcopy Create free account
hub / github.com/Singular/Singular / hLex2R

Function hLex2R

kernel/combinatorics/hutil.cc:880–944  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

878
879
880void hLex2R(scfmon rad, int e1, int a2, int e2, varset var,
881 int Nvar, scfmon w)
882{
883 int j0 = 0, j = 0, i = a2, k, k1;
884 scmon n, o;
885 if (!e1)
886 {
887 for (; i < e2; i++)
888 rad[i - a2] = rad[i];
889 return;
890 }
891 else if (i == e2)
892 return;
893 n = rad[j];
894 o = rad[i];
895 loop
896 {
897 k = Nvar;
898 loop
899 {
900 k1 = var[k];
901 if (!o[k1] && n[k1])
902 {
903 w[j0] = o;
904 j0++;
905 i++;
906 if (i < e2)
907 {
908 o = rad[i];
909 break;
910 }
911 else
912 {
913 for (; j < e1; j++)
914 {
915 w[j0] = rad[j];
916 j0++;
917 }
918 memcpy(rad, w, (e1 + e2 - a2) * sizeof(scmon));
919 return;
920 }
921 }
922 else if (o[k1] && !n[k1])
923 {
924 w[j0] = n;
925 j0++;
926 j++;
927 if (j < e1)
928 {
929 n = rad[j];
930 break;
931 }
932 else
933 {
934 for (; i < e2; i++)
935 {
936 w[j0] = rad[i];
937 j0++;

Callers 3

hDimSolveFunction · 0.85
hdegree.ccFile · 0.85
hIndAllMultFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected