LuaLaTeX | Beamer | fontspec | Define a Sans Serif Math Font

I think your best bet is mathastext.

\documentclass{beamer}
\usepackage[no-math]{fontspec}
\setsansfont[Scale=0.9]{DejaVu Sans Mono} % no MS Windows, sorry
\usepackage[italic]{mathastext}
\usepackage{mathtools}
\usepackage{isomath}
\newcommand*\diff{\mathop{}\!\mathrm{d}}

\begin{document}

\begin{frame}
  Testtext. Testtext. \textbf{Testtext.} Testtext. \textcolor{red}{Testtext.}

  \begin{align}
    1 + 2 &= x\\
    y(t) &= \int_0^\infty \sin(\alpha) \diff t
  \end{align}

  Testtext. Testtext. \textbf{Testtext.} Testtext. \textcolor{red}{Testtext.}
\end{frame}

\end{document}

enter image description here


Usually, I use arevmath for sans-serif math in beamer. Also, parts of the iwona fonts are helpful (for sans-serif integrals, for example, though big parentheses look a bit weird in this setup).

\documentclass[professionalfont]{beamer}
\usepackage{mathtools}
\usepackage{arevmath}
\SetSymbolFont{largesymbols}{normal}{OMX}{iwona}{m}{n}
\usepackage{fontspec}
%\setsansfont{PorscheNextTT}
%\setsansfont{Consolas} % Should be available on a Windows system
\setsansfont{Fira Sans} % I'm not on Windows, so Fira Sans instead

\begin{document}

\begin{frame}
Testtext. Testtext. \textbf{Testtext.} Testtext. \textcolor{red}{Testtext.}

\begin{align}
1 + 2 &= x\\
y(t) &= \int_0^\infty \sin(\alpha) d\text{t}
\end{align}

Testtext. Testtext. \textbf{Testtext.} Testtext. \textcolor{red}{Testtext.}
\end{frame}

\end{document}

The result:

enter image description here


As a quick hack, you could use your text font for the "normal" letters in math using the no-math option of fontspec. For all symbols which are not part of your font, the default sans serif ones of beamer will be used.

% !TeX TS-program = lualatex
\documentclass{beamer}
\usepackage[no-math]{fontspec}
\usepackage{mathtools}
%\setsansfont{PorscheNextTT}
\setsansfont{Consolas} % Should be available on a Windows system

\begin{document}

\begin{frame}
Testtext. Testtext. \textbf{Testtext.} Testtext. \textcolor{red}{Testtext.}

\begin{align}
1 + 2 &= x\\
y(t) &= \int_0^\infty \sin(\alpha) d\text{t}
\end{align}

Testtext. Testtext. \textbf{Testtext.} Testtext. \textcolor{red}{Testtext.}
\end{frame}

\end{document}

enter image description here