{"id":20031753,"url":"https://github.com/astrodynamic/matrix-in-c","last_synced_at":"2026-06-05T13:31:34.745Z","repository":{"id":162006938,"uuid":"636618747","full_name":"Astrodynamic/Matrix-in-C","owner":"Astrodynamic","description":"This is a C implementation of various matrix operations, including creating, removing, adding, subtracting, multiplying, and comparing matrices. The library provides functions to perform operations such as matrix transposition, determinant, and inverse.","archived":false,"fork":false,"pushed_at":"2023-05-05T09:08:57.000Z","size":11,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"develop","last_synced_at":"2025-11-29T09:43:09.626Z","etag":null,"topics":["c","check","cmake","leaning","makefile","mathematics","matrix","testing"],"latest_commit_sha":null,"homepage":"","language":"C","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Astrodynamic.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2023-05-05T09:01:28.000Z","updated_at":"2023-05-10T11:36:08.000Z","dependencies_parsed_at":null,"dependency_job_id":"557c9820-a9de-4d79-ae1b-e3cbcdb3d40e","html_url":"https://github.com/Astrodynamic/Matrix-in-C","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/Astrodynamic/Matrix-in-C","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Astrodynamic%2FMatrix-in-C","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Astrodynamic%2FMatrix-in-C/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Astrodynamic%2FMatrix-in-C/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Astrodynamic%2FMatrix-in-C/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Astrodynamic","download_url":"https://codeload.github.com/Astrodynamic/Matrix-in-C/tar.gz/refs/heads/develop","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Astrodynamic%2FMatrix-in-C/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":33944671,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-26T15:22:16.424Z","status":"online","status_checked_at":"2026-06-05T02:00:06.157Z","response_time":120,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["c","check","cmake","leaning","makefile","mathematics","matrix","testing"],"created_at":"2024-11-13T09:34:36.922Z","updated_at":"2026-06-05T13:31:34.728Z","avatar_url":"https://github.com/Astrodynamic.png","language":"C","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Matrix Library\n\nThis project provides a C implementation of various operations with matrices, such as creating, removing, adding, subtracting, multiplying, and comparing matrices.\n\n## Build\n\nTo build the project, run the following command:\n```\nmake all\n```\n\nTo clean the build artifacts, run the following command:\n```\nmake clean\n```\n\n## Dependencies\n\nThis project requires CMake version 3.0 or higher and a C99-compatible compiler.\n\n## Matrix operations\n\nAll operations (except matrix comparison) should return the resulting code:\n- 0 - OK\n- 1 - Error, incorrect matrix\n- 2 - Calculation error (mismatched matrix sizes; matrix for which calculations cannot be performed, etc.)\n\n```c\nint castom_create_matrix(int rows, int columns, matrix_t *result);\nvoid castom_remove_matrix(matrix_t *A);\n```\n\n```c\n#define SUCCESS 1\n#define FAILURE 0\n\nint castom_eq_matrix(matrix_t *A, matrix_t *B);\n```\n\n```c\nint castom_sum_matrix(matrix_t *A, matrix_t *B, matrix_t *result);\nint castom_sub_matrix(matrix_t *A, matrix_t *B, matrix_t *result);\nint castom_mult_number(matrix_t *A, double number, matrix_t *result);\nint castom_mult_matrix(matrix_t *A, matrix_t *B, matrix_t *result);\nint castom_transpose(matrix_t *A, matrix_t *result);\nint castom_calc_complements(matrix_t *A, matrix_t *result);\nint castom_determinant(matrix_t *A, double *result);\nint castom_inverse_matrix(matrix_t *A, matrix_t *result);\n```\n\n## Usage Examples\n\nHere's an example of how to use the library to create and add two matrices:\n\n```c\n#include \u003cstdio.h\u003e\n#include \"matrix.h\"\n\nint main() {\n    matrix_t A, B, C;\n    castom_create_matrix(3, 3, \u0026A);\n    castom_create_matrix(3, 3, \u0026B);\n    castom_create_matrix(3, 3, \u0026C);\n\n    for (int i = 0; i \u003c A.rows; i++) {\n        for (int j = 0; j \u003c A.columns; j++) {\n            A.matrix[i][j] = i * A.columns + j + 1;\n            B.matrix[i][j] = i * A.columns + j + 1;\n        }\n    }\n\n    castom_sum_matrix(\u0026A, \u0026B, \u0026C);\n\n    for (int i = 0; i \u003c C.rows; i++) {\n        for (int j = 0; j \u003c C.columns; j++) {\n            printf(\"%lf \", C.matrix[i][j]);\n        }\n        printf(\"\\n\");\n    }\n\n    castom_remove_matrix(\u0026A);\n    castom_remove_matrix(\u0026B);\n    castom_remove_matrix(\u0026C);\n    return 0;\n}\n```\n\n## Development\n\nTo run the tests, run the following command:\n```\nmake tests\n```\n\n## License\n\nThis project is licensed under the MIT License. See the [LICENSE](LICENSE) file for details.","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fastrodynamic%2Fmatrix-in-c","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fastrodynamic%2Fmatrix-in-c","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fastrodynamic%2Fmatrix-in-c/lists"}