# Math Help - Maple12

1. ## Maple12

How can I set my viewing window in a 2-d plot involving trig functions to fractional values of $\pi$?

2. Originally Posted by VonNemo19
How can I set my viewing window in a 2-d plot involving trig functions to fractional values of $\pi$?
Do you mean like this?

$plot(sin(x), x=0..\frac{\pi}{4});$

3. Originally Posted by McScruffy
Do you mean like this?

$plot(sin(x), x=0..\frac{\pi}{4});$
I mean like changing the numbers that apear on the axes however I wish.

In particular using symbols

4. Originally Posted by VonNemo19
I mean like changing the numbers that apear on the axes however I wish.

In particular using symbols

$plot(sin(x), 0..\frac{3\pi}{2}, xtickmarks=[1.57=Pi/2, 3.14=Pi, 4.71=3Pi/2]);$

5. That'll work.

6. Originally Posted by VonNemo19
That'll work.
You can use the $\pi$ symbol in the common symbols palette instead of the Pi, but in the end it doesn't really make a difference.

7. One last thing here...

Do I have to include the decimal approximation in the command, or is there another, more simpler way to label the axes?

8. Originally Posted by VonNemo19
One last thing here...

Do I have to include the decimal approximation in the command, or is there another, more simpler way to label the axes?
The only way that I know how to do it is with the decimal approximations, but that by no means implies that there isn't another way to do it. I'll let you know if I find another approach.

9. Originally Posted by VonNemo19
One last thing here...
Ok, I think that I got it.

plot(sin(x), x=0..(3Pi/2), tickmarks=[spacing(Pi/2, 0), default]);

you may have to play around with it a bit, but that should give you the general idea. That method prints the axis labels a bit nicer too.

10. Originally Posted by McScruffy
Ok, I think that I got it.

plot(sin(x), x=0..(3Pi/2), tickmarks=[spacing(Pi/2, 0), default]);

you may have to play around with it a bit, but that should give you the general idea. That method prints the axis labels a bit nicer too.