fimplicit increasing number of points

5 views (last 30 days)
I wonder how can I increase the number of points used by the fimplicit command to plot an implicit curve ?
From this question that I asked before I understand that it is possible to get the points used for the plot as a matrix with two lines:
But there seem to be about 500 points (I made more simulations with various curves and the number of points is approximately 500).
My question is: How can I increase that number to get a more precise representation?
I know that I can make changes in the fimplicit.m original matlab file but what is written there is super-professional and I cannot identify where in the code is set the precision.
P.S. My aim is to make a program that computes the perimeter of an implicit curve so for a better precision I need more points.

Accepted Answer

Walter Roberson
Walter Roberson on 17 Apr 2021
fp = fimplicit(@(x,y) x.^2 + 2*y.^2 - 1); %Example
Points1 = [fp.XData;fp.YData];
axis equal
title('mesh default = 151')
fp = fimplicit(@(x,y) x.^2 + 2*y.^2 - 1, 'meshdensity', 255); %Example
Points2 = [fp.XData;fp.YData];
axis equal
title('mesh 255')
size(Points1)
ans = 1×2
2 587
size(Points2)
ans = 1×2
2 1011
  2 Comments
Maxim Bogdan
Maxim Bogdan on 17 Apr 2021
That's awesome! From where do you know these stuff? I didn't find this in the documentation of fimplicit...

Sign in to comment.

More Answers (0)

Categories

Find more on Particle & Nuclear Physics in Help Center and File Exchange

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!