Your vet is not the person to ask for behaviour advice.
Firstly ask your vet to give your dog a thorough physical check (including blood tests for thyroid function, and an eyesight check). Then ask for a referral to a good behaviourist, one who doesn't cling to the old-fashioned notions of pack theory and dominance (if you post whereabouts you are, members here may be able to advise you of someone to see).
Do I assume he was on your bed when you sat down? Was he asleep? Did you disturb him in any way, or was he startled?
Assuming he is physically well, it does sound like guarding behaviour, which can be very complex, but is managable with the right techniques. A really good book on the subject is "Mine" by Jean Donaldson. I would advise you, in the short term, to be careful not to invade his personal space - if he is on your bed, use a treat to lure him off before you sit down.... this isn't a solution to the problem, but should stop you being bitten in the meantime. If he does growl or warn you off in any way, respect this... back off and then call him away from the area he is protecting - again this is a short term strategy to prevent further aggression while you work on the issues that are leading to the guarding. Don't tell him off for any growling - this is his way of warning you he's uncomfortable with the situation. A behaviourist is best placed to give you longer-term advice, as they will be able to observe the whole spectrum of his behaviour and might be able to pinpoint causes/triggers which you are unaware of, and so can't tell us about.
Another good technique which can help in the meantime is hand-feeding - this is a great tool for building trust between dog and owner.
Also do be consistent about any rules you have - if, for example, you sometimes allow him on your bed, and other times he gets told off for being there he will get confused and will be more likely to react aggressively.
Personally, as the bed (and potentially the sofa??) are currently areas he *is* guarding, I would keep him off them - not to show him his place in the pack, but to prevent further conflict while you work on the behaviour. When he eats (before or after you) will have no bearing on his behaviour...
