The Formation of a Gerund
Gerunds, or verbal nouns, are formed by adding –ing to the verbs and used in sentences as nouns. Like other nouns, gerunds act as direct objects, indirect objects, and objects of the preposition.
When a verb ends in -ing, it may be a present participle or it may be a gerund.
Eg. Tom placed the dining table in the middle of the room. (Gerund. Here the table is not dining. Tom uses it for dining.)
The main attraction of the event was Alice, the smiling girl. (Present participle. Here Alice is smiling. She is not used for smiling.)