revision based on Jeremy's comments and modification in 02122013