"I have gone to the office."
Translation:Dw i wedi mynd i'r swyddfa.
The 'n/yn is required to link forms of bod (being, to be) such as - such as dw i and dych chi - with verb-nouns such as mynd where the sense is of an unfinished action (I am going, I go, I will be going, I will go, I was going, etc) wedi is used instead where the action is completed (I have gone, I will have gone, I had gone, etc).
yn and wedi cannot be used together in this sense. So:
- Dw i'n mynd... - I am going...
- Dw i wedi mynd... - I have gone...
This use of 'n/yn is explained in the notes for the sections on 'Present Tense'. See also the informal explanation here which includes two other uses of yn.
This is in the hover hints - 'to the':
- i - to (a preposition)
- 'r/yr/y - the
if you go through the section 'The', you will see that 'r is the form of 'r/yr/y (the) that is used following a word that ends in a vowel, in which case the two then join together. So:
- i + 'r = i'r
The i in dw i is the pronoun i, meaning 'I'. So:
- dw i - I am