摘要: 初学蒙特卡洛 center <- c(2.5,2.5) #圓心 radius <- 2.5 #半徑 distancefromcenter <- function(a){ # 點到直线的距离 sqrt(sum((a-center)^2)) } n <- 1000000 A <- matrix(runi 阅读全文
posted @ 2019-12-27 21:17 be·freedom 阅读(1769) 评论(0) 推荐(1)