Cum

cum as a preposition means with, cum as a conjunction means {when, since, although} and as a conjunction it can optionally introduces a clause.

Cum as a preposition regularly is followed by the ablative case.

etymology

it was originally two words: "con" as the preposition meaning with. You can still see it in compound words like consul and convocare. the other one was the conjunction quom, which was once the accusative of qui.

Cum Clauses

this is directly copied from Latin Library's PDF.

Cum can be a subordinating conjunction (what??) introducing a subordinate clause (what???). There are four types of cum clauses:

Temporal

A temporal cum clause simply states the time at which something occurs, without any further relationship between the events. The mood in a cum temporal clause is indicative:

Cum Caesar consul erat, domus mea incendebatur.
When Caesar was consul, my house was burned down.

Cum Romae estis, agite sicut Romani.
When you are in Rome, do like the Romans.

Circumstantial

A circumstantial cum clause states the circumstances or surrounding events at the time of the action in the main clause. The mood in a circumstantial cum clause is subjunctive.

Caesar cum loqueretur, ab inimicis interfectus est.
When Caesar was speaking, he was killed by his enemies.

Causal

A causal cum clause states the cause of the action in the main clause. Subjunctive.

Cum nox iam appeteret, ad speluncam devertit.
Because night was now approaching, he turned away into a cave.

Dux urbem dedit cum hostes extra portas essent.
The general surrounded the city because the enemies were at the gates. (what??)

Concessive

A concessive cum clause expresses an incompatibility between the two clauses. Subjunctive.

Cicero, cum in oppido parvo natus esset, Romae tamen vivebat.
Cicero, although he was born in a small town, nevertheless lived in Rome.

Cum copiae hostium essent maiores, Romani tamen eas vicerunt.
Although the forces of the enemy were greater, the Romans nevertheless overcame them.