c_csstri(3NCARG)
π« c_csstri β it's giving Delaunay triangulation, but make it a sphere β¨
okay bestie, welcome to the NCAR GRAPHICS corner of the manual, where the function is literally called c_csstri and its whole entire job is: calculate a Delaunay triangulation for data on a sphere. no cap. that's the vibe. π
π FUNCTION PROTOTYPE
int *c_csstri(int, float [], float [], int *, int *);
πΈ SYNOPSIS
int *c_csstri(n, rlat, rlon, nt, ier);
β¨ DESCRIPTION
here's the cast of characters, and yes you need to know all of them:
nβ the number of input data points, and it has to ben > 2. three's company, two's just a line, bestie. πrlatβ an array holding the latitudes of your input data, expressed in degrees. π«Ά important: the first three points must not be collinear (i.e. they can't all lie on one common great circle). if they do... that's not the slay you think it is.rlonβ an array holding the longitudes of your input data, also in degrees. π¦ntβ*ntis the number of triangles in the triangulation. UNLESS*iercomes back non-zero, in which case*nt = 0. and ifnbis the number of boundary points on the convex hull of the data, then: ifnbis greater than3,*nt = 2n-nb-2; otherwise*nt = 2n-4. also, the input data are considered to be bounded if they all lie in one hemisphere. πierβ the error return value, our little drama detector. if*iercomes back as0, then no errors were detected, iconic, flawless. if*ieris non-zero, then go refer to the error list incssgrid_errorsfor the details. π
π USAGE
c_csstri gets called when you wanna find a Delaunay triangulation of data that's randomly positioned on the surface of a sphere. that's the whole assignment. main character energy fr fr. π
β RETURN VALUE
c_csstri returns a pointer to a linear array that contains a sequence of integer triples. each element of a triple is an index of a vertex of a triangle. every index references an original data point as it occurs in sequence in the input data set β and heads up, numbering starts at 0. π
so like, if the triple <5,0,2> were in the list of triples, then (rlat[5],rlon[5]), (rlat[0],rlon[0]), and (rlat[2],rlon[2]) would be vertices of a triangle in the Delaunay triangulation. see how that works? ate. π
π§ ACCESS
to use c_csstri, load the NCAR Graphics library ngmath. that's it, that's the whole step. β¨
π₯ SEE ALSO
css_overviewc_cssgridcssgrid_errors
and also, complete documentation for Cssgrid lives at this URL, go read it when you're done here:
http://ngwww.ucar.edu/ngdoc/ng/ngmath/cssgrid/cssgridhome.html
π COPYRIGHT
Copyright (C) 2000 University Corporation for Atmospheric Research
The use of this Software is governed by a License Agreement.
ngl the licensing line is the one part you should actually read with your whole chest, not just skim. π
okay that's the whole page, you're officially a sphere-triangulation girlie now πΈ
this was c_csstri(3NCARG) from the NCAR GRAPHICS manual, UNIX flavour, dated May 2000 β mwah, take care of her π
π«Ά
π¦ where this page comes from
- epel 9: ncl-devel 6.6.2-59.el9 Β· LicenseRef-Callaway-BSD
- fedora 43: ncl-devel 6.6.2-58.fc43 Β· LicenseRef-Callaway-BSD
- fedora 44: ncl-devel 6.6.2-62.fc44 Β· LicenseRef-Callaway-BSD
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms