Items tagged with pi pi Tagged Items Feed

Hello everybody,

 

I find a answer on that subject at this link: http://www.mapleprimes.com/maplesoftblog/95508-Monte-Carlo-Pi

But for starting easy, I try this:

with(RandomTools[MersenneTwister]);
directpi := proc (n)
local i, x, y, N;
N := 0;
Digits := 2;
for i to n do
x := GenerateFloat();
y := GenerateFloat();
if x^2+y^2 < 1 then
N := N+1:
end if:
end do:
N;
end proc;


evalf(directpi(4000)/(1000.0), 4);

                             3.176

I would like to know if this code is appropriate and if it is possible to have a random number between -1 to 1 so it will be easier to plot the points in the square with the circle inside.

 

Thank you.

--------------------------------------
Mario Lemelin
Maple 18 Ubuntu 13.10 - 64 bits
Maple 18 Win 7 - 64 bits messagerie : mario.lemelin@cgocable.ca téléphone :  (819) 376-0987

 

 

i have a large angle and i wish to represent this angle called theta in the range [0 2*Pi]. In matlab this is done by the command mod(theta, 2* Pi). ihave tried frem and mod in maple but the two cannot accept 2*Pi as a second argument 

how can i do that 

Hi,

 

I am completely new to Maple (and this kind of software in general).

I am just on my first steps of learning...but I quickly noticed, that if I write Pi and hit enter, I do not get

the well-known greek Pi-symbol. I get an ordinary "p" as the result.

I checked the greek-palette...nearly all items in this palette are ordinary letters.

Does anyone have an idea whats wrong?

BTW: I don`t know if it could have to do with that, but I use a german windows 7 installation.

 

Thank you,

regards,

Kai

Maple has a number of protected names that cannot be redefined without some work.

A common request is to use the letter j or J instead of the default I for the imaginary unit. Also common is to be able to use the letter I as an ordinary variable, rather than as an imaginary unit. For this, there is a very convenient interface command.


restart;

(-1)^(1/2);

I

interface(imaginaryunit=J):
(-1)^(1/2);
 
 J

(There...

Greetings to all.

A recent post at math.stackexchange.com asked for good approximations to pi using the nine nonzero digits, the four arithmetic operations and exponentiation. The problem definition definitely suggests a computational solution, which is actually non-trivial because the search space of all legal mathematical expressions over the nine digits and with the aforementioned operations is so huge that it cannot possibly be searched exhaustively.

Dear friends,

I am reporting with a brief comment concerning the integral int(1/(1+x^a), x=0..infinity) with a>=2 a real number. This was evaluated here.

Now Maple 15 (X86 64 LINUX) will quite happily compute this in its most simple form involving the sine when a is not a positive integer or a rational number. If it is, however, a beta function term results,...

Hello everybody,

I just realised Maple is allowed for my upcoming exam after New Year.

My plan is to have templates of the most common math problems, I might encounter for quick solutions.

Anyway, I have run into a problem with Laplace shifted data, particularly initial value problems. I have been searching for HOURS, and feel like I have look up everything on google, maplesoft and other sites without succes.

I hope some of you are able to help me. The exercise is:

pithe eight digits of your student Id number are used to individualise the questions. they are labelled a1a2a3a4a5a6a7a8a.. all non interger outputs should be to 3 decimal places. question 1_ depending of your own value of a8, write a program that performs the calculation below:

a8             ...

Hi, I have created 2 annulus;

 

> display(sector([2, -5.5], 2.5 .. 3.5, (1/5)*Pi .. (1/2)*Pi, color = "Niagara Burgundy"), axes = none, scaling = constrained);
%;

> display(sector([5, -5], 1 .. 1.5, (1/5)*Pi .. 2*Pi, color = "Green"), axes = none);
 
But I want the green annulus to cross the Niagara Burgundy annulus at the points where the green annulus is open. The green annulus is open with an angle...

How do I look for a 9 digit pi-sequence within decimal places of the EULER e  and find the position of that string.

2,71828182..............314159265..........

      123.....................x

can someone show me screen shot how to do this??

thanks so much

Horst

hi 

if I have two partition Pi and Pi 'I want to know the decomposition of Pi' 

So I want to display a plot containing a spiral and a polygon graph approximating the shape. I use a seq to make the points in pointplot3d and then connect them with the connect option. It looks like this:

y(t):=t-><cos(t),sin(t),t>:
graph := spacecurve(y(t), t = 0 .. 6, thickness = 3, axes = box, color = blue):
poly6 := pointplot3d({seq([cos(t), sin(t), t], t = 0 .. 6, 1)}, connect, axes = box, 
color = red, thickness = 3, caption = {n = 6}):


every time I enter / or ^, maple automatically changed the text I entered into fraction or power, and I am having hard time enter equations normally like the way I do in graphic calculator or matlab. I am forced to type all my equations on a text pad and then copy over.

is there a way to stop maple from auto formatting my input text? I am more of a matlab guy and I really need to use symbolics and integration abilities right now, but this version of maple is making...

I have defined a function as follows:

f:=alpha->1-RombInt(10*tan(x)^alpha,0,Pi/4,1,2);

and now i need to plot this function to see where the root lies, i have tried to do this using the following command:

plot(10*tan(x)^alpha);

and i have tried putting in boundaries but it doesnt seem to work. Can anyone help me please. 

 

                

3D Paper Physical Model

1 2 3 Page 1 of 3