Mathematica Stack Exchange is a question and answer site for users of Mathematica. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

Sorry if the title is wordy. Basically what I am asking would probably be easier if I just use an example.

Say I wanted to plot f(x) = Asin(x) and have the graph come up with the sine function, and then the tics on the y axis be like half integer multiples of A. What I have been doing for my homework assignments is just plotting f(x)=sin(x) and then turning off the ticks and manually adding my ticks. It would be really cool if mathematica could do this for me.

share|improve this question
I think what you ended up doing is perhaps the best way... it isn't all that complicated either. – R. M. Nov 13 '13 at 20:44
What do you mean by manually? Are you using a custom tick specification as in this documentation example?: Plot[Cos[x], {x, 0, 10}, Ticks -> {{{Pi, 180 \[Degree], {0, .5}, Red}, {2 Pi, 360 \[Degree], {.5, 0}, Thick}, {3 Pi, 540 \[Degree], {0, .5}, Directive[Red, Dashed]}}, {-1, 1}}] – Mr.Wizard Nov 13 '13 at 20:48

See Ticks in the documentation:

Plot[Sin[x], {x, 0, 2 Pi}, 
 Ticks -> {Automatic, Table[{y, Row[{y, " A"}]}, {y, -1, 1, 1/2}]}]

Mathematica graphics

Unless you meant A to be a numeric value:

With[{A = Sqrt[2]},
 Plot[A Sin[x], {x, 0, 2 Pi}, 
  Ticks -> {Automatic, Range[-1, 1, 1/2] A}]

Mathematica graphics

(OK, A = Sqrt[2] is a bit random. :)

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.