Thank you, it was simply my improper use of variable types that was giving me the problems. For reference here is the code I used for making it work..

`double PI = 3.14159265359;`

double TWOPI = PI * 2;

double ticksPerM = 105; // Odometer pulses per meter

double wheelBase = 0.35; // Wheelbase in meters

double pixelsPerMeter = 10; // Multiplier for how many pixels represent 1m

double distance = ((m_odometerVals[0]/ticksPerM) + (m_odometerVals[1]/ticksPerM)) / 2; // Calculate distance moved in meters

theta += ((((m_odometerVals[0]/ticksPerM) - (m_odometerVals[1]/ticksPerM)) / wheelBase)); // Accumulate change in bearing;

theta -= ((double)((int)(theta/TWOPI))*TWOPI); // clip to +/- 360

xPos += pixelsPerMeter * distance * sin(theta);

yPos += pixelsPerMeter * distance * cos(theta);

PlotPoint((int)xPos,(int)yPos); // Plot the pixel on the screen