private void pass() { inter.push(stack.popInt()); }
private void pass() { inter.push(stack.popInt()); }
private static void move(final IntArrayList[] queue, final int[] posInQueue, final int v, final int queueBefore, final int queueAfter) { if (queueBefore != queueAfter) { remove(queue[queueBefore], v, posInQueue); posInQueue[v] = queue[queueAfter].size(); queue[queueAfter].push(v); } }
public void reset(int stackID, int inputID) { stack.clear(); inter.clear(); stack.push(stackID); input = inputID; } }
public void reset(int stackID, int inputID) { stack.clear(); inter.clear(); stack.push(stackID); input = inputID; } }
segmentStack.push(1); dirStack.push(false); else segmentStack.push(segmentStack.popInt() + 1); jumpStack.push(internalNode); depthStack.push(depth); if (top != 1) segmentStack.push(top - 1); else dirStack.popBoolean(); segmentStack.push(1); dirStack.push(true); else segmentStack.push(segmentStack.popInt() + 1); jumpStack.push(internalNode); depthStack.push(depth); if (top != 1) segmentStack.push(top - 1); else dirStack.popBoolean();
if (DEBUG) System.err.println("Making variable " + var + " of weight " + weight[var] + " active (" + remaining + " equations to go)"); for(final int equationIndex: var2Eq[var]) if (--priority[equationIndex] == 1) equationList.push(equationIndex);
private void peel(final int x) { // System.err.println("Visiting " + x + "..."); final int[] vertex1 = this.vertex1; final int[] vertex2 = this.vertex2; final int[] edge = this.edge; final int[] stack = this.stack; final int[] d = this.d; final IntArrayList visitStack = this.visitStack; // Queue initialization int v; visitStack.clear(); visitStack.push(x); while (! visitStack.isEmpty()) { v = visitStack.popInt(); if (d[v] == 1) { stack[top++] = v; --d[v]; // System.err.println("Stripping <" + v + ", " + vertex1[v] + ", " + vertex2[v] + ">"); xorEdge(computeEdges ? edge[v] : -1, v, vertex1[v], vertex2[v], true); if (--d[vertex1[v]] == 1) visitStack.add(vertex1[v]); if (--d[vertex2[v]] == 1) visitStack.add(vertex2[v]); } } } }
private void peel(final int x) { // System.err.println("Visiting " + x + "..."); final int[] edge = this.edge; final int[] stack = this.stack; final int[] d = this.d; final IntArrayList visitStack = this.visitStack; // Stack initialization int v; visitStack.clear(); visitStack.push(x); final int[] edge2Vertex0 = edge2Vertex[0]; final int[] edge2Vertex1 = edge2Vertex[1]; final int[] edge2Vertex2 = edge2Vertex[2]; while (! visitStack.isEmpty()) { v = visitStack.popInt(); if (d[v] == 1) { stack[top++] = v; // System.err.println("Stripping <" + v + ", " + vertex1[v] + ", " + vertex2[v] + ">"); final int e = edge[v]; peeled[e] = true; xorEdge(e, v); if (--d[edge2Vertex0[e]] == 1) visitStack.add(edge2Vertex0[e]); if (--d[edge2Vertex1[e]] == 1) visitStack.add(edge2Vertex1[e]); if (--d[edge2Vertex2[e]] == 1) visitStack.add(edge2Vertex2[e]); } } }
if (DEBUG) System.err.println("Making variable " + var + " of weight " + weight[var] + " active (" + remaining + " equations to go)"); for(final int equationIndex: var2Eq[var]) if (--priority[equationIndex] == 1) equationList.push(equationIndex);
private void peel(final int x) { // System.err.println("Visiting " + x + "..."); final int[] edge = this.edge; final int[] stack = this.stack; final int[] d = this.d; final IntArrayList visitStack = this.visitStack; // Stack initialization int v; visitStack.clear(); visitStack.push(x); final int[] edge2Vertex0 = edge2Vertex[0]; final int[] edge2Vertex1 = edge2Vertex[1]; final int[] edge2Vertex2 = edge2Vertex[2]; final int[] edge2Vertex3 = edge2Vertex[3]; while (! visitStack.isEmpty()) { v = visitStack.popInt(); if (d[v] == 1) { stack[top++] = v; // System.err.println("Stripping <" + v + ", " + vertex1[v] + ", " + vertex2[v] + ">"); final int e = edge[v]; peeled[e] = true; xorEdge(e, v); if (--d[edge2Vertex0[e]] == 1) visitStack.add(edge2Vertex0[e]); if (--d[edge2Vertex1[e]] == 1) visitStack.add(edge2Vertex1[e]); if (--d[edge2Vertex2[e]] == 1) visitStack.add(edge2Vertex2[e]); if (--d[edge2Vertex3[e]] == 1) visitStack.add(edge2Vertex3[e]); } } }