Techniques for perserving long decimals in programs?
I'm trying to write a program for a project which approximates the values of and in the visual basic langue. Lets just look at , I'm approximating it with the two following integrals:
which is based off of the area of a quarter of a circle with radius one and center . And I used:
which is based of the integral distance formula and the relationship
Which integral is best to use in approximating pi in a computer program? And also, visual basic rounds off calculations (after a considerable decimal place), but I would like to be able to display many correct decimal places of and . When I plug in large numbers of rectangles my computer freezes for a few seconds and on larger inputs it simply states "overload". Is there a way to break up the rectangles into parts and express the decimal as a further extended expansion by some seperate technique? So I can approximate to an even greater accuracy without my computer freezing and without visual basic rounding it off?
Thanks in advance