File:Euler Maruyama example.svg

From Wikimedia Commons, the free media repository
Jump to navigation Jump to search

Original file(SVG file, nominally 630 × 630 pixels, file size: 41 KB)

Captions

Captions

Add a one-line explanation of what this file represents

Summary[edit]

Description
English: en:Euler-Maruyama method for SDE dS = S dW, S(0) = 1, step size 0.01, with exact solution (black)
Deutsch: de:Euler-Maruyama-Verfahren für die SDE dS = S dW, S(0) = 1, Schrittweite 0.01, mit exakter Lösung (schwarz)
Date
Source Own work
Author HilberTraum

R source:

brown <- function(N=100, dim=1, Tmax=1.0) 
{
  A <- apply(matrix(rnorm(N*dim), N, dim), 2, cumsum)
  ts(rbind(0, sqrt(Tmax/N)*A), start=0, deltat=Tmax/N)
}

set.seed(345087)

N <- 1000
m <- 10
W <- brown(N)
S <- exp(W - 0.5*time(W))
Shat <- ts(S[1], start=0, end=1, freq=N/m)
dW <- diff(W[seq(1,N+1,m)])
for (i in 1:length(dW)) {
  Shat[i+1] <- Shat[i] + Shat[i]*dW[i] 
}

svg()
plot(S, xlab="t", ylab="S")
lines(Shat, col="red", lwd=2)
dev.off()

Licensing[edit]

I, the copyright holder of this work, hereby publish it under the following licenses:
GNU head Permission is granted to copy, distribute and/or modify this document under the terms of the GNU Free Documentation License, Version 1.2 or any later version published by the Free Software Foundation; with no Invariant Sections, no Front-Cover Texts, and no Back-Cover Texts. A copy of the license is included in the section entitled GNU Free Documentation License.
w:en:Creative Commons
attribution share alike
This file is licensed under the Creative Commons Attribution-Share Alike 3.0 Unported license.
You are free:
  • to share – to copy, distribute and transmit the work
  • to remix – to adapt the work
Under the following conditions:
  • attribution – You must give appropriate credit, provide a link to the license, and indicate if changes were made. You may do so in any reasonable manner, but not in any way that suggests the licensor endorses you or your use.
  • share alike – If you remix, transform, or build upon the material, you must distribute your contributions under the same or compatible license as the original.
You may select the license of your choice.

File history

Click on a date/time to view the file as it appeared at that time.

Date/TimeThumbnailDimensionsUserComment
current10:13, 2 April 2014Thumbnail for version as of 10:13, 2 April 2014630 × 630 (41 KB)HilberTraum (talk | contribs){{Information |Description ={{en|1=en:Euler-Maruyama method for SDE dS = S dW, S(0) = 0, step size 0.01}} {{de|1=de:Euler-Maruyama-Verfahren für die SDE dS = S dW, S(0) = 0, Schrittweite 0.01}} |Source ={{own}} |Author =[[...

There are no pages that use this file.

File usage on other wikis

The following other wikis use this file:

Metadata