Hello Sheehan, 

 I have unsuccessfully tried to understand how works the differential 
equation solver (I do not understand the Airy example).

It would be nice to have an example of code for a simple BVP such as :

u" + 2(1-x^2)u + u^2 = 1 ,  u(-1) = u(1) = 0


Regards,
Stéphane

Le lundi 24 mars 2014 02:04:25 UTC+1, Sheehan Olver a écrit :
>
>
> I tagged a new release for ApproxFun (
> https://github.com/dlfivefifty/ApproxFun) with major new features that 
> might interest people.  Below are ODE solving and random number sampling 
> examples, find more in ApproxFun/examples.  The code is meant as alpha 
> quality, so don't expect too much beyond the examples.  There is 
> rudimentary support for PDE solving (e.g. Helmholtz in a square), but it's 
> reliability is limited without a better Lyapanov solver (
> https://github.com/JuliaLang/julia/issues/5814).  
>
> Cheers,
>
> Sheehan
>
>
>
>
>     Pkg.add("ApproxFun")
>     using ApproxFun
>
> *ODE Solving: solve the Airy equation on [-1000,10]*
>
>     x=Fun(identity,[-2000.,10.])
>     d=x.domain
>     D=diff(d)
>     ai=[dirichlet(d),D^2 - x]\[airyai(-2000.),0.]
>     plot(ai)
>
>
>
>
> *Random number sampling: Sample a 2D Cauchy distribution on (-∞,∞)^2*
>
>  f = Fun2D((x,y)->1./(2π.*(x.^2 .+ y.^2 .+ 1).^(3/2)),Line(),Line())
> r = sample(f,100)
>
>
>

Reply via email to