Message Boards Message Boards

0
|
3490 Views
|
2 Replies
|
0 Total Likes
View groups...
Share
Share this post:

How can i label ticks?

Posted 10 years ago

Goodmorning. I'm writing here to ask you how can i label ticks in a mathematica graphic. I've got a graphic and i need to insert a label instead of a numer in the x-axis, for example in the nuclear potential i need to insert r1 and r2 where the two functions cross. How can i do that?

I have tried like this, but doesn't work as i want.

Plot[{50, (-(x - 5)^3 + 6 (x - 5)^4 + (x - 5) + 10 + 1/
      x) Exp[-(x - 5)] + 30}, {x, 0, 15}, PlotRange -> {0, 80}, 
 PlotStyle -> {{Blue}, {Red, Thick}}, 
 Ticks -> {{0, r1, r2}, {0, 50}}, 
 Epilog -> 
  Line[{{{7.599501370522477`, 0}, {7.599501370522477`, 
      50}}, {{10.80231101397398`, 0}, {10.80231101397398`, 50}}}] ]

Thanks.

P.s.: Sorry for my bad english, tell me if it isn't clear.

POSTED BY: Giorgio Track
2 Replies

Hi Giorgio, Please find attached a few examples. I hope this will help. Good luck......Jos

Attachments:
POSTED BY: Jos Klaps
Posted 10 years ago

I solved the problem with the code:

Ticks->{0,{r1,"r_1"},{r2,"r_2"}}
POSTED BY: Giorgio Track
Reply to this discussion
Community posts can be styled and formatted using the Markdown syntax.
Reply Preview
Attachments
Remove
or Discard

Group Abstract Group Abstract