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

Method renamingStrings

gfanlib/gfanlib_polyhedralfan.cpp:441–482  ·  view source on GitHub ↗

Produce strings that express the vectors in terms of rays of the fan modulo the lineality space. Symmetry is ignored?? */

Source from the content-addressed store, hash-verified

439 Produce strings that express the vectors in terms of rays of the fan modulo the lineality space. Symmetry is ignored??
440 */
441vector<string> PolyhedralFan::renamingStrings(IntegerVectorList const &theVectors, IntegerVectorList const &originalRays, IntegerVectorList const &linealitySpace, SymmetryGroup *sym)const
442{
443 vector<string> ret;
444 for(IntegerVectorList::const_iterator i=theVectors.begin();i!=theVectors.end();i++)
445 {
446 for(PolyhedralConeList::const_iterator j=cones.begin();j!=cones.end();j++)
447 {
448 if(j->contains(*i))
449 {
450 vector<int> relevantIndices;
451 IntegerVectorList relevantRays=linealitySpace;
452 int K=0;
453 for(IntegerVectorList::const_iterator k=originalRays.begin();k!=originalRays.end();k++,K++)
454 if(j->contains(*k))
455 {
456 relevantIndices.push_back(K);
457 relevantRays.push_back(*k);
458 }
459
460 FieldMatrix LFA(Q,relevantRays.size(),n);
461 int J=0;
462 for(IntegerVectorList::const_iterator j=relevantRays.begin();j!=relevantRays.end();j++,J++)
463 LFA[J]=integerVectorToFieldVector(*j,Q);
464 FieldVector LFB=concatenation(integerVectorToFieldVector(*i,Q),FieldVector(Q,relevantRays.size()));
465 LFA=LFA.transposed();
466 FieldVector LFX=LFA.solver().canonicalize(LFB);
467 stringstream s;
468 if(LFX.subvector(0,n).isZero())
469 {
470 s<<"Was:";
471 FieldVector S=LFX.subvector(n+linealitySpace.size(),LFX.size());
472 for(int k=0;k<S.size();k++)
473 if(!S[k].isZero())
474 s<<"+"<<S[k].toString()<<"*["<<relevantIndices[k]<<"] ";
475 }
476 ret.push_back(s.str());
477 break;
478 }
479 }
480 }
481 return ret;
482}
483#endif
484
485SymmetricComplex PolyhedralFan::toSymmetricComplex()const

Callers

nothing calls this directly

Calls 12

transposedMethod · 0.80
solverMethod · 0.80
subvectorMethod · 0.80
beginMethod · 0.45
endMethod · 0.45
containsMethod · 0.45
push_backMethod · 0.45
sizeMethod · 0.45
canonicalizeMethod · 0.45
isZeroMethod · 0.45
toStringMethod · 0.45
strMethod · 0.45

Tested by

no test coverage detected