"Ma'am" is a polite manner to call a lady and is a short version of "Madam." We've shortened it even further to a mam, most likely because to our Indian pronunciation method, in which we write what we say. Mom is either a mother or a married lady. There is no other way to know for sure unless you ask her. Writing "mam" instead of "madam" was very common in the 17th century when India had many English traders and settlers. It is from this country that we get the word "camel" as well as the verb "to camelize." Until recently, "mam" was used as a sign-off on letters to women who were not relatives or friends. For example, if you were writing to Mrs. Johnson about something she had no connection with, you would address the letter to "mam". The "mam" turned out to be her son's name! He must have been a famous athlete or musician because "mam" became a generic term for mothers of young men involved in sports or music. Now that I think about it, "mam" is also used as a sign-off on letters to fathers, but I've never heard it before so cannot give any examples.