var php_base = "non_health_calculators/\nominal_to_effective/";

var nominal_value = document.getElementById('nominal_value');


function calculate_effective()
{
	var nominal = get_value('nominal_value');
	var effective = (Math.pow((1 + nominal / 1200), 12) - 1) * 100;
	effective = Math.round(effective * 100) / 100;
		
	set_value('effective_value', effective);
}

function select_correct_handler(func, index)
{
	for (var i = 0; i < gslider_array.length; i++)
	{
		gslider_array[i].onchange = func;
		
	}	
}
select_correct_handler(calculate_effective, 0);

