Выражение:
^(\d{1,2}) h (\d{1,2}) m$
Код:
var input = "8 h 13 m";
var regex = new Regex(@"^(\d{1,2}) h (\d{1,2}) m$", RegexOptions.IgnoreCase | RegexOptions.Compiled);
var match = regex.Match(input);
if (!match.Success) throw new Exception();
int h = Int32.Parse(match.Groups[1].Value);
int m = Int32.Parse(match.Groups[2].Value);
var output = String.Format("{0}.{1}", h, m);
// or to be sure that that's the realistic numbers
var today = DateTime.Now;
var output2 = new DateTime(today.Year, today.Month, today.Day, h, m, 0).ToString("hh.mm");