Fix include paths and divide by zero exception