Quantcast
Channel: Visual C# forum
Viewing all articles
Browse latest Browse all 31927

Help for C# function plotting

$
0
0

My question is: Is there a simple way to convert a string to a single executable instruction?

For example:

string function = "x*x+Math.Sin(x)";

public double f(double x)

{

return function.Something...();

//it should return x*x+Math.Sin(x);

}

P.S.: The string is written correctly at all times


Viewing all articles
Browse latest Browse all 31927

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>