The term elasticity in economics is almost surely linked to the concept of elasticity in physics.
While the introduction of the term elasticity in economics is attributed to Marshall, as far as I know, we haven’t an explicit source about the reason why Marshall chose this term.
But we can make conjectures that are not arbitrary and are based on relevant sources.
It is well known that the mathematization of economics in the second half of the XIX century referred widely to physics, and mathematical economists as Edgeworth, Walras, Pareto, Marshall himself, knew physics, and referred often to physics in their works.
In particular, Pareto wrote his graduation thesis in engineering on Principles of the theory of elastic solid bodies (Engl. transl).
Marshall knew their works, as he explicitly quotes them in his Principles of Economics
(1890)
.
Moreover, in Appendix C, sec. 2. The method in economics, physics and biology, of the Principles, he explicitly compares the methodology of physics and economics:
It is true that the forces with which economics deals have one advantage for
deductive treatment in the fact that their method of combination is, as Mill observed, are
that of mechanics rather than of chemistry. That is to say, when we know the action of
two economic forces separately—as for instance the influences which an increase in
the rate of wages and a diminution in the difficulty of the work in a trade will
severally exert on the supply of labour in it—we can predict fairly well their conjoint
action, without waiting for specific experience of it .[…] (p. 449)
Marshall himself had a degree in mathematics and physics at the University of Cambridge.
So, the hypothesis that Marshall had in mind the terminology of physics and the elasticity of a body, or the stretching of a wire, is more than reasonable (even if the concept of elasticity in economics and in physics are of course different).
$$***$$
In many economics texts it is taken for granted that the term elasticity in economics comes from the terminology of physics.
For an example,
Lionello Rossi, Del concetto di elasticità in economia (Engl. Tr. About the Concept of Elasticity in Economics), 1932
In this article, Rossi seems to take for granted that the concept of elasticity in economics originates from physics, and discusses the actual use in economics of the term elasticity and other terms coming from mechanics as rigidity and anelastic, comparing their use in economic and in physics.
For instance, he writes:
We try […] to clarify the concepts outlined above, and we start
making few remarks about the homonymous mechanical concepts[…]
In mechanics a body is defined elastic if, when deformed under the
action of a stimulus, has the property to resume its primitive form
[…]
The concept of rigidity, instead, defines the greater or smaller
deformability, and therefore it is not antithetical to the concept of
elasticity […]. That is, rigidity denotes a further property of
elastic bodies. Anelasticity, instead, it a concept antithetical to
that of elasticity[…].
That said about mechanical concepts, what about homonymous concepts of
economics?
The only concept that in the common use has a perfect analogy with the
concept of mechanics is that of rigidity […]; and the authors seem to
agree about it.
Instead, the concept of elasticity, would be, according to Marshall,
nothing more than the opposite of the concept of rigidity[…].
Whatever the mechanical concepts are, in economics the Marshallian
definition of elasticity as variability and antithetical to rigidity
seems obvious, in relations to the denominations that entered the
common usage, reserving the name of anelasticity to a different
concept, conform to the mechanical one […]. (pp. 20-21, my transl.)