Skip to main content
19-Tanzanite
July 31, 2023
Solved

How to create rectangles in Mathcad Prime?

  • July 31, 2023
  • 3 replies
  • 3626 views

Hello,

The right endpoints of the five intervals are:

Cornel_0-1690804180127.png

 

where i = 1, 2, 3, 4, 5.

The width of each rectangle is:

Cornel_2-1690803977641.png

and the height of each rectangle can be obtained by evaluating f(x) at the right endpoint of each interval.

 

Cornel_4-1690804049340.png

 

How to create the below rectangles in Mathcad Prime (8)?

Cornel_0-1690803867683.png

 

Best answer by ttokoro

image.png

3 replies

ttokoro
ttokoro21-Topaz IAnswer
21-Topaz I
July 31, 2023

image.png

t.t.
Cornel19-TanzaniteAuthor
19-Tanzanite
July 31, 2023

So, I need a function in which that if we give the Width and the Height of a rectangle, that function to draw the rectangle based on the Width and Height. Width to be a parameter that can be modified. Height to be a parameter that can be modified.
Cornel_0-1690809691654.png

Cornel_1-1690809699727.png

 

 

 

Cornel_3-1690809716870.png

Cornel_4-1690809727005.png

 

Cornel19-TanzaniteAuthor
19-Tanzanite
July 31, 2023

The above case is for inscribed rectangle.

@ttokoro 
But there is a second case (circumscribed rectangle):

The left endpoints of the five intervals are:

Cornel_0-1690806305429.png

where i = 1, 2, 3, 4, 5. The width of each rectangle is :

Cornel_1-1690806323466.png

and the height of each rectangle can be obtained by evaluating f(x) at the left endpoint of each interval.

Cornel_2-1690806375161.png

25-Diamond I
July 31, 2023

Again Prof. Birkelands Hatch functions can come handy.

Look up his examples for the Riemann sums and also for the trapezoid method in the already posted file.

Werner_E_0-1690823655690.png

 

You may also be interested in this thread

https://community.ptc.com/t5/Mathcad/Simple-Riemann-sum/m-p/93217

Who knows, some of the files posted there may even work in Prime after conversion.

 

Cornel19-TanzaniteAuthor
19-Tanzanite
August 1, 2023

Yes, the subject of this topic is about Riemann sums, how to make that rectangles (with different width and height) for some functions. Only for better understanding of integral calculation/concept...