How does identity work in modal predicate logic?

Namely how can we can have a correspondence between objects in different possible worlds if they are different?

If we have two worlds in S5

aw0(P(x)) = 1 and aw1(P(x)) = 0

How can we 'identify' x in w0 and x in w1 if they don't follow the identity of indiscernible?

Is it just a distinction we make in our propositions that some predicates are necessary to objects and others are not? It's a matter of essence? Or is there some other mechanic that I'm missing? (I'm new to modal logic).

A general summary of this topic can be found on the SEP.

"Some predicates are necessary to objects and others are not"

is exactly right: at least sometimes, we use predicate modal logic in order to talk about necessary vs. contingent properties of objects. Certainly it's hard not to think of some properties as contingent (for example, I'm awake but I totally could be asleep).

Of course, this leaves open the question

"How can we 'identify' x in w0 and x in w1 if they don't follow the identity of indiscernible[s]?"

In a semantics where worlds are allowed to "share" objects but those objects can change properties between worlds, the equality relation between objects has to be granted as a separate primitive.

It's worth noting however that we can also have semantics where worlds don't directly share objects but do have a notion of "analogous object:" basically, given a world w0 which sees a world w1 we have a relation between the objects of w0 and the objects of w1 such that each object of w0 is related to at least one object of w1. This relation captures "is a possible version of," and saves us from having to literally identify objects in different worlds; this approach is called counterpart semantics.

• Thank you, that clears it up. Commented May 4, 2020 at 17:54
• @MasonC.Hart If this answered your question please upvote and accept this answer by clicking on the check mark on the left. It rewards the answerer and indicates to other users that the question is addressed to the poster's satisfaction. Commented May 5, 2020 at 23:29