Dot 4 & 5.1 CAN be mixed safely, but you're not getting any benefits of the 5.1 if you do.
Dot 4 doesn't need changing quite as often as 5.1, but has a lower boiling point, so if you have a overheating issue, get some fresh new 5.1
Don't use an old bottle either, make sure it's fresh.
Dot 5 is different stuff completely & needs avoiding-it won't do your brakes much good at all.