九江网站建设排行榜,网站研发进度表下载,想要做网站,网站怎么在工信部备案信息查询Wiener过程是连续时间随机过程#xff0c;以纪念Norbert Wiener命名。 通常用于用随机成分表示噪音或财务状况。 可以计算几何布朗运动以可视化某些界限#xff08;以分位数表示#xff09;以暗示绝对范围。 为了进行计算#xff0c;需要以下参数#xff1a; #xff0… Wiener过程是连续时间随机过程以纪念Norbert Wiener命名。 通常用于用随机成分表示噪音或财务状况。 可以计算几何布朗运动以可视化某些界限以分位数表示以暗示绝对范围。 为了进行计算需要以下参数 µmu平均百分比 σsigma方差 t时间段 v初始值 常规计算的扩展使用m每个时间段的增值在我的情况下为月度值中断分位数中断以计算界限 计算值的代码 import java.time.LocalDate;
import java.util.*;
import static java.lang.Math.sqrt;
import static java.lang.Math.exp;public class WienerProcess {/*** Run the Wiener process for a given period and initial amount with a monthly value that is added every month. The* code calculates the projection of the value, a set of quantiles and the brownian geometric motion based on a* random walk.** param mu mean value (annualized)* param sigma standard deviation (annualized)* param years projection duration in years* param initialValue the initial value* param monthlyValue the value that is added per month* param breaks quantile breaks* return a List of double arrays containing the values per month for the given quantile breaks*/public static Listdouble[] getProjection(double mu, double sigma, int years, int initialValue,int monthlyValue, double[] breaks) {double periodizedMu mu / 12;double periodizedSigma sigma / Math.sqrt(12);int periods years * 12;Listdouble[] result new ArrayListdouble[]();for (int i 0; i periods; i) {double value initialValue (monthlyValue * i);NormalDistribution normalDistribution new NormalDistribution(periodizedMu * (i 1),periodizedSigma * sqrt(i 1));double bounds[] new double[breaks.length];for (int j 0; j breaks.length; j) {double normInv normalDistribution.inverseCumulativeProbability(breaks[j]);bounds[j] value * exp(normInv);}result.add(bounds);}return result;}
} 应用值 亩0.05或5 sigma0.1或10 初始值7000 每月增加100 时间6年 结果如下表 该代码可从Github获得。 它带有Swing GUI来输入值并根据计算结果绘制图表。 https://gist.github.com/mp911de/464c1e0e2d19dfc904a7 相关信息 维基百科维纳过程 维基百科几何布朗运动 翻译自: https://www.javacodegeeks.com/2015/12/geometric-brownian-motion-java.html