function extractNode(x, scope, parent) {
    var n = scope.allNodes[x];
    n.parent = parent;
    return n;
}
get Node in index x in scope and set parent
@param {Node} x - the desired node
@param {Scope} scope - the scope
@param {CircuitElement} parent - The parent of node
@category node