Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Feature] Add Centroid Of A Triangle Calculator #1488

Closed
4 of 7 tasks
SumithThota opened this issue Jun 28, 2024 · 16 comments · Fixed by #1548
Closed
4 of 7 tasks

[Feature] Add Centroid Of A Triangle Calculator #1488

SumithThota opened this issue Jun 28, 2024 · 16 comments · Fixed by #1548
Assignees
Labels
calculator addition 📱 Addition of new calculator enhancement ✨ New feature or request gssoc GSSOC Open Source Program level3 Advanced task

Comments

@SumithThota
Copy link
Contributor

Description

This calculator aims to find centroid of a triangle

Importance of centroid

  1. Centroid divides each median in a 2:1 ratio.
  2. Centroid is the center of mass or balance point of the triangle.
  3. The centroid is the intersection point of the three lines that divide the triangle into three equal areas.

Used in:

  1. Mechanics:
  2. Geometry
  3. Engineering

Screenshots

Note:

Here A,B,C are the three vertices of a triangle
Point G is the centroid of that triangle

Screenshot 2024-06-28 164857

Checklist

  • I have checked the existing issues.
  • I follow Contributing Guidelines of this project.
  • I am a GSSOC'24 contributor.
  • I am a IWOC'24 contributor.
  • I am a JWOC'24 contributor.
  • I am a SWOC'24 contributor.

Code of Conduct

Copy link

Hey @SumithThota, Welcome to the project CalcDiverse! 🎊
Thanks for opening an issue! 🙌 Please wait for the issue to be assigned. Happy Coding!! ✨

@jessicachawla
Copy link

All you give a picture with your output? If yes, will the sides have length written along with it? Also will you be taking coordinates as input or length of the sides?

@SumithThota
Copy link
Contributor Author

SumithThota commented Jun 29, 2024

Hi @jessicachawla
Yes the user need to enter co-ordinates as input
User need to enter 3 coorinates (x ,y) since the triangle as 3 vertices

@jessicachawla
Copy link

Are you giving some sort of a diagram?

@SumithThota
Copy link
Contributor Author

Sorry no,
As the user enters data then centroid points will be the output

@bharat-c27
Copy link
Contributor

@jessicachawla According to my understanding he is trying to tell that

Inputs :

  1. Take inputs for 3 vertices of the triangle A(x1,y1) , B(x2,y2), C (x3, y3)

Calculations :

  1. x = ( x1 + x2+ x3 ) / 3
  2. y = ( y1 + y2+ y3 ) / 3

The centroid coordinates will be G (x,y)

Output :

  1. The output will be centroid coordinates G(x,y)

@Rakesh9100 I am excited to contribute to the issue which have been assigned a label up for grab please can you assign it to me #1095

@jessicachawla
Copy link

@SumithThota pls consider giving a diagram as well

@SumithThota
Copy link
Contributor Author

@jessicachawla Yes ok I will try my level best

@jessicachawla
Copy link

@Rakesh9100 this issue can be assigned

@SumithThota
Copy link
Contributor Author

@jessicachawla Check this output
Screenshot 2024-07-03 064227

@jessicachawla
Copy link

Mention the centroid coordinates on the side of the triangle in the diagram. Rest looks good. Well done!

@SumithThota
Copy link
Contributor Author

SumithThota commented Jul 3, 2024

@jessicachawla ok fine I will take care of it.
You haven't assigned the issue till now
Please assign this issue to me

@SumithThota
Copy link
Contributor Author

@jessicachawla I am stilling waiting for your response
Please assign me this issue and let me proceed.

@Rakesh9100
Copy link
Owner

Pls go ahead @SumithThota

@Rakesh9100 Rakesh9100 added the gssoc GSSOC Open Source Program label Jul 6, 2024
@SumithThota
Copy link
Contributor Author

Hello, @Rakesh9100
I have successfully completed the task
check it over here #1548 and Please add appropriate labels to it

@Rakesh9100 Rakesh9100 changed the title [Feature] Calculator that finds centroid of a triangle [Feature] Add Centroid Of A Triangle Calculator Jul 11, 2024
Copy link

Hello @SumithThota! Your issue #1488 has been closed. Thank you for your contribution!! 🙌

@Rakesh9100 Rakesh9100 added enhancement ✨ New feature or request calculator addition 📱 Addition of new calculator level3 Advanced task labels Jul 29, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
calculator addition 📱 Addition of new calculator enhancement ✨ New feature or request gssoc GSSOC Open Source Program level3 Advanced task
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants