cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
Showing results for 
Search instead for 
Did you mean: 

Community Tip - You can subscribe to a forum, label or individual post and receive email notifications when someone posts a new topic or reply. Learn more! X

implicitplot2D function - looking for documentation

LouP
12-Amethyst

implicitplot2D function - looking for documentation

 

In the thread on "Roots of polynomial #3 and How to find unique values into a vector/matrice?" there is a Sept. 23. 2024 post from Werner that uses a function implicitplot2D. I gather from the results and descriptions that this function returns the x-y pts within a defined region where the specified real/complex function = 0 (or close?). 

 

I got around to playing with the attached mcd11 file that has the programmed definition fro this function, and I'm interested in the implicitplot2D function details. I started looking at the function program implementation in the mcd11 file, but it's not something I will work out in the next few minutes.

 

Diverting to the easier path for the moment (find out what has already been done), I found a reference to an implicitplot2D function link in Werner's Mar. 5, 2017 post. The link leads to https://community.ptc.com/t5/Mathcad/implicitplot3d/m-p/332011 ("3d" seems to be in the link, although it advertises itself as the 2d link). When I try to access this while logged in, I get a "Permission Required" message. Perhaps someone else can access and post the content of the link.

 

I searched the author and function - Viacheslav N. Mezentsev - but did not find any useful results.

 

Does anyone know of some other documentation on the procedure used in this implementation? As one example unknown, there are two constant value arrays defined - EdgeTable and TriTable. It's not obvious to me how the values came about, or what properties of the procedure depend on these.

 

While I hope some documentation will appear, I 'll continue to plug away and try to determine what's under the hood of this function.

 

A mcd121 copy of the function from Werner's file is attached.

 

Thx,

Lou

 

 

ACCEPTED SOLUTION

Accepted Solutions
uni
12-Amethyst
12-Amethyst
(To:LouP)

If I haven't got anything wrong, then this is where it all comes from.

View solution in original post

6 REPLIES 6
Werner_E
25-Diamond I
(To:LouP)

The fine thing about this tool is that it not only returns a couple of points (which could be achieved using a simple and more time consuming brute force attack as well)  but rather returns them faster and in a way so they can be plotted connected!

 

I can't say much about the working and underlying algorithm of implicitplot2D and implicitplot3D as I am just using the routines which Viacheslav N. Mezentsev was kind enough to share with us.

I am aware of two accounts of him here

https://community.ptc.com/t5/forums/recentpostspage/post-type/message/user-id/25905/page/1

https://community.ptc.com/t5/forums/recentpostspage/post-type/message/user-id/14846/page/1

Maybe you can find something of interest by flipping through his older postings.

 

But he doesn't frequent this forum often. He is quite active in the SMath forum with his username "uni".

 

When he posted implicitplot3D he gave a hint as to where the algorithm stems from (guess a similar one is used for 2D as well):

 

Idea: LORENSEN W. E., CLINE H. E.: Marching cubes: A high resolution 3D surface construction algorithm.
In SIGGRAPH 1987 (1987), pp. 163--169. 1.
Program author: (c) 2006-2007, All rights reserved, Uni Home Lab, Viacheslav N. Mezentsev.
E-mail: [unihomelab@yandex.ru]

 

This was back in 2013. Not sure if his e-mail is still valid, but you always can give it a try....

Werner_E_0-1727903960613.png

I attach the implicitplot3D for Mathcad(15) and also for Prime(2). Hope it helps!

 

BTW I experience the same error when trying to access the link you posted.
The forum was transferred several times from one forum software to another and each time something went wrong, posts were lost, linked posts no longer worked, attachments were lost, etc. The link you found there is probably one of these many collateral damages.
In addition, older posts have unfortunately been deliberately “archived”, so they are no longer fully accessible.

 

EDIT: Found some older files (Marching cubes) and attach them as well. It may be that it works in MC11 only, not sure.
Also found a pdf in Russian which seems to explain the algorithm used (main.pdf)

LouP
12-Amethyst
(To:Werner_E)

Thx. I'll take a peek at these and see how it goes.

 

I did find that the algorithm takes each point (m,n) in the user-defined array of points and evaluate the function at the set of five points (m, n+1), (m+1, n+1), (m+1, n), (m,n), m+0.5, n+-.5). This is the box of adjacent points to the upper right of the selected point, plus the point in the center of that box. I suspect it's used to estimate the derivative, but haven't got that far as yet.

 

Lou

StuartBruff
23-Emerald III
(To:Werner_E)

As far as I can tell(*), there is a discussion (starting on page 9) on the standard 15-case Lorensen-Cline marching cubes algorithm.  There is then brief discussion of the improved 33-case Marching Cubes 33 algorithm (page 13 of main.pdf):

 

https://www.cs.jhu.edu/~misha/ReadingSeminar/Papers/Chernyaev96.pdf

 

The Wikipedia page gives a short description of the Marching Cubes algorithms as well.

 

https://en.wikipedia.org/wiki/Marching_cubes

 

The article links to Paul Bourke's implementation of the 13-cell marching cubes algorithm; worth a read.  

 

https://paulbourke.net/geometry/polygonise/

 

Wikipedia also gives a nice article on the 2D equivalent, Marching Squares:

 

https://en.wikipedia.org/wiki/Marching_squares

 

The latter references marching squares code in a couple of programming languages.

 

Looking at Viacheslav's paper made wonder if PTC has any plans to allow nested meshes as inputs to 3D Plots - I have a Maple plotlib emulator that I'd like to port to Prime.

 

Stuart

 

(*) Мои навыки чтения по-русски немного заржавели. Мои навыки русского языка были погружены в плавиковую кислоту.

uni
12-Amethyst
12-Amethyst
(To:LouP)

If I haven't got anything wrong, then this is where it all comes from.

LouP
12-Amethyst
(To:uni)

While I checked Uni's post as the solution (and the original source of the function), thanks also to Werner and Stuart for the info in their posts. All of these contributed to my understanding and background. I wanted to check all three posts as a joint effort, but that wasn't possible.

 

Lou

Werner_E
25-Diamond I
(To:LouP)


@LouP wrote:

While I checked Uni's post as the solution (and the original source of the function), thanks also to Werner and Stuart for the info in their posts. All of these contributed to my understanding and background. I wanted to check all three posts as a joint effort, but that wasn't possible.

 

Lou


That's perfectly fine. Ultimately, uni is the creator of this very useful function(s), so he deserves all credit.

Announcements

Top Tags