IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Ignore:
Timestamp:
Feb 6, 2014, 12:43:34 PM (12 years ago)
Author:
eugene
Message:

fix cast in vgauss; add cast function; add psf smoothing options to densify and cdensify; add floor, ceil, rint functions to opihi math; add cdensify function; add fitpm function

Location:
trunk/Ohana/src/opihi
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/Ohana/src/opihi

  • trunk/Ohana/src/opihi/lib.shell/stack_math.c

    r36375 r36489  
    11231123  if (!strcmp (op, "abs"))    S_FUNC(fabs(M1), ST_SCALAR_INT);
    11241124  if (!strcmp (op, "int"))    S_FUNC((long long)(M1), ST_SCALAR_INT);
     1125  if (!strcmp (op, "floor"))  S_FUNC(floor (M1), ST_SCALAR_FLT);
     1126  if (!strcmp (op, "ceil"))   S_FUNC(ceil (M1), ST_SCALAR_FLT);
     1127  if (!strcmp (op, "rint"))   S_FUNC(nearbyint (M1), ST_SCALAR_FLT);
    11251128  if (!strcmp (op, "exp"))    S_FUNC(exp (M1), ST_SCALAR_FLT);
    11261129  if (!strcmp (op, "ten"))    S_FUNC(pow (10.0,M1), ST_SCALAR_FLT);
     
    12021205  if (!strcmp (op, "abs"))    V_FUNC(fabs(*M1), ST_SCALAR_INT);
    12031206  if (!strcmp (op, "int"))    V_FUNC((long long)(*M1), ST_SCALAR_INT);
     1207  if (!strcmp (op, "floor"))  V_FUNC(floor (*M1), ST_SCALAR_FLT);
     1208  if (!strcmp (op, "ceil"))   V_FUNC(ceil (*M1), ST_SCALAR_FLT);
     1209  if (!strcmp (op, "rint"))   V_FUNC(nearbyint (*M1), ST_SCALAR_FLT);
    12041210  if (!strcmp (op, "exp"))    V_FUNC(exp(*M1), ST_SCALAR_FLT);
    12051211  if (!strcmp (op, "ten"))    V_FUNC(pow(10.0,*M1), ST_SCALAR_FLT);
     
    12731279  if (!strcmp (op, "abs"))   { for (i = 0; i < Nx*Ny; i++, out++, M1++) { *out = fabs(*M1);         }}
    12741280  if (!strcmp (op, "int"))   { for (i = 0; i < Nx*Ny; i++, out++, M1++) { *out = (opihi_flt)(long long)(*M1); }}
     1281
     1282  if (!strcmp (op, "floor")) { for (i = 0; i < Nx*Ny; i++, out++, M1++) { *out = floor (*M1); }}
     1283  if (!strcmp (op, "ceil"))  { for (i = 0; i < Nx*Ny; i++, out++, M1++) { *out = ceil (*M1); }}
     1284  if (!strcmp (op, "rint"))  { for (i = 0; i < Nx*Ny; i++, out++, M1++) { *out = nearbyint (*M1); }}
     1285
    12751286  if (!strcmp (op, "exp"))   { for (i = 0; i < Nx*Ny; i++, out++, M1++) { *out = exp(*M1);          }}
    12761287  if (!strcmp (op, "ten"))   { for (i = 0; i < Nx*Ny; i++, out++, M1++) { *out = pow(10.0,*M1);     }}
Note: See TracChangeset for help on using the changeset viewer.