#include <tgmath.h>
#include <gmp.h>
#include <mpfr.h>
#include <stdio.h>
#include <stdbool.h>

char *name = "(- (hypot (sqrt (atan a)) b) (* c a))";

double f_if(float a, float b, float c, float __attribute__((unused)) d) {
        float r15314 = a;
        float r15315 = atan(r15314);
        float r15316 = sqrt(r15315);
        float r15317 = b;
        float r15318 = hypot(r15316, r15317);
        float r15319 = c;
        float r15320 = r15319 * r15314;
        float r15321 = r15318 - r15320;
        return r15321;
}

double f_id(double a, double b, double c, double __attribute__((unused)) d) {
        double r15322 = a;
        double r15323 = atan(r15322);
        double r15324 = sqrt(r15323);
        double r15325 = b;
        double r15326 = hypot(r15324, r15325);
        double r15327 = c;
        double r15328 = r15327 * r15322;
        double r15329 = r15326 - r15328;
        return r15329;
}


double f_of(float a, float b, float c, float __attribute__((unused)) d) {
        float r15330 = a;
        float r15331 = atan(r15330);
        float r15332 = sqrt(r15331);
        float r15333 = sqrt(r15332);
        float r15334 = r15333 * r15333;
        float r15335 = b;
        float r15336 = hypot(r15334, r15335);
        float r15337 = c;
        float r15338 = r15337 * r15330;
        float r15339 = r15336 - r15338;
        return r15339;
}

double f_od(double a, double b, double c, double __attribute__((unused)) d) {
        double r15340 = a;
        double r15341 = atan(r15340);
        double r15342 = sqrt(r15341);
        double r15343 = sqrt(r15342);
        double r15344 = r15343 * r15343;
        double r15345 = b;
        double r15346 = hypot(r15344, r15345);
        double r15347 = c;
        double r15348 = r15347 * r15340;
        double r15349 = r15346 - r15348;
        return r15349;
}

void mpfr_fmod2(mpfr_t r, mpfr_t n, mpfr_t d, mpfr_rnd_t rmd) {
        mpfr_fmod(r, n, d, rmd);
        if (mpfr_cmp_ui(r, 0) < 0) mpfr_add(r, r, d, rmd);
}


static mpfr_t r15350, r15351, r15352, r15353, r15354, r15355, r15356, r15357;

void setup_mpfr_f_im() {
        mpfr_set_default_prec(144);
        mpfr_init(r15350);
        mpfr_init(r15351);
        mpfr_init(r15352);
        mpfr_init(r15353);
        mpfr_init(r15354);
        mpfr_init(r15355);
        mpfr_init(r15356);
        mpfr_init(r15357);
}

double f_im(double a, double b, double c, double __attribute__((unused)) d) {
        mpfr_set_d(r15350, a, MPFR_RNDN);
        mpfr_atan(r15351, r15350, MPFR_RNDN);
        mpfr_sqrt(r15352, r15351, MPFR_RNDN);
        mpfr_set_d(r15353, b, MPFR_RNDN);
        mpfr_hypot(r15354, r15352, r15353, MPFR_RNDN);
        mpfr_set_d(r15355, c, MPFR_RNDN);
        mpfr_mul(r15356, r15355, r15350, MPFR_RNDN);
        mpfr_sub(r15357, r15354, r15356, MPFR_RNDN);
        return mpfr_get_d(r15357, MPFR_RNDN);
}

static mpfr_t r15358, r15359, r15360, r15361, r15362, r15363, r15364, r15365, r15366, r15367;

void setup_mpfr_f_fm() {
        mpfr_set_default_prec(144);
        mpfr_init(r15358);
        mpfr_init(r15359);
        mpfr_init(r15360);
        mpfr_init(r15361);
        mpfr_init(r15362);
        mpfr_init(r15363);
        mpfr_init(r15364);
        mpfr_init(r15365);
        mpfr_init(r15366);
        mpfr_init(r15367);
}

double f_fm(double a, double b, double c, double __attribute__((unused)) d) {
        mpfr_set_d(r15358, a, MPFR_RNDN);
        mpfr_atan(r15359, r15358, MPFR_RNDN);
        mpfr_sqrt(r15360, r15359, MPFR_RNDN);
        mpfr_sqrt(r15361, r15360, MPFR_RNDN);
        mpfr_sqr(r15362, r15361, MPFR_RNDN);
        mpfr_set_d(r15363, b, MPFR_RNDN);
        mpfr_hypot(r15364, r15362, r15363, MPFR_RNDN);
        mpfr_set_d(r15365, c, MPFR_RNDN);
        mpfr_mul(r15366, r15365, r15358, MPFR_RNDN);
        mpfr_sub(r15367, r15364, r15366, MPFR_RNDN);
        return mpfr_get_d(r15367, MPFR_RNDN);
}

static mpfr_t r15368, r15369, r15370, r15371, r15372, r15373, r15374, r15375, r15376, r15377;

void setup_mpfr_f_dm() {
        mpfr_set_default_prec(144);
        mpfr_init(r15368);
        mpfr_init(r15369);
        mpfr_init(r15370);
        mpfr_init(r15371);
        mpfr_init(r15372);
        mpfr_init(r15373);
        mpfr_init(r15374);
        mpfr_init(r15375);
        mpfr_init(r15376);
        mpfr_init(r15377);
}

double f_dm(double a, double b, double c, double __attribute__((unused)) d) {
        mpfr_set_d(r15368, a, MPFR_RNDN);
        mpfr_atan(r15369, r15368, MPFR_RNDN);
        mpfr_sqrt(r15370, r15369, MPFR_RNDN);
        mpfr_sqrt(r15371, r15370, MPFR_RNDN);
        mpfr_sqr(r15372, r15371, MPFR_RNDN);
        mpfr_set_d(r15373, b, MPFR_RNDN);
        mpfr_hypot(r15374, r15372, r15373, MPFR_RNDN);
        mpfr_set_d(r15375, c, MPFR_RNDN);
        mpfr_mul(r15376, r15375, r15368, MPFR_RNDN);
        mpfr_sub(r15377, r15374, r15376, MPFR_RNDN);
        return mpfr_get_d(r15377, MPFR_RNDN);
}

