Can the members of the domain be in the members of the range and be a function?

Yes, the domain must correspond to only one member of the range in order to be a function in a member of the domain goes to more than one member of the range it then is a relation and not a function

A function is a relation but a relation isnt always a function