Content-Length: 407829 | pFad | http://github.com/TheAlgorithms/Java/pull/6417

F5 Add matrix multiplication with double[][] and unit tests by Nishitha0730 · Pull Request #6417 · TheAlgorithms/Java · GitHub
Skip to content

Add matrix multiplication with double[][] and unit tests #6417

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

Merged
merged 29 commits into from
Jul 21, 2025

Conversation

Nishitha0730
Copy link
Contributor

Summary

This PR adds an implementation of standard matrix multiplication using double[][] arrays in the com.thealgorithms.matrix package.

  • The MatrixMultiplication class multiplies two 2D matrices with floating-point support.
  • Includes input validation for null, empty, and incompatible dimensions.

Tests

Added a comprehensive JUnit 5 test class MatrixMultiplicationTest with:

  • Valid multiplication tests
  • Edge cases: null input, empty matrix, incompatible dimensions
  • Floating-point accuracy check using EPSILON

Please let me know if any changes are needed!

@codecov-commenter
Copy link

codecov-commenter commented Jul 19, 2025

Codecov Report

Attention: Patch coverage is 93.33333% with 1 line in your changes missing coverage. Please review.

Project coverage is 74.77%. Comparing base (2722b0e) to head (8c1beaa).

Files with missing lines Patch % Lines
...com/thealgorithms/matrix/MatrixMultiplication.java 93.33% 0 Missing and 1 partial ⚠️
Additional details and impacted files
@@            Coverage Diff            @@
##             master    #6417   +/-   ##
=========================================
  Coverage     74.76%   74.77%           
- Complexity     5477     5483    +6     
=========================================
  Files           682      683    +1     
  Lines         19012    19027   +15     
  Branches       3670     3675    +5     
=========================================
+ Hits          14215    14228   +13     
  Misses         4245     4245           
- Partials        552      554    +2     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@DenizAltunkapan DenizAltunkapan enabled auto-merge (squash) July 21, 2025 16:04
@DenizAltunkapan DenizAltunkapan merged commit 2dfad7e into TheAlgorithms:master Jul 21, 2025
6 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants








ApplySandwichStrip

pFad - (p)hone/(F)rame/(a)nonymizer/(d)eclutterfier!      Saves Data!


--- a PPN by Garber Painting Akron. With Image Size Reduction included!

Fetched URL: http://github.com/TheAlgorithms/Java/pull/6417

Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy