geometry fit functions additions and improvements