I'm a bit lost as it's not clear to me exactly what you mean by 'hub number' and 'persons number'. However I'll take a bit of a guess that you currently connect your iPad to the internet through your BT Home Hub while in your house but you want to be able to use it with someone else's wi-fi while you're away. (If I've got that wrong please post again, with a bit more information about exactly what it is that you're seeking to do).
Assuming that I'm writing about the correct thing then, I'll start by pointing out that you don't need to 'change' anything; you simply need to 'add' another wi-fi connection. (i.e. when you return home your iPad will still connect to the wi-fi in your house; you won't need to 'change something back').
So, when you're in your friend's house (or in your B&B or wherever) all you need to do is to tap Settings and then Wi-Fi. Check that Wi-Fi is set to On and then look through the list of available networks to find the one that you friend's (or B&B's, etc) router is using. Tap on it. You'll then almost certainly be asked for the password which your friend/B&B/etc will have given you. Enter it and tap Join. That's all there is to it.
You should note however that (unlike people's homes, small B&Bs and independent pubs) big chain establishments (such as Wetherspoon's or Greene King pubs, major supermarkets, Costa, etc) usually have a slightly different system. With their way of connecting to wi-fi you won't be asked for a password in the way I've mentioned above. Instead you'll find that you seem to get straight onto their network but that any attempt at web browsing gets diverted to a registration or log-in page. So you'll need to complete the requirements shown on that page before you can start browsing.