RSS

WinForm:Using Numerical Recipe in C#

10 Apr

In my previous post, I have presented how to use the code of Numerical Recipes in MFC/C++. In this post, the use of it in C# is discussed.

The most straightforward way is to use some wrapper class, e.g. the one presneted here, and a wrapper class is downloadable at link1 or from my backup link2 here.

Below is how to use it in C#:

1. Add the C# implementation of the snippets of “Numeric Recipe in C++”, 3rd edition into the project:

SharpNumericRecipe_A

2. Import the related namespace and call the functions of interest:SharpNumericRecipe_B

Note that the starting index of the matrix element is “1”, rather than “0” !

Emm, it works!

SharpNumericRecipe_C

Cheers and happy coding!

 
2 Comments

Posted by on April 10, 2011 in Dotnet/C#, Programming

 

Tags: , , , , ,

2 responses to “WinForm:Using Numerical Recipe in C#

  1. toto

    June 1, 2011 at 4:03 pm

    Hi,
    nice tutorial about Numerical Recipes. I am searching about numerical recipes code, because I want to create grid data in my thesis. Can you share to me code in Numerical Recipes about kriging method?
    THank you very much

    Regards,

    Toto

     
  2. Abbey

    July 13, 2015 at 8:01 am

    Thank you for this.

     

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

 
%d bloggers like this: