function roundNumber(num, dec) {
	var result = Math.round(num*Math.pow(10,dec))/Math.pow(10,dec);
	return result;
}

function fixedNumber(num)
{
	var str_num = num.toString();
	var pos_point = str_num.indexOf('.');
	var integer_part = '';
	var decimal_part = '';
	
	if(pos_point != (str_num.length-1))
	{
		if(pos_point > 0)
		{
			integer_part = str_num.substr(0, pos_point);
			decimal_part = str_num.substr(pos_point, (str_num.length - pos_point));
		}
		else
		{
			integer_part = str_num;
			decimal_part = '';
		}
		if(decimal_part.length < 2)
		for(i=0;i<=decimal_part.length;i++)
		{
			decimal_part += '0';
		}
		return integer_part.concat + '.' + decimal_part;
	}
	else
		return str_num;
}