## Simply Reading it.
If it isn't in some form of code, you can "read" it if it is on your spell list just fine as evidenced by the fact that you can read scrolls of spells on your spell list even if you don't know the spell.

If it isn't on your spell list, and you proficient in arcana and the book isn't in code you should be able to ***try*** "read" it with something [arcana check][1].

> ### Arcana
> 
>Your Intelligence (Arcana) check measures your ability to recall lore about spells, magic items, eldritch symbols, magical traditions, the planes of existence, and the inhabitants of those planes.

That doesn't mean you can grasp the spell from the spell book enough to cast it. This will tell you what is written in the book. You'd learn what spells are in the book and their general effect.

## Casting From It

You can't cast it without **fully** understanding it. Which, for a wizard, requires studying it and copying it into your own notation into [your spellbook][2] which requires time and gold. And then preparing it.

>For each level of the spell, the process takes 2 hours and costs 50 gp. The cost represents material components you expend as you experiment with the spell to master it, as well as the fine inks you need to record it. Once you have spent this time and money, you can prepare the spell just like your other spells.

For other classes, knowing that it is a fireball, doesn't allow you to cast it.  
Unless it is Ritual, and you have Ritual Caster feat or class feature, then you may be able to cast it depending on your particular ability.

## Magic Item Spell Books

Some magic item spellbooks might be the exception to that.  The DMG lists a few.

 - Book of Vile Darkness
 - Tome of Stilled Tounge

These are just fancied up spell casting foci that grant spells, benefits or other effects (Book of Vile Darkness can cause insanity for instance).

  [1]: https://www.dndbeyond.com/sources/basic-rules/using-ability-scores#Arcana
  [2]: https://www.dndbeyond.com/classes/wizard#ClassFeatures