input stringlengths 16 454k | output stringlengths 13 350k | function_name stringlengths 1 100 | repo_name stringlengths 6 43 | category stringclasses 76
values | sample_id stringlengths 22 88 | decompiler stringclasses 1
value | opt_level stringclasses 1
value |
|---|---|---|---|---|---|---|---|
int guess_daily_pd(const DATASET *dset) {
int t;
int pd;
int wdbak;
_BOOL4 havesat;
int gotsat;
int gotsun;
int contig;
int wd;
pd = 5;
wdbak = -1;
gotsat = 0;
gotsun = 0;
contig = 0;
havesat = 6 - weekday_from_date(*(const char **)dset->S) < dset->n;
for (t = 0; t < dset->n && t <= 27; +... | int guess_daily_pd(const DATASET *dset) {
int t, wd, pd = 5;
int wdbak = -1;
int havesat = 0;
int gotsat = 0, gotsun = 0;
int contig = 0;
wd = weekday_from_date(dset->S[0]);
if (6 - wd < dset->n) {
havesat = 1;
}
for (t = 0; t < dset->n && t < 28; t++) {
wd = weekday_from_date(dset->S[t]);
... | guess_daily_pd | gretl-2021d | sci-mathematics | O0/sci-mathematics/gretl-2021d/libgretl-1.0.so.40.0.0 | ida | O0 |
int guess_panel_structure(double **Z, DATASET *dset) {
int v;
v = find_time_var(dset);
if (!v)
return 0;
if (fabs(*Z[v] - Z[v][1]) >= 2.220446049250313e-16) {
dset->structure = 2;
return 2;
} else {
dset->structure = 3;
return 3;
}
} | int guess_panel_structure(double **Z, DATASET *dset) {
int ret, v = find_time_var(dset);
if (v == 0) {
ret = 0;
} else if (floateq(Z[v][0], Z[v][1])) {
dset->structure = STACKED_CROSS_SECTION;
ret = STACKED_CROSS_SECTION;
} else {
dset->structure = STACKED_TIME_SERIES;
ret = STACKED_TIME_S... | guess_panel_structure | gretl-2021d | sci-mathematics | O0/sci-mathematics/gretl-2021d/libgretl-1.0.so.40.0.0 | ida | O0 |
void gui_logo(PRN *prn) {
char *v1;
char *v2;
char *v3;
PRN *prna;
PRN *myprn;
prna = prn;
myprn = 0;
if (!prn) {
myprn = gretl_print_new(GRETL_PRINT_STDOUT, 0);
prna = myprn;
}
v1 = gettext("gretl: gui client for gretl version %s,\n");
pprintf(prna, v1, "2021d");
v2 = gettext("Copyrigh... | void gui_logo(PRN *prn) {
PRN *myprn = NULL;
if (prn == NULL) {
myprn = gretl_print_new(GRETL_PRINT_STDOUT, NULL);
prn = myprn;
}
pprintf(prn, _("gretl: gui client for gretl version %s,\n"), GRETL_VERSION);
pputs(prn, _("Copyright Allin Cottrell and Riccardo \"Jack\" Lucchetti"));
pputc(prn, '\n')... | gui_logo | gretl-2021d | sci-mathematics | O0/sci-mathematics/gretl-2021d/libgretl-1.0.so.40.0.0 | ida | O0 |
void gui_save_system(ExecState *s) {
equation_system *sys;
sys = s->sys;
if (gretl_in_gui_mode() && s->callback) {
if (!sys && s->cmd->ci == 38 && s->cmd->param)
sys = get_equation_system_by_name(s->cmd->param);
if (sys && (s->cmd->savename[0] || (s->cmd->opt & 0x400000) != 0))
s->callback(s,... | static void gui_save_system(ExecState *s) {
equation_system *sys = s->sys;
if (!gretl_in_gui_mode() || s->callback == NULL) {
return;
}
if (sys == NULL && s->cmd->ci == ESTIMATE && s->cmd->param != NULL) {
sys = get_equation_system_by_name(s->cmd->param);
}
if (sys != NULL && (*s->cmd->savename !=... | gui_save_system | gretl-2021d | sci-mathematics | O0/sci-mathematics/gretl-2021d/libgretl-1.0.so.40.0.0 | ida | O0 |
void gui_script_logo(PRN *prn) {
char *v1;
char *v2;
char timestr[56];
unsigned long v4;
v4 = __readfsqword(0x28u);
v1 = gettext("gretl version %s\n");
pprintf(prn, v1, "2021d");
print_time(timestr);
v2 = gettext("Current session");
pprintf(prn, "%s: %s\n", v2, timestr);
pputc(prn, 10);
} | void gui_script_logo(PRN *prn) {
char timestr[48];
pprintf(prn, _("gretl version %s\n"), GRETL_VERSION);
print_time(timestr);
pprintf(prn, "%s: %s\n", _("Current session"), timestr);
pputc(prn, '\n');
} | gui_script_logo | gretl-2021d | sci-mathematics | O0/sci-mathematics/gretl-2021d/libgretl-1.0.so.40.0.0 | ida | O0 |
int gui_write_data(const char *fname, int *list, const DATASET *dset,
gretlopt opt) {
return real_write_data(fname, list, dset, opt, 1, 0);
} | int gui_write_data(const char *fname, int *list, const DATASET *dset,
gretlopt opt) {
return real_write_data(fname, list, dset, opt, 1, NULL);
} | gui_write_data | gretl-2021d | sci-mathematics | O0/sci-mathematics/gretl-2021d/libgretl-1.0.so.40.0.0 | ida | O0 |
gchar *gzipped_file_get_content(const char *fname, int *err) {
unsigned char *next;
bool v3;
gchar *ret;
size_t len;
gzFile fz;
fz = gretl_gzopen(fname, "rb");
ret = 0;
if (fz) {
for (len = 0;; ++len) {
if (fz->have) {
--fz->have;
++fz->pos;
next = fz->next;
fz... | static gchar *gzipped_file_get_content(const char *fname, int *err) {
gzFile fz = gretl_gzopen(fname, "rb");
gchar *ret = NULL;
if (fz == NULL) {
*err = E_FOPEN;
} else {
size_t len = 0;
int chk;
while (gzgetc(fz) > 0) {
len++;
}
if (len > 0) {
gzrewind(fz);
ret = g_t... | gzipped_file_get_content | gretl-2021d | sci-mathematics | O0/sci-mathematics/gretl-2021d/libgretl-1.0.so.40.0.0 | ida | O0 |
const char *hac_lag_string() {
check_for_state();
if (state->user_hac_lag > 0x7Eu)
return ahl_strs[state->auto_hac_lag];
sprintf(lagstr_3, "%d", state->user_hac_lag);
return lagstr_3;
} | static const char *hac_lag_string(void) {
check_for_state();
if (state->user_hac_lag >= 0 && state->user_hac_lag < 127) {
static char lagstr[6];
sprintf(lagstr, "%d", state->user_hac_lag);
return lagstr;
} else {
return ahl_strs[state->auto_hac_lag];
}
} | hac_lag_string | gretl-2021d | sci-mathematics | O0/sci-mathematics/gretl-2021d/libgretl-1.0.so.40.0.0 | ida | O0 |
int hac_recolor(gretl_matrix *XOX, gretl_matrix *A) {
double v2;
int err;
int i;
int j;
int k;
gretl_matrix *S;
double aij;
k = XOX->rows;
err = 0;
S = gretl_matrix_alloc(XOX->rows, XOX->rows);
if (!S)
err = 12;
if (!err) {
for (i = 0; i < k; ++i) {
for (j = 0; j < k; ++j) {
... | static int hac_recolor(gretl_matrix *XOX, gretl_matrix *A) {
gretl_matrix *S;
int k = XOX->rows;
int err = 0;
S = gretl_matrix_alloc(k, k);
if (S == NULL) {
err = E_ALLOC;
}
if (!err) {
double aij;
int i, j;
for (i = 0; i < k; i++) {
for (j = 0; j < k; j++) {
aij = gretl_m... | hac_recolor | gretl-2021d | sci-mathematics | O0/sci-mathematics/gretl-2021d/libgretl-1.0.so.40.0.0 | ida | O0 |
void hac_vcv_line(const VCVInfo *vi, PRN *prn) {
double bw;
char *v3;
unsigned int order;
char *v5;
char *v6;
char *v7;
const char *kstrs[3];
unsigned long v9;
v9 = __readfsqword(0x28u);
kstrs[0] = "Bartlett kernel";
kstrs[1] = "Parzen kernel";
kstrs[2] = "QS kernel";
if (vi->vmin == 2) {
... | static void hac_vcv_line(const VCVInfo *vi, PRN *prn) {
const char *kstrs[] = {N_("Bartlett kernel"), N_("Parzen kernel"),
N_("QS kernel")};
if (vi->vmin == KERNEL_QS) {
pprintf(prn,
_("HAC standard errors, "
"bandwidth %.2f"),
vi->bw);
} else {
... | hac_vcv_line | gretl-2021d | sci-mathematics | O0/sci-mathematics/gretl-2021d/libgretl-1.0.so.40.0.0 | ida | O0 |
double hac_weight(int kern, int h, int i) {
double v3;
double ai;
ai = fabs((double)i) / ((double)h + 1.0);
if (kern != 1)
return 1.0 - ai;
if (ai <= 0.5)
return pow(ai, 3.0) * 6.0 + 1.0 - 6.0 * ai * ai;
v3 = pow(1.0 - ai, 3.0);
return v3 + v3;
} | double hac_weight(int kern, int h, int i) {
double ai = fabs((double)i) / (h + 1.0);
double w;
if (kern == KERNEL_PARZEN) {
if (ai <= 0.5) {
w = 1.0 - 6 * ai * ai + 6 * pow(ai, 3.0);
} else {
w = 2.0 * pow(1.0 - ai, 3.0);
}
} else {
w = 1.0 - ai;
}
return w;
} | hac_weight | gretl-2021d | sci-mathematics | O0/sci-mathematics/gretl-2021d/libgretl-1.0.so.40.0.0 | ida | O0 |
double halton(int i, int base) {
double f;
double h;
f = 1.0 / (double)base;
h = 0.0;
while (i > 0) {
h = (double)(i % base) * f + h;
i = (int)(double)(i / base);
f = f / (double)base;
}
return h;
} | static double halton(int i, int base) {
double f = 1.0 / base;
double h = 0.0;
while (i > 0) {
h += f * (i % base);
i = floor(i / base);
f /= base;
}
return h;
} | halton | gretl-2021d | sci-mathematics | O0/sci-mathematics/gretl-2021d/libgretl-1.0.so.40.0.0 | ida | O0 |
gretl_matrix *halton_matrix(int m, int r, int offset, int *err) {
int v5;
int i;
int j;
int k;
gretl_matrix *H;
double hij;
int bases[42];
unsigned long v14;
v14 = __readfsqword(0x28u);
bases[0] = 2;
bases[1] = 3;
bases[2] = 5;
bases[3] = 7;
bases[4] = 11;
bases[5] = 13;
bases[6] = 17;
... | gretl_matrix *halton_matrix(int m, int r, int offset, int *err) {
const int bases[] = {2, 3, 5, 7, 11, 13, 17, 19, 23, 29, 31,
37, 41, 43, 47, 53, 59, 61, 67, 71, 73, 79,
83, 89, 97, 101, 103, 107, 109, 113, 127, 131, 137,
... | halton_matrix | gretl-2021d | sci-mathematics | O0/sci-mathematics/gretl-2021d/libgretl-1.0.so.40.0.0 | ida | O0 |
int handle_array_return(fncall *call, void *ptr, int copy) {
int err;
gretl_array *ret;
const char *name;
gretl_array *a;
unsigned long v8;
v8 = __readfsqword(0x28u);
name = call->retname;
ret = 0;
err = 0;
if (copy) {
a = get_array_by_name(name);
if (a)
ret = gretl_array_copy(a, &err... | static int handle_array_return(fncall *call, void *ptr, int copy) {
const char *name = call->retname;
gretl_array *ret = NULL;
int err = 0;
if (copy) {
gretl_array *a = get_array_by_name(name);
if (a != NULL) {
ret = gretl_array_copy(a, &err);
}
} else {
ret = gretl_array_pull_from_sta... | handle_array_return | gretl-2021d | sci-mathematics | O0/sci-mathematics/gretl-2021d/libgretl-1.0.so.40.0.0 | ida | O0 |
int handle_bundle_return(fncall *call, void *ptr, int copy) {
int err;
gretl_bundle *ret;
const char *name;
gretl_bundle *b;
unsigned long v8;
v8 = __readfsqword(0x28u);
name = call->retname;
ret = 0;
err = 0;
if (copy) {
b = get_bundle_by_name(name);
if (b)
ret = gretl_bundle_copy(b,... | static int handle_bundle_return(fncall *call, void *ptr, int copy) {
const char *name = call->retname;
gretl_bundle *ret = NULL;
int err = 0;
if (copy) {
gretl_bundle *b = get_bundle_by_name(name);
if (b != NULL) {
ret = gretl_bundle_copy(b, &err);
}
} else {
ret = gretl_bundle_pull_fr... | handle_bundle_return | gretl-2021d | sci-mathematics | O0/sci-mathematics/gretl-2021d/libgretl-1.0.so.40.0.0 | ida | O0 |
void handle_corrgm_plot_options(int ci, gretlopt opt, int *ascii, int *gp) {
const char *s;
if ((opt & 0x10000) != 0) {
*gp = 0;
*ascii = *gp;
} else if ((opt & 0x100000) != 0 && (s = get_optval_string(ci, OPT_U)) != 0) {
if (!strcmp(s, "none")) {
*gp = 0;
*ascii = *gp;
} else if (!st... | static void handle_corrgm_plot_options(int ci, gretlopt opt, int *ascii,
int *gp) {
if (opt & OPT_Q) {
*ascii = *gp = 0;
return;
}
if (opt & OPT_U) {
const char *s = get_optval_string(ci, OPT_U);
if (s != NULL) {
if (!strcmp(s, "none")) {
*... | handle_corrgm_plot_options | gretl-2021d | sci-mathematics | O0/sci-mathematics/gretl-2021d/libgretl-1.0.so.40.0.0 | ida | O0 |
int handle_excess_precision(int *ymd1, int *ymd2, int pd, char *obs1,
char *obs2) {
int err;
int m1_0;
int m2_0;
int m1;
int m2;
err = 0;
if (ymd1[2] != 1 || ymd2[2] != 1)
return 17;
*obs2 = 0;
*obs1 = *obs2;
if (pd == 1) {
if (ymd1[1] == 1 && ymd1[2] == 1) {
... | static int handle_excess_precision(int *ymd1, int *ymd2, int pd, char *obs1,
char *obs2) {
int err = 0;
if (ymd1[2] != 1 || ymd2[2] != 1) {
return E_INVARG;
}
*obs1 = *obs2 = '\0';
if (pd == 1) {
if (ymd1[1] != 1 || ymd1[2] != 1) {
err = E_INVARG;
} el... | handle_excess_precision | gretl-2021d | sci-mathematics | O0/sci-mathematics/gretl-2021d/libgretl-1.0.so.40.0.0 | ida | O0 |
int handle_gdt_selection(const char *fname, DATASET *dset, gretlopt opt,
PRN *prn) {
int n_ok;
int n_sel;
int err;
int i;
int j;
int k;
char **S_sel;
char **S_ok;
const char *s;
int *list;
unsigned long v17;
v17 = __readfsqword(0x28u);
s = get_optval_string(90, OPT_E)... | static int handle_gdt_selection(const char *fname, DATASET *dset, gretlopt opt,
PRN *prn) {
const char *s = get_optval_string(OPEN, OPT_E);
char **S_sel = NULL;
char **S_ok = NULL;
int n_ok, n_sel = 0;
int err = 0;
if (s == NULL || *s == '\0') {
return E_BADOPT;
}
e... | handle_gdt_selection | gretl-2021d | sci-mathematics | O0/sci-mathematics/gretl-2021d/libgretl-1.0.so.40.0.0 | ida | O0 |
int handle_join_varname(csvdata *c, int k, int *pj) {
int ka;
int matched;
int i;
int j;
const char *colname;
char okname[40];
unsigned long v11;
ka = k;
v11 = __readfsqword(0x28u);
matched = 0;
j = *pj;
if ((c->flags & 0x30) == 0)
ka = k + 1;
if ((c->flags & 0x4000) != 0)
sprintf(okn... | static int handle_join_varname(csvdata *c, int k, int *pj) {
const char *colname;
char okname[VNAMELEN];
int matched = 0;
int i, j = *pj;
if (!csv_skip_col_1(c)) {
k++;
}
if (csv_no_header(c)) {
sprintf(okname, "col%d", k);
} else {
gretl_normalize_varname(okname, c->str, 0, k);
}
#if ... | handle_join_varname | gretl-2021d | sci-mathematics | O0/sci-mathematics/gretl-2021d/libgretl-1.0.so.40.0.0 | ida | O0 |
void handle_lpnext(const char *s, parser *p, int have_dset) {
int vnum;
ufunc *u;
u = get_user_function_by_name(s);
vnum = -1;
if (have_dset)
vnum = current_series_index(p->dset, s);
if (u || vnum < 0) {
if (u && vnum < 0) {
p->sym = 88;
} else if (u) {
if (gretl_function_depth() <=... | static void handle_lpnext(const char *s, parser *p, int have_dset) {
ufunc *u = get_user_function_by_name(s);
int vnum = -1;
if (have_dset) {
vnum = current_series_index(p->dset, s);
}
if (u == NULL && vnum >= 0) {
p->sym = SERIES;
} else if (u != NULL && vnum < 0) {
p->sym = UFUN;
} else ... | handle_lpnext | gretl-2021d | sci-mathematics | O0/sci-mathematics/gretl-2021d/libgretl-1.0.so.40.0.0 | ida | O0 |
int handle_matrix_return(const char *name, void *ptr, int copy) {
int err;
gretl_matrix *ret;
const gretl_matrix *m;
ret = 0;
err = 0;
if (copy) {
m = get_matrix_by_name(name);
if (m) {
ret = gretl_matrix_copy(m);
if (!ret)
err = 12;
}
} else {
ret = steal_matrix_by_na... | static int handle_matrix_return(const char *name, void *ptr, int copy) {
gretl_matrix *ret = NULL;
int err = 0;
if (copy) {
gretl_matrix *m = get_matrix_by_name(name);
if (m != NULL) {
ret = gretl_matrix_copy(m);
if (ret == NULL) {
err = E_ALLOC;
}
}
} else {
ret = st... | handle_matrix_return | gretl-2021d | sci-mathematics | O0/sci-mathematics/gretl-2021d/libgretl-1.0.so.40.0.0 | ida | O0 |
void handle_midas_setup(joiner *jr, int i, int lv, int rv, int revseq) {
char label[136];
unsigned long v9;
v9 = __readfsqword(0x28u);
series_set_midas_period(jr->l_dset, lv, revseq);
sprintf(label, "%s in sub-period %d", jr->r_dset->varname[rv], revseq);
series_record_label(jr->l_dset, lv, label);
serie... | static void handle_midas_setup(joiner *jr, int i, int lv, int rv, int revseq) {
char label[MAXLABEL];
series_set_midas_period(jr->l_dset, lv, revseq);
sprintf(label, "%s in sub-period %d", jr->r_dset->varname[rv], revseq);
series_record_label(jr->l_dset, lv, label);
series_set_midas_freq(jr->l_dset, lv, jr->... | handle_midas_setup | gretl-2021d | sci-mathematics | O0/sci-mathematics/gretl-2021d/libgretl-1.0.so.40.0.0 | ida | O0 |
void handle_optional_string(char **ps, const char *src) {
if (src)
*ps = (char *)g_strdup(src);
else
*ps = 0;
} | static void handle_optional_string(char **ps, const char *src) {
if (src == NULL) {
*ps = NULL;
} else {
*ps = g_strdup(src);
}
} | handle_optional_string | gretl-2021d | sci-mathematics | O0/sci-mathematics/gretl-2021d/libgretl-1.0.so.40.0.0 | ida | O0 |
int handle_outbuf_content(FILE *fp, fpinfo *fi) {
int err;
char *buf;
user_var *uv;
signed long pos;
err = 0;
uv = get_user_var_of_type_by_name(fi->strvar, GRETL_TYPE_STRING);
if (!uv)
return 2;
fflush(fp);
fseek(fp, 0, 2);
pos = ftell(fp);
if (pos <= 0) {
buf = gretl_strdup(&byte_33E07B)... | static int handle_outbuf_content(FILE *fp, fpinfo *fi) {
user_var *uv;
int err = 0;
uv = get_user_var_of_type_by_name(fi->strvar, GRETL_TYPE_STRING);
if (uv == NULL) {
err = E_DATA;
} else {
char *buf = NULL;
long pos;
size_t len;
fflush(fp);
fseek(fp, 0, SEEK_END);
pos = ftell(f... | handle_outbuf_content | gretl-2021d | sci-mathematics | O0/sci-mathematics/gretl-2021d/libgretl-1.0.so.40.0.0 | ida | O0 |
void handle_palette(gretl_bundle *opts, const gretl_matrix *zrange,
int na_action, FILE *fp) {
double *zlim;
const char *p;
zlim = zrange->val;
p = gretl_bundle_get_string(opts, "palette", 0);
if (na_action == 2) {
tricky_print_palette(p, zlim, fp);
} else {
if (p)
simple_... | static void handle_palette(gretl_bundle *opts, const gretl_matrix *zrange,
int na_action, FILE *fp) {
const double *zlim = zrange->val;
const char *p;
p = gretl_bundle_get_string(opts, "palette", NULL);
if (na_action == NA_FILL) {
tricky_print_palette(p, zlim, fp);
return;
... | handle_palette | gretl-2021d | sci-mathematics | O0/sci-mathematics/gretl-2021d/libgretl-1.0.so.40.0.0 | ida | O0 |
int handle_plugin_call(fncall *call, DATASET *dset, void *retval, PRN *prn) {
long v5;
int v6;
int err;
GretlType type;
int i;
int size;
void *handle;
double size_0;
double *px;
ufunc *u;
int (*cfunc)(gretl_bundle *, PRN *);
gretl_bundle *argb;
fn_param *fp;
fn_arg *arg;
const char *key;
... | static int handle_plugin_call(fncall *call, DATASET *dset, void *retval,
PRN *prn) {
ufunc *u = call->fun;
int (*cfunc)(gretl_bundle *, PRN *);
void *handle;
gretl_bundle *argb;
int i, err = 0;
#if CDEBUG
fprintf(stderr, "handle_plugin_call: function '%s'\n", u->name);
#endif
... | handle_plugin_call | gretl-2021d | sci-mathematics | O0/sci-mathematics/gretl-2021d/libgretl-1.0.so.40.0.0 | ida | O0 |
int handle_prog_command(LOOPSET *loop, int j, CMD *cmd, int *err) {
int v4;
int v5;
const char *v6;
char *v7;
int handled;
handled = 0;
if (cmd->ci != 100 || (loop->cmds[j].flags & 2) != 0) {
if (cmd->ci == 128) {
if ((loop->cmds[j].flags & 0x40) != 0)
v5 = loop_store_update(loop, j, 0,... | static int handle_prog_command(LOOPSET *loop, int j, CMD *cmd, int *err) {
int handled = 0;
if (cmd->ci == PRINT && !loop_literal(loop, j)) {
if (prog_cmd_started(loop, j)) {
*err = loop_print_update(loop, j, NULL);
} else {
*err = loop_print_update(loop, j, cmd->parm2);
}
handled = 1;
... | handle_prog_command | gretl-2021d | sci-mathematics | O0/sci-mathematics/gretl-2021d/libgretl-1.0.so.40.0.0 | ida | O0 |
int handle_return_statement(fncall *call, ExecState *state, DATASET *dset,
int lineno) {
int err;
int len;
char *sa;
const char *s;
ufunc *fun;
char formula[65544];
unsigned long v13;
v13 = __readfsqword(0x28u);
sa = state->line + 6;
fun = call->fun;
err = 0;
s = &sa... | static int handle_return_statement(fncall *call, ExecState *state,
DATASET *dset, int lineno) {
const char *s = state->line + 6;
ufunc *fun = call->fun;
int err = 0;
s += strspn(s, " ");
#if EXEC_DEBUG
fprintf(stderr, "%s: return: s = '%s'\n", fun->name, s);
#endif
if (... | handle_return_statement | gretl-2021d | sci-mathematics | O0/sci-mathematics/gretl-2021d/libgretl-1.0.so.40.0.0 | ida | O0 |
int handle_scalar_return(fncall *call, void *ptr, int rtype) {
const char *name;
int err;
char *vname;
gretl_matrix *m;
vname = call->retname;
err = 0;
if (gretl_is_scalar(vname)) {
xret_0 = gretl_scalar_get_value(vname, 0);
} else {
m = get_matrix_by_name(vname);
if (m && !m->is_complex &&... | static int handle_scalar_return(fncall *call, void *ptr, int rtype) {
static double xret;
const char *vname = call->retname;
int err = 0;
if (gretl_is_scalar(vname)) {
xret = gretl_scalar_get_value(vname, NULL);
} else {
gretl_matrix *m = get_matrix_by_name(vname);
if (gretl_matrix_is_scalar(m))... | handle_scalar_return | gretl-2021d | sci-mathematics | O0/sci-mathematics/gretl-2021d/libgretl-1.0.so.40.0.0 | ida | O0 |
int handle_series_return(const char *vname, void *ptr, DATASET *dset, int copy,
char **label) {
char *v5;
int copya;
_BOOL4 copyb;
int err;
int v;
double *x;
const char *vstr;
v = series_index(dset, vname);
x = 0;
err = 0;
copyb = __PAIR64__(v, 0) == copya;
if (v < 0 ||... | static int handle_series_return(const char *vname, void *ptr, DATASET *dset,
int copy, char **label) {
int v = series_index(dset, vname);
double *x = NULL;
int err = 0;
if (!copy && v == 0) {
copy = 1;
}
if (v >= 0 && v < dset->v) {
if (copy) {
x = copyvec(dse... | handle_series_return | gretl-2021d | sci-mathematics | O0/sci-mathematics/gretl-2021d/libgretl-1.0.so.40.0.0 | ida | O0 |
int handle_string_return(const char *sname, void *ptr) {
int err;
char *ret;
char *s;
s = get_string_by_name(sname);
ret = 0;
err = 0;
if (s) {
ret = gretl_strdup(s);
if (!ret)
err = 12;
} else {
err = 2;
}
*(_QWORD *)ptr = ret;
return err;
} | static int handle_string_return(const char *sname, void *ptr) {
const char *s = get_string_by_name(sname);
char *ret = NULL;
int err = 0;
if (s == NULL) {
err = E_DATA;
} else {
ret = gretl_strdup(s);
if (ret == NULL) {
err = E_ALLOC;
}
}
*(char **)ptr = ret;
return err;
} | handle_string_return | gretl-2021d | sci-mathematics | O0/sci-mathematics/gretl-2021d/libgretl-1.0.so.40.0.0 | ida | O0 |
int handle_test_down_option(adf_info *ainfo, gretlopt opt, int *err) {
char *v3;
int kmethod;
const char *s;
kmethod = 0;
if ((ainfo->flags & 3) != 0)
s = get_optval_string(17, OPT_E);
else
s = get_optval_string(2, OPT_E);
if (s && *s) {
if (!strcmp(s, "MAIC") || !strcmp(s, "AIC")) {
km... | static int handle_test_down_option(adf_info *ainfo, gretlopt opt, int *err) {
int kmethod = 0;
const char *s;
if (ainfo->flags & (ADF_EG_TEST | ADF_EG_RESIDS)) {
s = get_optval_string(COINT, OPT_E);
} else {
s = get_optval_string(ADF, OPT_E);
}
if (s == NULL || *s == '\0') {
kmethod = k_AIC;
... | handle_test_down_option | gretl-2021d | sci-mathematics | O0/sci-mathematics/gretl-2021d/libgretl-1.0.so.40.0.0 | ida | O0 |
int handle_ts_restrict(char *mask, DATASET *dset, gretlopt opt, int t1) {
int pd;
int err;
double sd0;
char stobs[24];
unsigned long v10;
v10 = __readfsqword(0x28u);
pd = dset->pd;
ntolabel(stobs, t1, dset);
sd0 = get_date_x(dset->pd, stobs);
err = restrict_sample_from_mask(mask, dset, opt);
if (... | static int handle_ts_restrict(char *mask, DATASET *dset, gretlopt opt, int t1) {
char stobs[OBSLEN];
int pd = dset->pd;
double sd0;
int err;
ntolabel(stobs, t1, dset);
sd0 = get_date_x(dset->pd, stobs);
err = restrict_sample_from_mask(mask, dset, opt);
if (!err) {
dset->structure = TIME_SERIES;
... | handle_ts_restrict | gretl-2021d | sci-mathematics | O0/sci-mathematics/gretl-2021d/libgretl-1.0.so.40.0.0 | ida | O0 |
void handle_use_cwd(int use_cwd, ConfigPaths *cpaths) {
gchar *cwd;
libset_set_bool(USE_CWD, use_cwd);
if (use_cwd) {
cwd = (gchar *)g_get_current_dir();
if (cwd) {
cpaths->workdir[0] = 0;
strncat(cpaths->workdir, cwd, 0x1FEu);
slash_terminate(cpaths->workdir);
g_free(cwd);
}
... | static void handle_use_cwd(int use_cwd, ConfigPaths *cpaths) {
libset_set_bool(USE_CWD, use_cwd);
if (use_cwd) {
gchar *cwd = g_get_current_dir();
if (cwd != NULL) {
*cpaths->workdir = '\0';
strncat(cpaths->workdir, cwd, MAXLEN - 2);
slash_terminate(cpaths->workdir);
g_free(cwd);
... | handle_use_cwd | gretl-2021d | sci-mathematics | O0/sci-mathematics/gretl-2021d/libgretl-1.0.so.40.0.0 | ida | O0 |
int handle_vector_exclusion(const gretl_vector *s, int n, int **pslice) {
int rows;
char *v4;
int v6;
int i;
int ia;
int ib;
int j;
int ja;
int nsel;
int err;
int excluded;
int k_0;
int slen;
int k;
int *slice;
if (s) {
if (s->cols == 1) {
rows = s->rows;
} else if (s->row... | static int handle_vector_exclusion(const gretl_vector *s, int n, int **pslice) {
int slen = gretl_vector_get_length(s);
int i, j, k, nsel = n;
int err = 0;
for (i = 0; i < slen; i++) {
k = (int)fabs(s->val[i]);
if (k > n) {
gretl_errmsg_sprintf(_("Index value %d is out of bounds"), k);
retu... | handle_vector_exclusion | gretl-2021d | sci-mathematics | O0/sci-mathematics/gretl-2021d/libgretl-1.0.so.40.0.0 | ida | O0 |
int handle_zip_error(const char *fname, GError *gerr, int err,
const char *action) {
if (gerr) {
fprintf(stderr, "handle_zip_error: '%s'\n", gerr->message);
gretl_errmsg_sprintf("%s: %s", fname, gerr->message);
g_error_free(gerr);
} else if (err) {
gretl_errmsg_sprintf("%s: erro... | static int handle_zip_error(const char *fname, GError *gerr, int err,
const char *action) {
if (gerr != NULL) {
fprintf(stderr, "handle_zip_error: '%s'\n", gerr->message);
gretl_errmsg_sprintf("%s: %s", fname, gerr->message);
g_error_free(gerr);
} else if (err) {
gretl_er... | handle_zip_error | gretl-2021d | sci-mathematics | O0/sci-mathematics/gretl-2021d/libgretl-1.0.so.40.0.0 | ida | O0 |
int has_depvar_lags(MODEL *pmod, const DATASET *dset) {
int i;
int vi;
const int *xlist;
const char *yname;
const char *parent;
xlist = model_xlist(pmod);
if (!xlist)
return 0;
yname = gretl_model_get_depvar_name(pmod, dset);
for (i = 1; i <= *xlist; ++i) {
vi = xlist[i];
if (series_get_l... | static int has_depvar_lags(MODEL *pmod, const DATASET *dset) {
const char *yname, *parent;
const int *xlist;
int i, vi;
xlist = model_xlist(pmod);
if (xlist == NULL) {
return 0;
}
yname = gretl_model_get_depvar_name(pmod, dset);
for (i = 1; i <= xlist[0]; i++) {
vi = xlist[i];
if (series_... | has_depvar_lags | gretl-2021d | sci-mathematics | O0/sci-mathematics/gretl-2021d/libgretl-1.0.so.40.0.0 | ida | O0 |
int has_mean(PLOTGROUP *grp) {
int i;
BOXPLOT *plt;
for (i = 0; i < grp->nplots; ++i) {
plt = &grp->plots[i];
if (fabs(plt->mean) > 1.797693134862316e308 && plt->n == 1)
plt->mean = plt->min;
if (fabs(plt->mean) <= 1.797693134862316e308)
return 1;
}
return 0;
} | static int has_mean(PLOTGROUP *grp) {
BOXPLOT *plt;
int i;
for (i = 0; i < grp->nplots; i++) {
plt = &grp->plots[i];
if (na(plt->mean)) {
if (plt->n == 1) {
plt->mean = plt->min;
}
}
if (!na(plt->mean)) {
return 1;
}
}
return 0;
} | has_mean | gretl-2021d | sci-mathematics | O0/sci-mathematics/gretl-2021d/libgretl-1.0.so.40.0.0 | ida | O0 |
int has_native_suffix(const char *fname) {
return has_suffix(fname, ".gdt") || has_suffix(fname, ".gdtb");
} | static int has_native_suffix(const char *fname) {
return has_suffix(fname, ".gdt") || has_suffix(fname, ".gdtb");
} | has_native_suffix | gretl-2021d | sci-mathematics | O0/sci-mathematics/gretl-2021d/libgretl-1.0.so.40.0.0 | ida | O0 |
int has_param(const CMD *cmd) { return cmd->param && *cmd->param; } | static int has_param(const CMD *cmd) {
return cmd->param != NULL && *cmd->param != '\0';
} | has_param | gretl-2021d | sci-mathematics | O0/sci-mathematics/gretl-2021d/libgretl-1.0.so.40.0.0 | ida | O0 |
int has_raw_underscores(const char *s) {
int i;
int n;
n = 0;
for (i = 0; s[i]; ++i) {
if (s[i] == 95 && (!i || s[i - 1] != 92))
++n;
}
return n;
} | static int has_raw_underscores(const char *s) {
int i, n = 0;
for (i = 0; s[i] != '\0'; i++) {
if (s[i] == '_' && (i == 0 || s[i - 1] != '\\')) {
n++;
}
}
return n;
} | has_raw_underscores | gretl-2021d | sci-mathematics | O0/sci-mathematics/gretl-2021d/libgretl-1.0.so.40.0.0 | ida | O0 |
int has_real_exog_regressors(MODEL *pmod, const int *dvlags,
const DATASET *dset) {
int i;
int ret;
int xi;
const int *xlist;
xlist = model_xlist(pmod);
ret = 0;
if (xlist) {
for (i = 0; i < *xlist; ++i) {
xi = xlist[i + 1];
if (xi && (!dvlags || !dvlags[i]) &... | static int has_real_exog_regressors(MODEL *pmod, const int *dvlags,
const DATASET *dset) {
const int *xlist = model_xlist(pmod);
int i, xi, ret = 0;
if (xlist != NULL) {
for (i = 0; i < xlist[0]; i++) {
xi = xlist[i + 1];
if (xi != 0 && (dvlags == NULL || dvlag... | has_real_exog_regressors | gretl-2021d | sci-mathematics | O0/sci-mathematics/gretl-2021d/libgretl-1.0.so.40.0.0 | ida | O0 |
int has_system_prefix(const char *fname, SearchType stype) {
int ret;
int n;
const char *gretldir;
gretldir = gretl_home();
n = strlen(gretldir);
ret = 0;
if (strlen(fname) < n)
return 0;
if (!strncmp(fname, gretldir, n)) {
if (stype || strncmp(&fname[n], "data", 4u)) {
if (stype == SCRIP... | int has_system_prefix(const char *fname, SearchType stype) {
const char *gretldir = gretl_home();
int n = strlen(gretldir);
int ret = 0;
if (strlen(fname) < n) {
return 0;
}
if (!strncmp(fname, gretldir, n)) {
if (stype == DATA_SEARCH && !strncmp(fname + n, "data", 4)) {
ret = 1;
} else ... | has_system_prefix | gretl-2021d | sci-mathematics | O0/sci-mathematics/gretl-2021d/libgretl-1.0.so.40.0.0 | ida | O0 |
int hatvars(MODEL *pmod, const DATASET *dset) {
int i;
int t;
int yno;
double x;
double xa;
yno = pmod->list[1];
for (t = pmod->t1; t <= pmod->t2; ++t) {
if (!model_missing(pmod, t)) {
pmod->yhat[t] = 0.0;
for (i = 0; i < pmod->ncoeff; ++i) {
x = dset->Z[pmod->list[i + 2]][t];
... | static int hatvars(MODEL *pmod, const DATASET *dset) {
int yno = pmod->list[1];
int xno, i, t;
double x;
for (t = pmod->t1; t <= pmod->t2; t++) {
if (model_missing(pmod, t)) {
continue;
}
pmod->yhat[t] = 0.0;
for (i = 0; i < pmod->ncoeff; i++) {
xno = pmod->list[i + 2];
x = ds... | hatvars | gretl-2021d | sci-mathematics | O0/sci-mathematics/gretl-2021d/libgretl-1.0.so.40.0.0 | ida | O0 |
int hausman_move_uhat(MODEL *pmod, panelmod_t *pan) {
int v3;
int i;
int s;
int t;
int ti;
int n;
int Ti;
double *uhat;
n = pan->pooled->full_n;
uhat = (double *)malloc(8LL * n);
if (!uhat)
return 12;
for (t = 0; t < n; ++t)
uhat[t] = NAN;
s = 0;
for (i = 0; i < pan->nunits; ++i) {
... | static int hausman_move_uhat(MODEL *pmod, panelmod_t *pan) {
int n = pan->pooled->full_n;
double *uhat;
int i, s, t, ti;
uhat = malloc(n * sizeof *uhat);
if (uhat == NULL) {
return E_ALLOC;
}
for (t = 0; t < n; t++) {
uhat[t] = NADBL;
}
s = 0;
for (i = 0; i < pan->nunits; i++) {
int T... | hausman_move_uhat | gretl-2021d | sci-mathematics | O0/sci-mathematics/gretl-2021d/libgretl-1.0.so.40.0.0 | ida | O0 |
double hausman_regression_result(panelmod_t *pan, const int *relist,
const int *hlist, DATASET *rset, PRN *prn) {
MODEL v6;
PRN *prna;
DATASET *rseta;
const int *hlista;
const int *relista;
panelmod_t *pana;
int err;
double ret;
int *biglist;
MODEL hmod;
unsigned l... | static double hausman_regression_result(panelmod_t *pan, const int *relist,
const int *hlist, DATASET *rset,
PRN *prn) {
double ret = NADBL;
int *biglist = NULL;
int err = 0;
biglist = gretl_list_add(relist, hlist, &err);
if (bi... | hausman_regression_result | gretl-2021d | sci-mathematics | O0/sci-mathematics/gretl-2021d/libgretl-1.0.so.40.0.0 | ida | O0 |
void hc_vcv_line(const VCVInfo *vi, PRN *prn) {
const char *v2;
const char *v3;
char *v4;
char *v5;
int hcv;
int jack;
hcv = vi->vmin;
jack = 0;
if (hcv == 4) {
jack = 1;
hcv = 3;
}
if (jack)
v2 = " (jackknife)";
else
v2 = (const char *)&unk_3438AC;
if (jack)
v3 = (const c... | static void hc_vcv_line(const VCVInfo *vi, PRN *prn) {
int hcv = vi->vmin;
int jack = 0;
if (vi->vmin == 4) {
jack = 1;
hcv--;
}
pprintf(prn, "%s, %s%sHC%d%s", _("Heteroskedasticity-robust standard errors"),
(jack) ? "" : _("variant"), (jack) ? "" : " ", hcv,
(jack) ? " (jackknif... | hc_vcv_line | gretl-2021d | sci-mathematics | O0/sci-mathematics/gretl-2021d/libgretl-1.0.so.40.0.0 | ida | O0 |
MODEL *heckit_model(MODEL *__return_ptr retstr, const int *list, DATASET *dset,
gretlopt opt, PRN *prn) {
_BYTE v6[376];
PRN *prna;
gretlopt opta;
DATASET *dseta;
const int *lista;
MODEL *v11;
MODEL (*heckit_estimate)(const int *, DATASET *, gretlopt, PRN *);
MODEL model;
unsigned ... | MODEL heckit_model(const int *list, DATASET *dset, gretlopt opt, PRN *prn) {
MODEL model;
MODEL (*heckit_estimate)(const int *, DATASET *, gretlopt, PRN *);
gretl_error_clear();
heckit_estimate = get_plugin_function("heckit_estimate");
if (heckit_estimate == NULL) {
gretl_model_init(&model, dset);
m... | heckit_model | gretl-2021d | sci-mathematics | O0/sci-mathematics/gretl-2021d/libgretl-1.0.so.40.0.0 | ida | O0 |
const char *heckit_selvar_name(const MODEL *pmod, const DATASET *dset) {
int pos;
int *list;
list = pmod->list;
pos = gretl_list_separator_position(list);
if (pos <= 0 || pos >= *list || list[pos + 1] >= dset->v)
return 0;
else
return dset->varname[list[pos + 1]];
} | static const char *heckit_selvar_name(const MODEL *pmod, const DATASET *dset) {
const int *list = pmod->list;
int pos = gretl_list_separator_position(list);
if (pos > 0 && pos < list[0] && list[pos + 1] < dset->v) {
return dset->varname[list[pos + 1]];
} else {
return NULL;
}
} | heckit_selvar_name | gretl-2021d | sci-mathematics | O0/sci-mathematics/gretl-2021d/libgretl-1.0.so.40.0.0 | ida | O0 |
const char *helpfile_path(int id, int cli, int en) {
char *v3;
size_t v4;
char *v5;
int i;
i = -1;
hpath_4[0] = 0;
if (!id && force_en_cmdref || id == 1 && force_en_fnref)
en = 1;
if (cli) {
if (id) {
if (id == 1)
i = 3;
} else {
i = 0;
}
} else if (id) {
if (i... | const char *helpfile_path(int id, int cli, int en) {
static char hpath[MAXLEN + 19];
int i = -1;
*hpath = '\0';
if ((id == GRETL_CMDREF && force_en_cmdref) ||
(id == GRETL_FUNCREF && force_en_fnref)) {
en = 1;
}
if (cli) {
if (id == GRETL_CMDREF) {
i = 0;
} else if (id == GRETL_F... | helpfile_path | gretl-2021d | sci-mathematics | O0/sci-mathematics/gretl-2021d/libgretl-1.0.so.40.0.0 | ida | O0 |
int hermite_scale(int n, double *x, double *w, double mu, double sigma) {
int i;
if (fabs(mu) > 1.797693134862316e308 || fabs(sigma) > 1.797693134862316e308 ||
sigma <= 0.0)
return 17;
for (i = 0; i < n; ++i) {
x[i] = x[i] * (sigma * 1.414213562373095) + mu;
w[i] = w[i] / 1.772453850905516;
}... | static int hermite_scale(int n, double *x, double *w, double mu, double sigma) {
double rtpi = sqrt(M_PI);
int i;
if (na(mu) || na(sigma) || sigma <= 0.0) {
return E_INVARG;
}
for (i = 0; i < n; i++) {
x[i] = mu + M_SQRT2 * sigma * x[i];
w[i] /= rtpi;
}
return 0;
} | hermite_scale | gretl-2021d | sci-mathematics | O0/sci-mathematics/gretl-2021d/libgretl-1.0.so.40.0.0 | ida | O0 |
void hess_h_init(double *h, double *h0, int n) { memcpy(h, h0, 8LL * n); } | static void hess_h_init(double *h, double *h0, int n) {
memcpy(h, h0, n * sizeof *h);
} | hess_h_init | gretl-2021d | sci-mathematics | O0/sci-mathematics/gretl-2021d/libgretl-1.0.so.40.0.0 | ida | O0 |
void hess_h_reduce(double *h, double v, int n) {
int i;
for (i = 0; i < n; ++i)
h[i] = h[i] / v;
} | static void hess_h_reduce(double *h, double v, int n) {
int i;
for (i = 0; i < n; i++) {
h[i] /= v;
}
} | hess_h_reduce | gretl-2021d | sci-mathematics | O0/sci-mathematics/gretl-2021d/libgretl-1.0.so.40.0.0 | ida | O0 |
int hess_score_on() { return doing_hess_score; } | int hess_score_on(void) { return doing_hess_score; } | hess_score_on | gretl-2021d | sci-mathematics | O0/sci-mathematics/gretl-2021d/libgretl-1.0.so.40.0.0 | ida | O0 |
int hessian_from_score(double *b, gretl_matrix *H, BFGS_GRAD_FUNC gradfunc,
BFGS_CRIT_FUNC cfunc, void *data) {
int rows;
int extra_precision;
int i;
int j;
int ja;
int jb;
int jc;
int jd;
int err;
int n;
double *g;
double *splus;
double *sminus;
double *splus2;
doub... | int hessian_from_score(double *b, gretl_matrix *H, BFGS_GRAD_FUNC gradfunc,
BFGS_CRIT_FUNC cfunc, void *data) {
double *g, *splus, *sminus, *splus2, *sminus2;
double x, den, b0, eps = 1.0e-05;
int n = gretl_matrix_rows(H);
int extra_precision = 0;
int i, j, err = 0;
char *s = getenv(... | hessian_from_score | gretl-2021d | sci-mathematics | O0/sci-mathematics/gretl-2021d/libgretl-1.0.so.40.0.0 | ida | O0 |
gretl_matrix *hessian_inverse_from_score(double *b, int n,
BFGS_GRAD_FUNC gradfunc,
BFGS_CRIT_FUNC cfunc, void *data,
int *err) {
gretl_matrix *H;
H = gretl_zero_matrix_new(n, n);
if (H)
... | gretl_matrix *hessian_inverse_from_score(double *b, int n,
BFGS_GRAD_FUNC gradfunc,
BFGS_CRIT_FUNC cfunc, void *data,
int *err) {
gretl_matrix *H = gretl_zero_matrix_new(n, n);
if (H == NULL) ... | hessian_inverse_from_score | gretl-2021d | sci-mathematics | O0/sci-mathematics/gretl-2021d/libgretl-1.0.so.40.0.0 | ida | O0 |
int hf_list_diffgenr(int *list, int ci, double parm, DATASET *dset) {
char *v5;
double *val;
int v7;
int v8;
double parma;
int n_add;
int err;
int hfci;
int set_midas;
int i;
int s;
int t;
int vi;
int offset;
int n;
int v0;
gretl_matrix *dX_0;
const char *parent;
char vname[32];
... | int hf_list_diffgenr(int *list, int ci, double parm, DATASET *dset) {
gretl_matrix *dX = NULL;
int n_add, hfci = 0;
int set_midas = 1;
int err = 0;
if (list[0] == 0) {
return 0;
}
if (ci == DIFF) {
hfci = HFDIFF;
} else if (ci == LDIFF) {
hfci = HFLDIFF;
} else {
return E_INVARG;
}... | hf_list_diffgenr | gretl-2021d | sci-mathematics | O0/sci-mathematics/gretl-2021d/libgretl-1.0.so.40.0.0 | ida | O0 |
NODE *hf_list_make_lags(NODE *l, NODE *m, NODE *r, parser *p) {
int lmax;
int cfac;
int lmin;
int *list;
NODE *ret;
unsigned long v12;
v12 = __readfsqword(0x28u);
ret = aux_list_node(p);
if (ret && (p->flags & 2) != 0) {
list = 0;
lmax = 0;
cfac = 0;
lmin = node_get_int(l, p);
if ... | static NODE *hf_list_make_lags(NODE *l, NODE *m, NODE *r, parser *p) {
NODE *ret = aux_list_node(p);
if (ret != NULL && starting(p)) {
int *list = NULL;
int lmin, lmax = 0;
int cfac = 0;
lmin = node_get_int(l, p);
if (!p->err) {
lmax = node_get_int(m, p);
}
if (!p->err) {
l... | hf_list_make_lags | gretl-2021d | sci-mathematics | O0/sci-mathematics/gretl-2021d/libgretl-1.0.so.40.0.0 | ida | O0 |
NODE *hf_list_node(NODE *l, NODE *m, NODE *r, parser *p) {
int rows;
int v5;
int f_ratio;
int n;
NODE *ret;
gretl_matrix *v;
char *pfx;
v = l->v.m;
f_ratio = node_get_int(m, p);
pfx = r->v.str;
ret = 0;
if (!p->err) {
if (v) {
if (v->cols == 1) {
rows = v->rows;
} else i... | static NODE *hf_list_node(NODE *l, NODE *m, NODE *r, parser *p) {
gretl_matrix *v = l->v.m;
int f_ratio = node_get_int(m, p);
char *pfx = r->v.str;
NODE *ret = NULL;
if (!p->err) {
int n = gretl_vector_get_length(v);
if (n == 0) {
p->err = E_NONCONF;
} else if (f_ratio < 3) {
p->err ... | hf_list_node | gretl-2021d | sci-mathematics | O0/sci-mathematics/gretl-2021d/libgretl-1.0.so.40.0.0 | ida | O0 |
int hf_plot(const int *list, const char *literal, const DATASET *dset,
gretlopt opt) {
int v5;
char *v6;
const char *v7;
gretlopt plotopt;
int nv;
int nlf;
int cfac;
int i;
int ia;
int s;
int sa;
int sb;
int t;
int ta;
int plotpd;
int err;
int erra;
int vi;
int *hflist;... | int hf_plot(const int *list, const char *literal, const DATASET *dset,
gretlopt opt) {
DATASET *hset;
double xit;
char stobs[OBSLEN];
int *gplist = NULL;
int *hflist = NULL;
int *lflist = NULL;
gchar *mylit = NULL;
char *p;
gretlopt plotopt = OPT_T;
int plotpd = 0;
int nv, nlf = 0;
i... | hf_plot | gretl-2021d | sci-mathematics | O0/sci-mathematics/gretl-2021d/libgretl-1.0.so.40.0.0 | ida | O0 |
int highest_numbered_var_in_model(const MODEL *pmod, const DATASET *dset) {
int i;
int vmax;
int gotsep;
int v;
int va;
int vb;
int vc;
int vd;
int ve;
vmax = 0;
gotsep = 0;
if (pmod->ci == 78 || pmod->ci == 49 || !pmod->list)
return 0;
for (i = 1; i <= *pmod->list; ++i) {
v = pmod->l... | int highest_numbered_var_in_model(const MODEL *pmod, const DATASET *dset) {
int i, v, vmax = 0;
int gotsep = 0;
if (pmod->ci == MLE || pmod->ci == GMM || pmod->list == NULL) {
return 0;
}
for (i = 1; i <= pmod->list[0]; i++) {
v = pmod->list[i];
if (v == LISTSEP) {
gotsep = 1;
contin... | highest_numbered_var_in_model | gretl-2021d | sci-mathematics | O0/sci-mathematics/gretl-2021d/libgretl-1.0.so.40.0.0 | ida | O0 |
int highest_numbered_var_in_saved_object(const DATASET *dset) {
GretlObjType type;
int i;
int vmax;
int mvm;
void *ptr;
void *lmp;
unsigned long v8;
v8 = __readfsqword(0x28u);
lmp = 0;
vmax = 0;
for (i = -1; i < n_obj; ++i) {
if (i >= 0) {
ptr = ostack[i].ptr;
type = ostack[i].typ... | int highest_numbered_var_in_saved_object(const DATASET *dset) {
GretlObjType type;
void *ptr, *lmp = NULL;
int i, mvm, vmax = 0;
for (i = -1; i < n_obj; i++) {
if (i < 0) {
lmp = ptr = get_last_model(&type);
} else {
ptr = ostack[i].ptr;
type = ostack[i].type;
}
if (ptr == NUL... | highest_numbered_var_in_saved_object | gretl-2021d | sci-mathematics | O0/sci-mathematics/gretl-2021d/libgretl-1.0.so.40.0.0 | ida | O0 |
int highest_numbered_var_in_system(const equation_system *sys,
const DATASET *dset) {
int i;
int j;
int ja;
int vmax;
int v;
vmax = 0;
if (sys->biglist) {
for (j = 1; j <= *sys->biglist; ++j) {
if (sys->biglist[j] > vmax)
vmax = sys->biglist[j];
}
... | int highest_numbered_var_in_system(const equation_system *sys,
const DATASET *dset) {
int i, j, v, vmax = 0;
if (sys->biglist != NULL) {
for (j = 1; j <= sys->biglist[0]; j++) {
v = sys->biglist[j];
if (v > vmax) {
vmax = v;
}
}
} else {
f... | highest_numbered_var_in_system | gretl-2021d | sci-mathematics | O0/sci-mathematics/gretl-2021d/libgretl-1.0.so.40.0.0 | ida | O0 |
void hilu_header(PRN *prn) {
char *v1;
int i;
pputs(prn, "\n ");
for (i = 0; i <= 2; ++i) {
pputs(prn, "rho");
bufspace(10, prn);
v1 = gettext("ESS");
pputs(prn, v1);
if (i <= 1)
pputs(prn, " ");
}
pputc(prn, 10);
} | static void hilu_header(PRN *prn) {
int i;
pputs(prn, "\n ");
for (i = 0; i < 3; i++) {
pputs(prn, "rho");
bufspace(10, prn);
pputs(prn, _("ESS"));
if (i < 2) {
pputs(prn, " ");
}
}
pputc(prn, '\n');
} | hilu_header | gretl-2021d | sci-mathematics | O0/sci-mathematics/gretl-2021d/libgretl-1.0.so.40.0.0 | ida | O0 |
int hilu_plot(double *ssr, double *rho, int n) {
char *v4;
int err;
int i;
FILE *fp;
unsigned long v9;
v9 = __readfsqword(0x28u);
err = 0;
fp = open_plot_input_file(PLOT_REGULAR, (GptFlags)0, &err);
if (err)
return err;
fwrite("# hildreth-lu\n", 1u, 0xEu, fp);
fwrite("set xlabel 'rho'\n", 1u,... | static int hilu_plot(double *ssr, double *rho, int n) {
FILE *fp;
int i, err = 0;
fp = open_plot_input_file(PLOT_REGULAR, 0, &err);
if (err) {
return err;
}
fputs("# hildreth-lu\n", fp);
fputs("set xlabel 'rho'\n", fp);
fprintf(fp, "set ylabel '%s'\n", _("ESS"));
fputs("set nokey\n", fp);
fp... | hilu_plot | gretl-2021d | sci-mathematics | O0/sci-mathematics/gretl-2021d/libgretl-1.0.so.40.0.0 | ida | O0 |
void hilu_print_iter(double r, double ess, int iter, double *ssr, double *rh,
int *ip_0, int asciiplot, PRN *prn) {
int k;
char num[8];
unsigned long v14;
v14 = __readfsqword(0x28u);
sprintf(num, "%.1f", r * 100.0);
k = atoi(num);
if (k == -99 || k == 99 || !(k % 10)) {
if (ascii... | static void hilu_print_iter(double r, double ess, int iter, double *ssr,
double *rh, int *ip, int asciiplot, PRN *prn) {
char num[8];
int k;
sprintf(num, "%.1f", 100 * r);
k = atoi(num);
if (k == -99 || k == 99 || k % 10 == 0) {
if (asciiplot) {
ssr[*ip] = ess;
r... | hilu_print_iter | gretl-2021d | sci-mathematics | O0/sci-mathematics/gretl-2021d/libgretl-1.0.so.40.0.0 | ida | O0 |
double hilu_search(const int *list, DATASET *dset, MODEL *pmod, gretlopt opt,
PRN *prn) {
int v5;
MODEL *v7;
int v8;
MODEL *v9;
MODEL *v10;
char *v11;
MODEL v12;
PRN *prna;
gretlopt opta;
MODEL *pmoda;
DATASET *dseta;
const int *lista;
int i;
int iter;
int nplot;
int q... | static double hilu_search(const int *list, DATASET *dset, MODEL *pmod,
gretlopt opt, PRN *prn) {
double *rh = NULL, *ssr = NULL;
double essmin = 1.0e200;
double ess, r, hl_rho = 0;
int quiet = (opt & OPT_Q);
int niceplot = (opt & OPT_G);
int iter = 0, i = 0;
int nplot = 0;
if ... | hilu_search | gretl-2021d | sci-mathematics | O0/sci-mathematics/gretl-2021d/libgretl-1.0.so.40.0.0 | ida | O0 |
int hp_filter(const double *x, double *hp, const DATASET *dset, double lambda,
gretlopt opt) {
double lambdaa;
double *hpa;
const double *xa;
int t1;
int t2;
int i;
int t;
int err;
int T;
int tb;
double v00;
double v11;
double v01;
double **V;
double e0;
double e1;
double... | int hp_filter(const double *x, double *hp, const DATASET *dset, double lambda,
gretlopt opt) {
int t1 = dset->t1, t2 = dset->t2;
double v00 = 1.0, v11 = 1.0, v01 = 0.0;
double det, tmp0, tmp1;
double e0, e1, b00, b01, b11;
double **V = NULL;
double m[2], tmp[2];
int i, t, T, tb;
int err = ... | hp_filter | gretl-2021d | sci-mathematics | O0/sci-mathematics/gretl-2021d/libgretl-1.0.so.40.0.0 | ida | O0 |
gretl_matrix *hp_gain(double lambda, int hipass) {
double v3;
int i;
double gain;
double omega;
gretl_matrix *G;
omega = 0.0;
G = gretl_matrix_alloc(181, 2);
if (!G)
return 0;
for (i = 0; i <= 180; ++i) {
v3 = sin(omega / 2.0);
gain = 1.0 / (pow(v3 + v3, 4.0) * lambda + 1.0);
if (hipa... | gretl_matrix *hp_gain(double lambda, int hipass) {
gretl_matrix *G;
int i, width = 180;
double inc = M_PI / width;
double x, gain, omega = 0.0;
G = gretl_matrix_alloc(width + 1, 2);
if (G == NULL) {
return NULL;
}
for (i = 0; i <= width; i++) {
x = 2 * sin(omega / 2);
gain = 1 / (1 + lambd... | hp_gain | gretl-2021d | sci-mathematics | O0/sci-mathematics/gretl-2021d/libgretl-1.0.so.40.0.0 | ida | O0 |
int hpsolb_(int *n, double *t, int *iorder, int *iheap) {
int *iordera;
double *ta;
int i__;
int i__a;
int j;
int ja;
int k;
int i__1;
int indxin;
int indxina;
int indxou;
double ddum;
double dduma;
double out;
iordera = iorder - 1;
ta = t - 1;
if (!*iheap) {
i__1 = *n;
for (k... | static int hpsolb_(int *n, double *t, int *iorder, int *iheap) {
int i__1;
int i__, j, k;
double out, ddum;
int indxin, indxou;
--iorder;
--t;
if (*iheap == 0) {
i__1 = *n;
for (k = 2; k <= i__1; ++k) {
ddum = t[k];
indxin = iorder[k];
i__ = k;
L10:
if (i__ > 1) {
... | hpsolb_ | gretl-2021d | sci-mathematics | O0/sci-mathematics/gretl-2021d/libgretl-1.0.so.40.0.0 | ida | O0 |
MODEL *hsk_model(MODEL *__return_ptr retstr, const int *list, DATASET *dset,
gretlopt opt) {
gretlopt v4;
MODEL v6;
gretlopt opta;
DATASET *dseta;
const int *lista;
MODEL *v10;
int i;
int orig_nvar;
int err;
int *hsklist;
MODEL hsk;
unsigned long v16;
v10 = retstr;
lista = ... | MODEL hsk_model(const int *list, DATASET *dset, gretlopt opt) {
int i, err;
int orig_nvar = dset->v;
int *hsklist;
MODEL hsk;
if (dset->Z == NULL) {
hsk.errcode = E_DATA;
return hsk;
}
gretl_error_clear();
hsk = lsq(list, dset, OLS, OPT_A);
if (hsk.errcode) {
return hsk;
}
err = ge... | hsk_model | gretl-2021d | sci-mathematics | O0/sci-mathematics/gretl-2021d/libgretl-1.0.so.40.0.0 | ida | O0 |
int hurstplot(const int *list, DATASET *dset, gretlopt opt, PRN *prn) {
int (*hurst_exponent)(int, const DATASET *, gretlopt, PRN *);
hurst_exponent = (int (*)(int, const DATASET *, gretlopt,
PRN *))get_plugin_function("hurst_exponent");
if (hurst_exponent)
return hurst_exponent(l... | int hurstplot(const int *list, DATASET *dset, gretlopt opt, PRN *prn) {
int (*hurst_exponent)(int, const DATASET *, gretlopt, PRN *);
hurst_exponent = get_plugin_function("hurst_exponent");
if (hurst_exponent == NULL) {
return 1;
}
return hurst_exponent(list[1], dset, opt, prn);
} | hurstplot | gretl-2021d | sci-mathematics | O0/sci-mathematics/gretl-2021d/libgretl-1.0.so.40.0.0 | ida | O0 |
double hy1f1a(double a, double b, double x, double *err) {
double v4;
double v5;
double v6;
double err1;
double err2;
double t;
double u;
double temp;
double acanc;
double asum;
double h1;
double h2;
unsigned long v18;
v18 = __readfsqword(0x28u);
if (x == 0.0) {
acanc = 1.0;
asum ... | static double hy1f1a(double a, double b, double x, double *err) {
double h1, h2, t, u, temp, acanc, asum, err1, err2;
if (x == 0) {
acanc = 1.0;
asum = MAXNUM;
goto adone;
}
temp = log(fabs(x));
t = x + temp * (a - b);
u = -temp * a;
if (b > 0) {
temp = lgam(b);
t += temp;
u += t... | hy1f1a | gretl-2021d | sci-mathematics | O0/sci-mathematics/gretl-2021d/libgretl-1.0.so.40.0.0 | ida | O0 |
double hy1f1p(double a, double b, double x, double *err) {
double n;
double a0;
double sum;
double t;
double maxt;
double pcanc;
double temp;
a0 = 1.0;
sum = 1.0;
n = 1.0;
t = 1.0;
maxt = 0.0;
while (t > MACHEP) {
if (b == 0.0) {
mtherr("hyperg", 2);
return MAXNUM;
}
i... | static double hy1f1p(double a, double b, double x, double *err) {
double n, a0, sum, t, u, temp;
double an, bn, maxt, pcanc;
an = a;
bn = b;
a0 = 1.0;
sum = 1.0;
n = 1.0;
t = 1.0;
maxt = 0.0;
while (t > MACHEP) {
if (bn == 0) {
mtherr("hyperg", CEPHES_SING);
return MAXNUM;
}
... | hy1f1p | gretl-2021d | sci-mathematics | O0/sci-mathematics/gretl-2021d/libgretl-1.0.so.40.0.0 | ida | O0 |
double hyp2f0(double a, double b, double x, int type, double *err) {
double xa;
double a0;
double alast;
double tlast;
double maxt;
double n;
double na;
double an;
double bn;
double sum;
long t;
double temp;
an = a;
bn = b;
a0 = 1.0;
alast = 1.0;
sum = 0.0;
n = 1.0;
tlast = 100000... | double hyp2f0(double a, double b, double x, int type, double *err) {
double a0, alast, t, tlast, maxt;
double n, an, bn, u, sum, temp;
an = a;
bn = b;
a0 = 1.0e0;
alast = 1.0e0;
sum = 0.0;
n = 1.0e0;
t = 1.0e0;
tlast = 1.0e9;
maxt = 0.0;
do {
if (an == 0)
goto pdone;
if (bn == 0)... | hyp2f0 | gretl-2021d | sci-mathematics | O0/sci-mathematics/gretl-2021d/libgretl-1.0.so.40.0.0 | ida | O0 |
double hyp2f1(double a, double b, double c, double x) {
double v5;
double v6;
double v7;
double v8;
double v9;
double v10;
double v11;
double v12;
double v13;
double v14;
double v15;
int i;
int neg_int_a;
int neg_int_b;
int neg_int_ca_or_cb;
int aid;
double err;
double d1;
double d... | double hyp2f1(double a, double b, double c, double x) {
double d, d1, d2, e;
double p, q, r, s, y, ax;
double ia, ib, ic, id, err;
double t1;
int i, aid;
int neg_int_a = 0, neg_int_b = 0;
int neg_int_ca_or_cb = 0;
err = 0.0;
ax = fabs(x);
s = 1.0 - x;
ia = round(a);
ib = round(b);
if (x == 0... | hyp2f1 | gretl-2021d | sci-mathematics | O0/sci-mathematics/gretl-2021d/libgretl-1.0.so.40.0.0 | ida | O0 |
double hyp2f1ra(double a, double b, double c, double x, double *loss) {
int n;
int na;
int da;
double err;
double f1;
double f0;
double t;
double f2;
unsigned long v15;
v15 = __readfsqword(0x28u);
if ((c >= 0.0 || c < a) && (c < 0.0 || a < c))
da = (int)round(a);
else
da = (int)round(a ... | static double hyp2f1ra(double a, double b, double c, double x, double *loss) {
double f2, f1, f0;
int n, da;
double t, err;
if ((c < 0 && a <= c) || (c >= 0 && a >= c)) {
da = round(a - c);
} else {
da = round(a);
}
t = a - da;
*loss = 0;
if (da == 0) {
return NAN;
}
if (da < 0) {
... | hyp2f1ra | gretl-2021d | sci-mathematics | O0/sci-mathematics/gretl-2021d/libgretl-1.0.so.40.0.0 | ida | O0 |
double hyperg(double a, double b, double x) {
double v4;
double acanc;
double pcanc;
double psum;
double temp;
double asum;
unsigned long v11;
v11 = __readfsqword(0x28u);
pcanc = 0.0;
temp = b - a;
if (0.001 * fabs(a) <= fabs(b - a)) {
psum = hy1f1p(a, b, x, &pcanc);
if (pcanc >= 1.0e-15)... | double hyperg(double a, double b, double x) {
double asum, psum, acanc, temp, pcanc = 0;
temp = b - a;
if (fabs(temp) < 0.001 * fabs(a))
return exp(x) * hyperg(temp, b, -x);
psum = hy1f1p(a, b, x, &pcanc);
if (pcanc < 1.0e-15)
goto done;
asum = hy1f1a(a, b, x, &acanc);
if (acanc < pcanc) {
... | hyperg | gretl-2021d | sci-mathematics | O0/sci-mathematics/gretl-2021d/libgretl-1.0.so.40.0.0 | ida | O0 |
double hypergeo(double a, double b, double c, double x) {
double ret;
ret = hyp2f1(a, b, c, x);
if (get_cephes_errno())
return NAN;
return ret;
} | double hypergeo(double a, double b, double c, double x) {
double ret = hyp2f1(a, b, c, x);
if (get_cephes_errno()) {
ret = NADBL;
}
return ret;
} | hypergeo | gretl-2021d | sci-mathematics | O0/sci-mathematics/gretl-2021d/libgretl-1.0.so.40.0.0 | ida | O0 |
double hys2f1(double a, double b, double c, double x, double *loss) {
double ba;
double aa;
int i;
int intflag;
int ib;
double k;
double s;
double u;
double umax;
double f;
aa = a;
ba = b;
intflag = 0;
if (fabs(b) > fabs(a)) {
ba = a;
aa = b;
}
ib = (int)round(ba);
if (fabs(ba... | static double hys2f1(double a, double b, double c, double x, double *loss) {
double f, g, h, k, m, s, u, umax;
int i, ib, intflag = 0;
if (fabs(b) > fabs(a)) {
f = b;
b = a;
a = f;
}
ib = round(b);
if (fabs(b - ib) < EPS && ib <= 0 && fabs(b) < fabs(a)) {
f = b;
b = a;
a = f;
... | hys2f1 | gretl-2021d | sci-mathematics | O0/sci-mathematics/gretl-2021d/libgretl-1.0.so.40.0.0 | ida | O0 |
double hyt2f1(double a, double b, double c, double x, double *loss) {
double v5;
double v6;
double v7;
double v8;
double v9;
double v11;
double v12;
double v13;
double v14;
double v15;
double v16;
double v17;
double v18;
double v19;
double v20;
double v21;
double v22;
double v23;
d... | static double hyt2f1(double a, double b, double c, double x, double *loss) {
double p, q, r, s, t, y, d, err, err1;
double ax, id, d1, d2, e, y1;
int i, aid;
int ia, ib, neg_int_a = 0, neg_int_b = 0;
ia = round(a);
ib = round(b);
if (a <= 0 && fabs(a - ia) < EPS) {
neg_int_a = 1;
}
if (b <= 0 &... | hyt2f1 | gretl-2021d | sci-mathematics | O0/sci-mathematics/gretl-2021d/libgretl-1.0.so.40.0.0 | ida | O0 |
double i0e(double x) {
double v2;
double xa;
xa = x;
if (x < 0.0)
xa = -x;
if (xa <= 8.0)
return chbevl(xa / 2.0 - 2.0, A_0, 30);
v2 = chbevl(32.0 / xa - 2.0, B_0, 25);
return v2 / sqrt(xa);
} | double i0e(double x) {
double y;
if (x < 0)
x = -x;
if (x <= 8.0) {
y = (x / 2.0) - 2.0;
return chbevl(y, A, 30);
}
return chbevl(32.0 / x - 2.0, B, 25) / sqrt(x);
} | i0e | gretl-2021d | sci-mathematics | O0/sci-mathematics/gretl-2021d/libgretl-1.0.so.40.0.0 | ida | O0 |
double i1e(double x) {
double v1;
double z;
double za;
z = fabs(x);
if (z > 8.0) {
v1 = chbevl(32.0 / z - 2.0, B_1, 25);
za = v1 / sqrt(z);
} else {
za = chbevl(z / 2.0 - 2.0, A_1, 29) * z;
}
if (x >= 0.0)
return za;
else
return -za;
} | double i1e(double x) {
double y, z = fabs(x);
if (z <= 8.0) {
y = (z / 2.0) - 2.0;
z = chbevl(y, A, 29) * z;
} else {
z = chbevl(32.0 / z - 2.0, B, 25) / sqrt(z);
}
return (x < 0.0) ? -z : z;
} | i1e | gretl-2021d | sci-mathematics | O0/sci-mathematics/gretl-2021d/libgretl-1.0.so.40.0.0 | ida | O0 |
int ic_adjust_order(adf_info *ainfo, int kmethod, DATASET *dset, gretlopt opt,
int test_num, int *err, PRN *prn) {
const char *v8;
const char *v9;
MODEL v10;
PRN *prna;
int *erra;
int test_numa;
DATASET *dseta;
gretlopt opta;
int kmethoda;
adf_info *ainfoa;
int k;
int kopt;
... | static int ic_adjust_order(adf_info *ainfo, int kmethod, DATASET *dset,
gretlopt opt, int test_num, int *err, PRN *prn) {
MODEL kmod;
gretlopt kmod_opt = (OPT_A | OPT_Z);
double IC, ICmin = 0;
double sum_ylag2 = 0;
int kmax = ainfo->kmax;
int k, kopt = kmax;
int save_t1 = dset->... | ic_adjust_order | gretl-2021d | sci-mathematics | O0/sci-mathematics/gretl-2021d/libgretl-1.0.so.40.0.0 | ida | O0 |
identity *ident_new(int nv) {
identity *ident;
ident = (identity *)malloc(0x10u);
if (!ident)
return 0;
ident->n_atoms = nv;
ident->atoms = (id_atom *)malloc(8LL * nv);
if (!ident->atoms) {
free(ident);
return 0;
}
return ident;
} | static identity *ident_new(int nv) {
identity *ident;
ident = malloc(sizeof *ident);
if (ident == NULL)
return NULL;
ident->n_atoms = nv;
ident->atoms = malloc(nv * sizeof *ident->atoms);
if (ident->atoms == NULL) {
free(ident);
ident = NULL;
}
return ident;
} | ident_new | gretl-2021d | sci-mathematics | O0/sci-mathematics/gretl-2021d/libgretl-1.0.so.40.0.0 | ida | O0 |
int if_eval(int ci, const char *s, DATASET *dset, PRN *prn, void *ptr,
int *err) {
char *v6;
char *v7;
const char *v8;
int ret;
GENERATOR *ifgen;
double val;
gchar *cond;
ifgen = 0;
val = NAN;
ret = -1;
if (ptr) {
ifgen = *(GENERATOR **)ptr;
if (!*(_QWORD *)ptr) {
if (s)... | static int if_eval(int ci, const char *s, DATASET *dset, PRN *prn, void *ptr,
int *err) {
GENERATOR *ifgen = NULL;
double val = NADBL;
int ret = -1;
#if IFDEBUG
fprintf(stderr, "if_eval: s = '%s'\n", s);
#endif
if (ptr != NULL) {
ifgen = *(GENERATOR **)ptr;
if (ifgen == NULL && s... | if_eval | gretl-2021d | sci-mathematics | O0/sci-mathematics/gretl-2021d/libgretl-1.0.so.40.0.0 | ida | O0 |
int ifstate(int code, int val, int *err) {
int v4;
unsigned char v5;
int i;
int ret;
ret = 0;
if (code != 5 && code != 6) {
switch (code) {
case 9:
indent_2 = 0;
break;
case 10:
indent_2 = val;
break;
case 8:
return indent_2;
case 7:
return --indent_2... | static int ifstate(int code, int val, int *err) {
static unsigned char T[IF_DEPTH];
static unsigned char tok[IF_DEPTH];
static unsigned char got_T[IF_DEPTH];
static unsigned short indent;
int i, ret = 0;
#if IFDEBUG
if (code != IS_FALSE) {
fprintf(stderr, "ifstate: code = %s\n", ifstr(code));
}
#endi... | ifstate | gretl-2021d | sci-mathematics | O0/sci-mathematics/gretl-2021d/libgretl-1.0.so.40.0.0 | ida | O0 |
double igam(double a, double x) {
double v3;
double ans;
double c;
double r;
double ax_0;
double ax_0a;
if (x <= 0.0 || a <= 0.0)
return 0.0;
if (x > 1.0 && x > a)
return 1.0 - igamc(a, x);
v3 = log(x) * a - x;
ax_0 = v3 - lgam(a);
if (-MAXLOG <= ax_0) {
ax_0a = exp(ax_0);
r = a;
... | double igam(double a, double x) {
double ans, ax, c, r;
if (x <= 0 || a <= 0) {
return 0.0;
}
if (x > 1.0 && x > a) {
return 1.0 - igamc(a, x);
}
ax = a * log(x) - x - lgam(a);
if (ax < -MAXLOG) {
mtherr("igam", CEPHES_UNDERFLOW);
return 0.0;
}
ax = exp(ax);
r = a;
c = 1.0;
... | igam | gretl-2021d | sci-mathematics | O0/sci-mathematics/gretl-2021d/libgretl-1.0.so.40.0.0 | ida | O0 |
double igamc(double a, double x) {
double v3;
double ans;
double c;
double t;
double y;
double z;
double pkm1;
double pkm2;
double qkm1;
double qkm2;
double ax_0;
double ax_0a;
double pk;
double qk;
if (x <= 0.0 || a <= 0.0)
return 1.0;
if (x < 1.0 || a > x)
return 1.0 - igam(a,... | double igamc(double a, double x) {
double ans, ax, c, yc, r, t, y, z;
double pk, pkm1, pkm2, qk, qkm1, qkm2;
if (x <= 0 || a <= 0) {
return 1.0;
}
if (x < 1.0 || x < a) {
return 1.0 - igam(a, x);
}
ax = a * log(x) - x - lgam(a);
if (ax < -MAXLOG) {
#if 0
mtherr("igamc", CEPHES_UNDERFLOW);
#... | igamc | gretl-2021d | sci-mathematics | O0/sci-mathematics/gretl-2021d/libgretl-1.0.so.40.0.0 | ida | O0 |
double igami(double a, double y0) {
double v2;
double v4;
int i;
int ia;
int dir;
double x0;
double x1;
double x;
double yl;
double yh;
double dd;
double d;
double da;
double db;
double dc;
double dithresh;
double y;
double ya;
double yb;
double lgm;
x0 = MAXNUM;
yl = 0.0;
... | double igami(double a, double y0) {
double x0, x1, x, yl, yh, y, d, lgm, dithresh;
int i, dir;
x0 = MAXNUM;
yl = 0;
x1 = 0;
yh = 1.0;
dithresh = 5.0 * MACHEP;
d = 1.0 / (9.0 * a);
y = (1.0 - d - ndtri(y0) * sqrt(d));
x = a * y * y * y;
lgm = lgam(a);
for (i = 0; i < 10; i++) {
if (x > x0... | igami | gretl-2021d | sci-mathematics | O0/sci-mathematics/gretl-2021d/libgretl-1.0.so.40.0.0 | ida | O0 |
int ijton(int i, int j, int nrows) {
int ja;
int ia;
ia = i;
ja = j;
if (i > j) {
ia = j;
ja = i;
}
return ia * nrows + ja - ia + ia * (ia - 1) / -2;
} | int ijton(int i, int j, int nrows) {
if (i > j) {
int tmp = i;
i = j;
j = tmp;
}
return nrows * i + j - i - ((i - 1) * i / 2);
} | ijton | gretl-2021d | sci-mathematics | O0/sci-mathematics/gretl-2021d/libgretl-1.0.so.40.0.0 | ida | O0 |
int imag_part_zero(const gretl_matrix *A) {
int i;
for (i = 0; i < A->rows * A->cols; ++i) {
if (fabs(A->z[i].imag) > 1.0e-15) {
fprintf(stderr, "imag_part_zero? no, got %g\n", A->z[i].imag);
return 0;
}
}
return 1;
} | static int imag_part_zero(const gretl_matrix *A) {
int i, n = A->rows * A->cols;
double tol = 1.0e-15;
for (i = 0; i < n; i++) {
if (fabs(cimag(A->z[i])) > tol) {
fprintf(stderr, "imag_part_zero? no, got %g\n", cimag(A->z[i]));
return 0;
}
}
return 1;
} | imag_part_zero | gretl-2021d | sci-mathematics | O0/sci-mathematics/gretl-2021d/libgretl-1.0.so.40.0.0 | ida | O0 |
int imax2(int x, int y) {
int result;
result = x;
if (y >= x)
return y;
return result;
} | static int imax2(int x, int y) { return (x > y) ? x : y; } | imax2 | gretl-2021d | sci-mathematics | O0/sci-mathematics/gretl-2021d/libgretl-1.0.so.40.0.0 | ida | O0 |
double imhof(const gretl_matrix *m, double arg, int *err) {
int rows;
int *v4;
char *v5;
int k;
int free_lambda;
double *lambda;
double bound;
double ret;
unsigned long v13;
v13 = __readfsqword(0x28u);
lambda = 0;
ret = NAN;
k = 0;
free_lambda = 0;
*__errno_location() = 0;
if (m->cols =... | double imhof(const gretl_matrix *m, double arg, int *err) {
double *lambda = NULL;
double bound, ret = NADBL;
int k = 0, free_lambda = 0;
errno = 0;
if (m->cols == 1 || m->rows == 1) {
lambda = m->val;
k = gretl_vector_get_length(m);
} else if (m->rows == m->cols) {
*err = imhof_get_eigenval... | imhof | gretl-2021d | sci-mathematics | O0/sci-mathematics/gretl-2021d/libgretl-1.0.so.40.0.0 | ida | O0 |
double imhof_bound(const double *lambda, int k, int *err) {
double v4;
int i;
double bound;
double nl;
double nla;
double sum;
double suma;
double absl;
nl = 0.0;
sum = 0.0;
for (i = 0; i < k; ++i) {
absl = fabs(lambda[i]);
if (absl > 0.0001) {
nl = nl + 1.0;
sum = log(absl) +... | static double imhof_bound(const double *lambda, int k, int *err) {
double e1 = 0.0001;
double e2 = 0.0001;
double absl, bound;
double nl = 0.0, sum = 0.0;
int i;
for (i = 0; i < k; i++) {
absl = fabs(lambda[i]);
if (absl > e2) {
nl += 1.0;
sum += log(absl);
}
}
if (nl == 0.0)... | imhof_bound | gretl-2021d | sci-mathematics | O0/sci-mathematics/gretl-2021d/libgretl-1.0.so.40.0.0 | ida | O0 |
double imhof_f(double u, const double *lambda, int k, double arg) {
double v5;
int i;
double rho;
double theta;
double ul;
rho = 0.0;
theta = -u * arg;
if (u == 0.0)
return 0.5 * (vecsum(lambda, k) - arg);
for (i = 0; i < k; ++i) {
ul = lambda[i] * u;
theta = atan(ul) + theta;
rho = l... | static double imhof_f(double u, const double *lambda, int k, double arg) {
double ul, rho = 0.0;
double theta = -u * arg;
int i;
if (u == 0.0) {
return 0.5 * (-arg + vecsum(lambda, k));
}
for (i = 0; i < k; i++) {
ul = u * lambda[i];
theta += atan(ul);
rho += log(1.0 + ul * ul);
}
ret... | imhof_f | gretl-2021d | sci-mathematics | O0/sci-mathematics/gretl-2021d/libgretl-1.0.so.40.0.0 | ida | O0 |
int imhof_get_eigenvals(const gretl_matrix *m, double **plam, int *pk) {
int err;
gretl_matrix *E;
unsigned long v7;
v7 = __readfsqword(0x28u);
err = 0;
E = gretl_general_matrix_eigenvals(m, &err);
if (!err) {
*pk = E->rows;
*plam = gretl_matrix_steal_data(E);
}
gretl_matrix_free(E);
return... | static int imhof_get_eigenvals(const gretl_matrix *m, double **plam, int *pk) {
gretl_matrix *E;
int err = 0;
E = gretl_general_matrix_eigenvals(m, &err);
if (!err) {
*pk = E->rows;
*plam = gretl_matrix_steal_data(E);
}
gretl_matrix_free(E);
return err;
} | imhof_get_eigenvals | gretl-2021d | sci-mathematics | O0/sci-mathematics/gretl-2021d/libgretl-1.0.so.40.0.0 | ida | O0 |
double imhof_integral(double arg, const double *lambda, int k, double bound,
int *err) {
int j;
int n;
double basea;
double base;
double int0;
double int1;
double sum4;
double ret;
double step;
double sum1;
int0 = 0.0;
int1 = 0.0;
sum4 = 0.0;
ret = NAN;
n = 2;
base... | static double imhof_integral(double arg, const double *lambda, int k,
double bound, int *err) {
double e3 = 0.0001;
double base, step, sum1;
double int0 = 0.0, int1 = 0.0;
double eps4 = 3.0 * M_PI * e3;
double sum4 = 0.0;
double ret = NADBL;
int j, n = 2;
base = imhof_f(0, ... | imhof_integral | gretl-2021d | sci-mathematics | O0/sci-mathematics/gretl-2021d/libgretl-1.0.so.40.0.0 | ida | O0 |
int imin2(int x, int y) {
int result;
result = x;
if (y <= x)
return y;
return result;
} | static int imin2(int x, int y) { return (x < y) ? x : y; } | imin2 | gretl-2021d | sci-mathematics | O0/sci-mathematics/gretl-2021d/libgretl-1.0.so.40.0.0 | ida | O0 |
int import_csv(const char *fname, DATASET *dset, gretlopt opt, PRN *prn) {
int v5;
int err;
int ci;
const char *cols;
const char *rows;
cols = 0;
rows = 0;
err = incompatible_options(opt, OPT_L | OPT_F);
if (err)
return err;
if (dset && dset->v > 0)
v5 = 4;
else
v5 = 90;
ci = v5;
... | int import_csv(const char *fname, DATASET *dset, gretlopt opt, PRN *prn) {
const char *cols = NULL;
const char *rows = NULL;
int ci, err;
err = incompatible_options(opt, OPT_F | OPT_L);
if (err) {
return err;
}
ci = (dset != NULL && dset->v > 0) ? APPEND : OPEN;
if (opt & OPT_F) {
cols = ge... | import_csv | gretl-2021d | sci-mathematics | O0/sci-mathematics/gretl-2021d/libgretl-1.0.so.40.0.0 | ida | O0 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.