Sha256: 0d0b6a3e6ee57f32f9d239af1ca31baa275bb44236cfcc3c9b062db944f65877

Contents?: true

Size: 437 Bytes

Versions: 8

Compression:

Stored size: 437 Bytes

Contents

# encoding: utf-8

# Runge-Kutta method. Like vanilla Euler method, assumes that only T transitions are in the net.
# 
module YPetri::Core::Timed::RungeKutta
  def delta Δt
    fail NotImplementedError, "RungeKutta not implemented yet!"
    # Of course, the following line is from Euler method.
    # The formula of Runge-Kutta is more complicated.
    # 
    gradient * Δt
  end
  alias Δ delta
end # YPetri::Core::Timed::RungeKutta

Version data entries

8 entries across 8 versions & 1 rubygems

Version Path
y_petri-2.3.10 lib/y_petri/core/timed/runge_kutta.rb
y_petri-2.3.9 lib/y_petri/core/timed/runge_kutta.rb
y_petri-2.3.8 lib/y_petri/core/timed/runge_kutta.rb
y_petri-2.3.6 lib/y_petri/core/timed/runge_kutta.rb
y_petri-2.3.5 lib/y_petri/core/timed/runge_kutta.rb
y_petri-2.3.4 lib/y_petri/core/timed/runge_kutta.rb
y_petri-2.3.3 lib/y_petri/core/timed/runge_kutta.rb
y_petri-2.3.2 lib/y_petri/core/timed/runge_kutta.rb