float x1 = x[0]; float y1 = x[1]; float z1 = x[2]; //float cube = R_int(R_int(10 - fabs(x1-1), 10 - fabs(y1)), 10 - fabs(z1-2)); float cube = R_int(R_int(1 - fabs(x1-1)/10, 1 - fabs(y1)/10), 1 - fabs(z1-2)/10); //float cylinder3 = R_int(49 - (z1-1)*(z1-1) - x1*x1, 18 - fabs(y1)); float cylinder3 = R_int(1 - (z1-1)*(z1-1)/49 - x1*x1/49, 1 - fabs(y1)/18); float cylinder = 1 - x1*x1/25 - y1*y1/25; float cylinder2 = 1 - (y1-3)*(y1-3)/16 - z1*z1/16; return R_int(R_int(-cylinder, R_uni(cylinder3, cube)), -cylinder2);