9
$\begingroup$

The output of ListPointPlot3D is shown below: enter image description here I only want to connect the dots in such a way that it forms a ring-like mesh. However, when I use ListPlot3D, the output is like this: enter image description here Which is not what I want.

May I know how I should modify the code to achieve the intended result? Thank you.

Here is the data I used (with fewer data points):

{{15.,-4.33154,0.015},{15.4114,-3.89839,0.0154114},{15.7792,-3.46523,0.0157792},{16.1037,-3.03208,0.0161037},{16.3847,-2.59893,0.0163847},{16.6224,-2.16577,0.0166224},{16.8169,-1.73262,0.0168169},{16.968,-1.29946,0.0169681},{17.076,-0.866309,0.017076},{17.1408,-0.433154,0.0171408},{17.1624,-6.01122*10^-16,0.0171624},{17.1408,0.433154,0.0171408},{17.076,0.866309,0.017076},{16.968,1.29946,0.0169681},{16.8169,1.73262,0.0168169},{16.6224,2.16577,0.0166224},{16.3847,2.59893,0.0163847},{16.1037,3.03208,0.0161037},{15.7792,3.46523,0.0157792},{15.4114,3.89839,0.0154114},{14.698,-4.79395,2.99474},{15.1194,-4.31455,3.08061},{15.4564,-3.83516,3.14927},{15.7246,-3.35576,3.2039},{15.9361,-2.87637,3.24701},{16.1009,-2.39697,3.28058},{16.2264,-1.91758,3.30616},{16.3185,-1.43818,3.32492},{16.3815,-0.95879,3.33775},{16.4181,-0.479395,3.34521},{16.4301,-6.65294*10^-16,3.34766},{16.4181,0.479395,3.34521},{16.3815,0.95879,3.33775},{16.3185,1.43818,3.32492},{16.2264,1.91758,3.30616},{16.1009,2.39697,3.28058},{15.9361,2.87637,3.24701},{15.7246,3.35576,3.2039},{15.4564,3.83516,3.14927},{15.1194,4.31455,3.08061},{13.8101,-5.25915,5.85509},{14.2225,-4.73323,6.02996},{14.5189,-4.20732,6.15563},{14.7316,-3.6814,6.24579},{14.8837,-3.15549,6.31026},{14.9917,-2.62957,6.35607},{15.0675,-2.10366,6.3882},{15.1193,-1.57774,6.41015},{15.1527,-1.05183,6.42432},{15.1714,-0.525915,6.43225},{15.1774,-7.29853*10^-16,6.4348},{15.1714,0.525915,6.43225},{15.1527,1.05183,6.42432},{15.1193,1.57774,6.41015},{15.0675,2.10366,6.3882},{14.9917,2.62957,6.35607},{14.8837,3.15549,6.31026},{14.7316,3.6814,6.24579},{14.5189,4.20732,6.15563},{14.2225,4.73323,6.02996},{12.3716,-5.68073,8.48201},{12.7528,-5.11265,8.74341},{13.0014,-4.54458,8.91387},{13.1635,-3.97651,9.02496},{13.2689,-3.40844,9.09726},{13.3374,-2.84036,9.14419},{13.3815,-2.27229,9.17442},{13.4094,-1.70422,9.19355},{13.4263,-1.13615,9.20515},{13.4353,-0.568073,9.21134},{13.4382,-7.88359*10^-16,9.21329},{13.4353,0.568073,9.21134},{13.4263,1.13615,9.20515},{13.4094,1.70422,9.19355},{13.3815,2.27229,9.17442},{13.3374,2.84036,9.14419},{13.2689,3.40844,9.09726},{13.1635,3.97651,9.02496},{13.0014,4.54458,8.91387},{12.7528,5.11265,8.74341},{10.4398,-6.03187,10.7708},{10.7685,-5.42868,11.1099},{10.9656,-4.8255,11.3133},{11.0838,-4.22231,11.4352},{11.1547,-3.61912,11.5083},{11.1971,-3.01594,11.552},{11.2223,-2.41275,11.5781},{11.2372,-1.80956,11.5935},{11.2457,-1.20637,11.6022},{11.25,-0.603187,11.6066},{11.2513,-8.3709*10^-16,11.608},{11.25,0.603187,11.6066},{11.2457,1.20637,11.6022},{11.2372,1.80956,11.5935},{11.2223,2.41275,11.5781},{11.1971,3.01594,11.552},{11.1547,3.61912,11.5083},{11.0838,4.22231,11.4352},{10.9656,4.8255,11.3133},{10.7685,5.42868,11.1099},{8.09191,-6.3005,12.6302},{8.35003,-5.67045,13.033},{8.49481,-5.0404,13.259},{8.57602,-4.41035,13.3858},{8.62155,-3.7803,13.4569},{8.64707,-3.15025,13.4967},{8.66132,-2.5202,13.5189},{8.66922,-1.89015,13.5313},{8.67348,-1.2601,13.5379},{8.67557,-0.63005,13.5412},{8.67619,-8.74371*10^-16,13.5421},{8.67557,0.63005,13.5412},{8.67348,1.2601,13.5379},{8.66922,1.89015,13.5313},{8.66132,2.5202,13.5189},{8.64707,3.15025,13.4967},{8.62155,3.7803,13.4569},{8.57602,4.41035,13.3858},{8.49481,5.0404,13.259},{8.35003,5.67045,13.033},{5.42138,-6.48148,13.986},{5.5955,-5.83333,14.4352},{5.68862,-5.18519,14.6754},{5.73842,-4.53704,14.8039},{5.76505,-3.88889,14.8726},{5.77928,-3.24074,14.9093},{5.78687,-2.59259,14.9289},{5.79089,-1.94444,14.9393},{5.79297,-1.2963,14.9446},{5.79396,-0.648148,14.9472},{5.79425,-8.99486*10^-16,14.9479},{5.79396,0.648148,14.9472},{5.79297,1.2963,14.9446},{5.79089,1.94444,14.9393},{5.78687,2.59259,14.9289},{5.77928,3.24074,14.9093},{5.76505,3.88889,14.8726},{5.73842,4.53704,14.8039},{5.68862,5.18519,14.6754},{5.5955,5.83333,14.4352},{2.53472,-6.57254,14.7843},{2.6163,-5.91529,15.2601},{2.65878,-5.25803,15.5079},{2.6809,-4.60078,15.6369},{2.69241,-3.94352,15.704},{2.69841,-3.28627,15.739},{2.70152,-2.62902,15.7572},{2.70313,-1.97176,15.7666},{2.70395,-1.31451,15.7713},{2.70433,-0.657254,15.7735},{2.70444,-9.12123*10^-16,15.7742},{2.70433,0.657254,15.7735},{2.70395,1.31451,15.7713},{2.70313,1.97176,15.7666},{2.70152,2.62902,15.7572},{2.69841,3.28627,15.739},{2.69241,3.94352,15.704},{2.6809,4.60078,15.6369},{2.65878,5.25803,15.5079},{2.6163,5.91529,15.2601},{-0.452986,-6.5727,14.9932},{-0.467535,-5.91543,15.4747},{-0.475076,-5.25816,15.7243},{-0.478985,-4.60089,15.8537},{-0.481011,-3.94362,15.9207},{-0.48206,-3.28635,15.9555},{-0.482603,-2.62908,15.9734},{-0.482883,-1.97181,15.9827},{-0.483024,-1.31454,15.9873},{-0.483089,-0.65727,15.9895},{-0.483108,-9.12146*10^-16,15.9901},{-0.483089,0.65727,15.9895},{-0.483024,1.31454,15.9873},{-0.482883,1.97181,15.9827},{-0.482603,2.62908,15.9734},{-0.48206,3.28635,15.9555},{-0.481011,3.94362,15.9207},{-0.478985,4.60089,15.8537},{-0.475076,5.25816,15.7243},{-0.467535,5.91543,15.4747},{-3.42264,-6.48177,14.6043},{-3.5319,-5.8336,15.0705},{-3.58953,-5.18542,15.3164},{-3.61993,-4.53724,15.4462},{-3.63597,-3.88906,15.5146},{-3.64442,-3.24089,15.5507},{-3.64887,-2.59271,15.5696},{-3.6512,-1.94453,15.5796},{-3.65239,-1.29635,15.5847},{-3.65295,-0.648177,15.587},{-3.65311,-8.99527*10^-16,15.5877},{-3.65295,0.648177,15.587},{-3.65239,1.29635,15.5847},{-3.6512,1.94453,15.5796},{-3.64887,2.59271,15.5696},{-3.64442,3.24089,15.5507},{-3.63597,3.88906,15.5146},{-3.61993,4.53724,15.4462},{-3.58953,5.18542,15.3164},{-3.5319,5.8336,15.0705},{-6.25584,-6.30022,13.6332},{-6.45337,-5.6702,14.0637},{-6.5617,-5.04017,14.2998},{-6.62112,-4.41015,14.4293},{-6.65369,-3.78013,14.5002},{-6.67154,-3.15011,14.5391},{-6.6813,-2.52009,14.5604},{-6.6866,-1.89007,14.572},{-6.6894,-1.26004,14.5781},{-6.69075,-0.630022,14.581},{-6.69115,-8.74331*10^-16,14.5819},{-6.69075,0.630022,14.581},{-6.6894,1.26004,14.5781},{-6.6866,1.89007,14.572},{-6.6813,2.52009,14.5604},{-6.67154,3.15011,14.5391},{-6.65369,3.78013,14.5002},{-6.62112,4.41015,14.4293},{-6.5617,5.04017,14.2998},{-6.45337,5.6702,14.0637},{-8.83964,-6.02948,12.1186},{-9.11395,-5.42653,12.4947},{-9.27348,-4.82358,12.7134},{-9.36624,-4.22063,12.8406},{-9.42016,-3.61769,12.9145},{-9.45147,-3.01474,12.9574},{-9.46959,-2.41179,12.9822},{-9.47997,-1.80884,12.9965},{-9.48573,-1.2059,13.0044},{-9.48862,-0.602948,13.0083},{-9.48949,-8.36758*10^-16,13.0095},{-9.48862,0.602948,13.0083},{-9.48573,1.2059,13.0044},{-9.47997,1.80884,12.9965},{-9.46959,2.41179,12.9822},{-9.45147,3.01474,12.9574},{-9.42016,3.61769,12.9145},{-9.36624,4.22063,12.8406},{-9.27348,4.82358,12.7134},{-9.11395,5.42653,12.4947},{-11.071,-5.67305,10.1209},{-11.4057,-5.10574,10.4268},{-11.6157,-4.53844,10.6188},{-11.7474,-3.97113,10.7392},{-11.8299,-3.40383,10.8146},{-11.8815,-2.83652,10.8618},{-11.9135,-2.26922,10.8911},{-11.9332,-1.70191,10.909},{-11.9448,-1.13461,10.9196},{-11.9508,-0.567305,10.9252},{-11.9527,-7.87294*10^-16,10.9269},{-11.9508,0.567305,10.9252},{-11.9448,1.13461,10.9196},{-11.9332,1.70191,10.909},{-11.9135,2.26922,10.8911},{-11.8815,2.83652,10.8618},{-11.8299,3.40383,10.8146},{-11.7474,3.97113,10.7392},{-11.6157,4.53844,10.6188},{-11.4057,5.10574,10.4268},{-12.8611,-5.23969,7.71966},{-13.2354,-4.71572,7.94438},{-13.4923,-4.19175,8.09855},{-13.6683,-3.66778,8.20422},{-13.7887,-3.14381,8.27649},{-13.8707,-2.61984,8.32569},{-13.926,-2.09588,8.35886},{-13.9624,-1.57191,8.38074},{-13.9853,-1.04794,8.39446},{-13.9978,-0.523969,8.40198},{-14.0018,-7.27153*10^-16,8.40437},{-13.9978,0.523969,8.40198},{-13.9853,1.04794,8.39446},{-13.9624,1.57191,8.38074},{-13.926,2.09588,8.35886},{-13.8707,2.61984,8.32569},{-13.7887,3.14381,8.27649},{-13.6683,3.66778,8.20422},{-13.4923,4.19175,8.09855},{-13.2354,4.71572,7.94438},{-14.1384,-4.75095,5.01069},{-14.5294,-4.27585,5.14928},{-14.8254,-3.80076,5.25418},{-15.0488,-3.32566,5.33334},{-15.2164,-2.85057,5.39276},{-15.3411,-2.37547,5.43696},{-15.4323,-1.90038,5.46928},{-15.497,-1.42528,5.49219},{-15.5399,-0.950189,5.50741},{-15.5645,-0.475095,5.5161},{-15.5724,-6.59326*10^-16,5.51893},{-15.5645,0.475095,5.5161},{-15.5399,0.950189,5.50741},{-15.497,1.42528,5.49219},{-15.4323,1.90038,5.46928},{-15.3411,2.37547,5.43696},{-15.2164,2.85057,5.39276},{-15.0488,3.32566,5.33334},{-14.8254,3.80076,5.25418},{-14.5294,4.27585,5.14928},{-14.852,-4.25023,2.10195},{-15.2382,-3.82521,2.1566},{-15.5612,-3.40019,2.20232},{-15.8293,-2.97516,2.24027},{-16.0493,-2.55014,2.2714},{-16.2268,-2.12512,2.29652},{-16.3663,-1.70009,2.31626},{-16.4712,-1.27507,2.33111},{-16.5443,-0.850047,2.34146},{-16.5875,-0.425023,2.34756},{-16.6017,-5.89838*10^-16,2.34958},{-16.5875,0.425023,2.34756},{-16.5443,0.850047,2.34146},{-16.4712,1.27507,2.33111},{-16.3663,1.70009,2.31626},{-16.2268,2.12512,2.29652},{-16.0493,2.55014,2.2714},{-15.8293,2.97516,2.24027},{-15.5612,3.40019,2.20232},{-15.2382,3.82521,2.1566},{-15.,-4.25023,-0.015},{-15.3725,-3.82521,-0.0153725},{-15.7059,-3.40019,-0.0157059},{-16.0002,-2.97516,-0.0160002},{-16.2554,-2.55014,-0.0162554},{-16.4714,-2.12512,-0.0164714},{-16.6481,-1.70009,-0.0166482},{-16.7857,-1.27507,-0.0167857},{-16.8839,-0.850047,-0.0168839},{-16.9428,-0.425023,-0.0169428},{-16.9625,-5.89838*10^-16,-0.0169625},{-16.9428,0.425023,-0.0169428},{-16.8839,0.850047,-0.0168839},{-16.7857,1.27507,-0.0167857},{-16.6481,1.70009,-0.0166482},{-16.4714,2.12512,-0.0164714},{-16.2554,2.55014,-0.0162554},{-16.0002,2.97516,-0.0160002},{-15.7059,3.40019,-0.0157059},{-15.3725,3.82521,-0.0153725},{-14.698,-4.25023,-2.99474},{-15.0417,-3.82521,-3.06476},{-15.3769,-3.40019,-3.13307},{-15.6956,-2.97516,-3.19799},{-15.9897,-2.55014,-3.25792},{-16.2521,-2.12512,-3.31138},{-16.4762,-1.70009,-3.35704},{-16.6565,-1.27507,-3.39378},{-16.7886,-0.850047,-3.4207},{-16.8692,-0.425023,-3.43711},{-16.8962,-5.89838*10^-16,-3.44263},{-16.8692,0.425023,-3.43711},{-16.7886,0.850047,-3.4207},{-16.6565,1.27507,-3.39378},{-16.4762,1.70009,-3.35704},{-16.2521,2.12512,-3.31138},{-15.9897,2.55014,-3.25792},{-15.6956,2.97516,-3.19799},{-15.3769,3.40019,-3.13307},{-15.0417,3.82521,-3.06476},{-13.8101,-4.25023,-5.85509},{-14.1175,-3.82521,-5.98541},{-14.44,-3.40019,-6.12216},{-14.7648,-2.97516,-6.25985},{-15.0787,-2.55014,-6.39296},{-15.3693,-2.12512,-6.51615},{-15.6248,-1.70009,-6.62448},{-15.835,-1.27507,-6.7136},{-15.9915,-0.850047,-6.77994},{-16.0879,-0.425023,-6.82084},{-16.1205,-5.89838*10^-16,-6.83466},{-16.0879,0.425023,-6.82084},{-15.9915,0.850047,-6.77994},{-15.835,1.27507,-6.7136},{-15.6248,1.70009,-6.62448},{-15.3693,2.12512,-6.51615},{-15.0787,2.55014,-6.39296},{-14.7648,2.97516,-6.25985},{-14.44,3.40019,-6.12216},{-14.1175,3.82521,-5.98541},{-12.3716,-4.25023,-8.48201},{-12.6372,-3.82521,-8.66411},{-12.933,-3.40019,-8.86697},{-13.2444,-2.97516,-9.08044},{-13.5556,-2.55014,-9.29382},{-13.8512,-2.12512,-9.49646},{-14.1163,-1.70009,-9.6782},{-14.3376,-1.27507,-9.82995},{-14.5041,-0.850047,-9.94411},{-14.6075,-0.425023,-10.015},{-14.6425,-5.89838*10^-16,-10.039},{-14.6075,0.425023,-10.015},{-14.5041,0.850047,-9.94411},{-14.3376,1.27507,-9.82995},{-14.1163,1.70009,-9.6782},{-13.8512,2.12512,-9.49646},{-13.5556,2.55014,-9.29382},{-13.2444,2.97516,-9.08044},{-12.933,3.40019,-8.86697},{-12.6372,3.82521,-8.66411},{-10.4398,-4.25023,-10.7708},{-10.6588,-3.82521,-10.9967},{-10.9148,-3.40019,-11.2608},{-11.1935,-2.97516,-11.5483},{-11.4789,-2.55014,-11.8428},{-11.7549,-2.12512,-12.1276},{-12.0059,-1.70009,-12.3865},{-12.2176,-1.27507,-12.6049},{-12.3781,-0.850047,-12.7705},{-12.4781,-0.425023,-12.8737},{-12.5121,-5.89838*10^-16,-12.9087},{-12.4781,0.425023,-12.8737},{-12.3781,0.850047,-12.7705},{-12.2176,1.27507,-12.6049},{-12.0059,1.70009,-12.3865},{-11.7549,2.12512,-12.1276},{-11.4789,2.55014,-11.8428},{-11.1935,2.97516,-11.5483},{-10.9148,3.40019,-11.2608},{-10.6588,3.82521,-10.9967},{-8.09191,-4.25023,-12.6302},{-8.25964,-3.82521,-12.892},{-8.46364,-3.40019,-13.2104},{-8.6914,-2.97516,-13.5659},{-8.92895,-2.55014,-13.9366},{-9.16172,-2.12512,-14.3},{-9.37544,-1.70009,-14.6335},{-9.557,-1.27507,-14.9169},{-9.69528,-0.850047,-15.1328},{-9.78179,-0.425023,-15.2678},{-9.81123,-5.89838*10^-16,-15.3137},{-9.78179,0.425023,-15.2678},{-9.69528,0.850047,-15.1328},{-9.557,1.27507,-14.9169},{-9.37544,1.70009,-14.6335},{-9.16172,2.12512,-14.3},{-8.92895,2.55014,-13.9366},{-8.6914,2.97516,-13.5659},{-8.46364,3.40019,-13.2104},{-8.25964,3.82521,-12.892},{-5.42138,-4.25023,-13.986},{-5.53367,-3.82521,-14.2757},{-5.67456,-3.40019,-14.6392},{-5.83496,-2.97516,-15.053},{-6.00451,-2.55014,-15.4904},{-6.17225,-2.12512,-15.9231},{-6.32735,-1.70009,-16.3232},{-6.45979,-1.27507,-16.6649},{-6.56102,-0.850047,-16.926},{-6.6245,-0.425023,-17.0898},{-6.64612,-5.89838*10^-16,-17.1456},{-6.6245,0.425023,-17.0898},{-6.56102,0.850047,-16.926},{-6.45979,1.27507,-16.6649},{-6.32735,1.70009,-16.3232},{-6.17225,2.12512,-15.9231},{-6.00451,2.55014,-15.4904},{-5.83496,2.97516,-15.053},{-5.67456,3.40019,-14.6392},{-5.53367,3.82521,-14.2757},{-2.53472,-4.25023,-14.7843},{-2.58773,-3.82521,-15.0935},{-2.65588,-3.40019,-15.4909},{-2.7346,-2.97516,-15.9501},{-2.81864,-2.55014,-16.4403},{-2.90236,-2.12512,-16.9286},{-2.98017,-1.70009,-17.3824},{-3.04685,-1.27507,-17.7714},{-3.09795,-0.850047,-18.0694},{-3.13005,-0.425023,-18.2566},{-3.14099,-5.89838*10^-16,-18.3205},{-3.13005,0.425023,-18.2566},{-3.09795,0.850047,-18.0694},{-3.04685,1.27507,-17.7714},{-2.98017,1.70009,-17.3824},{-2.90236,2.12512,-16.9286},{-2.81864,2.55014,-16.4403},{-2.7346,2.97516,-15.9501},{-2.65588,3.40019,-15.4909},{-2.58773,3.82521,-15.0935},{0.452986,-4.25023,-14.9932},{0.462651,-3.82521,-15.313},{0.475302,-3.40019,-15.7318},{0.490072,-2.97516,-16.2206},{0.50595,-2.55014,-16.7462},{0.521847,-2.12512,-17.2723},{0.536673,-1.70009,-17.7631},{0.549412,-1.27507,-18.1847},{0.559192,-0.850047,-18.5084},{0.565341,-0.425023,-18.7119},{0.567439,-5.89838*10^-16,-18.7814},{0.565341,0.425023,-18.7119},{0.559192,0.850047,-18.5084},{0.549412,1.27507,-18.1847},{0.536673,1.70009,-17.7631},{0.521847,2.12512,-17.2723},{0.50595,2.55014,-16.7462},{0.490072,2.97516,-16.2206},{0.475302,3.40019,-15.7318},{0.462651,3.82521,-15.313},{3.42264,-4.25023,-14.6043},{3.49796,-3.82521,-14.9257},{3.59775,-3.40019,-15.3515},{3.71508,-2.97516,-15.8521},{3.84178,-2.55014,-16.3927},{3.96903,-2.12512,-16.9357},{4.08798,-1.70009,-17.4433},{4.19036,-1.27507,-17.8801},{4.26904,-0.850047,-18.2159},{4.31855,-0.425023,-18.4271},{4.33545,-5.89838*10^-16,-18.4992},{4.31855,0.425023,-18.4271},{4.26904,0.850047,-18.2159},{4.19036,1.27507,-17.8801},{4.08798,1.70009,-17.4433},{3.96903,2.12512,-16.9357},{3.84178,2.55014,-16.3927},{3.71508,2.97516,-15.8521},{3.59775,3.40019,-15.3515},{3.49796,3.82521,-14.9257},{6.25584,-4.25023,-13.6332},{6.39959,-3.82521,-13.9465},{6.59119,-3.40019,-14.364},{6.81723,-2.97516,-14.8566},{7.06186,-2.55014,-15.3898},{7.30794,-2.12512,-15.926},{7.53823,-1.70009,-16.4279},{7.73659,-1.27507,-16.8602},{7.88913,-0.850047,-17.1926},{7.98514,-0.425023,-17.4018},{8.01791,-5.89838*10^-16,-17.4733},{7.98514,0.425023,-17.4018},{7.88913,0.850047,-17.1926},{7.73659,1.27507,-16.8602},{7.53823,1.70009,-16.4279},{7.30794,2.12512,-15.926},{7.06186,2.55014,-15.3898},{6.81723,2.97516,-14.8566},{6.59119,3.40019,-14.364},{6.39959,3.82521,-13.9465},{8.83964,-4.25023,-12.1186},{9.05484,-3.82521,-12.4136},{9.34149,-3.40019,-12.8066},{9.67949,-2.97516,-13.27},{10.0452,-2.55014,-13.7714},{10.413,-2.12512,-14.2756},{10.7572,-1.70009,-14.7474},{11.0536,-1.27507,-15.1538},{11.2815,-0.850047,-15.4663},{11.425,-0.425023,-15.663},{11.4739,-5.89838*10^-16,-15.7301},{11.425,0.425023,-15.663},{11.2815,0.850047,-15.4663},{11.0536,1.27507,-15.1538},{10.7572,1.70009,-14.7474},{10.413,2.12512,-14.2756},{10.0452,2.55014,-13.7714},{9.67949,2.97516,-13.27},{9.34149,3.40019,-12.8066},{9.05484,3.82521,-12.4136},{11.071,-4.25023,-10.1209},{11.3621,-3.82521,-10.3869},{11.7462,-3.40019,-10.7381},{12.1968,-2.97516,-11.15},{12.6827,-2.55014,-11.5942},{13.1703,-2.12512,-12.04},{13.6257,-1.70009,-12.4563},{14.0175,-1.27507,-12.8145},{14.3185,-0.850047,-13.0896},{14.5078,-0.425023,-13.2627},{14.5725,-5.89838*10^-16,-13.3218},{14.5078,0.425023,-13.2627},{14.3185,0.850047,-13.0896},{14.0175,1.27507,-12.8145},{13.6257,1.70009,-12.4563},{13.1703,2.12512,-12.04},{12.6827,2.55014,-11.5942},{12.1968,2.97516,-11.15},{11.7462,3.40019,-10.7381},{11.3621,3.82521,-10.3869},{12.8611,-4.25023,-7.71966},{13.1937,-3.82521,-7.91934},{13.5924,-3.40019,-8.15863},{14.0333,-2.97516,-8.42327},{14.4901,-2.55014,-8.69748},{14.9356,-2.12512,-8.96488},{15.3432,-1.70009,-9.20953},{15.6886,-1.27507,-9.41684},{15.9511,-0.850047,-9.57444},{16.1152,-0.425023,-9.67292},{16.171,-5.89838*10^-16,-9.70641},{16.1152,0.425023,-9.67292},{15.9511,0.850047,-9.57444},{15.6886,1.27507,-9.41684},{15.3432,1.70009,-9.20953},{14.9356,2.12512,-8.96488},{14.4901,2.55014,-8.69748},{14.0333,2.97516,-8.42327},{13.5924,3.40019,-8.15863},{13.1937,3.82521,-7.91934},{14.1384,-4.25023,-5.01069},{14.5057,-3.82521,-5.14086},{14.9022,-3.40019,-5.2814},{15.3101,-2.97516,-5.42596},{15.711,-2.55014,-5.56803},{16.0867,-2.12512,-5.7012},{16.4204,-1.70009,-5.81946},{16.697,-1.27507,-5.91747},{16.9039,-0.850047,-5.99082},{17.032,-0.425023,-6.0362},{17.0753,-5.89838*10^-16,-6.05155},{17.032,0.425023,-6.0362},{16.9039,0.850047,-5.99082},{16.697,1.27507,-5.91747},{16.4204,1.70009,-5.81946},{16.0867,2.12512,-5.7012},{15.711,2.55014,-5.56803},{15.3101,2.97516,-5.42596},{14.9022,3.40019,-5.2814},{14.5057,3.82521,-5.14086},{14.852,-4.25023,-2.10195},{15.2481,-3.82521,-2.15801},{15.6315,-3.40019,-2.21227},{15.9935,-2.97516,-2.26351},{16.3259,-2.55014,-2.31055},{16.6211,-2.12512,-2.35233},{16.8724,-1.70009,-2.38788},{17.074,-1.27507,-2.41642},{17.2214,-0.850047,-2.43728},{17.3111,-0.425023,-2.44998},{17.3413,-5.89838*10^-16,-2.45425},{17.3111,0.425023,-2.44998},{17.2214,0.850047,-2.43728},{17.074,1.27507,-2.41642},{16.8724,1.70009,-2.38788},{16.6211,2.12512,-2.35233},{16.3259,2.55014,-2.31055},{15.9935,2.97516,-2.26351},{15.6315,3.40019,-2.21227},{15.2481,3.82521,-2.15801}}
$\endgroup$
7
  • $\begingroup$ I prefer to have a continuous plot (a smooth one) instead of individual dots :) @kglr $\endgroup$ Commented Dec 6, 2021 at 12:33
  • $\begingroup$ .. or ListLinePlot3D[GatherBy[pts,#[[2]]&]? $\endgroup$
    – kglr
    Commented Dec 6, 2021 at 12:33
  • $\begingroup$ ..or ListSurfacePlot3D[pts]? $\endgroup$
    – kglr
    Commented Dec 6, 2021 at 12:35
  • 1
    $\begingroup$ For some reason, ListLinePlot3D does not work on my version of Mathematica, which is 12.1. There is no error message, it seems that ListLinePlot3D is not recognised as a function as it is blue instead of black. $\endgroup$ Commented Dec 6, 2021 at 12:36
  • $\begingroup$ ListSurfacePlot3D is sort of achieving what i want, although we some artifact errors at the edges $\endgroup$ Commented Dec 6, 2021 at 12:37

5 Answers 5

10
$\begingroup$

Update 2: Additional methods using Partition[pts, 20] with BSplineSurface and BSplineFunction:

array = Partition[pts, 20];

We can get the surface (without lines connecting the points) using array with BSplineSurface as follows:

bSS = BSplineSurface[array, SplineClosed -> {True, False}, SplineDegree -> {1, 1}]

Graphics3D[{Directive[FaceForm[Opacity[.75, LightBlue]], EdgeForm[Gray]], bSS, 
  Red, Point @ pts
  Gray, Line @ array, Line @ Transpose[Append[First @ #] @ # & @ array]}, 
ImageSize -> 600, Boxed -> False]

enter image description here

To get the surface with mesh lines we can use BSplineFunction + ParametricPlot3D:

bSF = BSplineFunction[array, 
   SplineClosed -> {True, False}, SplineDegree -> {1, 1}];

Show[ParametricPlot3D[bSF[u, v], {u, 0, 1}, {v, 0, 1}, 
  Mesh -> Full, 
  PlotPoints -> {1, 0} + Most @ Dimensions[array],
  MaxRecursion -> 0, 
  PlotStyle -> Directive[FaceForm[Opacity[.75, LightBlue]], EdgeForm[Gray]], 
  ImageSize -> 600, Boxed -> False, Axes -> False], 
 Graphics3D[{Red, AbsolutePointSize[4], Point @ pts}]]

enter image description here

Original answer:

NearestNeighborGraph[ScalingTransform[{1, 5, 1}] @ pts, 4, 
 VertexCoordinates -> pts, ImageSize -> Large]

enter image description here

Note: the magic factor {1,5,1} is obtained using

Round[1/Normalize[Max /@ Abs[Differences /@ Sort /@ Transpose[pts]],  Max]]
{1, 5, 1}

Update 1: Realized based on N.J.Evans's answer that the input data is more regular than I thought.

So we get a cleaner result using cycles in a periodic GridGraph to identify indices of polygon coordinates:

edges = Join[EdgeList @ GridGraph[{20, 32}], Thread[Range[20] <-> Range[621, 640]]];

cycles = VertexList /@ FindCycle[edges, {4}, All];

Graphics3D[GraphicsComplex[pts, 
  {Opacity[.5], RandomColor[], Polygon @ #} & /@ cycles], 
 ImageSize -> Large, Boxed -> False]

enter image description here

Alternatively, we can directly construct the polygon coordinates for use with Graphics3D + GraphicsComplex:

indexlist = Map[(a |-> (# - 1) 20 + #2 & @@ Mod[a + #, {32, 20}, {1, 1}]) /@ 
     {{0, 0}, {1, 0}, {1, 1}, {0, 1}} &] @ Tuples[{Range[32], Range[19]}];

Graphics3D[GraphicsComplex[pts, 
   {Opacity[.5], LightBlue, Polygon @ indexlist}], 
 Boxed -> False, ImageSize -> Large]

enter image description here

$\endgroup$
7
$\begingroup$

You can partition the data into units of three or four and create polygons. There's probably a better way to do it, but here's one option:

dat = {{15.,-4.33154,0.015},{15.4114,-3.89839,0.0154114},{15.7792,-3.46523,0.0157792},{16.1037,-3.03208,0.0161037},{16.3847,-2.59893,0.0163847},{16.6224,-2.16577,0.0166224},{16.8169,-1.73262,0.0168169},{16.968,-1.29946,0.0169681},{17.076,-0.866309,0.017076},{17.1408,-0.433154,0.0171408},{17.1624,-6.01122*10^-16,0.0171624},{17.1408,0.433154,0.0171408},{17.076,0.866309,0.017076},{16.968,1.29946,0.0169681},{16.8169,1.73262,0.0168169},{16.6224,2.16577,0.0166224},{16.3847,2.59893,0.0163847},{16.1037,3.03208,0.0161037},{15.7792,3.46523,0.0157792},{15.4114,3.89839,0.0154114},{14.698,-4.79395,2.99474},{15.1194,-4.31455,3.08061},{15.4564,-3.83516,3.14927},{15.7246,-3.35576,3.2039},{15.9361,-2.87637,3.24701},{16.1009,-2.39697,3.28058},{16.2264,-1.91758,3.30616},{16.3185,-1.43818,3.32492},{16.3815,-0.95879,3.33775},{16.4181,-0.479395,3.34521},{16.4301,-6.65294*10^-16,3.34766},{16.4181,0.479395,3.34521},{16.3815,0.95879,3.33775},{16.3185,1.43818,3.32492},{16.2264,1.91758,3.30616},{16.1009,2.39697,3.28058},{15.9361,2.87637,3.24701},{15.7246,3.35576,3.2039},{15.4564,3.83516,3.14927},{15.1194,4.31455,3.08061},{13.8101,-5.25915,5.85509},{14.2225,-4.73323,6.02996},{14.5189,-4.20732,6.15563},{14.7316,-3.6814,6.24579},{14.8837,-3.15549,6.31026},{14.9917,-2.62957,6.35607},{15.0675,-2.10366,6.3882},{15.1193,-1.57774,6.41015},{15.1527,-1.05183,6.42432},{15.1714,-0.525915,6.43225},{15.1774,-7.29853*10^-16,6.4348},{15.1714,0.525915,6.43225},{15.1527,1.05183,6.42432},{15.1193,1.57774,6.41015},{15.0675,2.10366,6.3882},{14.9917,2.62957,6.35607},{14.8837,3.15549,6.31026},{14.7316,3.6814,6.24579},{14.5189,4.20732,6.15563},{14.2225,4.73323,6.02996},{12.3716,-5.68073,8.48201},{12.7528,-5.11265,8.74341},{13.0014,-4.54458,8.91387},{13.1635,-3.97651,9.02496},{13.2689,-3.40844,9.09726},{13.3374,-2.84036,9.14419},{13.3815,-2.27229,9.17442},{13.4094,-1.70422,9.19355},{13.4263,-1.13615,9.20515},{13.4353,-0.568073,9.21134},{13.4382,-7.88359*10^-16,9.21329},{13.4353,0.568073,9.21134},{13.4263,1.13615,9.20515},{13.4094,1.70422,9.19355},{13.3815,2.27229,9.17442},{13.3374,2.84036,9.14419},{13.2689,3.40844,9.09726},{13.1635,3.97651,9.02496},{13.0014,4.54458,8.91387},{12.7528,5.11265,8.74341},{10.4398,-6.03187,10.7708},{10.7685,-5.42868,11.1099},{10.9656,-4.8255,11.3133},{11.0838,-4.22231,11.4352},{11.1547,-3.61912,11.5083},{11.1971,-3.01594,11.552},{11.2223,-2.41275,11.5781},{11.2372,-1.80956,11.5935},{11.2457,-1.20637,11.6022},{11.25,-0.603187,11.6066},{11.2513,-8.3709*10^-16,11.608},{11.25,0.603187,11.6066},{11.2457,1.20637,11.6022},{11.2372,1.80956,11.5935},{11.2223,2.41275,11.5781},{11.1971,3.01594,11.552},{11.1547,3.61912,11.5083},{11.0838,4.22231,11.4352},{10.9656,4.8255,11.3133},{10.7685,5.42868,11.1099},{8.09191,-6.3005,12.6302},{8.35003,-5.67045,13.033},{8.49481,-5.0404,13.259},{8.57602,-4.41035,13.3858},{8.62155,-3.7803,13.4569},{8.64707,-3.15025,13.4967},{8.66132,-2.5202,13.5189},{8.66922,-1.89015,13.5313},{8.67348,-1.2601,13.5379},{8.67557,-0.63005,13.5412},{8.67619,-8.74371*10^-16,13.5421},{8.67557,0.63005,13.5412},{8.67348,1.2601,13.5379},{8.66922,1.89015,13.5313},{8.66132,2.5202,13.5189},{8.64707,3.15025,13.4967},{8.62155,3.7803,13.4569},{8.57602,4.41035,13.3858},{8.49481,5.0404,13.259},{8.35003,5.67045,13.033},{5.42138,-6.48148,13.986},{5.5955,-5.83333,14.4352},{5.68862,-5.18519,14.6754},{5.73842,-4.53704,14.8039},{5.76505,-3.88889,14.8726},{5.77928,-3.24074,14.9093},{5.78687,-2.59259,14.9289},{5.79089,-1.94444,14.9393},{5.79297,-1.2963,14.9446},{5.79396,-0.648148,14.9472},{5.79425,-8.99486*10^-16,14.9479},{5.79396,0.648148,14.9472},{5.79297,1.2963,14.9446},{5.79089,1.94444,14.9393},{5.78687,2.59259,14.9289},{5.77928,3.24074,14.9093},{5.76505,3.88889,14.8726},{5.73842,4.53704,14.8039},{5.68862,5.18519,14.6754},{5.5955,5.83333,14.4352},{2.53472,-6.57254,14.7843},{2.6163,-5.91529,15.2601},{2.65878,-5.25803,15.5079},{2.6809,-4.60078,15.6369},{2.69241,-3.94352,15.704},{2.69841,-3.28627,15.739},{2.70152,-2.62902,15.7572},{2.70313,-1.97176,15.7666},{2.70395,-1.31451,15.7713},{2.70433,-0.657254,15.7735},{2.70444,-9.12123*10^-16,15.7742},{2.70433,0.657254,15.7735},{2.70395,1.31451,15.7713},{2.70313,1.97176,15.7666},{2.70152,2.62902,15.7572},{2.69841,3.28627,15.739},{2.69241,3.94352,15.704},{2.6809,4.60078,15.6369},{2.65878,5.25803,15.5079},{2.6163,5.91529,15.2601},{-0.452986,-6.5727,14.9932},{-0.467535,-5.91543,15.4747},{-0.475076,-5.25816,15.7243},{-0.478985,-4.60089,15.8537},{-0.481011,-3.94362,15.9207},{-0.48206,-3.28635,15.9555},{-0.482603,-2.62908,15.9734},{-0.482883,-1.97181,15.9827},{-0.483024,-1.31454,15.9873},{-0.483089,-0.65727,15.9895},{-0.483108,-9.12146*10^-16,15.9901},{-0.483089,0.65727,15.9895},{-0.483024,1.31454,15.9873},{-0.482883,1.97181,15.9827},{-0.482603,2.62908,15.9734},{-0.48206,3.28635,15.9555},{-0.481011,3.94362,15.9207},{-0.478985,4.60089,15.8537},{-0.475076,5.25816,15.7243},{-0.467535,5.91543,15.4747},{-3.42264,-6.48177,14.6043},{-3.5319,-5.8336,15.0705},{-3.58953,-5.18542,15.3164},{-3.61993,-4.53724,15.4462},{-3.63597,-3.88906,15.5146},{-3.64442,-3.24089,15.5507},{-3.64887,-2.59271,15.5696},{-3.6512,-1.94453,15.5796},{-3.65239,-1.29635,15.5847},{-3.65295,-0.648177,15.587},{-3.65311,-8.99527*10^-16,15.5877},{-3.65295,0.648177,15.587},{-3.65239,1.29635,15.5847},{-3.6512,1.94453,15.5796},{-3.64887,2.59271,15.5696},{-3.64442,3.24089,15.5507},{-3.63597,3.88906,15.5146},{-3.61993,4.53724,15.4462},{-3.58953,5.18542,15.3164},{-3.5319,5.8336,15.0705},{-6.25584,-6.30022,13.6332},{-6.45337,-5.6702,14.0637},{-6.5617,-5.04017,14.2998},{-6.62112,-4.41015,14.4293},{-6.65369,-3.78013,14.5002},{-6.67154,-3.15011,14.5391},{-6.6813,-2.52009,14.5604},{-6.6866,-1.89007,14.572},{-6.6894,-1.26004,14.5781},{-6.69075,-0.630022,14.581},{-6.69115,-8.74331*10^-16,14.5819},{-6.69075,0.630022,14.581},{-6.6894,1.26004,14.5781},{-6.6866,1.89007,14.572},{-6.6813,2.52009,14.5604},{-6.67154,3.15011,14.5391},{-6.65369,3.78013,14.5002},{-6.62112,4.41015,14.4293},{-6.5617,5.04017,14.2998},{-6.45337,5.6702,14.0637},{-8.83964,-6.02948,12.1186},{-9.11395,-5.42653,12.4947},{-9.27348,-4.82358,12.7134},{-9.36624,-4.22063,12.8406},{-9.42016,-3.61769,12.9145},{-9.45147,-3.01474,12.9574},{-9.46959,-2.41179,12.9822},{-9.47997,-1.80884,12.9965},{-9.48573,-1.2059,13.0044},{-9.48862,-0.602948,13.0083},{-9.48949,-8.36758*10^-16,13.0095},{-9.48862,0.602948,13.0083},{-9.48573,1.2059,13.0044},{-9.47997,1.80884,12.9965},{-9.46959,2.41179,12.9822},{-9.45147,3.01474,12.9574},{-9.42016,3.61769,12.9145},{-9.36624,4.22063,12.8406},{-9.27348,4.82358,12.7134},{-9.11395,5.42653,12.4947},{-11.071,-5.67305,10.1209},{-11.4057,-5.10574,10.4268},{-11.6157,-4.53844,10.6188},{-11.7474,-3.97113,10.7392},{-11.8299,-3.40383,10.8146},{-11.8815,-2.83652,10.8618},{-11.9135,-2.26922,10.8911},{-11.9332,-1.70191,10.909},{-11.9448,-1.13461,10.9196},{-11.9508,-0.567305,10.9252},{-11.9527,-7.87294*10^-16,10.9269},{-11.9508,0.567305,10.9252},{-11.9448,1.13461,10.9196},{-11.9332,1.70191,10.909},{-11.9135,2.26922,10.8911},{-11.8815,2.83652,10.8618},{-11.8299,3.40383,10.8146},{-11.7474,3.97113,10.7392},{-11.6157,4.53844,10.6188},{-11.4057,5.10574,10.4268},{-12.8611,-5.23969,7.71966},{-13.2354,-4.71572,7.94438},{-13.4923,-4.19175,8.09855},{-13.6683,-3.66778,8.20422},{-13.7887,-3.14381,8.27649},{-13.8707,-2.61984,8.32569},{-13.926,-2.09588,8.35886},{-13.9624,-1.57191,8.38074},{-13.9853,-1.04794,8.39446},{-13.9978,-0.523969,8.40198},{-14.0018,-7.27153*10^-16,8.40437},{-13.9978,0.523969,8.40198},{-13.9853,1.04794,8.39446},{-13.9624,1.57191,8.38074},{-13.926,2.09588,8.35886},{-13.8707,2.61984,8.32569},{-13.7887,3.14381,8.27649},{-13.6683,3.66778,8.20422},{-13.4923,4.19175,8.09855},{-13.2354,4.71572,7.94438},{-14.1384,-4.75095,5.01069},{-14.5294,-4.27585,5.14928},{-14.8254,-3.80076,5.25418},{-15.0488,-3.32566,5.33334},{-15.2164,-2.85057,5.39276},{-15.3411,-2.37547,5.43696},{-15.4323,-1.90038,5.46928},{-15.497,-1.42528,5.49219},{-15.5399,-0.950189,5.50741},{-15.5645,-0.475095,5.5161},{-15.5724,-6.59326*10^-16,5.51893},{-15.5645,0.475095,5.5161},{-15.5399,0.950189,5.50741},{-15.497,1.42528,5.49219},{-15.4323,1.90038,5.46928},{-15.3411,2.37547,5.43696},{-15.2164,2.85057,5.39276},{-15.0488,3.32566,5.33334},{-14.8254,3.80076,5.25418},{-14.5294,4.27585,5.14928},{-14.852,-4.25023,2.10195},{-15.2382,-3.82521,2.1566},{-15.5612,-3.40019,2.20232},{-15.8293,-2.97516,2.24027},{-16.0493,-2.55014,2.2714},{-16.2268,-2.12512,2.29652},{-16.3663,-1.70009,2.31626},{-16.4712,-1.27507,2.33111},{-16.5443,-0.850047,2.34146},{-16.5875,-0.425023,2.34756},{-16.6017,-5.89838*10^-16,2.34958},{-16.5875,0.425023,2.34756},{-16.5443,0.850047,2.34146},{-16.4712,1.27507,2.33111},{-16.3663,1.70009,2.31626},{-16.2268,2.12512,2.29652},{-16.0493,2.55014,2.2714},{-15.8293,2.97516,2.24027},{-15.5612,3.40019,2.20232},{-15.2382,3.82521,2.1566},{-15.,-4.25023,-0.015},{-15.3725,-3.82521,-0.0153725},{-15.7059,-3.40019,-0.0157059},{-16.0002,-2.97516,-0.0160002},{-16.2554,-2.55014,-0.0162554},{-16.4714,-2.12512,-0.0164714},{-16.6481,-1.70009,-0.0166482},{-16.7857,-1.27507,-0.0167857},{-16.8839,-0.850047,-0.0168839},{-16.9428,-0.425023,-0.0169428},{-16.9625,-5.89838*10^-16,-0.0169625},{-16.9428,0.425023,-0.0169428},{-16.8839,0.850047,-0.0168839},{-16.7857,1.27507,-0.0167857},{-16.6481,1.70009,-0.0166482},{-16.4714,2.12512,-0.0164714},{-16.2554,2.55014,-0.0162554},{-16.0002,2.97516,-0.0160002},{-15.7059,3.40019,-0.0157059},{-15.3725,3.82521,-0.0153725},{-14.698,-4.25023,-2.99474},{-15.0417,-3.82521,-3.06476},{-15.3769,-3.40019,-3.13307},{-15.6956,-2.97516,-3.19799},{-15.9897,-2.55014,-3.25792},{-16.2521,-2.12512,-3.31138},{-16.4762,-1.70009,-3.35704},{-16.6565,-1.27507,-3.39378},{-16.7886,-0.850047,-3.4207},{-16.8692,-0.425023,-3.43711},{-16.8962,-5.89838*10^-16,-3.44263},{-16.8692,0.425023,-3.43711},{-16.7886,0.850047,-3.4207},{-16.6565,1.27507,-3.39378},{-16.4762,1.70009,-3.35704},{-16.2521,2.12512,-3.31138},{-15.9897,2.55014,-3.25792},{-15.6956,2.97516,-3.19799},{-15.3769,3.40019,-3.13307},{-15.0417,3.82521,-3.06476},{-13.8101,-4.25023,-5.85509},{-14.1175,-3.82521,-5.98541},{-14.44,-3.40019,-6.12216},{-14.7648,-2.97516,-6.25985},{-15.0787,-2.55014,-6.39296},{-15.3693,-2.12512,-6.51615},{-15.6248,-1.70009,-6.62448},{-15.835,-1.27507,-6.7136},{-15.9915,-0.850047,-6.77994},{-16.0879,-0.425023,-6.82084},{-16.1205,-5.89838*10^-16,-6.83466},{-16.0879,0.425023,-6.82084},{-15.9915,0.850047,-6.77994},{-15.835,1.27507,-6.7136},{-15.6248,1.70009,-6.62448},{-15.3693,2.12512,-6.51615},{-15.0787,2.55014,-6.39296},{-14.7648,2.97516,-6.25985},{-14.44,3.40019,-6.12216},{-14.1175,3.82521,-5.98541},{-12.3716,-4.25023,-8.48201},{-12.6372,-3.82521,-8.66411},{-12.933,-3.40019,-8.86697},{-13.2444,-2.97516,-9.08044},{-13.5556,-2.55014,-9.29382},{-13.8512,-2.12512,-9.49646},{-14.1163,-1.70009,-9.6782},{-14.3376,-1.27507,-9.82995},{-14.5041,-0.850047,-9.94411},{-14.6075,-0.425023,-10.015},{-14.6425,-5.89838*10^-16,-10.039},{-14.6075,0.425023,-10.015},{-14.5041,0.850047,-9.94411},{-14.3376,1.27507,-9.82995},{-14.1163,1.70009,-9.6782},{-13.8512,2.12512,-9.49646},{-13.5556,2.55014,-9.29382},{-13.2444,2.97516,-9.08044},{-12.933,3.40019,-8.86697},{-12.6372,3.82521,-8.66411},{-10.4398,-4.25023,-10.7708},{-10.6588,-3.82521,-10.9967},{-10.9148,-3.40019,-11.2608},{-11.1935,-2.97516,-11.5483},{-11.4789,-2.55014,-11.8428},{-11.7549,-2.12512,-12.1276},{-12.0059,-1.70009,-12.3865},{-12.2176,-1.27507,-12.6049},{-12.3781,-0.850047,-12.7705},{-12.4781,-0.425023,-12.8737},{-12.5121,-5.89838*10^-16,-12.9087},{-12.4781,0.425023,-12.8737},{-12.3781,0.850047,-12.7705},{-12.2176,1.27507,-12.6049},{-12.0059,1.70009,-12.3865},{-11.7549,2.12512,-12.1276},{-11.4789,2.55014,-11.8428},{-11.1935,2.97516,-11.5483},{-10.9148,3.40019,-11.2608},{-10.6588,3.82521,-10.9967},{-8.09191,-4.25023,-12.6302},{-8.25964,-3.82521,-12.892},{-8.46364,-3.40019,-13.2104},{-8.6914,-2.97516,-13.5659},{-8.92895,-2.55014,-13.9366},{-9.16172,-2.12512,-14.3},{-9.37544,-1.70009,-14.6335},{-9.557,-1.27507,-14.9169},{-9.69528,-0.850047,-15.1328},{-9.78179,-0.425023,-15.2678},{-9.81123,-5.89838*10^-16,-15.3137},{-9.78179,0.425023,-15.2678},{-9.69528,0.850047,-15.1328},{-9.557,1.27507,-14.9169},{-9.37544,1.70009,-14.6335},{-9.16172,2.12512,-14.3},{-8.92895,2.55014,-13.9366},{-8.6914,2.97516,-13.5659},{-8.46364,3.40019,-13.2104},{-8.25964,3.82521,-12.892},{-5.42138,-4.25023,-13.986},{-5.53367,-3.82521,-14.2757},{-5.67456,-3.40019,-14.6392},{-5.83496,-2.97516,-15.053},{-6.00451,-2.55014,-15.4904},{-6.17225,-2.12512,-15.9231},{-6.32735,-1.70009,-16.3232},{-6.45979,-1.27507,-16.6649},{-6.56102,-0.850047,-16.926},{-6.6245,-0.425023,-17.0898},{-6.64612,-5.89838*10^-16,-17.1456},{-6.6245,0.425023,-17.0898},{-6.56102,0.850047,-16.926},{-6.45979,1.27507,-16.6649},{-6.32735,1.70009,-16.3232},{-6.17225,2.12512,-15.9231},{-6.00451,2.55014,-15.4904},{-5.83496,2.97516,-15.053},{-5.67456,3.40019,-14.6392},{-5.53367,3.82521,-14.2757},{-2.53472,-4.25023,-14.7843},{-2.58773,-3.82521,-15.0935},{-2.65588,-3.40019,-15.4909},{-2.7346,-2.97516,-15.9501},{-2.81864,-2.55014,-16.4403},{-2.90236,-2.12512,-16.9286},{-2.98017,-1.70009,-17.3824},{-3.04685,-1.27507,-17.7714},{-3.09795,-0.850047,-18.0694},{-3.13005,-0.425023,-18.2566},{-3.14099,-5.89838*10^-16,-18.3205},{-3.13005,0.425023,-18.2566},{-3.09795,0.850047,-18.0694},{-3.04685,1.27507,-17.7714},{-2.98017,1.70009,-17.3824},{-2.90236,2.12512,-16.9286},{-2.81864,2.55014,-16.4403},{-2.7346,2.97516,-15.9501},{-2.65588,3.40019,-15.4909},{-2.58773,3.82521,-15.0935},{0.452986,-4.25023,-14.9932},{0.462651,-3.82521,-15.313},{0.475302,-3.40019,-15.7318},{0.490072,-2.97516,-16.2206},{0.50595,-2.55014,-16.7462},{0.521847,-2.12512,-17.2723},{0.536673,-1.70009,-17.7631},{0.549412,-1.27507,-18.1847},{0.559192,-0.850047,-18.5084},{0.565341,-0.425023,-18.7119},{0.567439,-5.89838*10^-16,-18.7814},{0.565341,0.425023,-18.7119},{0.559192,0.850047,-18.5084},{0.549412,1.27507,-18.1847},{0.536673,1.70009,-17.7631},{0.521847,2.12512,-17.2723},{0.50595,2.55014,-16.7462},{0.490072,2.97516,-16.2206},{0.475302,3.40019,-15.7318},{0.462651,3.82521,-15.313},{3.42264,-4.25023,-14.6043},{3.49796,-3.82521,-14.9257},{3.59775,-3.40019,-15.3515},{3.71508,-2.97516,-15.8521},{3.84178,-2.55014,-16.3927},{3.96903,-2.12512,-16.9357},{4.08798,-1.70009,-17.4433},{4.19036,-1.27507,-17.8801},{4.26904,-0.850047,-18.2159},{4.31855,-0.425023,-18.4271},{4.33545,-5.89838*10^-16,-18.4992},{4.31855,0.425023,-18.4271},{4.26904,0.850047,-18.2159},{4.19036,1.27507,-17.8801},{4.08798,1.70009,-17.4433},{3.96903,2.12512,-16.9357},{3.84178,2.55014,-16.3927},{3.71508,2.97516,-15.8521},{3.59775,3.40019,-15.3515},{3.49796,3.82521,-14.9257},{6.25584,-4.25023,-13.6332},{6.39959,-3.82521,-13.9465},{6.59119,-3.40019,-14.364},{6.81723,-2.97516,-14.8566},{7.06186,-2.55014,-15.3898},{7.30794,-2.12512,-15.926},{7.53823,-1.70009,-16.4279},{7.73659,-1.27507,-16.8602},{7.88913,-0.850047,-17.1926},{7.98514,-0.425023,-17.4018},{8.01791,-5.89838*10^-16,-17.4733},{7.98514,0.425023,-17.4018},{7.88913,0.850047,-17.1926},{7.73659,1.27507,-16.8602},{7.53823,1.70009,-16.4279},{7.30794,2.12512,-15.926},{7.06186,2.55014,-15.3898},{6.81723,2.97516,-14.8566},{6.59119,3.40019,-14.364},{6.39959,3.82521,-13.9465},{8.83964,-4.25023,-12.1186},{9.05484,-3.82521,-12.4136},{9.34149,-3.40019,-12.8066},{9.67949,-2.97516,-13.27},{10.0452,-2.55014,-13.7714},{10.413,-2.12512,-14.2756},{10.7572,-1.70009,-14.7474},{11.0536,-1.27507,-15.1538},{11.2815,-0.850047,-15.4663},{11.425,-0.425023,-15.663},{11.4739,-5.89838*10^-16,-15.7301},{11.425,0.425023,-15.663},{11.2815,0.850047,-15.4663},{11.0536,1.27507,-15.1538},{10.7572,1.70009,-14.7474},{10.413,2.12512,-14.2756},{10.0452,2.55014,-13.7714},{9.67949,2.97516,-13.27},{9.34149,3.40019,-12.8066},{9.05484,3.82521,-12.4136},{11.071,-4.25023,-10.1209},{11.3621,-3.82521,-10.3869},{11.7462,-3.40019,-10.7381},{12.1968,-2.97516,-11.15},{12.6827,-2.55014,-11.5942},{13.1703,-2.12512,-12.04},{13.6257,-1.70009,-12.4563},{14.0175,-1.27507,-12.8145},{14.3185,-0.850047,-13.0896},{14.5078,-0.425023,-13.2627},{14.5725,-5.89838*10^-16,-13.3218},{14.5078,0.425023,-13.2627},{14.3185,0.850047,-13.0896},{14.0175,1.27507,-12.8145},{13.6257,1.70009,-12.4563},{13.1703,2.12512,-12.04},{12.6827,2.55014,-11.5942},{12.1968,2.97516,-11.15},{11.7462,3.40019,-10.7381},{11.3621,3.82521,-10.3869},{12.8611,-4.25023,-7.71966},{13.1937,-3.82521,-7.91934},{13.5924,-3.40019,-8.15863},{14.0333,-2.97516,-8.42327},{14.4901,-2.55014,-8.69748},{14.9356,-2.12512,-8.96488},{15.3432,-1.70009,-9.20953},{15.6886,-1.27507,-9.41684},{15.9511,-0.850047,-9.57444},{16.1152,-0.425023,-9.67292},{16.171,-5.89838*10^-16,-9.70641},{16.1152,0.425023,-9.67292},{15.9511,0.850047,-9.57444},{15.6886,1.27507,-9.41684},{15.3432,1.70009,-9.20953},{14.9356,2.12512,-8.96488},{14.4901,2.55014,-8.69748},{14.0333,2.97516,-8.42327},{13.5924,3.40019,-8.15863},{13.1937,3.82521,-7.91934},{14.1384,-4.25023,-5.01069},{14.5057,-3.82521,-5.14086},{14.9022,-3.40019,-5.2814},{15.3101,-2.97516,-5.42596},{15.711,-2.55014,-5.56803},{16.0867,-2.12512,-5.7012},{16.4204,-1.70009,-5.81946},{16.697,-1.27507,-5.91747},{16.9039,-0.850047,-5.99082},{17.032,-0.425023,-6.0362},{17.0753,-5.89838*10^-16,-6.05155},{17.032,0.425023,-6.0362},{16.9039,0.850047,-5.99082},{16.697,1.27507,-5.91747},{16.4204,1.70009,-5.81946},{16.0867,2.12512,-5.7012},{15.711,2.55014,-5.56803},{15.3101,2.97516,-5.42596},{14.9022,3.40019,-5.2814},{14.5057,3.82521,-5.14086},{14.852,-4.25023,-2.10195},{15.2481,-3.82521,-2.15801},{15.6315,-3.40019,-2.21227},{15.9935,-2.97516,-2.26351},{16.3259,-2.55014,-2.31055},{16.6211,-2.12512,-2.35233},{16.8724,-1.70009,-2.38788},{17.074,-1.27507,-2.41642},{17.2214,-0.850047,-2.43728},{17.3111,-0.425023,-2.44998},{17.3413,-5.89838*10^-16,-2.45425},{17.3111,0.425023,-2.44998},{17.2214,0.850047,-2.43728},{17.074,1.27507,-2.41642},{16.8724,1.70009,-2.38788},{16.6211,2.12512,-2.35233},{16.3259,2.55014,-2.31055},{15.9935,2.97516,-2.26351},{15.6315,3.40019,-2.21227},{15.2481,3.82521,-2.15801}};
Graphics3D[
 Table[
  With[{dat = RotateRight[dat, 20*j]},
   Table[
    Polygon[{dat[[i]], dat[[i + 1]], dat[[i + 21]], dat[[i + 20]]}]
    , {i, 1, 19}
    ]
   ]
  , {j, 1, Length@dat/20}
  ]
 ]

enter image description here

If you prefer triangles:

Graphics3D[
 Table[
  With[{dat = RotateRight[dat, 20*j]},
   Table[{
     Polygon[{dat[[i]], dat[[i + 1]], dat[[i + 20]]}],
     Polygon[{dat[[i + 1]], dat[[i + 20]], dat[[i + 21]]}]
     }
    , {i, 1, 19}
    ]
   ]
  , {j, 1, Length@dat/20}
  ]
 ]

enter image description here

$\endgroup$
4
$\begingroup$
bdr = BoundaryDiscretizeRegion @ DelaunayMesh[pts]

enter image description here

With some manual tweaking of the threshold t, we can filter the polygons that lie on the outer ring based on the y component of the face normal vector:

t = .9;

cellindices = First /@ Select[Abs[#[[2, 2]]] <= t &]@
    Transpose[{MeshCellIndex[bdr, 2], Region`Mesh`MeshCellNormals[bdr, 2]}];

Graphics3D[{LightBlue, Opacity[.5], EdgeForm[LightGray], 
  MeshPrimitives[bdr, cellindices],  Black, Point @ pts}, 
 ImageSize -> 600, Boxed -> False]

enter image description here

$\endgroup$
3
  • 1
    $\begingroup$ Sorry I am afraid this is not what I wanted, I would prefer too have a continuous surface instead of individual lines. $\endgroup$ Commented Dec 6, 2021 at 13:07
  • 1
    $\begingroup$ @bobthelegend, please see the update. $\endgroup$
    – kglr
    Commented Dec 6, 2021 at 14:10
  • $\begingroup$ Oh wow it looks beautiful, thank you so much for the great answer. $\endgroup$ Commented Dec 6, 2021 at 14:35
2
$\begingroup$

A solution with a hole:

d1 = Select[pts, #[[3]] > -0.1 &];
d2 = Select[pts, #[[3]] < 0 &];
ListPlot3D[{d1, d2}, BoxRatios -> Automatic]

enter image description here

You could try to patch the hole with a third surface:

d1 = Select[pts, #[[3]] > -0.1 &];
d2 = Select[pts, #[[3]] < 0 &];
d3 = Select[pts, #[[1]] > 0 && -3 < #[[3]] < 3 &];
ListPlot3D[{d1, d2, d3}, BoxRatios -> Automatic]

enter image description here

$\endgroup$
2
  • $\begingroup$ For some reason, the lower part (blue) is connected at the sides as well $\endgroup$ Commented Dec 6, 2021 at 13:32
  • $\begingroup$ The problem is that there the surface is doubled valued. That means to a specific {x,y} there are 2 z values. To eliminate this, you could rotate the coordinate system so that the problematic part becomes an ordinary part. And subsequently patch the different pieces together. $\endgroup$ Commented Dec 6, 2021 at 13:33
2
$\begingroup$

Using Partition:

Graphics3D[
 Polygon[
  Flatten[
    Partition[Partition[dat, 20], {2, 2}, 1, 1][[All, 1 ;; -2]],
    {{1, 2}, {3, 4}}][[All, {1, 2, 4, 3}]]
  ]
 ]

enter image description here

Or as a GraphicsComplex:

Graphics3D[
 GraphicsComplex[
  dat,
  Polygon[
   Flatten[
     Partition[Partition[Range@Length@dat, 20], {2, 2}, 1, 1][[All, 1 ;; -2]],
     {{1, 2}, {3, 4}}][[All, {1, 2, 4, 3}]]
   ]
  ]
 ]
$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.