        nearest_eq_id = find_nearest_eqution_id(name, e.clientX - canvas_rect.left, e.clientY - canvas_rect.top);
            eval(name + "_eq_temp_id = nearest_eq_id;");
       }
    }, false);

    plot.addEventListener('mousedown', function(e){
        invalidate_plot_named(name);
        var canvas_rect = plot.getBoundingClientRect();
        nearest_eq_id = find_nearest_eqution_id(name, e.clientX - canvas_rect.left, e.clientY - canvas_rect.top);
        eval(name + "_eq_temp_id = nearest_eq_id;");
    