 void lexpr_replace_relu_bounds(float_type* __restrict__ inf_coeff, float_type* __restrict__ sup_coeff, float_type* __restrict__ inf_cst, float_type* __restrict__ sup_cst, const float_type* __restrict__ lb_array, const float_type* __restrict__ ub_array, const size_t num_out_neurons_current_layer, const bool use_area_heuristic)
 {
     const size_t n = blockIdx.x;
-    size_t i = threadIdx.x;
-
-    while(i < num_out_neurons_current_layer)
+
+    for(size_t i = 0; i < num_out_neurons_current_layer; i++)
     {
         const size_t a = n*num_out_neurons_current_layer + i;
 

        {
            if(fp->layers[k]->activation==RELU)
            {
                lexpr_replace_relu_bounds<<<num_out_neurons_last_layer, num_threads>>>(linf_coeff, lsup_coeff, linf_cst, lsup_cst, fp->layers[k]->lb_array, fp->layers[k]->ub_array, fp->layers[k]->num_out_neurons, use_area_heuristic);
            }

            std::cout << "DENSE RESIDUAL" << std::endl;


    if(fp->layers[k]->activation == RELU)
    {
        lexpr_replace_relu_bounds<<<num_out_neurons_last_layer, 1>>>(*linf_coeff, *lsup_coeff, *linf_cst, *lsup_cst, aux_lb_array, aux_ub_array, num_out_neurons_current_layer, use_area_heuristic);
        uexpr_replace_relu_bounds<<<num_out_neurons_last_layer, 1>>>(*uinf_coeff, *usup_coeff, *uinf_cst, *usup_cst, aux_lb_array, aux_ub_array, num_out_neurons_current_layer, use_area_heuristic);
    }

    cudaMalloc((void**) &(*linf_coeff_tmp), num_out_neurons_last_layer*num_in_neurons_current_layer*sizeof(float_type));
