A CAN of refried beans? For backpacking? Surely you jest?
I’ve paid as little as $1.00 for a package of these. Andrew Skurka has a recipe for beans and rice based on these instant beans.
https://santafebean.com/Santa_Fe_Bea.../Products.html
Wayne