谢谢!

解决方案 »

  1.   

    一、基础公式:   ⑴ π=180°sinθ∕θ 、   
    ⑶ π=180°tgθ∕θ 、   
    (θ→0°.θ>0°)   
    二、   
    派生公式:   
    ⑸ π=(n/2)*sin(360°∕n) 、   
    ⑺ π=(n/2)*tg(360°∕n) 、   
    (n→∞, n≥5)   派生公式:   
    ⑼ π=nsin(180°∕n) 、   
    ⑾ π=ntg(180°∕n) 、   
    (n→∞,n≥3)   三、专业公式:   ①π= 2^n√(2-√(2+…√2)…)   
    ②π=3×2^n√(2-√(2+…√3)…)   
    ③π=2×2^n√(2-√(2+…√2)…)/√(2+√(2+…√2)…)   
    ④π=6×2^n√(2-√(2+…√3)…)/√(2+√(2+…√3)…)   
    (n→∞,根式中有n个2)   
      

  2.   

    如果你真的想要那样的精度,请执行下面的程序,再等上几个小时 
    import java.math.*; 
    public class ForPI { //PI=4*(1-1/3+1/5-1/7...) 
    public static String forPI(int a){ BigDecimal result,index,temp,flag,b,c; 
    b=new BigDecimal(1,new MathContext(a,RoundingMode.HALF_UP));//分子 
    c=new BigDecimal(2);//增量 
    result=new BigDecimal(0,new MathContext(a,RoundingMode.HALF_UP)); 
    index=new BigDecimal(1);//分母 
    temp=new BigDecimal(1,new MathContext(a,RoundingMode.HALF_UP)); 
    flag=new BigDecimal(0.1); 
    flag=flag.pow(a);//精度 
    while(temp.abs().compareTo(flag)==1){ 
    temp=b.divide(index); 
    result.add(temp); 
    index.add(c); 
    index=index.negate(); 

    result=result.multiply(new BigDecimal(4)); 
    return result.toPlainString(); } 
    public static void main(String[] args) { 
    // TODO Auto-generated method stub 
    System.out.println(forPI(100)); } }
      

  3.   

    楼上疯了...要几个小时...你下个superΠ,测试cpu运算能力的软件...算104万位的,才用25秒..
      

  4.   

    100位而已,我背都背出来了。还可以google it。
      

  5.   

    System.out.println("Pi=3.14159 26535 89793 23846 26433 83279 
    50288 41971 69399 37510 58209 74944 5923078164 06286 20899 86280 34825 34211 70679 
    ");