+ Post New Thread
Results 1 to 5 of 5

16th May 2019, 13:59 #1
 Join Date
 Apr 2009
 Posts
 185
 Helped
 4 / 4
 Points
 2,569
 Level
 11

Advertisment

17th May 2019, 02:23 #2
 Join Date
 Apr 2011
 Location
 Minneapolis, Minnesota, USA
 Posts
 12,639
 Helped
 2513 / 2513
 Points
 51,492
 Level
 55
Re: [CSTMWS] How to get datapoints for 2D geometry?
To send only the outline:
1) Send a code which designates row 1.
2) Starting from the left, send column position of each pixel which is turned on.
3) Do the same until you reach the rightmost pixel which is turned on.
4) Your receiving software understands to turn on each pixel listed (not pixels in between).
5) Send a code which designates 'next row'.
6) Etc. Continue to last row of image.
To send the entire blue area:
1) Starting at row 1, send column position of leftmost pixel which is turned on.
2) Send column position of rightmost pixel which is turned on.
3) Your receiving routine 'understands' that all pixels in between are turned on.
4) Continue likewise for all rows.

Advertisment

17th May 2019, 04:22 #3
 Join Date
 Jan 2019
 Posts
 169
 Helped
 31 / 31
 Points
 831
 Level
 6
Re: [CSTMWS] How to get datapoints for 2D geometry?
you have the "vertices" of the ellipse  that is the four points
the major axis is the horizontal distance from the left point to the right point. (27)
the minor axis is the vertical distance from the top point to the bottom point. (13)
now it gets interesting:
the semi major axis and the semiminor axis are 1/2 respectively, or a = 13.5 and b = 6.5
the eccentricity is e = square root ( 1  (b/a)^2 ) or 0.87645
go to this page:
https://en.wikipedia.org/wiki/Ellipse
look for da La Hires method of drawing ellipses
basically x = a cos (theta) and y = b sin (theta), for theta = 0 to 360 degrees
so you can construct the ellipse outline mathematically with as many points as you like

Advertisment

17th May 2019, 14:12 #4
 Join Date
 Jan 2019
 Posts
 169
 Helped
 31 / 31
 Points
 831
 Level
 6
Re: [CSTMWS] How to get datapoints for 2D geometry?
supplement:
a point x,y is inside the ellipse if y < b sin (tan inverse (y/x)) AND x < a cos (tan inverse (y/x))
if y = b sin (tan inverse (y/x)) AND x = a cos (tan inverse (y/x)) then x,y is on the ellipse
and if y > b sin (tan inverse (y/x)) OR x > a cos (tan inverse (y/x)) then x,y is outside the ellipse

18th May 2019, 19:38 #5
 Join Date
 Apr 2009
 Posts
 185
 Helped
 4 / 4
 Points
 2,569
 Level
 11
Re: [CSTMWS] How to get datapoints for 2D geometry?
Dear @wwfeldman and @Bradtherad
Thank you for your suggestions. They are indeed informative and knowledgeable.
But I am looking for a solution mostly related to the EM software CST MWS.
Can you guys assist in this regard.
+ Post New Thread
Please login