@ -45,5 +45,16 @@ NON-STANDARD FEATURES
#include "ngspice/cmproto.h"
#include "ngspice/mifcmdat.h"
#if defined (_MSC_VER)
#ifndef NAN
static const __int64 global_nan = 0x7ff8000000000000i64;
#define NAN (*(const double *) &global_nan)
#endif
#if !defined(NAN)
#define NAN (0.0/0.0)
@ -294,8 +294,8 @@ cm_core(ARGS)
/*** must determine position progressively & then ***/
/*** calculate required output. ***/
dout_din = 0.0 / 0.0;
B_out = 0.0 / 0.0;
dout_din = NAN;
B_out = NAN;
for (i = 1; i < size; i++)
if (H_input < (H[i].rvalue + H[i+1].rvalue) / 2.0) {