Skip to content

Leapfrog integration #88

@cablanc

Description

@cablanc

q_next = q + p_next_half * self.delta_t

I think there is an issue with the leapfrog step. The current implementation updates q using:

p_next_half = p + dp_dt * (self.delta_t) / 2
q_next = q + p_next_half * self.delta_t

I think it should be changed to:

p_next_half = p + dp_dt * (self.delta_t) / 2
dq_dt, _ = self._get_grads(q, p_next_half, hnn)
q_next = q + dq_dt * self.delta_t

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions