Heart failure treatment algorithm