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 |
|---|---|---|---|---|---|---|---|
double *api_vector_coord(GMTAPI_CTRL *API, int dim, GMT_VECTOR *V) {
uint64_t v4;
double v5;
double v6;
unsigned int k;
double *coord;
double off;
double inc;
GMT_Report(API, 6u, "api_vector_coord called: dim = %d\n", dim);
if (V->range[0] == 0.0 && V->range[1] == 0.0)
return 0;
coord = (double... | GMT_LOCAL double * api_vector_coord (struct GMTAPI_CTRL *API, int dim, struct GMT_VECTOR *V) {
unsigned int k;
double *coord = NULL, off, inc;
GMT_Report (API, GMT_MSG_DEBUG, "api_vector_coord called: dim = %d\n", dim);
if (V->range[0] == 0.0 && V->range[1] == 0.0) return (NULL);
coord = gmt_M_memory (API->GMT,... | api_vector_coord | gmt-5.4.4 | sci-geosciences | O0/sci-geosciences/gmt-5.4.4/libgmt.so.5.4.4 | ida | O0 |
int api_wind_to_next_datarecord(int64_t *count, GMT_DATASET *D,
unsigned int mode) {
if (count[1] == -1) {
if (count[3] >= D->table[*count]->n_headers) {
count[2] = 0;
count[1] = count[2];
return 2;
} else {
++count[3];
return 1;
}
} else if ... | static inline int api_wind_to_next_datarecord (int64_t *count, struct GMT_DATASET *D, unsigned int mode) {
if (count[GMT_SEG] == -1) {
if (count[GMTAPI_HDR_POS] < D->table[count[GMT_TBL]]->n_headers) {
count[GMTAPI_HDR_POS]++;
return GMT_IO_TABLE_HEADER;
}
count[GMT_SEG] = count[GMT_ROW] = 0;
ret... | api_wind_to_next_datarecord | gmt-5.4.4 | sci-geosciences | O0/sci-geosciences/gmt-5.4.4/libgmt.so.5.4.4 | ida | O0 |
int api_wind_to_next_textrecord(int64_t *count, GMT_TEXTSET *D,
unsigned int mode) {
if (count[1] == -1) {
if (count[3] >= D->table[*count]->n_headers) {
count[2] = 0;
count[1] = count[2];
return 2;
} else {
++count[3];
return 1;
}
} else if ... | static inline int api_wind_to_next_textrecord (int64_t *count, struct GMT_TEXTSET *D, unsigned int mode) {
if (count[GMT_SEG] == -1) {
if (count[GMTAPI_HDR_POS] < D->table[count[GMT_TBL]]->n_headers) {
count[GMTAPI_HDR_POS]++;
return GMT_IO_TABLE_HEADER;
}
count[GMT_SEG] = count[GMT_ROW] = 0;
ret... | api_wind_to_next_textrecord | gmt-5.4.4 | sci-geosciences | O0/sci-geosciences/gmt-5.4.4/libgmt.so.5.4.4 | ida | O0 |
int api_write_matrix(GMT_CTRL *GMT, void *dest, unsigned int dest_type,
unsigned int mode, GMT_MATRIX *M) {
const char *v5;
unsigned int dest_typea;
bool close_file;
bool append;
uint64_t row;
uint64_t col;
uint64_t cola;
FILE *fp;
p_func_uint64_t GMT_2D_to_index;
GMT_getfunctio... | GMT_LOCAL int api_write_matrix (struct GMT_CTRL *GMT, void *dest, unsigned int dest_type, unsigned int mode, struct GMT_MATRIX *M) {
bool close_file = false, append = false;
uint64_t row, col, ij;
char M_file[GMT_BUFSIZ] = {""};
static char *msg1[2] = {"Writing", "Appending"};
FILE *fp = NULL;
p_func_uint64... | api_write_matrix | gmt-5.4.4 | sci-geosciences | O0/sci-geosciences/gmt-5.4.4/libgmt.so.5.4.4 | ida | O0 |
int api_write_vector(GMT_CTRL *GMT, void *dest, unsigned int dest_type,
unsigned int mode, GMT_VECTOR *V) {
const char *v6;
unsigned int dest_typea;
bool close_file;
bool append;
uint64_t row;
uint64_t col;
uint64_t cola;
uint64_t colb;
FILE *fp;
GMT_getfunction *api_get_val;
... | GMT_LOCAL int api_write_vector (struct GMT_CTRL *GMT, void *dest, unsigned int dest_type, unsigned int mode, struct GMT_VECTOR *V) {
bool close_file = false, append = false;
uint64_t row, col;
char V_file[GMT_BUFSIZ] = {""};
static char *msg1[2] = {"Writing", "Appending"};
FILE *fp = NULL;
GMT_getfunction *... | api_write_vector | gmt-5.4.4 | sci-geosciences | O0/sci-geosciences/gmt-5.4.4/libgmt.so.5.4.4 | ida | O0 |
unsigned int area_size(GMT_CTRL *GMT, double *x, double *y, uint64_t n,
double *out, int geo) {
double v6;
double v7;
double v8;
double v9;
int v10;
double xx;
double yy;
uint64_t i;
double size;
double *xp;
double *yp;
double ix;
double iy;
double wesn[6];
*(_QWORD... | GMT_LOCAL unsigned int area_size (struct GMT_CTRL *GMT, double x[], double y[], uint64_t n, double *out, int geo) {
uint64_t i;
double wesn[4], xx, yy, size, ix, iy;
double *xp = NULL, *yp = NULL;
wesn[XLO] = wesn[YLO] = DBL_MAX;
wesn[XHI] = wesn[YHI] = -DBL_MAX;
gmt_centroid (GMT, x, y, n, out, geo);
for... | area_size | gmt-5.4.4 | sci-geosciences | O0/sci-geosciences/gmt-5.4.4/libgmt.so.5.4.4 | ida | O0 |
void ascii_output_three(GMTAPI_CTRL *API, double *out, int ntabs) {
char X[256];
char Y[256];
char Z[264];
unsigned long v7;
v7 = __readfsqword(0x28u);
memset(X, 0, sizeof(X));
memset(Y, 0, sizeof(Y));
memset(Z, 0, 256);
gmt_ascii_format_col(API->GMT, X, *out, 1u, 0);
gmt_ascii_format_col(API->GMT,... | GMT_LOCAL void ascii_output_three (struct GMTAPI_CTRL *API, double out[], int ntabs) {
char X[GMT_LEN256] = {""}, Y[GMT_LEN256] = {""}, Z[GMT_LEN256] = {""};
gmt_ascii_format_col (API->GMT, X, out[GMT_X], GMT_OUT, GMT_X);
gmt_ascii_format_col (API->GMT, Y, out[GMT_Y], GMT_OUT, GMT_Y);
gmt_ascii_format_col (API->GMT... | ascii_output_three | gmt-5.4.4 | sci-geosciences | O0/sci-geosciences/gmt-5.4.4/libgmt.so.5.4.4 | ida | O0 |
void assign_gmtstack(GMTMATH_STACK *Sto, GMTMATH_STACK *Sfrom) {
*Sto = *Sfrom;
} | GMT_LOCAL void assign_gmtstack (struct GMTMATH_STACK *Sto, struct GMTMATH_STACK *Sfrom)
{
Sto->D = Sfrom->D;
Sto->constant = Sfrom->constant;
Sto->factor = Sfrom->factor;
} | assign_gmtstack | gmt-5.4.4 | sci-geosciences | O0/sci-geosciences/gmt-5.4.4/libgmt.so.5.4.4 | ida | O0 |
void assign_grdstack(GRDMATH_STACK *Sto, GRDMATH_STACK *Sfrom) {
*Sto = *Sfrom;
} | GMT_LOCAL void assign_grdstack (struct GRDMATH_STACK *Sto, struct GRDMATH_STACK *Sfrom)
{
Sto->G = Sfrom->G;
Sto->constant = Sfrom->constant;
Sto->factor = Sfrom->factor;
} | assign_grdstack | gmt-5.4.4 | sci-geosciences | O0/sci-geosciences/gmt-5.4.4/libgmt.so.5.4.4 | ida | O0 |
void assign_node(GMT_CTRL *GMT, NEARNEIGHBOR_NODE **node, unsigned int n_sector,
unsigned int sector, double distance, uint64_t id) {
float v6;
if (!*node)
*node = add_new_node(GMT, n_sector);
if ((*node)->datum[sector] == -1 || (*node)->distance[sector] > distance) {
v6 = distance;
... | GMT_LOCAL void assign_node (struct GMT_CTRL *GMT, struct NEARNEIGHBOR_NODE **node, unsigned int n_sector, unsigned int sector, double distance, uint64_t id) {
if (!(*node)) *node = add_new_node (GMT, n_sector);
if ((*node)->datum[sector] == -1 || (*node)->distance[sector] > distance) {
(*node)->distance[sector] ... | assign_node | gmt-5.4.4 | sci-geosciences | O0/sci-geosciences/gmt-5.4.4/libgmt.so.5.4.4 | ida | O0 |
void assign_output_spectrum1d(GMT_CTRL *GMT, SPECTRUM1D_INFO *C, char *col,
int n_outputs, int write_wavelength,
double **out) {
double v6;
int v7;
int v8;
double v9;
int v10;
int v11;
double v12;
int v13;
double v14;
int v15;
double v16;... | GMT_LOCAL void assign_output_spectrum1d (struct GMT_CTRL *GMT, struct SPECTRUM1D_INFO *C, char *col, int n_outputs, int write_wavelength, double *out[]) {
int i, j, k;
double delta_f, eps_pow, tmp, *f_or_w;
delta_f = 1.0 / (C->window * C->dt);
eps_pow = 1.0 / sqrt(C->d_n_windows);
f_or_w = gmt_M_memory (GMT, ... | assign_output_spectrum1d | gmt-5.4.4 | sci-geosciences | O0/sci-geosciences/gmt-5.4.4/libgmt.so.5.4.4 | ida | O0 |
bool at_pole(double *lat, uint64_t n) {
return *lat == lat[n - 1] && fabs(*lat) == 90.0;
} | GMT_LOCAL bool at_pole (double *lat, uint64_t n) {
return (lat[0] == lat[n-1] && fabs (lat[0]) == 90.0);
} | at_pole | gmt-5.4.4 | sci-geosciences | O0/sci-geosciences/gmt-5.4.4/libgmt.so.5.4.4 | ida | O0 |
uint64_t bcr_prep(GMT_GRID_HEADER *h, double xx, double yy, double *wx,
double *wy) {
unsigned int bcr_interpolant;
int col;
int row;
double x;
double y;
double xi;
double yj;
long ij;
double wp;
double wpa;
x = h->r_inc[0] * (xx - h->wesn[0]) - h->xy_off;
y = h->r_inc[1] * (h... | GMT_LOCAL uint64_t bcr_prep (struct GMT_GRID_HEADER *h, double xx, double yy, double wx[], double wy[]) {
int col, row;
uint64_t ij;
double x, y, wp, wq, w, xi, yj;
x = (xx - h->wesn[XLO]) * h->r_inc[GMT_X] - h->xy_off;
y = (h->wesn[YHI] - yy) * h->r_inc[GMT_Y] - h->xy_off;
if (h->bcr_interpolant == BCR_NEA... | bcr_prep | gmt-5.4.4 | sci-geosciences | O0/sci-geosciences/gmt-5.4.4/libgmt.so.5.4.4 | ida | O0 |
unsigned int bcr_reject(GMT_GRID_HEADER *h, double *xx, double *yy) {
if (h->wesn[0] <= *xx) {
if (*xx > h->wesn[1]) {
if (*xx > h->wesn[1] + 0.0001)
return 1;
*xx = h->wesn[1];
}
} else {
if (h->wesn[0] - 0.0001 > *xx)
return 1;
*xx = h->wesn[0];
}
if (h->wesn[2] <= *y... | GMT_LOCAL unsigned int bcr_reject (struct GMT_GRID_HEADER *h, double *xx, double *yy) {
if (gmt_M_is_dnan (*xx) || gmt_M_is_dnan (*yy)) return (2);
if (*xx < h->wesn[XLO]) {
if (*xx < h->wesn[XLO] - GMT_CONV4_LIMIT) return (1);
*xx = h->wesn[XLO];
}
else if (*xx > h->wesn[XHI]) {
if (*xx > ... | bcr_reject | gmt-5.4.4 | sci-geosciences | O0/sci-geosciences/gmt-5.4.4/libgmt.so.5.4.4 | ida | O0 |
double bin_mode(GMT_CTRL *GMT, BLK_DATA *d, uint64_t n, uint64_t k,
BIN_MODE_INFO *B) {
double v5;
int mode_choice;
bool done;
signed int n_modes;
int bin;
int bina;
int mode_bin;
double value;
double mode_count;
uint64_t i;
value = 0.0;
mode_count = 0.0;
n_modes = 0;
mode_b... | GMT_LOCAL double bin_mode (struct GMT_CTRL *GMT, struct BLK_DATA *d, uint64_t n, uint64_t k, struct BIN_MODE_INFO *B) {
double value = 0.0, mode_count = 0.0;
uint64_t i;
unsigned int n_modes = 0;
int bin, mode_bin = 0;
bool done;
gmt_M_unused(GMT);
gmt_M_memset (B->count, B->n_bins, double);
for (i = 0;... | bin_mode | gmt-5.4.4 | sci-geosciences | O0/sci-geosciences/gmt-5.4.4/libgmt.so.5.4.4 | ida | O0 |
BIN_MODE_INFO *bin_setup(GMT_CTRL *GMT, double width, bool center,
int mode_choice, bool is_integer, double z_min,
double z_max) {
long v7;
long v8;
double v9;
double v10;
int v11;
double widtha;
BIN_MODE_INFO *B;
double d_intval;
widtha = width;
B ... | GMT_LOCAL struct BIN_MODE_INFO *bin_setup (struct GMT_CTRL *GMT, double width, bool center, int mode_choice, bool is_integer, double z_min, double z_max) {
struct BIN_MODE_INFO *B = gmt_M_memory (GMT, NULL, 1, struct BIN_MODE_INFO);
char *mode = "lah";
if (is_integer) {
double d_intval;
if (width == 0.... | bin_setup | gmt-5.4.4 | sci-geosciences | O0/sci-geosciences/gmt-5.4.4/libgmt.so.5.4.4 | ida | O0 |
double boxcar_weight(double radius, double half_width) {
if (radius <= half_width)
return 1.0;
else
return 0.0;
} | GMT_LOCAL double boxcar_weight (double radius, double half_width) {
return ((radius > half_width) ? 0.0 : 1.0);
} | boxcar_weight | gmt-5.4.4 | sci-geosciences | O0/sci-geosciences/gmt-5.4.4/libgmt.so.5.4.4 | ida | O0 |
double bw_weight(F_INFO *f_info, double freq, int j) {
double v3;
double v4;
double v5;
double v6;
double lo;
if (f_info->llambda[j] == -1.0) {
v4 = 0.0;
} else {
v3 = pow(f_info->llambda[j] * freq, f_info->bw_order);
v4 = sqrt(1.0 / (v3 + 1.0));
}
lo = v4;
if (f_info->hlambda[j] == -1.... | GMT_LOCAL double bw_weight (struct F_INFO *f_info, double freq, int j) {
double hi, lo;
lo = (f_info->llambda[j] == -1.0) ? 0.0 : sqrt (1.0 / (1.0 + pow (freq * f_info->llambda[j], f_info->bw_order)));
hi = (f_info->hlambda[j] == -1.0) ? 1.0 : sqrt (1.0 / (1.0 + pow (freq * f_info->hlambda[j], f_info->bw_order)));... | bw_weight | gmt-5.4.4 | sci-geosciences | O0/sci-geosciences/gmt-5.4.4/libgmt.so.5.4.4 | ida | O0 |
void calc_m_and_r_1d(TREND1D_DATA *data, uint64_t n_data, double *model,
unsigned int n_model, GMT_MODEL *M, double *grow) {
unsigned int j;
uint64_t i;
for (i = 0; i < n_data; ++i) {
load_g_row_1d(data[i].x, data[i].t, n_model, grow, M);
data[i].m = 0.0;
for (j = 0; j < n_model;... | GMT_LOCAL void calc_m_and_r_1d (struct TREND1D_DATA *data, uint64_t n_data, double *model, unsigned int n_model, struct GMT_MODEL *M, double *grow) {
uint64_t i;
unsigned int j;
for (i = 0; i < n_data; i++) {
load_g_row_1d (data[i].x, data[i].t, n_model, grow, M);
data[i].m = 0.0;
for (j = 0; j < n_model; ... | calc_m_and_r_1d | gmt-5.4.4 | sci-geosciences | O0/sci-geosciences/gmt-5.4.4/libgmt.so.5.4.4 | ida | O0 |
void calc_m_and_r_2d(TREND2D_DATA *data, uint64_t n_data, double *model,
unsigned int n_model, double *grow) {
unsigned int j;
uint64_t i;
for (i = 0; i < n_data; ++i) {
load_g_row_2d(data[i].x, data[i].y, n_model, grow);
data[i].m = 0.0;
for (j = 0; j < n_model; ++j)
data[... | GMT_LOCAL void calc_m_and_r_2d (struct TREND2D_DATA *data, uint64_t n_data, double *model, unsigned int n_model, double *grow) {
uint64_t i;
unsigned int j;
for (i = 0; i < n_data; i++) {
load_g_row_2d (data[i].x, data[i].y, n_model, grow);
data[i].m = 0.0;
for (j = 0; j < n_model; j++) data[i].m += model[... | calc_m_and_r_2d | gmt-5.4.4 | sci-geosciences | O0/sci-geosciences/gmt-5.4.4/libgmt.so.5.4.4 | ida | O0 |
int calclock_cal_imod(int64_t x, int y) {
double v2;
if (!y)
__assert_fail("y != 0",
"/var/tmp/portage/sci-geosciences/gmt-5.4.4/work/gmt-5.4.4/"
"src/gmt_calclock.c",
0x50u, "calclock_cal_imod");
v2 = floor((double)(int)x / (double)y);
return x - y * l... | GMT_LOCAL int calclock_cal_imod (int64_t x, int y) {
assert (y != 0);
return ((int)(x - y * lrint (floor ((double)x / (double)y))));
} | calclock_cal_imod | gmt-5.4.4 | sci-geosciences | O0/sci-geosciences/gmt-5.4.4/libgmt.so.5.4.4 | ida | O0 |
int calclock_gyear_from_rd(int64_t date) {
double v1;
int v2;
double v3;
int v4;
double v5;
int v6;
double v7;
int year;
int n400;
int n100;
int n4;
int n1;
int64_t d1;
int64_t d2;
v1 = floor((double)((int)date - 1) / 146097.0);
n400 = lrint(v1);
v2 = calclock_cal_imod(date - 1, 14609... | GMT_LOCAL int calclock_gyear_from_rd (int64_t date) {
int64_t d0, d1, d2, d3;
int year, n400, n100, n4, n1;
d0 = date - 1;
n400 = irint (floor (d0 / 146097.0));
d1 = calclock_cal_imod (d0, 146097);
n100 = irint (floor (d1 / 36524.0));
d2 = calclock_cal_imod (d1, 36524);
n4 = irint (floor (d2 / 1461.0));
d3... | calclock_gyear_from_rd | gmt-5.4.4 | sci-geosciences | O0/sci-geosciences/gmt-5.4.4/libgmt.so.5.4.4 | ida | O0 |
int64_t calclock_kday_after(int64_t date, int kday) {
return calclock_kday_on_or_before(date + 7, kday);
} | GMT_LOCAL int64_t calclock_kday_after (int64_t date, int kday) {
return (calclock_kday_on_or_before (date+7, kday));
} | calclock_kday_after | gmt-5.4.4 | sci-geosciences | O0/sci-geosciences/gmt-5.4.4/libgmt.so.5.4.4 | ida | O0 |
int64_t calclock_kday_before(int64_t date, int kday) {
return calclock_kday_on_or_before(date - 1, kday);
} | GMT_LOCAL int64_t calclock_kday_before (int64_t date, int kday) {
return (calclock_kday_on_or_before (date-1, kday));
} | calclock_kday_before | gmt-5.4.4 | sci-geosciences | O0/sci-geosciences/gmt-5.4.4/libgmt.so.5.4.4 | ida | O0 |
int64_t calclock_kday_on_or_before(int64_t date, int kday) {
return date - calclock_cal_imod(date - kday, 7);
} | GMT_LOCAL int64_t calclock_kday_on_or_before (int64_t date, int kday) {
return (date - calclock_cal_imod (date-kday, 7));
} | calclock_kday_on_or_before | gmt-5.4.4 | sci-geosciences | O0/sci-geosciences/gmt-5.4.4/libgmt.so.5.4.4 | ida | O0 |
int64_t calclock_nth_kday(int n, int kday, int64_t date) {
if (n <= 0)
return 7 * n + calclock_kday_after(date, kday);
else
return 7 * n + calclock_kday_before(date, kday);
} | GMT_LOCAL int64_t calclock_nth_kday (int n, int kday, int64_t date) {
if (n > 0)
return (7*n + calclock_kday_before (date, kday));
else
return (7*n + calclock_kday_after (date, kday));
} | calclock_nth_kday | gmt-5.4.4 | sci-geosciences | O0/sci-geosciences/gmt-5.4.4/libgmt.so.5.4.4 | ida | O0 |
void calclock_small_moment_interval(GMT_CTRL *GMT, GMT_MOMENT_INTERVAL *p,
int step_secs, bool init) {
double x;
double xa;
if (step_secs == (_DWORD)&stru_15180) {
if (p->sd[0] != 0.0) {
p->dt[0] =
p->dt[0] - *(double *)((char *)&loc_412F0 + (_QWORD)GMT) * ... | GMT_LOCAL void calclock_small_moment_interval (struct GMT_CTRL *GMT, struct GMT_MOMENT_INTERVAL *p, int step_secs, bool init) {
double x;
if (step_secs == GMT_DAY2SEC_I) {
if (p->sd[0] != 0.0) {
p->dt[0] -= (p->sd[0] * GMT->current.setting.time_system.i_scale);
p->sd[0] = 0.0;
}
p->rd[1] = p... | calclock_small_moment_interval | gmt-5.4.4 | sci-geosciences | O0/sci-geosciences/gmt-5.4.4/libgmt.so.5.4.4 | ida | O0 |
bool central_meridian_not_set(GMT_CTRL *GMT) { return 0; } | GMT_LOCAL bool central_meridian_not_set (struct GMT_CTRL *GMT) {
return (gmt_M_is_dnan (GMT->current.proj.pars[0]));
} | central_meridian_not_set | gmt-5.4.4 | sci-geosciences | O0/sci-geosciences/gmt-5.4.4/libgmt.so.5.4.4 | ida | O0 |
void cheb_to_pol(GMT_CTRL *GMT, double *c, unsigned int un, double a, double b,
unsigned int denorm) {
double v6;
int j;
int ja;
int k;
double *d;
double *dd;
double sv;
double sva;
d = (double *)gmt_memory_func(GMT, 0, (int)un, 8u, 0, "cheb_to_pol");
dd = (double *)gmt_memory_func... | GMT_LOCAL void cheb_to_pol (struct GMT_CTRL *GMT, double c[], unsigned int un, double a, double b, unsigned int denorm) {
int j, k, n = (int)un;
double sv, *d, *dd;
d = gmt_M_memory (GMT, NULL, n, double);
dd = gmt_M_memory (GMT, NULL, n, double);
d[0] = c[n-1];
for (j = n - 2; j >= 1; j--) {
... | cheb_to_pol | gmt-5.4.4 | sci-geosciences | O0/sci-geosciences/gmt-5.4.4/libgmt.so.5.4.4 | ida | O0 |
double chebyshev(double x, unsigned int n) {
unsigned int j;
double cj;
long cj1;
double cj2;
if (!n)
return 1.0;
if (n != 1) {
cj1 = 0x3FF0000000000000LL;
cj = x;
for (j = 2; j <= n; ++j) {
cj2 = *(double *)&cj1;
cj1 = *(_QWORD *)&cj;
cj = (x + x) * cj - cj2;
}
re... | GMT_LOCAL double chebyshev (double x, unsigned int n) {
double cj, cj1, cj2;
unsigned int j;
if (n == 0) return 1.0;
if (n == 1) return x;
cj1 = 1.0; cj = x;
for (j = 2; j <= n; j++) {
cj2 = cj1;
cj1 = cj;
cj = 2.0 * x * cj1 - cj2;
}
return (cj);
} | chebyshev | gmt-5.4.4 | sci-geosciences | O0/sci-geosciences/gmt-5.4.4/libgmt.so.5.4.4 | ida | O0 |
int check_antipode_status(GMT_CTRL *GMT, GMT_SHORE *c, int inside, double clon,
double clat, int *status) {
int v6;
int v8;
double alon;
char old_J[136];
unsigned long v14;
v14 = __readfsqword(0x28u);
memset(old_J, 0, 128);
alon = clon + 180.0;
if (clon + 180.0 >= 360.0)
... | GMT_LOCAL int check_antipode_status (struct GMT_CTRL *GMT, struct GMT_SHORE *c, int inside, double clon, double clat, int status[]) {
char old_J[GMT_LEN128] = {""};
double alon = clon + 180.0;
if (alon >= 360.0) alon -= 360.0;
strncpy (old_J, GMT->common.J.string, GMT_LEN128-1);
GMT->common.J.active = false;
... | check_antipode_status | gmt-5.4.4 | sci-geosciences | O0/sci-geosciences/gmt-5.4.4/libgmt.so.5.4.4 | ida | O0 |
void check_errors(GMT_CTRL *GMT, SURFACE_INFO *C) {
float v2;
float v3;
float v4;
float v5;
float v6;
float v7;
float v8;
float v9;
float v10;
float v11;
float v12;
float v13;
float v14;
signed long npoints;
double v16;
uint64_t v17;
signed long v18;
double v19;
uint64_t v20;
int... | GMT_LOCAL void check_errors (struct GMT_CTRL *GMT, struct SURFACE_INFO *C) {
int i, j, move_over[12];
uint64_t ij, k;
unsigned char *iu = C->iu;
double x0, y0, dx, dy, mean_error, mean_squared_error, z_est, z_err, curvature, c;
double du_dx, du_dy, d2u_dx2, d2u_dxdy, d2u_dy2, d3u_dx3, d3u_dx2dy, d3u_dxdy2, d3... | check_errors | gmt-5.4.4 | sci-geosciences | O0/sci-geosciences/gmt-5.4.4/libgmt.so.5.4.4 | ida | O0 |
int check_lon_lat(GMT_CTRL *GMT, double *lon, double *lat) {
if (*(double *)((char *)&stru_21360.r_offset + (_QWORD)GMT) > *lat ||
*lat > GMT->common.R.wesn[3])
return 1;
if (GMT->common.R.wesn[0] > *lon)
*lon = *lon + 360.0;
if (*lon > GMT->common.R.wesn[1])
*lon = *lon - 360.0;
return GMT->c... | GMT_LOCAL int check_lon_lat (struct GMT_CTRL *GMT, double *lon, double *lat) {
if (*lat < GMT->common.R.wesn[YLO] || *lat > GMT->common.R.wesn[YHI]) return (true);
if (*lon < GMT->common.R.wesn[XLO]) *lon += 360.0;
if (*lon > GMT->common.R.wesn[XHI]) *lon -= 360.0;
if (*lon < GMT->common.R.wesn[XLO]) return (true);... | check_lon_lat | gmt-5.4.4 | sci-geosciences | O0/sci-geosciences/gmt-5.4.4/libgmt.so.5.4.4 | ida | O0 |
double circle_misfit(GMT_CTRL *GMT, FITCIRCLE_DATA *data, uint64_t ndata,
double *pole, int norm, double *work,
double *circle_distance) {
double v7;
double v8;
double v9;
double v10;
double v11;
double v12;
double v13;
double v14;
double v15;
uint64_t i;
... | GMT_LOCAL double circle_misfit (struct GMT_CTRL *GMT, struct FITCIRCLE_DATA *data, uint64_t ndata, double *pole, int norm, double *work, double *circle_distance) {
uint64_t i;
double distance, delta_distance, misfit = 0.0;
if (norm == 1) {
for (i = 0; i < ndata; i++) work[i] = d_acos (gmt_dot3v (GM... | circle_misfit | gmt-5.4.4 | sci-geosciences | O0/sci-geosciences/gmt-5.4.4/libgmt.so.5.4.4 | ida | O0 |
uint64_t clip_contours(GMT_CTRL *GMT, PSMASK_INFO *info, char *grd,
GMT_GRID_HEADER *h, double *inc2, unsigned int *edge,
unsigned int first, double **x, double **y,
uint64_t *max) {
uint32_t n_rows;
double v11;
double v12;
double v13;
doubl... | GMT_LOCAL uint64_t clip_contours (struct GMT_CTRL *GMT, struct PSMASK_INFO *info, char *grd, struct GMT_GRID_HEADER *h, double inc2[], unsigned int *edge, unsigned int first, double **x, double **y, uint64_t *max) {
unsigned int n_edges, edge_bit, i, j;
static unsigned int i0, j0, side;
uint64_t edge_word, ... | clip_contours | gmt-5.4.4 | sci-geosciences | O0/sci-geosciences/gmt-5.4.4/libgmt.so.5.4.4 | ida | O0 |
void column3D(GMT_CTRL *GMT, PSL_CTRL *PSL, double x, double y, double z,
double *dim, double (*rgb)[4], int outline) {
int i;
double sign;
double x_size;
double y_size;
double z_size;
x_size = 0.5 * *dim;
y_size = 0.5 * dim[1];
z_size = 0.5 * dim[2];
for (i = 0; i <= 2; ++i) {
sign... | GMT_LOCAL void column3D (struct GMT_CTRL *GMT, struct PSL_CTRL *PSL, double x, double y, double z, double *dim, double rgb[3][4], int outline) {
int i, k;
double x_size, y_size, z_size, sign;
x_size = 0.5 * dim[0];
y_size = 0.5 * dim[1];
z_size = 0.5 * dim[2];
for (i = 0; i < 3; i++) {
sign = -1.0;
k = GMT-... | column3D | gmt-5.4.4 | sci-geosciences | O0/sci-geosciences/gmt-5.4.4/libgmt.so.5.4.4 | ida | O0 |
int comp_pairs(const void *a, const void *b) {
if (*(double *)b <= *(double *)a)
return *(double *)a > *(double *)b;
else
return -1;
} | GMT_LOCAL int comp_pairs (const void *a, const void *b) {
const struct PAIR *xa = a, *xb = b;
if (xa->node < xb->node) return (-1);
if (xa->node > xb->node) return (+1);
return (0);
} | comp_pairs | gmt-5.4.4 | sci-geosciences | O0/sci-geosciences/gmt-5.4.4/libgmt.so.5.4.4 | ida | O0 |
int compare_classes(const void *point_1v, const void *point_2v) {
if (*(float *)point_2v <= *(float *)point_1v)
return *(float *)point_1v > *(float *)point_2v;
else
return -1;
} | GMT_LOCAL int compare_classes (const void *point_1v, const void *point_2v) {
const struct GRDCLIP_RECLASSIFY *point_1 = point_1v, *point_2 = point_2v;
if (point_1->low < point_2->low) return (-1);
if (point_1->low > point_2->low) return (+1);
return (0);
} | compare_classes | gmt-5.4.4 | sci-geosciences | O0/sci-geosciences/gmt-5.4.4/libgmt.so.5.4.4 | ida | O0 |
int compare_distances(const void *point_1, const void *point_2) {
double d_1;
double d_2;
d_1 = *((double *)point_1 + 2);
d_2 = *((double *)point_2 + 2);
if (d_2 <= d_1)
return d_1 > d_2;
else
return -1;
} | GMT_LOCAL int compare_distances (const void *point_1, const void *point_2) {
double d_1, d_2;
d_1 = ((struct PROJECT_DATA *)point_1)->a[2];
d_2 = ((struct PROJECT_DATA *)point_2)->a[2];
if (d_1 < d_2) return (-1);
if (d_1 > d_2) return (1);
return (0);
} | compare_distances | gmt-5.4.4 | sci-geosciences | O0/sci-geosciences/gmt-5.4.4/libgmt.so.5.4.4 | ida | O0 |
int compare_edge(const void *p1, const void *p2) {
if (*(_DWORD *)p1 < *(_DWORD *)p2)
return -1;
if (*(_DWORD *)p1 > *(_DWORD *)p2)
return 1;
if (*((_DWORD *)p1 + 1) >= *((_DWORD *)p2 + 1))
return *((_DWORD *)p1 + 1) > *((_DWORD *)p2 + 1);
return -1;
} | GMT_LOCAL int compare_edge (const void *p1, const void *p2) {
const struct TRIANGULATE_EDGE *a = p1, *b = p2;
if (a->begin < b->begin) return (-1);
if (a->begin > b->begin) return (+1);
if (a->end < b->end) return (-1);
if (a->end > b->end) return (+1);
return (0);
} | compare_edge | gmt-5.4.4 | sci-geosciences | O0/sci-geosciences/gmt-5.4.4/libgmt.so.5.4.4 | ida | O0 |
int compare_indexed_floats(const void *point_1, const void *point_2) {
if (*(float *)point_2 <= *(float *)point_1)
return *(float *)point_1 > *(float *)point_2;
else
return -1;
} | GMT_LOCAL int compare_indexed_floats (const void *point_1, const void *point_2) {
if (((struct INDEXED_DATA *)point_1)->x < ((struct INDEXED_DATA *)point_2)->x) return (-1);
if (((struct INDEXED_DATA *)point_1)->x > ((struct INDEXED_DATA *)point_2)->x) return (+1);
return (0);
} | compare_indexed_floats | gmt-5.4.4 | sci-geosciences | O0/sci-geosciences/gmt-5.4.4/libgmt.so.5.4.4 | ida | O0 |
int compare_indices(const void *point_1, const void *point_2) {
if (*((_QWORD *)point_1 + 1) >= *((_QWORD *)point_2 + 1))
return *((_QWORD *)point_1 + 1) > *((_QWORD *)point_2 + 1);
else
return -1;
} | GMT_LOCAL int compare_indices (const void *point_1, const void *point_2) {
if (((struct INDEXED_DATA *)point_1)->i < ((struct INDEXED_DATA *)point_2)->i) return (-1);
if (((struct INDEXED_DATA *)point_1)->i > ((struct INDEXED_DATA *)point_2)->i) return (1);
return (0);
} | compare_indices | gmt-5.4.4 | sci-geosciences | O0/sci-geosciences/gmt-5.4.4/libgmt.so.5.4.4 | ida | O0 |
int compare_nn_info(const void *point_1v, const void *point_2v) {
if (*((_QWORD *)point_1v + 1) >= *((_QWORD *)point_2v + 1))
return *((_QWORD *)point_1v + 1) > *((_QWORD *)point_2v + 1);
else
return -1;
} | GMT_LOCAL int compare_nn_info (const void *point_1v, const void *point_2v) {
const struct NN_INFO *point_1 = point_1v, *point_2 = point_2v;
if (point_1->orig_rec < point_2->orig_rec) return (-1);
if (point_1->orig_rec > point_2->orig_rec) return (+1);
return (0);
} | compare_nn_info | gmt-5.4.4 | sci-geosciences | O0/sci-geosciences/gmt-5.4.4/libgmt.so.5.4.4 | ida | O0 |
int compare_nn_points(const void *point_1v, const void *point_2v) {
if (*((double *)point_2v + 4) <= *((double *)point_1v + 4))
return *((double *)point_1v + 4) > *((double *)point_2v + 4);
else
return -1;
} | GMT_LOCAL int compare_nn_points (const void *point_1v, const void *point_2v) {
const struct NN_DIST *point_1 = point_1v, *point_2 = point_2v;
if (gmt_M_is_dnan (point_1->distance)) return (+1);
if (gmt_M_is_dnan (point_2->distance)) return (-1);
if (point_1->distance < point_2->distance) return (-1);
if (poin... | compare_nn_points | gmt-5.4.4 | sci-geosciences | O0/sci-geosciences/gmt-5.4.4/libgmt.so.5.4.4 | ida | O0 |
int compare_points(const void *point_1v, const void *point_2v) {
double v3;
double v4;
uint64_t index_1;
uint64_t index_2;
uint64_t block_i;
uint64_t block_j;
double x0;
double y0;
double dist_1;
double dist_2;
index_1 = *((_QWORD *)point_1v + 2);
index_2 = *((_QWORD *)point_2v + 2);
if (inde... | GMT_LOCAL int compare_points (const void *point_1v, const void *point_2v) {
uint64_t block_i, block_j, index_1, index_2;
double x0, y0, dist_1, dist_2;
const struct SURFACE_DATA *point_1 = point_1v, *point_2 = point_2v;
index_1 = point_1->index;
index_2 = point_2->index;
if (index_1 < index_2) return (-1)... | compare_points | gmt-5.4.4 | sci-geosciences | O0/sci-geosciences/gmt-5.4.4/libgmt.so.5.4.4 | ida | O0 |
int compare_terms(const void *term_1v, const void *term_2v) {
if (*(_DWORD *)term_1v < *(_DWORD *)term_2v)
return -1;
if (*(_DWORD *)term_1v > *(_DWORD *)term_2v)
return 1;
if (term_1v >= term_2v)
return term_1v > term_2v;
return -1;
} | GMT_LOCAL int compare_terms (const void *term_1v, const void *term_2v) {
const struct GMT_MODEL_TERM *term_1 = term_1v, *term_2 = term_2v;
if (term_1->kind < term_2->kind) return (-1);
if (term_1->kind > term_2->kind) return (+1);
if (term_1->order < term_2->order) return (-1);
if (term_1->order > term_2->or... | compare_terms | gmt-5.4.4 | sci-geosciences | O0/sci-geosciences/gmt-5.4.4/libgmt.so.5.4.4 | ida | O0 |
int compare_x(const void *point_1, const void *point_2) {
if (*(double *)point_2 <= *(double *)point_1)
return *(double *)point_1 > *(double *)point_2;
else
return -1;
} | GMT_LOCAL int compare_x (const void *point_1, const void *point_2) {
const struct GMTSELECT_DATA *p1 = point_1, *p2 = point_2;
if (p1->x < p2->x) return (-1);
if (p1->x > p2->x) return (1);
return (0);
} | compare_x | gmt-5.4.4 | sci-geosciences | O0/sci-geosciences/gmt-5.4.4/libgmt.so.5.4.4 | ida | O0 |
double compute_chisq(GMT_CTRL *GMT, GMT_GRID *R, GMT_GRID *W, double scale) {
unsigned int row;
signed int col;
uint64_t ij;
double tmp;
double tmpa;
double chisq;
chisq = 0.0;
for (row = 0; (signed int)R->header->n_rows > (signed int)row; ++row) {
col = 0;
ij = R->header->mx * (R->header->pad[... | GMT_LOCAL double compute_chisq (struct GMT_CTRL *GMT, struct GMT_GRID *R, struct GMT_GRID *W, double scale) {
unsigned int row, col;
uint64_t ij;
double tmp, chisq = 0.0;
gmt_M_unused(GMT);
gmt_M_grd_loop (GMT, R, row, col, ij) {
if (gmt_M_is_fnan (R->data[ij])) continue;
tmp = R->data[ij];
if (scale != 1... | compute_chisq | gmt-5.4.4 | sci-geosciences | O0/sci-geosciences/gmt-5.4.4/libgmt.so.5.4.4 | ida | O0 |
void compute_resid(GMT_CTRL *GMT, GMT_GRID *D, GMT_GRID *T, GMT_GRID *R) {
unsigned int row;
signed int col;
uint64_t ij;
for (row = 0; (signed int)T->header->n_rows > (signed int)row; ++row) {
col = 0;
ij = T->header->mx * (T->header->pad[3] + (unsigned long)row) +
T->header->pad[0];
whil... | GMT_LOCAL void compute_resid (struct GMT_CTRL *GMT, struct GMT_GRID *D, struct GMT_GRID *T, struct GMT_GRID *R) {
unsigned int row, col;
uint64_t ij;
gmt_M_unused(GMT);
gmt_M_grd_loop (GMT, T, row, col, ij) R->data[ij] = D->data[ij] - T->data[ij];
} | compute_resid | gmt-5.4.4 | sci-geosciences | O0/sci-geosciences/gmt-5.4.4/libgmt.so.5.4.4 | ida | O0 |
double compute_robust_weight(GMT_CTRL *GMT, GMT_GRID *R, GMT_GRID *W) {
uint64_t v3;
float v4;
float v5;
unsigned int row;
unsigned int rowa;
signed int col;
signed int cola;
float scale;
float r;
uint64_t j;
uint64_t ij;
uint64_t ija;
uint64_t j2;
j = 0;
for (row = 0; (signed int)R->head... | GMT_LOCAL double compute_robust_weight (struct GMT_CTRL *GMT, struct GMT_GRID *R, struct GMT_GRID *W) {
unsigned int row, col;
uint64_t j = 0, j2, ij;
float r, mad, scale;
gmt_M_grd_loop (GMT, R, row, col, ij) {
if (gmt_M_is_fnan (R->data[ij])) continue;
W->data[j++] = fabsf (R->data[ij]);
}
gmt_sort_arra... | compute_robust_weight | gmt-5.4.4 | sci-geosciences | O0/sci-geosciences/gmt-5.4.4/libgmt.so.5.4.4 | ida | O0 |
int compute_spectra(GMT_CTRL *GMT, SPECTRUM1D_INFO *C, double *x, double *y,
uint64_t n_data, bool leave_trend, unsigned int mode) {
double v7;
uint64_t v8;
double v9;
double v10;
double v11;
float v12;
float v13;
float v14;
float v16;
double v17;
float v18;
double v19;
uns... | GMT_LOCAL int compute_spectra (struct GMT_CTRL *GMT, struct SPECTRUM1D_INFO *C, double *x, double *y, uint64_t n_data, bool leave_trend, unsigned int mode) {
int n_windows, w, i, t_start, t_stop, t, f;
double dw, spec_scale, x_varp, y_varp = 1.0, one_on_nw, co_quad;
double xreal, ximag, yreal, yimag, xpower, ypower,... | compute_spectra | gmt-5.4.4 | sci-geosciences | O0/sci-geosciences/gmt-5.4.4/libgmt.so.5.4.4 | ida | O0 |
void compute_trend(GMT_CTRL *GMT, GMT_GRID *T, double *xval, double *yval,
double *gtd, unsigned int n_model, double *pstuff) {
float v7;
unsigned int row;
signed int col;
unsigned int k;
uint64_t ij;
for (row = 0; (signed int)T->header->n_rows > (signed int)row; ++row) {
col = 0;
... | GMT_LOCAL void compute_trend (struct GMT_CTRL *GMT, struct GMT_GRID *T, double *xval, double *yval, double *gtd, unsigned int n_model, double *pstuff) {
unsigned int row, col, k;
uint64_t ij;
gmt_M_unused(GMT);
gmt_M_grd_loop (GMT, T, row, col, ij) {
load_pstuff (pstuff, n_model, xval[col], yval[row], 1, (!(co... | compute_trend | gmt-5.4.4 | sci-geosciences | O0/sci-geosciences/gmt-5.4.4/libgmt.so.5.4.4 | ida | O0 |
void convert_c_row(GMT_CTRL *GMT, GRDRASTER_INFO *ras, float *row,
char *buffer) {
float z_scale_factor;
float z_add_offset;
char tempval;
uint32_t i;
for (i = 0; i < ras->h.n_columns; ++i) {
tempval = buffer[i];
if (ras->nanset && tempval == ras->nanflag) {
row[i] = GMT->ses... | GMT_LOCAL inline void convert_c_row (struct GMT_CTRL *GMT, struct GRDRASTER_INFO *ras, float *row, char *buffer) {
unsigned int i;
char tempval;
for (i = 0; i < ras->h.n_columns; ++i) {
tempval = buffer[i];
if (ras->nanset && tempval == ras->nanflag) {
row[i] = GMT->session.f_NaN;
}
else {
row[i] = (... | convert_c_row | gmt-5.4.4 | sci-geosciences | O0/sci-geosciences/gmt-5.4.4/libgmt.so.5.4.4 | ida | O0 |
void convert_d_row(GMT_CTRL *GMT, GRDRASTER_INFO *ras, float *row,
char *buffer) {
float z_scale_factor;
float z_add_offset;
uint16_t tempval;
uint32_t i;
for (i = 0; i < ras->h.n_columns; ++i) {
tempval = *(_WORD *)&buffer[2 * i];
if (ras->swap_me)
tempval = __ROL2__(tempval... | GMT_LOCAL inline void convert_d_row (struct GMT_CTRL *GMT, struct GRDRASTER_INFO *ras, float *row, char *buffer) {
unsigned int i;
uint16_t tempval;
for (i = 0; i < ras->h.n_columns; ++i) {
gmt_M_memcpy (&tempval, &buffer[i * sizeof(uint16_t)], 1, uint16_t);
if (ras->swap_me)
tempval = bswap16 (tempval);
... | convert_d_row | gmt-5.4.4 | sci-geosciences | O0/sci-geosciences/gmt-5.4.4/libgmt.so.5.4.4 | ida | O0 |
void convert_i_row(GMT_CTRL *GMT, GRDRASTER_INFO *ras, float *row,
char *buffer) {
float z_scale_factor;
float z_add_offset;
int16_t tempval;
unsigned int i;
uint16_t *u;
unsigned long v9;
v9 = __readfsqword(0x28u);
u = (uint16_t *)&tempval;
for (i = 0; i < ras->h.n_columns; ++i) {... | GMT_LOCAL inline void convert_i_row (struct GMT_CTRL *GMT, struct GRDRASTER_INFO *ras, float *row, char *buffer) {
unsigned int i;
int16_t tempval;
uint16_t *u = (uint16_t *)&tempval;
for (i = 0; i < ras->h.n_columns; i++) {
gmt_M_memcpy (&tempval, &buffer[i * sizeof(int16_t)], 1, int16_t);
if (ras->swap_me)
... | convert_i_row | gmt-5.4.4 | sci-geosciences | O0/sci-geosciences/gmt-5.4.4/libgmt.so.5.4.4 | ida | O0 |
void convert_l_row(GMT_CTRL *GMT, GRDRASTER_INFO *ras, float *row,
char *buffer) {
float z_scale_factor;
float z_add_offset;
int32_t tempval;
unsigned int i;
uint32_t *u;
unsigned long v9;
v9 = __readfsqword(0x28u);
u = (uint32_t *)&tempval;
for (i = 0; i < ras->h.n_columns; ++i) {... | GMT_LOCAL inline void convert_l_row (struct GMT_CTRL *GMT, struct GRDRASTER_INFO *ras, float *row, char *buffer) {
unsigned int i;
int32_t tempval;
uint32_t *u = (uint32_t *)&tempval;
for (i = 0; i < ras->h.n_columns; i++) {
gmt_M_memcpy (&tempval, &buffer[i * sizeof(int32_t)], 1, int32_t);
if (ras->swap_me)
... | convert_l_row | gmt-5.4.4 | sci-geosciences | O0/sci-geosciences/gmt-5.4.4/libgmt.so.5.4.4 | ida | O0 |
void convert_u_row(GMT_CTRL *GMT, GRDRASTER_INFO *ras, float *row,
char *buffer) {
float z_scale_factor;
float z_add_offset;
unsigned char tempval;
uint32_t i;
for (i = 0; i < ras->h.n_columns; ++i) {
tempval = buffer[i];
if (ras->nanset && tempval == ras->nanflag) {
row[i] =... | GMT_LOCAL inline void convert_u_row (struct GMT_CTRL *GMT, struct GRDRASTER_INFO *ras, float *row, char *buffer) {
unsigned int i;
unsigned char tempval;
for (i = 0; i < ras->h.n_columns; ++i) {
gmt_M_memcpy (&tempval, &buffer[i], 1, char);
if (ras->nanset && tempval == ras->nanflag) {
row[i] = GMT->session... | convert_u_row | gmt-5.4.4 | sci-geosciences | O0/sci-geosciences/gmt-5.4.4/libgmt.so.5.4.4 | ida | O0 |
void copy_points_bw(double *x, double *y, double *z, double *v, double *xcont,
double *ycont, double *zcont, double *vcont,
unsigned int ncont, uint64_t *n) {
unsigned int k;
unsigned int k2_0;
k2_0 = 0;
k = ncont - 1;
while (k2_0 < ncont) {
x[*n] = xcont[k];
y... | GMT_LOCAL void copy_points_bw (double x[], double y[], double z[], double v[], double xcont[], double ycont[], double zcont[], double vcont[], unsigned int ncont, uint64_t *n) {
unsigned int k, k2;
for (k2 = 0, k = ncont - 1; k2 < ncont; k2++, k--, (*n)++) {
x[*n] = xcont[k];
y[*n] = ycont[k];
z[*n] = zcont[k];... | copy_points_bw | gmt-5.4.4 | sci-geosciences | O0/sci-geosciences/gmt-5.4.4/libgmt.so.5.4.4 | ida | O0 |
void copy_points_fw(double *x, double *y, double *z, double *v, double *xcont,
double *ycont, double *zcont, double *vcont,
unsigned int ncont, uint64_t *n) {
unsigned int k;
for (k = 0; k < ncont; ++k) {
x[*n] = xcont[k];
y[*n] = ycont[k];
z[*n] = zcont[k];
... | GMT_LOCAL void copy_points_fw (double x[], double y[], double z[], double v[], double xcont[], double ycont[], double zcont[], double vcont[], unsigned int ncont, uint64_t *n) {
unsigned int k;
for (k = 0; k < ncont; k++, (*n)++) {
x[*n] = xcont[k];
y[*n] = ycont[k];
z[*n] = zcont[k];
v[*n] = vcont[k];
}
} | copy_points_fw | gmt-5.4.4 | sci-geosciences | O0/sci-geosciences/gmt-5.4.4/libgmt.so.5.4.4 | ida | O0 |
void copy_text_from_col3(char *line, char *z_cols) {
unsigned int i;
for (i = 0; line[i]; ++i) {
if (line[i] == 44)
line[i] = 32;
}
__isoc99_sscanf(line, "%*s %*s %[^\n]", z_cols);
} | GMT_LOCAL void copy_text_from_col3 (char *line, char *z_cols) {
unsigned int i;
for (i = 0; line[i]; i++) if (line[i] == ',') line[i] = ' ';
sscanf (line, "%*s %*s %[^\n]", z_cols);
} | copy_text_from_col3 | gmt-5.4.4 | sci-geosciences | O0/sci-geosciences/gmt-5.4.4/libgmt.so.5.4.4 | ida | O0 |
double cosine_weight_filter1d(double radius, double half_width) {
if (radius <= half_width)
return cos(3.141592653589793 * radius / half_width) + 1.0;
else
return 0.0;
} | GMT_LOCAL double cosine_weight_filter1d (double radius, double half_width) {
return ((radius > half_width) ? 0.0 : 1.0 + cos (radius * M_PI / half_width));
} | cosine_weight_filter1d | gmt-5.4.4 | sci-geosciences | O0/sci-geosciences/gmt-5.4.4/libgmt.so.5.4.4 | ida | O0 |
double cosine_weight_grdfft(F_INFO *f_info, double freq, int j) {
if (f_info->lc[j] >= freq || freq >= f_info->hc[j])
return 0.0;
if (freq > f_info->lc[j] && f_info->lp[j] > freq)
return 0.5 * (cos((freq - f_info->lp[j]) * 3.141592653589793 *
f_info->ltaper[j]) +
1.0)... | GMT_LOCAL double cosine_weight_grdfft (struct F_INFO *f_info, double freq, int j) {
if (freq <= f_info->lc[j] || freq >= f_info->hc[j]) return(0.0);
if (freq > f_info->lc[j] && freq < f_info->lp[j]) return (0.5 * (1.0 + cos (M_PI * (freq - f_info->lp[j]) * f_info->ltaper[j])));
if (freq > f_info->hp[j] && freq < f_... | cosine_weight_grdfft | gmt-5.4.4 | sci-geosciences | O0/sci-geosciences/gmt-5.4.4/libgmt.so.5.4.4 | ida | O0 |
unsigned int count_NaNs(GMT_CTRL *GMT, GMT_GRID *G, unsigned int row0,
unsigned int row1, unsigned int col0, unsigned int col1,
unsigned int *count, unsigned int *side) {
long col0a;
unsigned int col;
unsigned int cola;
unsigned int row;
unsigned int rowa;
uns... | GMT_LOCAL unsigned int count_NaNs (struct GMT_CTRL *GMT, struct GMT_GRID *G, unsigned int row0, unsigned int row1, unsigned int col0, unsigned int col1, unsigned int count[], unsigned int *side) {
unsigned int col, row, sum = 0, k;
uint64_t node;
gmt_M_memset (count, 4, unsigned int);
*side = 0;
for (col = ... | count_NaNs | gmt-5.4.4 | sci-geosciences | O0/sci-geosciences/gmt-5.4.4/libgmt.so.5.4.4 | ida | O0 |
bool crossed_dateline(double this_x, double last_x) {
if (this_x > 90.0 && this_x <= 180.0 && last_x > 180.0 && last_x < 270.0)
return 1;
if (last_x > 90.0 && last_x <= 180.0 && this_x > 180.0 && this_x < 270.0)
return 1;
if (this_x > 90.0 && this_x <= 180.0 && last_x > -180.0 && last_x < -90.0)
retur... | GMT_LOCAL bool crossed_dateline (double this_x, double last_x) {
if (this_x > 90.0 && this_x <= 180.0 && last_x > +180.0 && last_x < 270.0) return (true);
if (last_x > 90.0 && last_x <= 180.0 && this_x > +180.0 && this_x < 270.0) return (true);
if (this_x > 90.0 && this_x <= 180.0 && last_x > -180.0 && last_x < -9... | crossed_dateline | gmt-5.4.4 | sci-geosciences | O0/sci-geosciences/gmt-5.4.4/libgmt.so.5.4.4 | ida | O0 |
double csplint(double *y, double *c, double b, double h2, uint64_t klo) {
return (c[klo + 1] * (b * b * b - b) +
((1.0 - b) * (1.0 - b) * (1.0 - b) - (1.0 - b)) * c[klo]) *
h2 / 6.0 +
y[klo] * (1.0 - b) + y[klo + 1] * b;
} | GMT_LOCAL double csplint (double *y, double *c, double b, double h2, uint64_t klo) {
uint64_t khi;
double a, yp;
khi = klo + 1;
a = 1.0 - b;
yp = a * y[klo] + b * y[khi] + ((a*a*a - a) * c[klo] + (b*b*b - b) * c[khi]) * h2 / 6.0;
return (yp);
} | csplint | gmt-5.4.4 | sci-geosciences | O0/sci-geosciences/gmt-5.4.4/libgmt.so.5.4.4 | ida | O0 |
int customio_compare_grd_fmt_strings(const void *a, const void *b) {
return strncmp(*(const char **)a, *(const char **)b, 2u);
} | GMT_LOCAL int customio_compare_grd_fmt_strings(const void* a, const void* b) {
const char **ia = (const char **)a;
const char **ib = (const char **)b;
return strncmp(*ia, *ib, 2);
} | customio_compare_grd_fmt_strings | gmt-5.4.4 | sci-geosciences | O0/sci-geosciences/gmt-5.4.4/libgmt.so.5.4.4 | ida | O0 |
int customio_native_read_grd_header(FILE *fp, GMT_GRID_HEADER *header) {
int err;
err = 0;
if (fread(header, 0xCu, 1u, fp) != 1 ||
fread(header->wesn, 0x370u, 1u, fp) != 1)
return 9;
return err;
} | GMT_LOCAL int customio_native_read_grd_header (FILE *fp, struct GMT_GRID_HEADER *header) {
int err = GMT_NOERROR;
if (gmt_M_fread (&header->n_columns, SIZEOF_NATIVE_GRD_HDR1, 1U, fp) != 1 ||
gmt_M_fread (header->wesn, SIZEOF_NATIVE_GRD_HDR2, 1U, fp) != 1)
err = GMT_GRDIO_READ_FAILED;
return (err);
} | customio_native_read_grd_header | gmt-5.4.4 | sci-geosciences | O0/sci-geosciences/gmt-5.4.4/libgmt.so.5.4.4 | ida | O0 |
int customio_native_skip_grd_header(FILE *fp, GMT_GRID_HEADER *header) {
int err;
err = 0;
if (fseeko(fp, 892, 0))
return 12;
return err;
} | GMT_LOCAL int customio_native_skip_grd_header (FILE *fp, struct GMT_GRID_HEADER *header) {
int err = GMT_NOERROR;
gmt_M_unused(header);
if (fseek (fp, SIZEOF_NATIVE_GRD_HDR, SEEK_SET))
err = GMT_GRDIO_SEEK_FAILED;
return (err);
} | customio_native_skip_grd_header | gmt-5.4.4 | sci-geosciences | O0/sci-geosciences/gmt-5.4.4/libgmt.so.5.4.4 | ida | O0 |
int customio_native_write_grd_header(FILE *fp, GMT_GRID_HEADER *header) {
int err;
err = 0;
if (fwrite(header, 0xCu, 1u, fp) != 1 ||
fwrite(header->wesn, 0x370u, 1u, fp) != 1)
return 10;
return err;
} | GMT_LOCAL int customio_native_write_grd_header (FILE *fp, struct GMT_GRID_HEADER *header) {
int err = GMT_NOERROR;
if (gmt_M_fwrite (&header->n_columns, SIZEOF_NATIVE_GRD_HDR1, 1U, fp) != 1 ||
gmt_M_fwrite (header->wesn, SIZEOF_NATIVE_GRD_HDR2, 1U, fp) != 1)
err = GMT_GRDIO_WRITE_FAILED;
return (err);
} | customio_native_write_grd_header | gmt-5.4.4 | sci-geosciences | O0/sci-geosciences/gmt-5.4.4/libgmt.so.5.4.4 | ida | O0 |
int customio_read_rasheader(FILE *fp, rasterfile *h) {
double v3;
int32_t i;
int value;
uint8_t byte[4];
unsigned long v7;
v7 = __readfsqword(0x28u);
for (i = 0; i <= 7; ++i) {
if (fread(byte, 1u, 4u, fp) != 4)
return 9;
value = (byte[2] << 8) + (byte[1] << 16) + (byte[0] << 24) + byte[3];
... | GMT_LOCAL int customio_read_rasheader (FILE *fp, struct rasterfile *h) {
uint8_t byte[4];
int32_t i, value;
for (i = 0; i < 8; i++) {
if (gmt_M_fread (byte, sizeof (uint8_t), 4, fp) != 4)
return (GMT_GRDIO_READ_FAILED);
value = (byte[0] << 24) + (byte[1] << 16) + (byte[2] << 8) + byte[3];
switch (... | customio_read_rasheader | gmt-5.4.4 | sci-geosciences | O0/sci-geosciences/gmt-5.4.4/libgmt.so.5.4.4 | ida | O0 |
int customio_read_srfheader6(FILE *fp, srf_header6 *h) {
if (fread(h, 4u, 1u, fp) != 1)
return 9;
if (fread(&h->n_columns, 4u, 1u, fp) != 1)
return 9;
if (fread(h->wesn, 8u, 4u, fp) != 4)
return 9;
if (fread(&h->z_min, 0x10u, 1u, fp) == 1)
return 0;
return 9;
} | GMT_LOCAL int customio_read_srfheader6 (FILE *fp, struct srf_header6 *h) {
if (gmt_M_fread (h->id, 4*sizeof (char), 1U, fp) != 1U)
return (GMT_GRDIO_READ_FAILED);
if (gmt_M_fread (&h->n_columns, 2*sizeof (short int), 1U, fp) != 1U)
return (GMT_GRDIO_READ_FAILED);
if (gmt_M_fread (h->wesn, sizeof (double),... | customio_read_srfheader6 | gmt-5.4.4 | sci-geosciences | O0/sci-geosciences/gmt-5.4.4/libgmt.so.5.4.4 | ida | O0 |
int customio_read_srfheader7(FILE *fp, srf_header7 *h) {
if (fseeko(fp, 12, 0))
return 12;
if (fread(h, 4u, 1u, fp) != 1)
return 9;
if (fread(&h->len_g, 0xCu, 1u, fp) != 1)
return 9;
if (fread(&h->x_min, 0x40u, 1u, fp) != 1)
return 9;
if (fread(h->id3, 4u, 1u, fp) != 1)
return 9;
if (fre... | GMT_LOCAL int customio_read_srfheader7 (FILE *fp, struct srf_header7 *h) {
if (fseek (fp, (off_t)(3*sizeof(int)), SEEK_SET))
return (GMT_GRDIO_SEEK_FAILED);
if (gmt_M_fread (h->id2, 4*sizeof (char), 1U, fp) != 1)
return (GMT_GRDIO_READ_FAILED);
if (gmt_M_fread (&h->len_g, 3*sizeof (int), 1U, fp) != 1)
... | customio_read_srfheader7 | gmt-5.4.4 | sci-geosciences | O0/sci-geosciences/gmt-5.4.4/libgmt.so.5.4.4 | ida | O0 |
int customio_write_rasheader(FILE *fp, rasterfile *h) {
double v2;
int i;
int32_t value;
uint8_t byte[4];
unsigned long v7;
v7 = __readfsqword(0x28u);
if (!h->type && !h->length) {
v2 = ceil((double)(h->width * h->depth) / 16.0);
h->length = h->height * 2 * lrint(v2);
h->type = 1;
}
for (... | GMT_LOCAL int customio_write_rasheader (FILE *fp, struct rasterfile *h) {
int i;
uint8_t byte[4];
int32_t value;
if (h->type == RT_OLD && h->length == 0) {
h->length = 2 * irint (ceil (h->width * h->depth / 16.0)) * h->height;
h->type = RT_STANDARD;
}
for (i = 0; i < 8; i++) {
switch (i) {
case ... | customio_write_rasheader | gmt-5.4.4 | sci-geosciences | O0/sci-geosciences/gmt-5.4.4/libgmt.so.5.4.4 | ida | O0 |
int customio_write_srfheader(FILE *fp, srf_header6 *h) {
if (fwrite(h, 4u, 1u, fp) != 1)
return 10;
if (fwrite(&h->n_columns, 4u, 1u, fp) != 1)
return 10;
if (fwrite(h->wesn, 0x30u, 1u, fp) == 1)
return 0;
return 10;
} | GMT_LOCAL int customio_write_srfheader (FILE *fp, struct srf_header6 *h) {
if (gmt_M_fwrite (h->id, 4*sizeof (char), 1U, fp) != 1)
return (GMT_GRDIO_WRITE_FAILED);
if (gmt_M_fwrite (&h->n_columns, 2*sizeof (short int), 1U, fp) != 1)
return (GMT_GRDIO_WRITE_FAILED);
if (gmt_M_fwrite (h->wesn, sizeof (struct s... | customio_write_srfheader | gmt-5.4.4 | sci-geosciences | O0/sci-geosciences/gmt-5.4.4/libgmt.so.5.4.4 | ida | O0 |
int dcw_comp_countries(const void *p1, const void *p2) {
return strcmp((const char *)p1 + 4, (const char *)p2 + 4);
} | GMT_LOCAL int dcw_comp_countries (const void *p1, const void *p2) {
struct GMT_DCW_COUNTRY *A = (struct GMT_DCW_COUNTRY *)p1;
struct GMT_DCW_COUNTRY *B = (struct GMT_DCW_COUNTRY *)p2;
return (strcmp (A->code, B->code));
} | dcw_comp_countries | gmt-5.4.4 | sci-geosciences | O0/sci-geosciences/gmt-5.4.4/libgmt.so.5.4.4 | ida | O0 |
int dcw_find_country(char *code, GMT_DCW_COUNTRY *list, int n) {
int low;
int last;
int mid;
int way;
low = 0;
last = -1;
while (low < n) {
mid = (low + n) / 2;
if (mid == last)
return -1;
way = strcmp(code, list[mid].code);
if (way <= 0) {
if (way >= 0)
return (low + ... | GMT_LOCAL int dcw_find_country (char *code, struct GMT_DCW_COUNTRY *list, int n) {
int low = 0, high = n, mid, last = -1, way;
while (low < high) {
mid = (low + high) / 2;
if (mid == last) return (-1);
way = strcmp (code, list[mid].code);
if (way > 0) low = mid;
else if (way < 0) high = mid;
else retu... | dcw_find_country | gmt-5.4.4 | sci-geosciences | O0/sci-geosciences/gmt-5.4.4/libgmt.so.5.4.4 | ida | O0 |
int dcw_find_state(char *scode, char *ccode, GMT_DCW_STATE *slist, int ns) {
int i;
for (i = 0; i < ns; ++i) {
if (!strcmp(scode, slist[i].code) && !strcmp(ccode, slist[i].country))
return i;
}
return -1;
} | GMT_LOCAL int dcw_find_state (char *scode, char *ccode, struct GMT_DCW_STATE *slist, int ns) {
int i;
for (i = 0; i < ns; i++) if (!strcmp (scode, slist[i].code) && !strcmp (ccode, slist[i].country)) return (i);
return (-1);
} | dcw_find_state | gmt-5.4.4 | sci-geosciences | O0/sci-geosciences/gmt-5.4.4/libgmt.so.5.4.4 | ida | O0 |
bool dcw_get_path(GMT_CTRL *GMT, char *name, char *suffix, char *path) {
char found;
found = 0;
if (*(unsigned long *)((char *)&stru_20C10.r_offset + (_QWORD)GMT)) {
sprintf(path, "%s/%s%s",
*(const char **)((char *)&stru_20C10.r_offset + (_QWORD)GMT), name,
suffix);
if (access(pa... | GMT_LOCAL bool dcw_get_path (struct GMT_CTRL *GMT, char *name, char *suffix, char *path) {
bool found = false;
if (GMT->session.DCWDIR) {
sprintf (path, "%s/%s%s", GMT->session.DCWDIR, name, suffix);
if ( access (path, R_OK) == 0)
found = true;
else {
GMT->session.DCWDIR = NULL;
}
}
if (... | dcw_get_path | gmt-5.4.4 | sci-geosciences | O0/sci-geosciences/gmt-5.4.4/libgmt.so.5.4.4 | ida | O0 |
int dcw_load_lists(GMT_CTRL *GMT, GMT_DCW_COUNTRY **C, GMT_DCW_STATE **S,
GMT_DCW_COUNTRY_STATE **CS_0, unsigned int *dim) {
unsigned int v6;
unsigned int k;
unsigned int ka;
unsigned int kb;
unsigned int n;
unsigned int na;
size_t n_alloc;
GMT_DCW_COUNTRY *Country;
GMT_DCW_COUNTRY ... | GMT_LOCAL int dcw_load_lists (struct GMT_CTRL *GMT, struct GMT_DCW_COUNTRY **C, struct GMT_DCW_STATE **S, struct GMT_DCW_COUNTRY_STATE **CS, unsigned int dim[]) {
size_t n_alloc = 300;
unsigned int k, n;
char path[GMT_BUFSIZ] = {""}, line[BUFSIZ] = {""};
FILE *fp = NULL;
struct GMT_DCW_COUNTRY *Country = NULL;
... | dcw_load_lists | gmt-5.4.4 | sci-geosciences | O0/sci-geosciences/gmt-5.4.4/libgmt.so.5.4.4 | ida | O0 |
void decode_R(GMT_CTRL *GMT, char *string, double *wesn) {
unsigned int v3;
unsigned int v4;
unsigned int pos;
unsigned int i;
unsigned int error;
char text[4104];
unsigned long v11;
v11 = __readfsqword(0x28u);
error = 0;
pos = 0;
i = 0;
while (!error && gmt_strtok(string, "/", &pos, text)) {
... | GMT_LOCAL void decode_R (struct GMT_CTRL *GMT, char *string, double wesn[]) {
unsigned int i, pos, error = 0;
char text[GMT_BUFSIZ];
i = pos = 0;
while (!error && (gmt_strtok (string, "/", &pos, text))) {
error += gmt_verify_expectations (GMT, GMT->current.io.col_type[GMT_IN][i/2], gmt_scanf_arg (GMT, text, G... | decode_R | gmt-5.4.4 | sci-geosciences | O0/sci-geosciences/gmt-5.4.4/libgmt.so.5.4.4 | ida | O0 |
bool decode_columns(char *txt, bool *skip, uint64_t n_col, uint64_t t_col) {
uint64_t v4;
unsigned int pos;
uint64_t start;
uint64_t stop;
uint64_t i;
char p[4104];
unsigned long v13;
v13 = __readfsqword(0x28u);
if (*txt) {
if (*txt != 114 || txt[1]) {
if (*txt == 97) {
for (i = 0; ... | GMT_LOCAL bool decode_columns (char *txt, bool *skip, uint64_t n_col, uint64_t t_col) {
uint64_t i, start, stop;
unsigned int pos;
char p[GMT_BUFSIZ];
if (!txt[0]) {
for (i = 0; i < n_col; i++) skip[i] = false;
skip[t_col] = true;
}
else if (txt[0] == 'r' && txt[1] == '\0') {
for (i = 0; i < n_col; i+... | decode_columns | gmt-5.4.4 | sci-geosciences | O0/sci-geosciences/gmt-5.4.4/libgmt.so.5.4.4 | ida | O0 |
int decode_gmt_argument(GMT_CTRL *GMT, char *txt, double *value,
bool *dimension, GMT_HASH *H) {
unsigned int v6;
bool check;
bool possible_number;
int key;
double tmp;
char *mark;
size_t last;
char copy[264];
unsigned long v17;
v17 = __readfsqword(0x28u);
check = 0;
pos... | GMT_LOCAL int decode_gmt_argument (struct GMT_CTRL *GMT, char *txt, double *value, bool *dimension, struct GMT_HASH *H) {
unsigned int expect;
int key;
size_t last;
bool check = GMT_IS_NAN, possible_number = false;
char copy[GMT_LEN256] = {""};
char *mark = NULL;
double tmp = 0.0;
if (!txt) return (GMTMATH_ARG... | decode_gmt_argument | gmt-5.4.4 | sci-geosciences | O0/sci-geosciences/gmt-5.4.4/libgmt.so.5.4.4 | ida | O0 |
int decode_grd_argument(GMT_CTRL *GMT, GMT_OPTION *opt, double *value,
GMT_HASH *H) {
unsigned int v5;
bool possible_number;
int check;
int i;
double tmp[2];
*(_QWORD *)&tmp[1] = __readfsqword(0x28u);
check = 0;
possible_number = 0;
tmp[0] = 0.0;
if (!opt || !opt->arg || !*o... | GMT_LOCAL int decode_grd_argument (struct GMT_CTRL *GMT, struct GMT_OPTION *opt, double *value, struct GMT_HASH *H) {
int i, expect, check = GMT_IS_NAN;
bool possible_number = false;
double tmp = 0.0;
if (opt == NULL || opt->arg == NULL || opt->arg[0] == '\0') return GRDMATH_ARG_IS_BAD;
grdmath_backwards_fixing... | decode_grd_argument | gmt-5.4.4 | sci-geosciences | O0/sci-geosciences/gmt-5.4.4/libgmt.so.5.4.4 | ida | O0 |
unsigned int decode_vector(GMT_CTRL *GMT, char *arg, double *coord,
int cartesian, int geocentric) {
unsigned int v5;
unsigned int v6;
double v7;
double v8;
int n_out;
unsigned int n_errors;
unsigned int n_errorsa;
unsigned int ix;
unsigned int iy;
int n;
char txt_a[64];... | GMT_LOCAL unsigned int decode_vector (struct GMT_CTRL *GMT, char *arg, double coord[], int cartesian, int geocentric) {
unsigned int n_out, n_errors = 0, ix, iy;
int n;
char txt_a[GMT_LEN64] = {""}, txt_b[GMT_LEN64] = {""}, txt_c[GMT_LEN64] = {""};
ix = (GMT->current.setting.io_lonlat_toggle[GMT_IN]); iy = 1 - ix... | decode_vector | gmt-5.4.4 | sci-geosciences | O0/sci-geosciences/gmt-5.4.4/libgmt.so.5.4.4 | ida | O0 |
void detrend_and_hanning(SPECTRUM1D_INFO *C, bool leave_trend,
unsigned int mode) {
double v3;
double v4;
double v5;
double v6;
float v7;
float v8;
float v9;
float v10;
float v11;
int i;
int ia;
int ib;
int ic;
int t;
int ta;
int tb;
int tc;
double sumx;
do... | GMT_LOCAL void detrend_and_hanning (struct SPECTRUM1D_INFO *C, bool leave_trend, unsigned int mode) {
int i, t;
double sumx, sumtx, sumy, sumty, sumt2, x_slope, x_mean, y_slope, y_mean;
double t_factor, h_period, h_scale, hc, hw, tt, x_min, x_max, y_min, y_max;
sumx = sumtx = sumy = sumty = sumt2 = 0.0;
x_slop... | detrend_and_hanning | gmt-5.4.4 | sci-geosciences | O0/sci-geosciences/gmt-5.4.4/libgmt.so.5.4.4 | ida | O0 |
int dist_compare(const void *a, const void *b) {
if (*((double *)b + 17) > *((double *)a + 17))
return -1;
if (*((double *)a + 17) > *((double *)b + 17))
return 1;
if (*((double *)b + 18) <= *((double *)a + 18))
return *((double *)a + 18) > *((double *)b + 18);
return -1;
} | GMT_LOCAL int dist_compare (const void *a, const void *b) {
if (((struct PSXYZ_DATA *)a)->dist[0] < ((struct PSXYZ_DATA *)b)->dist[0]) return (-1);
if (((struct PSXYZ_DATA *)a)->dist[0] > ((struct PSXYZ_DATA *)b)->dist[0]) return (1);
if (((struct PSXYZ_DATA *)a)->dist[1] < ((struct PSXYZ_DATA *)b)->dist[1]) return ... | dist_compare | gmt-5.4.4 | sci-geosciences | O0/sci-geosciences/gmt-5.4.4/libgmt.so.5.4.4 | ida | O0 |
unsigned int do_azimuthal_derivative(GMT_GRID *Grid, double *azim,
GMT_FFT_WAVENUMBER *K) {
float *v3;
double v4;
double v5;
double v7;
double cosx;
double sinx;
GMT_FFT_WAVENUMBER *Ka;
double *azima;
GMT_GRID *Grida;
float fact;
float tempr;
float tempi;
d... | GMT_LOCAL unsigned int do_azimuthal_derivative (struct GMT_GRID *Grid, double *azim, struct GMT_FFT_WAVENUMBER *K) {
uint64_t k;
float tempr, tempi, fact, *datac = Grid->data;
double cos_azim, sin_azim;
sincosd (*azim, &sin_azim, &cos_azim);
datac[0] = datac[1] = 0.0f;
for (k = 2; k < Grid->header->size; k += ... | do_azimuthal_derivative | gmt-5.4.4 | sci-geosciences | O0/sci-geosciences/gmt-5.4.4/libgmt.so.5.4.4 | ida | O0 |
unsigned int do_continuation(GMT_GRID *Grid, double *zlevel,
GMT_FFT_WAVENUMBER *K) {
double wave;
float v4;
double v6;
size_t k;
float *datac;
datac = Grid->data;
for (k = 2; k < Grid->header->size; k += 2LL) {
v6 = -*zlevel;
wave = gmt_fft_get_wave(k, K);
v4 = e... | GMT_LOCAL unsigned int do_continuation (struct GMT_GRID *Grid, double *zlevel, struct GMT_FFT_WAVENUMBER *K) {
uint64_t k;
float tmp, *datac = Grid->data;
for (k = 2; k < Grid->header->size; k += 2) {
tmp = (float)exp (-(*zlevel) * gmt_fft_get_wave (k, K));
datac[k] *= tmp;
datac[k+1] *= tmp;
}
return... | do_continuation | gmt-5.4.4 | sci-geosciences | O0/sci-geosciences/gmt-5.4.4/libgmt.so.5.4.4 | ida | O0 |
int do_derivative(float *z, uint64_t this_node, int off, unsigned int type) {
uint64_t prev_node;
uint64_t next_node;
prev_node = this_node - off;
next_node = off + this_node;
if (z[this_node] == z[prev_node] && z[this_node] == z[next_node])
return -2;
if (z[prev_node] > z[this_node] && z[next_node] > ... | GMT_LOCAL int do_derivative (float *z, uint64_t this_node, int off, unsigned int type)
{
uint64_t next_node, prev_node;
int nan_flag;
nan_flag = (type == 0) ? -2 : 0;
prev_node = this_node - off;
next_node = this_node + off;
if (gmt_M_is_fnan (z[prev_node])) {
if (gmt_M_is_fnan (z[next_node])) r... | do_derivative | gmt-5.4.4 | sci-geosciences | O0/sci-geosciences/gmt-5.4.4/libgmt.so.5.4.4 | ida | O0 |
unsigned int do_differentiate(GMT_GRID *Grid, double *par,
GMT_FFT_WAVENUMBER *K) {
long v3;
float v4;
size_t k;
float *datac;
double scale;
datac = Grid->data;
if (*par == 0.0)
v3 = 0x3FF0000000000000LL;
else
v3 = *(_QWORD *)par;
scale = *(double *)&v3;
datac[... | GMT_LOCAL unsigned int do_differentiate (struct GMT_GRID *Grid, double *par, struct GMT_FFT_WAVENUMBER *K) {
uint64_t k;
double scale, fact;
float *datac = Grid->data;
scale = (*par != 0.0) ? *par : 1.0;
datac[0] = datac[1] = 0.0f;
for (k = 2; k < Grid->header->size; k += 2) {
fact = scale * gmt_fft_get_w... | do_differentiate | gmt-5.4.4 | sci-geosciences | O0/sci-geosciences/gmt-5.4.4/libgmt.so.5.4.4 | ida | O0 |
void do_filter(GMT_GRID *Grid, F_INFO *f_info, GMT_FFT_WAVENUMBER *K) {
float filter_weight;
size_t k;
float *datac;
datac = Grid->data;
for (k = 0; k < Grid->header->size; k += 2LL) {
filter_weight = get_filter_weight(k, f_info, K);
datac[k] = datac[k] * filter_weight;
datac[k + 1] = datac[k + 1... | GMT_LOCAL void do_filter (struct GMT_GRID *Grid, struct F_INFO *f_info, struct GMT_FFT_WAVENUMBER *K) {
uint64_t k;
float weight, *datac = Grid->data;
for (k = 0; k < Grid->header->size; k += 2) {
weight = (float) get_filter_weight (k, f_info, K);
datac[k] *= weight;
datac[k+1] *= weight;
}
} | do_filter | gmt-5.4.4 | sci-geosciences | O0/sci-geosciences/gmt-5.4.4/libgmt.so.5.4.4 | ida | O0 |
int do_gaussian_scores(GMT_CTRL *GMT, GMT_GRID *Grid, double norm) {
uint64_t v3;
double v4;
double v5;
float v6;
float v7;
uint64_t v8;
unsigned int row;
unsigned int rowa;
signed int col;
signed int cola;
uint64_t i;
uint64_t ia;
uint64_t j;
uint64_t ij;
uint64_t ija;
uint64_t nxy;
I... | GMT_LOCAL int do_gaussian_scores (struct GMT_CTRL *GMT, struct GMT_GRID *Grid, double norm) {
unsigned int row, col;
uint64_t i = 0, j = 0, ij, nxy;
double dnxy;
struct INDEXED_DATA *indexed_data = NULL;
indexed_data = gmt_M_memory (GMT, NULL, Grid->header->nm, struct INDEXED_DATA);
nxy = Grid->header->nm;
g... | do_gaussian_scores | gmt-5.4.4 | sci-geosciences | O0/sci-geosciences/gmt-5.4.4/libgmt.so.5.4.4 | ida | O0 |
int do_hist_equalization(GMT_CTRL *GMT, GMT_GRID *Grid, char *outfile,
unsigned int n_cells, bool quadratic,
bool dump_intervals) {
if (GMT->current.io.col_type[0][0] == 4 &&
GMT->current.io.col_type[0][1] == 2)
return do_hist_equalization_geo(GMT, Grid, out... | GMT_LOCAL int do_hist_equalization (struct GMT_CTRL *GMT, struct GMT_GRID *Grid, char *outfile, unsigned int n_cells, bool quadratic, bool dump_intervals) {
int err = 0;
if (gmt_M_is_geographic (GMT, GMT_IN))
err = do_hist_equalization_geo (GMT, Grid, outfile, n_cells, quadratic, dump_intervals);
else
err = do_h... | do_hist_equalization | gmt-5.4.4 | sci-geosciences | O0/sci-geosciences/gmt-5.4.4/libgmt.so.5.4.4 | ida | O0 |
int do_hist_equalization_cart(GMT_CTRL *GMT, GMT_GRID *Grid, char *outfile,
unsigned int n_cells, bool quadratic,
bool dump_intervals) {
long v6;
double v8;
double v9;
double v10;
double v11;
__m128i v12;
double v13;
int current_cell;
unsigne... | GMT_LOCAL int do_hist_equalization_cart (struct GMT_CTRL *GMT, struct GMT_GRID *Grid, char *outfile, unsigned int n_cells, bool quadratic, bool dump_intervals) {
uint64_t i, j, nxy;
unsigned int n_cells_m1 = 0, current_cell, pad[4];
double delta_cell, target, out[3];
struct CELL *cell = NULL;
struct GMT_GRID *Or... | do_hist_equalization_cart | gmt-5.4.4 | sci-geosciences | O0/sci-geosciences/gmt-5.4.4/libgmt.so.5.4.4 | ida | O0 |
int do_hist_equalization_geo(GMT_CTRL *GMT, GMT_GRID *Grid, char *outfile,
unsigned int n_cells, bool quadratic,
bool dump_intervals) {
float *v6;
uint64_t v7;
float v8;
float v9;
__m128i v11;
int current_cell;
unsigned int row;
unsigned int rowa... | GMT_LOCAL int do_hist_equalization_geo (struct GMT_CTRL *GMT, struct GMT_GRID *Grid, char *outfile, unsigned int n_cells, bool quadratic, bool dump_intervals) {
uint64_t i, j, node, nxy = 0;
unsigned int n_cells_m1 = 0, current_cell, row, col;
double cell_w, delta_w, target_w, wsum = 0.0, out[3];
struct CELL *cel... | do_hist_equalization_geo | gmt-5.4.4 | sci-geosciences | O0/sci-geosciences/gmt-5.4.4/libgmt.so.5.4.4 | ida | O0 |
unsigned int do_integrate(GMT_GRID *Grid, double *par, GMT_FFT_WAVENUMBER *K) {
long v3;
float v4;
size_t k;
float *datac;
double scale;
datac = Grid->data;
if (*par == 0.0)
v3 = 0x3FF0000000000000LL;
else
v3 = *(_QWORD *)par;
scale = *(double *)&v3;
datac[1] = 0.0;
*datac = datac[1];
f... | GMT_LOCAL unsigned int do_integrate (struct GMT_GRID *Grid, double *par, struct GMT_FFT_WAVENUMBER *K) {
uint64_t k;
double fact, scale;
float *datac = Grid->data;
scale = (*par != 0.0) ? *par : 1.0;
datac[0] = datac[1] = 0.0f;
for (k = 2; k < Grid->header->size; k += 2) {
fact = 1.0 / (scale * gmt_fft_get_... | do_integrate | gmt-5.4.4 | sci-geosciences | O0/sci-geosciences/gmt-5.4.4/libgmt.so.5.4.4 | ida | O0 |
unsigned int do_isostasy(GMT_GRID *Grid, GRDFFT_CTRL *Ctrl, double *par,
GMT_FFT_WAVENUMBER *K) {
float v5;
size_t k;
float *datac;
double rm;
double ri;
double airy_ratio;
double d_over_restoring_force;
double mk;
datac = Grid->data;
rm = par[2];
ri = par[4];
airy_rati... | GMT_LOCAL unsigned int do_isostasy (struct GMT_GRID *Grid, struct GRDFFT_CTRL *Ctrl, double *par, struct GMT_FFT_WAVENUMBER *K) {
uint64_t k;
double airy_ratio, rigidity_d, d_over_restoring_force, mk, k2, k4, transfer_fn;
double te;
double rl;
double rm;
double rw;
double ri;
float *datac = Grid->d... | do_isostasy | gmt-5.4.4 | sci-geosciences | O0/sci-geosciences/gmt-5.4.4/libgmt.so.5.4.4 | ida | O0 |
void do_normalization(GMTAPI_CTRL *API, double **X, double *obs, uint64_t n,
unsigned int mode, unsigned int dim, double *coeff) {
double v7;
double v8;
double v9;
double v10;
double v11;
uint64_t i;
uint64_t ia;
uint64_t ib;
uint64_t ic;
double min;
double max;
double sxx;... | GMT_LOCAL void do_normalization (struct GMTAPI_CTRL *API, double **X, double *obs, uint64_t n, unsigned int mode, unsigned int dim, double *coeff) {
uint64_t i;
double d, min = DBL_MAX, max = -DBL_MAX;
GMT_Report (API, GMT_MSG_LONG_VERBOSE, "Normalization mode: %d\n", mode);
if (dim == 1) {
do_normalizati... | do_normalization | gmt-5.4.4 | sci-geosciences | O0/sci-geosciences/gmt-5.4.4/libgmt.so.5.4.4 | ida | O0 |
void do_normalization_1d(GMTAPI_CTRL *API, double **X, double *obs, uint64_t n,
unsigned int mode, double *coeff) {
double v6;
double v7;
double v8;
double v9;
char modea;
uint64_t i;
uint64_t ia;
uint64_t ib;
uint64_t ic;
double min;
double max;
double sxx;
double sxz... | GMT_LOCAL void do_normalization_1d (struct GMTAPI_CTRL *API, double **X, double *obs, uint64_t n, unsigned int mode, double *coeff) {
uint64_t i;
double d, min = DBL_MAX, max = -DBL_MAX;
gmt_M_memset (coeff, GSP_LENGTH, double);
for (i = 0; i < n; i++) {
coeff[GSP_MEAN_Z] += obs[i];
if ((mode & GREENSPL... | do_normalization_1d | gmt-5.4.4 | sci-geosciences | O0/sci-geosciences/gmt-5.4.4/libgmt.so.5.4.4 | ida | O0 |
double *do_regression(GMT_CTRL *GMT, double *x_in, double *y_in, double **w,
uint64_t n, unsigned int regression, unsigned int in_norm,
double *par, unsigned int mode) {
double v9;
double v11;
unsigned int regressiona;
bool flipped;
bool reweighted_ls;
unsigned in... | GMT_LOCAL double *do_regression (struct GMT_CTRL *GMT, double *x_in, double *y_in, double *w[], uint64_t n, unsigned int regression, unsigned int in_norm, double *par, unsigned int mode) {
uint64_t k;
unsigned int norm = in_norm;
bool flipped, reweighted_ls = false;
double scale = 1.0, *x = NULL, *y = NULL, *z... | do_regression | gmt-5.4.4 | sci-geosciences | O0/sci-geosciences/gmt-5.4.4/libgmt.so.5.4.4 | ida | O0 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.