help mapping pot values to degrees like 99.5, 99.6 ect

I am trying to make an incubator controller for exotic chicken eggs, so far the code I have done works great. However when I ajust the max and min temp with the pot, I can only adjust to whole numbers, I need some help getting it to be able to adjust in decimel like: 94.1, 94.2, 94.3 ect ect. right now I can only adjust like this: 94, 95, 96, 97 ect ect?

//-------Import needed libraries
#include <OneWire.h> //-------Get 1-wire Library here: http://www.pjrc.com/teensy/td_libs_OneWire.html
#include <DallasTemperature.h> //-------Get DallasTemperature Library here:  http://milesburton.com/Main_Page?title=Dallas_Temperature_Control_Library
#include <Wire.h> //-------comes with arduino IDE
#include <LCD.h> //-------Download: https://bitbucket.org/fmalpartida/new-liquidcrystal/downloads
#include <LiquidCrystal_I2C.h> //-------Download: https://bitbucket.org/fmalpartida/new-liquidcrystal/downloads
#include <DHT.h>
#include <Time.h>
time_t elapsedTime;

//-------Declare Constants and Pin Numbers
#define ONE_WIRE_BUS 2 //-------Data wire is plugged into port 2 on the Arduino (can be changed) 
#define I2C_ADDR    0x27  //-------Define I2C Address for the 20x4 i2c lcd 
#define DHTPIN 3 //-------goes to data pin on dht22 sensor
#define DHTTYPE DHT22
#define HEAT 7 //-------goes to 4ch relay board pin 7 for fan and heat
#define EXTRA 8 // extra pin for relay board, future expansion
const int sensorPin = A0;  //-------analog pin reading from potentiometer

//-------Declare objects
OneWire oneWire(ONE_WIRE_BUS); // Setup a oneWire instance to communicate with any OneWire devices
DallasTemperature sensors(&oneWire); // Pass address of our oneWire instance to Dallas Temperature.
LiquidCrystal_I2C lcd(0x27, 2, 1, 0, 4, 5, 6, 7, 3, POSITIVE); // Start the LCD display library

//-------Declare Variables
int sensorValue = 0;  // variable to store the value coming from the sensor
int settempMax = 105; // variable to store temp desired
int settempMin = 95; // variable to store temp desired
const int switchPin = 4; // To switch between min and max
int switchReading;

//-------Assign the addresses of your 1-Wire temp sensors, See the tutorial on how to obtain these addresses: http://www.hacktronics.com/Tutorials/arduino-1-wire-address-finder.html

DeviceAddress Probe01 = { 0x28, 0x40, 0x45, 0x7E, 0x06, 0x00, 0x00, 0x3C }; 
DeviceAddress Probe02 = { 0x28, 0xEC, 0x5E, 0x7E, 0x06, 0x00, 0x00, 0x11 };
float tempC, tempF;
DHT dht(DHTPIN, DHTTYPE); //-------Initialize DHT sensor for normal 16mhz Arduino

void getTemperature(DeviceAddress deviceAddress) 
    {   
      sensors.requestTemperatures();   
      tempC = sensors.getTempC(deviceAddress);   
      tempF = DallasTemperature::toFahrenheit(tempC); 
    }  

//-------setup only runs once
void setup()   
{
//-------Initialize the pins
  pinMode(HEAT, OUTPUT);
  digitalWrite(HEAT, HIGH);
  pinMode(switchPin,INPUT);
  pinMode(EXTRA, OUTPUT);
  digitalWrite(switchPin, HIGH);
  digitalWrite(EXTRA, HIGH);
  
//-------Initialize the Temperature measurement library
  sensors.begin(); 
  sensors.setResolution(Probe01, 9); //-------set the resolution to 10 bit (Can be 9 to 12 bits .. lower is faster)
  sensors.setResolution(Probe02, 9); //-------set the resolution to 10 bit (Can be 9 to 12 bits .. lower is faster)
  dht.begin(); //-------initialize the dht sensor  
  
//-------Initialize the lcd, display startup message 
  lcd.begin (20,4);  //-------begin lcd for a 20 characters, 4 line display
  lcd.setCursor(6,0); //-------Start at character 6 on line 0
  lcd.print("Welcome");
  delay(1000);
  lcd.setCursor(9,1);
  lcd.print("To");
  delay(1000);
  lcd.setCursor(6,2);
  lcd.print("CHUCK'S");
  delay(1000);
  lcd.setCursor(0,3);
  lcd.print("Incubator Controler");
  delay(2000);
  
//-------setup static display for temp probe data
  lcd.clear();
  lcd.setCursor(0,0);
  lcd.print("EGG");
  lcd.setCursor(0,1);
  lcd.print("AIR");
  lcd.setCursor(0,2);
  lcd.print("Rh%");
  lcd.setCursor(0,3);
  lcd.print("OUT");
  lcd.setCursor(11,0);
  lcd.print("SetM");
  lcd.setCursor(11,1);
  lcd.print("Setm");
  
}
//-------end setup

//-------LOOP: RUNS CONSTANTLY
void loop()   
{
  elapsedTime = now();
  lcd.setCursor (11,3);               
  lcd.print("DAYS ");             // elapsed days
  lcd.print(elapsedTime / SECS_PER_DAY);
  
  lcd.setCursor(4,0); //-------Start at character 0 on line 0
  displayTemperature(Probe01); //-------print temp from probe 1 on lcd (inside incubator temp)
  
  lcd.setCursor(4,3); //-------Start at character 0 on line 1
  displayTemperature(Probe02); //-------print temp from probe 2 on lcd (outside temp out)
  
  int sensorValue = analogRead(sensorPin);

  switchReading = digitalRead(switchPin);// represents digitalRead(SwitchPin);
  if (switchReading == LOW)
  {
  settempMax = map(sensorValue, 0, 1023.0, 95, 104);
  lcd.setCursor(17,0);
  lcd.print(settempMax);
  }
  else
  {
  settempMin = map(sensorValue, 0, 1023, 95, 104);
  lcd.setCursor(17,1);
  lcd.print(settempMin);
  
  }
  if (settempMax < 100)
      {
        lcd.setCursor(19,0);
        lcd.print(".");
      }
  if (settempMin < 100)
      {
        lcd.setCursor(19,1);
        lcd.print(".");
      } 
  
    getTemperature(Probe01);
    {
  
     if  (tempF < settempMin) // IF TEMP ON SENSOR0 (probe01) IS less THAN settempm (reading from potentiometer) turn on heat 
     {
     digitalWrite(HEAT, LOW);
     lcd.setCursor(11,2);
     lcd.print("Heat ON.");
     
     }
     else if  (tempF > settempMax) // if temp on sensor 0 probe 01 is greater then settempM (reading from potentiometer) turn off heat
     {
     digitalWrite(HEAT,HIGH);
     lcd.setCursor(11,2);
     lcd.print("Heat OFF ");
     }

   }
   
  int h = dht.readHumidity(); //-------read dht sensor humidity
  int f = dht.readTemperature(true); // Read dht temperature as Fahrenheit
  if (isnan(h)  || isnan(f)) 
  {
    lcd.setCursor(13,2);
    lcd.print("");
    lcd.setCursor(13,3);
    lcd.print("");
    
  } 
  
//-------indoor temp display from dht22
      lcd.setCursor(4,1);
      lcd.print(f);
	
//-------indoor relative humidity display from dht22	
    lcd.setCursor(4,2);
    lcd.print(h);

   
}
//-------end main loop  
  
//-------Declare User-written Functions
void displayTemperature(DeviceAddress deviceAddress)
{

float tempC = sensors.getTempC(deviceAddress);

   if (tempC == -127.00) // Measurement failed or no device found
   {
	lcd.setCursor(13,2);   
        lcd.print(""); //-------print temp err on the lcd
	lcd.setCursor(13,3);
	lcd.print("");
   } 
   else
   {
   lcd.print(DallasTemperature::toFahrenheit(tempC)); // Convert to F 
   }
}// End printTemperature

//*********( THE END )***********

I know it relates to this:

int sensorValue = 0;  // variable to store the value coming from the sensor
int settempMax = 105; // variable to store temp desired
int settempMin = 95; // variable to store temp desired

int sensorValue = analogRead(sensorPin);

  {
  settempMax = map(sensorValue, 0, 1023.0, 95, 104);

I am thinking the int's have to be floats, however am unsure how to do this, as I replaced the int with float and it still did not work. Perhaps the map is screwing it up

I did pay attention in school and barely passed algebra Math is not my strong suit, and I am trying to figure it out on my own, just a few pointers in the right direction would be appreciated. This is what I am thinking now:

sensorValue = analogRead (sensorPin);
float settempMax =  104.0 * sensorValue/ 1023.0;
lcd.setCursor(17,0);
lcd.print(settempMax, 2);

The above code I just posted:
float settempMax =  104.0 * sensorValue/ 1023.0;
works great exactly as expecteddisplay to 2 dec places. However it has a range of 0 to 104 and that is too wide of a range. How would I constrain the range to like 98.0 to 104.0

aspireonescs:
I did pay attention in school and barely passed algebra Math is not my strong suit, and I am trying to figure it out on my own, just a few pointers in the right direction would be appreciated. This is what I am thinking now:

sensorValue = analogRead (sensorPin);

float settempMax =  104.0 * sensorValue/ 1023.0;
lcd.setCursor(17,0);
lcd.print(settempMax, 2);

Close.

You haven't used your lower limit of 95. The code above will give you values between 0 and 104.

You know sensorValue / 1023.0 will give you values between 0 and 1, but you need to map these to between 95 and 104, so:

95 + ((104 - 95) * sensorValue / 1023.0);

which simplifies to:
95 + (9 * sensorValue / 1023.0);

let's check:
when the sensor value is 0, we end up with 95 + 0 = 95.
when the sensor value is 1023, we end up with 95 + 9 = 104
when the sensor value is 512, we end up with 95 + 4.5 = 99.5

thank you very much arduinodlb, that works well and displays the expected values, however now that I changed it to float settempMax = 95 + (9 * sensorValue / 1023.0); the relay no longer turns on when: if (tempF < settempMin) digitalWrite(HEAT, LOW);

arduinodlb:
Close.

You haven't used your lower limit of 95. The code above will give you values between 0 and 104.

You know sensorValue / 1023.0 will give you values between 0 and 1, but you need to map these to between 95 and 104, so:

95 + ((104 - 95) * sensorValue / 1023.0);

which simplifies to:
95 + (9 * sensorValue / 1023.0);

let's check:
when the sensor value is 0, we end up with 95 + 0 = 95.
when the sensor value is 1023, we end up with 95 + 9 = 104
when the sensor value is 512, we end up with 95 + 4.5 = 99.5

please post your whole current code

Here it is, I can not figure out why that would break the relay's on and off cycyle

//-------Import needed libraries
#include <OneWire.h> //-------Get 1-wire Library here: http://www.pjrc.com/teensy/td_libs_OneWire.html
#include <DallasTemperature.h> //-------Get DallasTemperature Library here:  http://milesburton.com/Main_Page?title=Dallas_Temperature_Control_Library
#include <Wire.h> //-------comes with arduino IDE
#include <LCD.h> //-------Download: https://bitbucket.org/fmalpartida/new-liquidcrystal/downloads
#include <LiquidCrystal_I2C.h> //-------Download: https://bitbucket.org/fmalpartida/new-liquidcrystal/downloads
#include <DHT.h>
#include <Time.h>
time_t elapsedTime;

//-------Declare Constants and Pin Numbers
#define ONE_WIRE_BUS 2 //-------Data wire is plugged into port 2 on the Arduino (can be changed) 
#define I2C_ADDR    0x27  //-------Define I2C Address for the 20x4 i2c lcd 
#define DHTPIN 3 //-------goes to data pin on dht22 sensor
#define DHTTYPE DHT22
#define HEAT 7 //-------goes to 4ch relay board pin 7 for fan and heat
#define EXTRA 8 // extra pin for relay board, future expansion
int sensorPin = A0;  //-------analog pin reading from potentiometer

//-------Declare objects
OneWire oneWire(ONE_WIRE_BUS); // Setup a oneWire instance to communicate with any OneWire devices
DallasTemperature sensors(&oneWire); // Pass address of our oneWire instance to Dallas Temperature.
LiquidCrystal_I2C lcd(0x27, 2, 1, 0, 4, 5, 6, 7, 3, POSITIVE); // Start the LCD display library

//-------Declare Variables
int sensorValue = 0;  // variable to store the value coming from the sensor
int settempMax = 0; // variable to store temp desired
int settempMin = 0; // variable to store temp desired
const int switchPin = 4; // To switch between min and max
int switchReading;

//-------Assign the addresses of your 1-Wire temp sensors, See the tutorial on how to obtain these addresses: http://www.hacktronics.com/Tutorials/arduino-1-wire-address-finder.html

DeviceAddress Probe01 = { 0x28, 0x40, 0x45, 0x7E, 0x06, 0x00, 0x00, 0x3C }; 
DeviceAddress Probe02 = { 0x28, 0xEC, 0x5E, 0x7E, 0x06, 0x00, 0x00, 0x11 };
float tempC, tempF;
DHT dht(DHTPIN, DHTTYPE); //-------Initialize DHT sensor for normal 16mhz Arduino

void getTemperature(DeviceAddress deviceAddress) 
    {   
      sensors.requestTemperatures();   
      tempC = sensors.getTempC(deviceAddress);   
      tempF = DallasTemperature::toFahrenheit(tempC); 
    }  

//-------setup only runs once
void setup()   
{
//-------Initialize the pins
  pinMode(HEAT, OUTPUT);
  digitalWrite(HEAT, HIGH);
  pinMode(switchPin,INPUT);
  pinMode(EXTRA, OUTPUT);
  digitalWrite(switchPin, HIGH);
  digitalWrite(EXTRA, HIGH);
  
//-------Initialize the Temperature measurement library
  sensors.begin(); 
  sensors.setResolution(Probe01, 9); //-------set the resolution to 10 bit (Can be 9 to 12 bits .. lower is faster)
  sensors.setResolution(Probe02, 9); //-------set the resolution to 10 bit (Can be 9 to 12 bits .. lower is faster)
  dht.begin(); //-------initialize the dht sensor  
  
//-------Initialize the lcd, display startup message 
  lcd.begin (20,4);  //-------begin lcd for a 20 characters, 4 line display
  lcd.setCursor(6,0); //-------Start at character 6 on line 0
  lcd.print("Welcome");
  delay(1000);
  lcd.setCursor(9,1);
  lcd.print("To");
  delay(1000);
  lcd.setCursor(6,2);
  lcd.print("CHUCK'S");
  delay(1000);
  lcd.setCursor(0,3);
  lcd.print("Incubator Controler");
  delay(2000);
  
//-------setup static display for temp probe data
  lcd.clear();
  lcd.setCursor(0,0);
  lcd.print("EGG");
  lcd.setCursor(0,1);
  lcd.print("AIR");
  lcd.setCursor(0,2);
  lcd.print("Rh%");
  lcd.setCursor(0,3);
  lcd.print("OUT");
  lcd.setCursor(10,0);
  lcd.print("SetM");
  lcd.setCursor(10,1);
  lcd.print("Setm");
  
}
//-------end setup

//-------LOOP: RUNS CONSTANTLY
void loop()   
{
  elapsedTime = now();
  lcd.setCursor (10,3);               
  lcd.print("DAYS ");             // elapsed days
  lcd.print(elapsedTime / SECS_PER_DAY);
  
  lcd.setCursor(4,0); //-------Start at character 0 on line 0
  displayTemperature(Probe01); //-------print temp from probe 1 on lcd (inside incubator temp)
  
  lcd.setCursor(4,3); //-------Start at character 0 on line 1
  displayTemperature(Probe02); //-------print temp from probe 2 on lcd (outside temp out)
  
  sensorValue = analogRead(sensorPin);

  switchReading = digitalRead(switchPin);// represents digitalRead(SwitchPin);
  if (switchReading == LOW)
  {
  float settempMax = 95 + (9 * sensorValue / 1023.0);   
  lcd.setCursor(15,0);
  lcd.print(settempMax);
  }
  else
  {
  float settempMin = 95 + ((104 - 95) * sensorValue / 1023.0);
  lcd.setCursor(15,1);
  lcd.print(settempMin);
  
  }
   
    getTemperature(Probe01);
    {
  
     if  (tempF < settempMin) // IF TEMP ON SENSOR0 (probe01) IS less THAN settempm (reading from potentiometer) turn on heat 
     {
     digitalWrite(HEAT, LOW);
     lcd.setCursor(10,2);
     lcd.print("Heat ON.");
     
     }
     else if  (tempF > settempMax) // if temp on sensor 0 probe 01 is greater then settempM (reading from potentiometer) turn off heat
     {
     digitalWrite(HEAT,HIGH);
     lcd.setCursor(10,2);
     lcd.print("Heat OFF ");
     }

   }
   
  int h = dht.readHumidity(); //-------read dht sensor humidity
  int f = dht.readTemperature(true); // Read dht temperature as Fahrenheit
  if (isnan(h)  || isnan(f)) 
  {
    lcd.setCursor(13,2);
    lcd.print("");
    lcd.setCursor(13,3);
    lcd.print("");
    
  } 
  
//-------indoor temp display from dht22
      lcd.setCursor(4,1);
      lcd.print(f);
	
//-------indoor relative humidity display from dht22	
    lcd.setCursor(4,2);
    lcd.print(h);

   
}
//-------end main loop  
  
//-------Declare User-written Functions
void displayTemperature(DeviceAddress deviceAddress)
{

float tempC = sensors.getTempC(deviceAddress);

   if (tempC == -127.00) // Measurement failed or no device found
   {
	lcd.setCursor(13,2);   
        lcd.print(""); //-------print temp err on the lcd
	lcd.setCursor(13,3);
	lcd.print("");
   } 
   else
   {
   lcd.print(DallasTemperature::toFahrenheit(tempC)); // Convert to F 
   }
}// End printTemperature

//*********( THE END )***********

Try modifying your line to this:

float settempMin = 95.0f + ((104.0f - 95.0f) * (float)sensorValue / 1023.0f);

OK. You have a scope problem. You are redeclaring your variables in a different scope.

Change this:
float settempMin = 95 + ((104 - 95) * sensorValue / 1023.0);
to
settempMin = 95 + ((104 - 95) * sensorValue / 1023.0);

and this:
float settempMax = 95 + (9 * sensorValue / 1023.0);
to
settempMax = 95 + (9 * sensorValue / 1023.0);

Also, at the top of your file, change the setTempMax and Min to floats instead of ints.

Ah ha! that makes perfect sense arduinodlb, and it works great. I was thinking that I had to declare it every time it was written. now I see that if I declare a float variable at the top, then I do not have to re-declare as a float, again in the loop. This would apply to int's as well. I fully understand it now, though the algebra is fuzzy for me, really its the formula. I understand how to do the quations, its the coming up with the right formula to use that gets me. I will further research this, I guess the floating point numbers reference would be a good start?

aspireonescs:
Ah ha! that makes perfect sense arduinodlb, and it works great. I was thinking that I had to declare it every time it was written. now I see that if I declare a float variable at the top, then I do not have to re-declare as a float, again in the loop. This would apply to int's as well.

Actually, it's worse than that. If you do re-declare it in a different scope, it actually is a completely separate variable. You may as well give it a different name, as it also exists, but just happens to have the same name as another variable, which causes a lot of confusion and bugs. So yeah, general rule of thumb, only declare variables with the same name once if you want to to avoid problems.