public double getKok() {
        double x_son = getX0();
        double delta_son = getDelta_x();
        double fx_ilk = 0;
        double fx_son = 0;
        double x_ilk = 0;
        double kontrol = 0;

        while (true) {
            do {
                fx_ilk = 0;
                fx_son = 0;

                x_ilk = x_son;
                for (int i = 0; i < katsayilar.length; i++) {
                    fx_ilk += katsayilar[i] * Math.pow(x_ilk, i);
                }
                x_son = x_son + delta_son;
                for (int i = 0; i < katsayilar.length; i++) {
                    fx_son += katsayilar[i] * Math.pow(x_son, i);
                }
                
                kontrol++;
                System.out.println("1.burda");
            } while ((fx_ilk * fx_son) > 0 && kontrol < 20000);
                System.out.println("2.burda");
            if(kontrol == 20000) {
                return -111222333;
            }
            if (fx_son >= 0 && fx_son <= getEpsilon()) {
                return x_son;
            }
            x_son = x_ilk;
            delta_son /= 2;
        }
    }