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

Community Tip - Did you get an answer that solved your problem? Please mark it as an Accepted Solution so others with the same problem can find the answer easily. X

Translate the entire conversation x

Interpolated Points with Sloped Ground

Eng_ReyD_497
10-Marble

Interpolated Points with Sloped Ground

I have three stacked blocks with widths denoted as B1, B2, and B3. Each block is 4 feet high, and the bottom elevation of the lowest block is defined by BotEL.

The ground surface is represented by a set of known points with X and Y coordinates describing its sloping geometry.

For each block, I need to determine the coordinates of two intersection points with the ground surface. These are labeled a1 and b1 for the first block, a2 and b2 for the second, and so on.

The "a" points correspond to the vertical lines at the right edge of each block, where the X-coordinate aligns with the block’s right edge. The corresponding Y-coordinate must be interpolated from the ground profile at that X-location, The "b" points correspond to lines forming an angle θ (theta) with the ground as shown. A Mathcad and an image illustrating the problem are attached.
I appreciate any help!

9 REPLIES 9

Something like this?

Werner_E_0-1749414330089.png

Note that in the sheet I could not use the "linterp" function because I am limited to Prime Express. In the full version you should delete my workaround and enable the region using "linterp".

 

Prime 10 sheet attached

 

For future questions you should say which version of Prime you are using. Otherwise you might get the answer in a the format of a newer version which you would not be able to read.

 

AK_10736668
4-Participant
(To:Werner_E)

Thank you very much, @Werner_E, for the excellent response. The good news is that I’m also using Prime 10, I’ll definitely keep your reminder in mind for the future.

I followed your instructions and made a few minor adjustments, such as setting the ORIGIN to 1 and combining the X and Y inputs into a single matrix (attached). Fortunately, everything is still working perfectly! I’m learning a lot from your code, thank you!

I’d greatly appreciate your help in taking this a step further by:

  1. Calculating the area of each triangle formed using each pair of points (a and b) as the triangle's base (assuming a straight line between them for simplicity).

  2. Determining the centroid coordinates (CGx and CGy) for each triangle.

Of course, I completely understand if you're busy or prefer not to go further, I truly appreciate the help you've already provided! ...  Thanks again!

Werner_E
25-Diamond I
(To:AK_10736668)

I am confused as of the account you are posting from now. Are you using two different accounts aren't you the original poster`?

According area and centroid. That's quite easy. You have the coordinated of every three points of each triangle.

So simply use the available formulas which calculate area and centroid coordinates based on the coordinates of the three vertices.

 

It might also be possible to calculate the area of the correct polygons using Gauss's 'shoelace' formula. But collecting the points from the ground line polygon which are part of the polygon under consideration might be a bit difficult without having access to basic programming.

AK_10736668
4-Participant
(To:Werner_E)

It appears so regarding the accounts. I am sorry, since I did not access for years, and I have trouble with password, I tried an older email account, and it worked!... but it is me!

Werner_E
25-Diamond I
(To:AK_10736668)


@AK_10736668 wrote:

It appears so regarding the accounts. I am sorry, since I did not access for years, and I have trouble with password, I tried an older email account, and it worked!... but it is me!


Obviously you could access both accounts now. You should stay with the one you used initially.

Werner_E
25-Diamond I
(To:AK_10736668)

I finally found a way using recursion to collect the appropriate polygon vertices even in the free Express version, but its not nice looking nor easy to read.
Using simple programming with a for loop you should be able to do a much nicer job.

Werner_E_0-1749436755771.png

Using the shoelace formula we can calculate the areas and compare them with the approximating triangle areas

Werner_E_1-1749436956849.png

Not sure if the difference has any significance for your work.

 

Concerning the centroids we have the choice between the centroid of the vertices and the centroid of the polygon area. I guess you need the latter. They are only equal in case of a triangle.

Werner_E_2-1749437095482.png

Werner_E_3-1749437175365.png

 

 

 

 

I finally could get back to business again using my original account. I apologize for the confusion!
That is really cool... Thanks @Werner_E I really appreciate it. Can I get the Mathcad file for these calculations.
Thanks

 

Here you are

 

Hello @Eng_ReyD_497

 

It looks like you have some responses from our community champion. If it helped you solve your question, please mark the appropriate reply as the Accepted Solution. 

Of course, if you have more to share on your issue, please let the Community know so other community members can continue to help you.

Thanks,
Vivek N.
Community Moderation Team.

Announcements


Top Tags