Skip to content
This repository was archived by the owner on Sep 9, 2024. It is now read-only.
This repository was archived by the owner on Sep 9, 2024. It is now read-only.

ode45 should support stepping from high to low and support a vector of steps #2

@ViralBShah

Description

@ViralBShah

The original issue was filed as JuliaLang/julia#365. Moving it here in the context of the ODE package.

ode45 should support stepping from high to low like ode23 does, and both should also support any-size vectors of steps instead of just [t0, tfinal].

I'd like to do

function tracywidom()
    t0 = 5.
    tn = -8.
    dx = .005

    deq = function (t::Float64, y::Vector{Float64})
        [y[2]; t*y[1]+2*y[1]^3; y[4]; y[1]^2]
    end

    y0 = [airy(t0); airy(1,t0); 0; airy(t0)^2]

    (t, y) = ode45(deq, [t0:-dx:tn], y0)

    F2 = exp(-y[:,3][:])
    f2 = gradient(F2,t)
    return (t, f2)
end

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions