Keep at all times, the minus sign above aligned with minus sign below
Do you mean like this?
\documentclass{article}
\usepackage{xparse,array}
\ExplSyntaxOn
\NewDocumentCommand{\frg}{mm}
{
\dbn_frg:nn { #1 } { #2 }
}
\tl_new:N \l__dbn_frg_num_tl
\tl_new:N \l__dbn_frg_den_tl
\cs_new_protected:Nn \dbn_frg:nn
{
\tl_set:Nn \l__dbn_frg_num_tl { #1 }
\tl_set:Nn \l__dbn_frg_den_tl { #2 }
\regex_replace_once:nnN { (\+|\-) } { \cT\& \1 \cT\& } \l__dbn_frg_num_tl
\regex_replace_once:nnN { (\+|\-) } { \cT\& \1 \cT\& } \l__dbn_frg_den_tl
\begin{array}{@{} r @{} >{{}}c<{{}} @{} l @{} }
\l__dbn_frg_num_tl \\
\hline
\l__dbn_frg_den_tl
\end{array}
}
\ExplSyntaxOff
\begin{document}
\[
\frg{4-3}{4-1}\qquad \frg{4+3}{4+11} \qquad \frg{15-2}{6+12}
\]
\end{document}
I do not know what the purpose of this exercise is but alignment can e.g. achieved with an array. Notice that I didn't pay any attention to spacing, bold and etc. because I do not know the purpose.
\documentclass{article}
\makeatletter
\def\frg@aux#1-#2,#3-#4\@nil{\begin{array}{@{\,}r@{}c@{}l@{\,}}
#1&-\\
\hline
#3&-
\end{array}}
\def\frg#1{\frg@aux#1\@nil}
\makeatother
\begin{document}
\[ a=\frg{4 - 3, 3 - 1 }\]
\end{document}