{"id":19552456,"url":"https://github.com/mahmoudelshimi/vector_space","last_synced_at":"2026-05-19T06:04:26.551Z","repository":{"id":219370131,"uuid":"748866355","full_name":"mahmoudElshimi/vector_space","owner":"mahmoudElshimi","description":"An implementation of Vector Space written in both C and Python.","archived":false,"fork":false,"pushed_at":"2025-05-04T22:31:16.000Z","size":39,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-05-04T23:24:18.835Z","etag":null,"topics":["c","math","modeling","python","vectors"],"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/mahmoudElshimi.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,"zenodo":null}},"created_at":"2024-01-26T22:53:33.000Z","updated_at":"2025-05-04T22:31:20.000Z","dependencies_parsed_at":"2024-01-27T01:44:19.728Z","dependency_job_id":"8a104221-9228-41ce-8d27-8a61223b1bcf","html_url":"https://github.com/mahmoudElshimi/vector_space","commit_stats":null,"previous_names":["mahmoudelshimi/vector_space"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/mahmoudElshimi/vector_space","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mahmoudElshimi%2Fvector_space","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mahmoudElshimi%2Fvector_space/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mahmoudElshimi%2Fvector_space/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mahmoudElshimi%2Fvector_space/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/mahmoudElshimi","download_url":"https://codeload.github.com/mahmoudElshimi/vector_space/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mahmoudElshimi%2Fvector_space/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":265167476,"owners_count":23721450,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","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","math","modeling","python","vectors"],"created_at":"2024-11-11T04:18:11.715Z","updated_at":"2026-05-19T06:04:26.523Z","avatar_url":"https://github.com/mahmoudElshimi.png","language":"C","funding_links":[],"categories":[],"sub_categories":[],"readme":"Vector Space:  An implementation of Vector Space written in both C and Python.\n==============================================================================\n- Why C? God created universe in C.\n- Why Python? You know.\n- Python code was statically typed and checked using mypy.\n\nDefinition and basic properties\n-------------------------------\n- A vector is any object that respects these [axioms](https://en.wikipedia.org/wiki/Vector_space#Definition_and_basic_properties). \n   In this implementation we assume that they are $\\in \\mathbb{C}^{n}$\n  \n- [Dot product](https://en.wikipedia.org/wiki/Dot_product#Definition) is defined as:\n  \nFor $\\mathbb{R}^n$:\n\n $$\\vec{u} \\cdot \\vec{w} = \\sum_{i}{u_{i}w_{i}} \\textit{, where } \\vec{u}, \\vec{w} \\in \\mathbb{R}^{n} \\text{. In general } V \\times V \\to F$$\n \nFor $\\mathbb{C}^n$:\n     \n  $$\\vec{u} \\cdot \\vec{w} = \\sum_{i}{u_{i}\\overline{w_{i}}} \\textit{, where } \\vec{u}, \\vec{w} \\in \\mathbb{C}^{n} \\text{ and } \\overline{w_{i}} \\text{ is the complex conjugate of } w_{i}$$\n  \n- [Norm](https://en.wikipedia.org/wiki/Norm_(mathematics)) is defined as:\n\n $$\\|\\|\\vec{u}\\|\\| = \\sqrt{\\sum_{i}{\\|u_{i}\\|}} = \\sqrt{\\sum_{i}{u_{i}^{2}}}$$\n\n- [Cross product](https://en.wikipedia.org/wiki/Cross_product) is defined only in 3D as:\n  \n $$\\vec{u} \\times \\vec{w} = \n  \\left(\n  \\begin{array}{c}\n  u_2 w_3 - u_3 w_2 \\\\\n  u_3 w_1 - u_1 w_3 \\\\\n  u_1 w_2 - u_2 w_1\n  \\end{array}\n  \\right)\n  \\textit{, where } \\vec{u}, \\vec{w} \\in \\mathbb{R}^{3}$$\n  \n  \n  \nTo Do\n-----\n- Implement a Cross product. #Done as per: #3bc7daa, #22a5520.\n- Support Vectors  $\\in \\mathbb{C}^{n}$ . #Done as per: #4be75a6\n- Adding Rust implementation, whay? cuz i love Rust.  \n\nRequirements\n------------\n- Python \u003e= 3.11.6\n- CC --std=c99 -lm (Clang or GCC).\n\nRunning\n-------\n```\n$ git clone https://github.com/mahmoudElshimi/vector_space\n$ cd vector_space\n$ python -i vec.py\n$ cc --std=c99 -lm -Wall -o vec vec.c \u0026\u0026 ./vec\n```\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmahmoudelshimi%2Fvector_space","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmahmoudelshimi%2Fvector_space","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmahmoudelshimi%2Fvector_space/lists"}