Mathematica not plotting for me

Click For Summary
SUMMARY

The discussion centers on a common issue encountered in Mathematica when attempting to plot the function Plot[x^2/4 - ln[x]/2, {x, 0, 5}]. Users reported receiving a blank graph due to the incorrect use of the natural logarithm function. The correct syntax for the logarithm in Mathematica is Log[x], not ln[x]. The corrected command Plot[x^2/4 - Log[x]/2, {x, 0, 5}] successfully generates the desired plot.

PREREQUISITES
  • Familiarity with Mathematica syntax
  • Understanding of mathematical functions and their representations
  • Basic knowledge of plotting functions in Mathematica
  • Experience with logarithmic functions
NEXT STEPS
  • Explore Mathematica's documentation on plotting functions
  • Learn about the differences between Log[x] and ln[x] in Mathematica
  • Investigate common errors in Mathematica plotting and their solutions
  • Practice plotting various mathematical functions in Mathematica
USEFUL FOR

Students, educators, and researchers using Mathematica for mathematical modeling and visualization who need to troubleshoot plotting issues.

flyingpig
Messages
2,574
Reaction score
1

Homework Statement



I've been trying to plot

Plot[x^2/4 - ln[x]/2, {x, 0, 5}]

And it keeps showing me a blank graph. I did it on Wolframalpha and it worked.
 
Physics news on Phys.org
A blank graph means it didn't understand something in your expression. In this case it is ln[x], which needs to be Log[x]. Try:

Plot[x^2/4 - Log[x]/2, {x, 0, 5}]
 
thanks
 

Similar threads

Replies
7
Views
3K
  • · Replies 1 ·
Replies
1
Views
1K
  • · Replies 5 ·
Replies
5
Views
2K
  • · Replies 1 ·
Replies
1
Views
3K
  • · Replies 12 ·
Replies
12
Views
3K
  • · Replies 1 ·
Replies
1
Views
2K
  • · Replies 10 ·
Replies
10
Views
2K
  • · Replies 3 ·
Replies
3
Views
3K
  • · Replies 1 ·
Replies
1
Views
2K
  • · Replies 6 ·
Replies
6
Views
2K