>>2647093TL;DR: bear spray, noise maker, sidearm. rifle if you're in polar bear or maybe grizzly country. i roll with a 10mm. people kill grizzlies with .22's. the smaller the round the more you have to place your shots and the less it works when surprised/charged.
if you take a rifle keep a sidearm too. guys with guns get killed by bears and a typical cause is not being able to get to it. taking a piss/shit sleeping etc.
Full academic answer with a ton of shit on ballistics and pro gamer tips you won't have thought of:
https://archive.org/details/bearattackstheir00herr easy to find @ the library for a physical copy.