File:BrownFractionalH55.svg
From testwiki
Jump to navigation
Jump to search
Original file (SVG file, nominally 720 × 540 pixels, file size: 413 KB)
Contents
This file is from Wikimedia Commons and may be used by other projects. The description on its file description page there is shown below.
Summary
| DescriptionBrownFractionalH55.svg |
English: Fractional Brownian Motion with H = 0.55. |
| Date | |
| Source | Own work |
| Author | Shiyu Ji |
| SVG development InfoField |
Python/Matplotlib Code
# A realization of 1D Fractional Brownian motion with time step dt = .5
import matplotlib.pyplot as pl
import numpy as np
t0 = 0.0
dt = 0.5
t_final = 1000.0
T = np.arange(t0, t_final+dt, dt)
H = .55
ax = pl.figure().add_subplot(111)
ax.set_xlabel('t')
ax.set_ylabel('X')
np.random.seed(0)
Gamma = [[0.0 for _ in T] for _ in T]
for i in range(len(T)):
for j in range(len(T)):
Gamma[i][j] = 0.5*(T[i]**(2*H) + T[j]**(2*H) - abs(T[j]-T[i])**(2*H))
eigens, P = np.linalg.eig(Gamma)
Lambda = [[0.0 for _ in T] for _ in T]
for i in range(len(Lambda)):
Lambda[i][i] = eigens[i]**0.5
Sigma = np.matmul(np.matmul(P, Lambda), np.matrix.transpose(P))
path = [np.random.normal(0, 1) for _ in T]
path = np.matmul(Sigma, path)
for i in range(1, len(T)):
ax.plot([T[i-1], T[i]], [path[i-1], path[i]], 'k-', linewidth=0.5)
pl.show()
Licensing
Shiyu Ji, the copyright holder of this work, hereby publishes it under the following license:
This file is licensed under the Creative Commons Attribution-Share Alike 4.0 International license.
Attribution:
- 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.
Captions
Add a one-line explanation of what this file represents
Items portrayed in this file
depicts
21 November 2016
image/svg+xml
f052ee814901c8b7f1b918b72f3a64e0b437ad67
422,954 byte
540 pixel
720 pixel
File history
Click on a date/time to view the file as it appeared at that time.
| Date/Time | Thumbnail | Dimensions | User | Comment | |
|---|---|---|---|---|---|
| current | 11:29, 21 November 2016 | 720 × 540 (413 KB) | wikimediacommons>Shiyu Ji | User created page with UploadWizard |
File usage
There are no pages that use this file.