class_docstr: 1d-solver generating pairs of approximative root and error.
  
  Uses bisection method to find a root of f in [a, b].
  Might fail for multiple roots (needs sign change).
  
  Pro:
  
  * robust and reliable
  
  Contra:
  
  * converges slowly
  * needs sign change
class_docstr_tok: ["1d-solver","generating","pairs","of","approximative","root","and","error",".","Uses","bisection","method","to","find","a","root","of","f","in","[","a",",","b","]",".","Might","fail","for","multiple","roots","(","needs","sign","change",")",".","Pro",":","*","robust","and","reliable","Contra",":","*","converges","slowly","*","needs","sign","change"]
code: def __init__(self, ctx, f, x0, **kwargs):
      self.ctx = ctx
      if len(x0) != 2:
          raise ValueError(
              "expected interval of 2 points, got %i" % len(x0)
          )
      self.f = f
      self.a = x0[0]
      self.b = x0[1]
  
imports: from __future__ import print_function
  from copy import copy
  from ..libmp.backend import xrange
label_desc: Use image node_id 1 to create a new Bisection object  with example: obj = Bisection(ctx, f, x0)