In order to use Unicode maths in pdflatex as well as in LuaTeX, in preamble of my document I have:
\usepackage{ifxetex,ifluatex}
\ifnum 0\ifxetex 1\fi\ifluatex 1\fi=0 % if pdftex
\usepackage[T1]{fontenc}
\usepackage[utf8]{inputenc}
\usepackage{textcomp} % provide euro and other symbols
\usepackage{newunicodechar}
\newunicodechar{ρ}{\rho}
\newunicodechar{∈}{\in}
\newunicodechar{μ}{\mu}
\newunicodechar{≠}{\neq}
% ... and more of these \newunicodechar
%
\else % if luatex or xetex
\usepackage{unicode-math}
\defaultfontfeatures{Scale=MatchLowercase}
\defaultfontfeatures[\rmfamily]{Ligatures=TeX,Scale=1}
\fi
This allows one to have an arxiv.org-submittable document (arxiv.org does not do LuaTeX).
However, I wonder whether there is actually a package I can use instead of manually writing out all these \newunicodechar{...}{...}, as it looks pretty standard to me.

\inis imho much faster. Side remark: in current latex neither textcomp nor inputenc is needed. – Ulrike Fischer Jun 16 '21 at 21:09\mathscrand\mathcalmean the same font in Unicode, and emojic things like red heart are just begging for troubles. (C) I sometimes want some flexibilities; for instance\def†#1†{\text{#1}}and\def…{,\allowbreak\dotsc,\allowbreak}. So a good interface is all I need. – Symbol 1 Jun 16 '21 at 21:11iftexpackage you can use\iftutexwhich is true in xetex and luatex rather than teh nested\ifnumgame. – David Carlisle Jun 16 '21 at 21:24unicode-mathpackage with luatex as well) but if you do want this you can inputunicode-mathpackage'sunicode-math-table.texwith a suitable definition of\UnicodeMathSymbolwhich defines the definitions in the "reverse" definition. – David Carlisle Jun 16 '21 at 21:28newunicodechar's, it was whatpandocproduced after convering a markdown doc with some unicode maths in it to LaTeX. – Dima Pasechnik Jun 16 '21 at 21:41