# Is there any way to plot a 1 variable function in 3d plot?

by user3390471   Last Updated May 15, 2018 19:23 PM

all, I'm trying to plot a 2d function with only 1 variable in 3d coordinate: y=9x-x^3....It should be just 1 curved line on xy-plane......Is there anyway to do it??? Don't ask me why, too much to explain.....Below are the codes I have so far, it works, but the direction is wrong which I don't understand why, it should curve on xy-plane, not xz-plane......Then I don't really understand how 3dplot, pgfplot anyway....so help! Oh, and my package name might be wrong, if the code doesn't compile, check the package name.....Apology for the inconvenience, I typed the package on site, might spelled some wrong......Thanks!

\usepackage{tikz}
\usepackage{3dplot}
\usepackage{pgfplot}
\documentclass{article}

\begin{tikzpicture}
\begin{axis}
[domain=0:2.00,
samples=20,
z buffer=sort,
]