[Yuima-commits] r316 - pkg/yuima/R

noreply at r-forge.r-project.org noreply at r-forge.r-project.org
Tue May 13 14:10:47 CEST 2014


Author: abrouste
Date: 2014-05-13 14:10:47 +0200 (Tue, 13 May 2014)
New Revision: 316

Modified:
   pkg/yuima/R/WoodChanfGn.R
Log:
corr WoodChan

Modified: pkg/yuima/R/WoodChanfGn.R
===================================================================
--- pkg/yuima/R/WoodChanfGn.R	2014-05-04 12:04:09 UTC (rev 315)
+++ pkg/yuima/R/WoodChanfGn.R	2014-05-13 12:10:47 UTC (rev 316)
@@ -1,5 +1,5 @@
 WoodChanfGn <- 
-function( mesh , H , dim )
+function( mesh , H , dimmesh )
 {
 
 ##--------------------------------------------------------------------------
@@ -25,13 +25,13 @@
 	mesh<-mesh[[1]]
 	
 	N<-length(mesh)-2 # N+1 is the size of the fGn sample to be simulated
-	fGn<-matrix(0,dim,N+1)
+	fGn<-matrix(0,dimmesh,N+1)
 	T<-mesh[N+2]
 	
 	H2 <- 2*H
 	
 	k <- 0:N
-    autocov<-0.5 * (abs(k-1)^H2 - 2*(k)^H2 + (k+1)^H2) * (T/(N+2))^H2
+    autocov<-0.5 * (abs(k-1)^H2 - 2*(k)^H2 + (k+1)^H2) * (T/(N+1))^H2
 	# g(0),g(1),g(n-1),g(1)
 	
 	
@@ -39,7 +39,7 @@
 	lambdak<-Re(fft(ligne1C,inverse = TRUE))
 	
 	
-	for (k in 1:dim){
+	for (k in 1:dimmesh){
 		
 	zr <- rnorm(N+1)
     zi <- rnorm(N-1)



More information about the Yuima-commits mailing list