Yosemite National Park has an area of 1,169 square miles;in comparison, the State of Rhode Island is 1,214 square miles. Park biologists believe that Yosemite's population of black bears is between 300 and 500 bears. This means, assuming an even distribution of Yosemite's bears, there's one bear every 2.3 to 3.9 square miles. A black bear's sense of smell can easily be measured in miles.
Looking at a black bear's head, it's obvious that they have a very large nose. The area inside a black bear's nose, called the nasal mucosa, is 100 times greater than ours. This large nose results in an excellent sense of smell! Even bloodhounds, dogs so famous for their sense of smell that they're used to track missing people, don't smell as well a black bear. It is estimated that black bears' sense of smell is about seven times greater than a bloodhound's.
A black bear's sense of smell is so good that it's difficult to measure. Bears are commonly thought to have the keenest sense of smell in the animal kingdom, and estimates of the range of their sense of smell vary widely. Conservative estimates of a black bear's sense of smell state that a black bear can smell a food source from over a mile away, while other sources claim a black bear can smell food from over two miles away. A personal account from "The Great Bear Almanac" describes a black bear in California traveling "upwind three miles in a straight line to reach the carcass of a dead deer." More generous estimates place a black bear's sense of smell between 18 and 20 miles, which may sound extreme, until you learn that polar bears, the black bear's cousin, have been known to follow seals for up to 40 miles.
In summary, though it's difficult to measure just how far a black bear can smell, a range of a few miles isn't unrealistic. With 300 to 500 bears roaming Yosemite at any given time, it's more than likely that at least one of them are smelling you at all times. So the next time you're in Yosemite, take a minute to stop and think about everything you smell, and what also might be smelling you.