You can create a function called Evaluate and use that function to evaluate your string(1/4).
See
this[
^]:
static double Evaluate(string expression)
{
var loDataTable = new DataTable();
var loDataColumn = new DataColumn("Eval", typeof(double), expression);
loDataTable.Columns.Add(loDataColumn);
loDataTable.Rows.Add(0);
return (double)(loDataTable.Rows[0]["Eval"]);
}
Now call this function:
double value = Evaluate("1/4");
Console.WriteLine(value);
--Amit