Background: I am currently developing a general purpose programming language which allows formal verification (i.e. correctness proofs) of programs. During the development it came out that a lot of mathematics (order theory, lattice theory, cpos, etc.) is necessary to reach a sound definition.

For objects it is necessary to distinguish between identity and equality. Two objects are identical if they are indistinguishable. For this notion I have used the symbol $\sim$ (i.e. $a\sim b$ means the object $a$ is indistinguishable from the object $b$. Furthermore I allow user specific definitions of equality using the $=$ sign. I.e. $a=b$ means that $a$ and $b$ are equivalent with respect to some equivalence relation.

During my study of the needed mathematical theories I get more and more convinced that it would be better to take $=$ for identity or indistinguishability and $\sim$ for equalitiy or equivalence.

Is there a commonly accepted usage of symbols in mathematics expressing the notion of identy and equality?

P.S. For those who are interested in the definition of the programming language here is a link to my blog

  • 1
    $\begingroup$ Depends who you are I guess, $=$ is usually equals to. For identity/definition I have seen $\equiv$, $\stackrel{!}{=}$, $\stackrel{\bigtriangleup}{=}$ or if dealing with a specific equivalence relation $\sim$. $\endgroup$
    – dcs24
    Oct 17, 2012 at 15:11
  • $\begingroup$ I see $=$ is used in mathematics for equality in the sense of identity. $a=b$ usually means I can substitute $a$ by $b$ and vice versa in any formula. I think this is called Leibnitz equality. $\endgroup$ Oct 17, 2012 at 16:14
  • $\begingroup$ Unfortunately for understanding your question, most mathematicians use "equal" and "identical" as synonyms. "Indistinguishable" is sometimes weaker --- meaning that certain specific tools or criteria won't distinguish the two things, which might nevertheless be distinct. (E.g., identical twins might be genetically indistinguishable".) I would use "x=y" to mean that "x" and "y" are two names for the same entity. So = would be the strongest (i.e., smallest) possible equivalence relation. $\endgroup$ Oct 17, 2012 at 16:26
  • $\begingroup$ @Andreas: You confirm my suspicion that in mathematics "equal" and "identical" are used as synonyms, i.e. $=$ is the strongest equivalence relation. This implies that I have to reconsider my decision to use = for equality in the sense of equivalence with respect to some equivalence relation (which might not be the strongest possible) and ~ for identity (i.e. the strongest equivalence relation. $\endgroup$ Oct 17, 2012 at 17:00
  • 1
    $\begingroup$ Well, if you're going to type all this on a keyboard, consider using =, or ==, or even ===, for different types of assignment, equality, and comparison (see Mathematica for example). $\endgroup$ Oct 17, 2012 at 19:16


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.