A metric space is a set paired with a real-valued metric function , such that the following properties hold,

  • identity of indiscernibles: iff for all
  • symmetry: for all
  • triangle inequality: for all .