MCPcopy Create free account
hub / github.com/Gecode/gecode / tupleset2dfa

Function tupleset2dfa

test/int/extensional.cpp:376–388  ·  view source on GitHub ↗

% Transform a TupleSet into a DFA

Source from the content-addressed store, hash-verified

374
375 ///% Transform a TupleSet into a DFA
376 Gecode::DFA tupleset2dfa(Gecode::TupleSet ts) {
377 using namespace Gecode;
378 REG expression;
379 for (int i = 0; i<ts.tuples(); i++) {
380 REG r;
381 for (int j = 0; j<ts.arity(); j++) {
382 r += REG(ts[i][j]);
383 }
384 expression |= r;
385 }
386 DFA dfa(expression);
387 return dfa;
388 }
389
390 /// %Test with tuple set
391 class TupleSetBase : public Test {

Callers 2

postMethod · 0.85
postMethod · 0.85

Calls 2

tuplesMethod · 0.80
arityMethod · 0.80

Tested by

no test coverage detected