LaTeX forum ⇒ Graphics, Figures & TablesStereographic map projections for drawing ellipsoids

Information and discussion about graphics, figures & tables in LaTeX documents.
Posts: 4
Joined: Tue Sep 05, 2017 1:21 pm

Stereographic map projections for drawing ellipsoids

Postby matsun » Tue Sep 05, 2017 1:39 pm

I would need to plot with Tikz some 3D drawings of ellipsoids: I am trying to adapt the excellent code provided by Tomas M. Trzeciak for plotting spheres based on stereographic and cylindrical map projections.

Original code:

I started to have a look at the functions but I do not know Tex very well.. Is there anyone skilled in math and Tex who's willing to help me?

I started to check the command \LongitudePlane:
  1. \newcommand\LongitudePlane[3][current plane]{%
  2. \pgfmathsinandcos\sinEl\cosEl{#2} % elevation
  3. \pgfmathsinandcos\sint\cost{#3} % azimuth
  4. \tikzset{#1/.estyle={cm={\cost,\sint*\sinEl,0,\cosEl,(0,0)}}}
  5. }

but I am already lost.. What does [current plane] stand for? What is the output of this function?

Thank you for the support!


User avatar
Stefan Kottwitz
Site Admin
Posts: 8365
Joined: Mon Mar 10, 2008 9:44 pm
Location: Hamburg, Germany

Postby Stefan Kottwitz » Tue Sep 05, 2017 10:46 pm

Hi matsun,

welcome to the forum!

current plane is an parameter of this function. This function/macro is called several times with various planes, that are: xzplane, pzplane, qzplane, and equator.

cm may stand for "coordinate matrix", just a quick guess, as I could not look deeper into the code yet.

Site admin

Return to “Graphics, Figures & Tables”

Who is online

Users browsing this forum: No registered users and 10 guests