Ask Your Question

Revision history [back]

To plot one quantity vs. another you can build a list of coordinates of points on the graph and then plot those points. Use plot for graphing a function of an independent variable. In your graph, neither axis variable is "independent".

sage: coordinates = [ (log(x), log(x^2)) for x in range(1,150) ]
sage: point( coordinates )

Which is just a line with slope 2 since $\log(x^2) = 2 \log(x)$. If you want the points to be connected with lines try:

sage: line(coordinates)