This project has moved. For the latest updates, please go here.

c++ example

Jun 18, 2011 at 11:25 PM

Hi people,

I need to implement LambertW function in my visual c++ project. I am using Visual studio 2010. I put reference to meta.numerics.dll, but I dont know how to call LambertW in my code.

I tried something, but it doesny work.

Thanks for a help.


Jun 19, 2011 at 10:35 PM

Here's example C++ CLR code that uses the LambertW function:

#include "stdafx.h"

using namespace System;
using namespace Meta::Numerics::Functions;

int main (array<System::String ^> ^args) {
    double x = 1.0;
    double y = AdvancedMath::LambertW(x);
    Console::WriteLine(L"W({0}) = {1}", x, y);
    return 0;


Note that your project must be C++ CLR. A native C++ project will not be able to use Meta.Numerics directly.