Standard notation for 'same' function with different ranges Does anyone know of a standard notation for the situation when we want to define the 'same' function but on a larger or smaller range.
More precisely, if $$f:A \to B$$ is a function and $C$ contains $f(A)$, then we can define a function $$g:A \to C$$ in the obvious way (put $g(a)=f(a)$). 
These functions are different, but it's extremely cumbersome to have to write out this difference every time.
(By the way, the context this has come up in has been in thinking about algebraic substructures. For example, if $G$ is a group then there is a binary operation $m$ on $G$ satisfying the usual properties. We'd like to define a subgroup by saying that it is a subset $H$ of $G$ which is a group under the restriction of $m$ to $H \times H$, but unfortunately this restriction is not a binary operation (because it's range is technically still $G$). So we're forced to make an annoying adjustment as described above...)
 A: I'm afraid I don't have the necessary points to comment, so here are my responses / clarifications. Thanks for the responses, by the way:
To Mathaholic:
I use the word 'range' to refer to the set $B$ in the definition of $f$ above, and 'image' for the set $f(A)$. 
To user331406: I understand that it works in this way, but the restriction of a function $f:A \to B$ to a subset $D$ of $A$ is defined as the function $f:D \to B$ - in other words, it doesn't change the range of the function.
A: This is often called the corestriction. A similar question was asked on mathoverflow
What's the notation for a function restricted to a subset of the codomain?
and the best answer I could find there, even though it is not marked, was the answer given by Mathy

It's called a range restriction. There's no established notation, but you might as well use the Z notation which is f  ▷ B'. (f \rhd B' in LaTeX plus amsfonts)

In the discussion of the same question there was this exchange

I'd be tempted to invent the notation B′|f for this. – Harald Hanche-Olsen Jun 29 '10 at 13:58
Anyway, Mizar mathematial library chose exactly this notation; actually, it is introduced in the article on basic relations RELAT_1.MIZ, Def. 12, so it fits any relation and any set.

to which Marco Caminati replied.

In a Mizar article you have just ASCII, so no subscripts, but you can always avoid ambiguities like f|X versus X|f by typing the two objects appearing in the notation as Relation and set respectively. I find interesting that what is expressible on paper by varying font size is emulated by typing in a proof checker. -
Marco Caminati  Aug 23 '10 at 14:19

