@@ -0,0 +1,646 @@
+package data_manipulation;%0A%0A/******************%0A * Trying to write a simple script to testy Monte Carlo integration. %0A * %0A * @author Jeff%0A *%0A */%0Apublic class D0107_MonteCarloIntegration_simpleEquations %7B%0A%09%0A%09public static void main(String%5B%5D args)%7B%0A%09%09%0A%09%09int circle = 1000000;%0A%09%09%0A%09%09double sum = 0.0;%0A%09%09%0A%09%09for(int i=0; i%3Ccircle; i++)%7B%0A%09%09%09%0A%09%09%09double random = Math.random(); %0A%09%09%09sum += Math.pow(random, 3)/3; %0A%09%09%09%0A%09%09%09if(i%2510000 == 0)%7B%0A%09%09%09%09%0A%09%09%09%09System.out.println(%22i=%22 + i +%22 current simulated result: %22 + sum/i);%0A%09%09%09%7D%0A%09%09%09%0A%09%09%7D%0A%09%09%0A%09%09double result = 1.0/12; %0A%09%09%0A%09%09System.out.println(%22The result: %22 + result +%22 the simulated result:%22 + sum/circle); %0A%09%7D%0A%0A%7D%0A

add a simple naive Monte Carlo integration simulation script