I have had the alarm go off on my car because I locked it with the fob but when I returned to it the fob wouldn't work (the battery had died), unlocking with the key caused the alarm to go off. The way to silence it was to put the key in the ignition, turn on and wait till alarm stopped -- then you could start and drive normally.
If you lock the car with the key then you can unlock with the key and the alarm won't go off, it only happens if you lock with the fob then unlock with the key. According to the handbook this is to prevent theft using a duplicate key (because the duplicate key's fob would not have the correct code unlock the door and unlocking with the key itself will result in the alarm sounding). Mind you if the would-be thief knew enough he would simply put his duplicate key in the ignition and wait till the alarm stopped then drive off.
The car? an 8 year old Kia (don't laugh -- it's fine as a daily runner) so it's unlikely to be stolen anyway :-).