addition to QuantLib-SWIG/SWIG/stochasticprocess.i

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

addition to QuantLib-SWIG/SWIG/stochasticprocess.i

Tito Ingargiola

Hi,

Could someone kindly add the below code to QuantLib-SWIG/SWIG/stochasticprocess.i

It's a purely additive change: it just exposes a teeny bit of functionality to users of the SWIG interfaces to QuantLib.

I have just tested it against the current repository and it builds and runs correctly.  If you provide me with access to that project, I'll be happy to make the change myself.  Thanks and regards,

     Tito.

--


%{
using QuantLib::GeometricBrownianMotionProcess;
typedef boost::shared_ptr<StochasticProcess> GeometricBrownianMotionProcessPtr;
%}

%rename(GeometricBrownianMotionProcess) GeometricBrownianMotionProcessPtr;
class GeometricBrownianMotionProcessPtr : public StochasticProcess1DPtr {
  public:
    %extend {
      GeometricBrownianMotionProcessPtr
          (double initialValue, double mue, double sigma) {
          return new GeometricBrownianMotionProcessPtr
              (new GeometricBrownianMotionProcess(initialValue, mue, sigma));
      }
    }
};

-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
QuantLib-dev mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/quantlib-dev
Reply | Threaded
Open this post in threaded view
|

Re: addition to QuantLib-SWIG/SWIG/stochasticprocess.i

Luigi Ballabio
On Sun, 2008-08-17 at 12:18 -0700, Tito Ingargiola wrote:
> Could someone kindly add the below code to
> QuantLib-SWIG/SWIG/stochasticprocess.i

Done, thanks.

Luigi


--

A programming language is low-level when its programs require attention
to the irrelevant.
-- Alan Perlis



-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
QuantLib-dev mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/quantlib-dev