Ask Your Question
1

Is there a way to insert a .png into a LaTex document?

asked 2015-01-14 20:50:34 -0500

kstd gravatar image

I'm trying to insert a picture of a graph I made for a project I'm working on and I would like to insert it into my final Latex file. Is there a way to do this on sagemath?

Thank you.

edit retag flag offensive close merge delete

2 answers

Sort by ยป oldest newest most voted
1

answered 2015-01-15 09:56:38 -0500

dazedANDconfused gravatar image

updated 2015-01-15 09:58:12 -0500

Assuming sagemath means Sagemath Cloud, you can. First you need to put \usepackage{graphicx} in your preamble (before \begin{document}). Then you insert the picture as nousfalasharaf indicates: \includegraphics{picturename.png}.

Depending on how your picture was made, you might find your picture is too big/small. The \includegraphics command comes with options to help with the size, rotation, etc. The LaTeX wiki is a great reference to answer many questions. The section on including graphics and the various options is here.

Note (in the link above) that if you aren't using Sagemath Cloud to compile your document and the engine used is LaTeX, rather than pdfLaTeX, then it won't compile. It needs images as eps files.

edit flag offensive delete link more

Comments

Thank you! I was using that command (which I should have mentioned), but I saved the image in the wrong place.

kstd gravatar imagekstd ( 2015-01-15 14:26:14 -0500 )edit
1

answered 2015-01-15 06:31:16 -0500

noufalasharaf gravatar image

you can do it by \includegraphics {name.png}

edit flag offensive delete link more

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

Stats

Asked: 2015-01-14 20:50:34 -0500

Seen: 3,056 times

Last updated: Jan 15 '15