Tehilim 74:13-17 recounts a series of victories of Hashem. The first couplet documents victories in battle against both the tanin and the Leviathan:
אַתָּ֤ה פוֹרַ֣רְתָּ בְעׇזְּךָ֣ יָ֑ם שִׁבַּ֖רְתָּ רָאשֵׁ֥י תַ֝נִּינִ֗ים עַל־הַמָּֽיִם׃
13 You divided the sea by your might; you broke the heads of the dragons in the waters. (NSRV)
אַתָּ֣ה רִ֭צַּצְתָּ רָאשֵׁ֣י לִוְיָתָ֑ן תִּתְּנֶ֥נּוּ מַ֝אֲכָ֗ל לְעָ֣ם לְצִיִּֽים׃
14 You crushed the heads of Leviathan; you gave him as food for the creatures of the wilderness.
Then turns to acts of creating day/night, waters, stars, and seasons:
אַתָּ֣ה בָ֭קַעְתָּ מַעְיָ֣ן וָנָ֑חַל אַתָּ֥ה ה֝וֹבַ֗שְׁתָּ נַהֲר֥וֹת אֵיתָֽן׃
15 You cut openings for springs and torrents; you dried up ever-flowing streams.
לְךָ֣ י֭וֹם אַף־לְךָ֥ לָ֑יְלָה אַתָּ֥ה הֲ֝כִינ֗וֹתָ מָא֥וֹר וָשָֽׁמֶשׁ׃
16 Yours is the day, yours also the night; you established the luminaries and the sun.
אַתָּ֣ה הִ֭צַּבְתָּ כׇּל־גְּבוּל֣וֹת אָ֑רֶץ קַ֥יִץ וָ֝חֹ֗רֶף אַתָּ֥ה יְצַרְתָּֽם׃
17 You have fixed all the bounds of the earth; you made summer and winter.
What is the connection between the victories against these monsters and the creation account here? Why does one follow the other?