The story
- Spanish · derived fromalmártaga
- Latin · derived frommaritima
- Occitan · derived frommartegalo
- Middle French · borrowed frommartingale
- English todaymartingale
From Middle French martingale, from Occitan martegalo, feminine form of martegal, an inhabitant of Martigues, which is from Latin maritima. Possibly merged with Spanish almártaga. The meaning in gambling may come from an old usage of à la martingale to mean absurdly or foolishly.https://people.math.harvard.edu/~ctm/home/text/class/sem/html/home/notes/martingales/martingales.pdf
Etymology from Wiktionary, CC BY-SA 4.0.