{"id":20673630,"url":"https://github.com/jmiszczak/hoqus","last_synced_at":"2026-04-24T09:34:42.894Z","repository":{"id":139079189,"uuid":"100585549","full_name":"jmiszczak/hoqus","owner":"jmiszczak","description":"hoqus - Haskell-oriented quantum calculations","archived":false,"fork":false,"pushed_at":"2024-01-04T10:29:08.000Z","size":33,"stargazers_count":2,"open_issues_count":0,"forks_count":1,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-03-10T18:11:40.949Z","etag":null,"topics":["linear-algebra","matrices","matrix-calculations","quantum-computing","quantum-mechanics","vector-math"],"latest_commit_sha":null,"homepage":"","language":"Haskell","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/jmiszczak.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":"2017-08-17T09:19:49.000Z","updated_at":"2024-01-04T10:29:12.000Z","dependencies_parsed_at":"2024-11-17T00:19:17.520Z","dependency_job_id":null,"html_url":"https://github.com/jmiszczak/hoqus","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/jmiszczak/hoqus","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jmiszczak%2Fhoqus","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jmiszczak%2Fhoqus/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jmiszczak%2Fhoqus/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jmiszczak%2Fhoqus/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/jmiszczak","download_url":"https://codeload.github.com/jmiszczak/hoqus/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jmiszczak%2Fhoqus/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32216971,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-24T08:24:32.376Z","status":"ssl_error","status_checked_at":"2026-04-24T08:24:26.731Z","response_time":64,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"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":["linear-algebra","matrices","matrix-calculations","quantum-computing","quantum-mechanics","vector-math"],"created_at":"2024-11-16T20:42:06.525Z","updated_at":"2026-04-24T09:34:37.886Z","avatar_url":"https://github.com/jmiszczak.png","language":"Haskell","funding_links":[],"categories":[],"sub_categories":[],"readme":"# hoqus package\n\n## Description\n\nThis repo contains some functions used for playing with quantum mechanics in\nHaskell. Much of this work is based on [package for\nMathematica](https://github.com/jmiszczak/qi).\n\n## Dependencies\n\nNumerical procedures used in ```hoqus``` are based on [hmatrix package for\nHaskell](https://hackage.haskell.org/package/hmatrix).\n\n# Examples\n\n## Quantum computing\n\nThe following program (see ```examples/ex01_ket_proj.hs```) demonstrates how to\nuse kets and projectors along with matrix-vector multiplication.\n\n```haskell\nmodule Main where\n\nimport Numeric.LinearAlgebra\nimport Hoqus.Dirac\n\nmain = do\n  let dim = 4\n  let v1 = ket dim 0\n  let v2 = ket dim 4\n  let prj = proj 4 0 0\n  print v1\n  print v2\n  print $ v1 + v2\n  print $ prj #\u003e v1\n  print $ prj #\u003e v2\n```\n\nIn order to compile on of the exampes use ```ghc``` in the main directory\n\n```\nghc --make examples/ex01_ket_proj\n```\n\nTo run the programm issue\n\n```\n./examples/ex01_ket_proj\n```\n\nin the main directory.\n\n## Other functions\n\nModule ```Cplx``` provides some functionality for manipulating complex numbers.\nIt is located in ```alternative``` directory as it is not used in the\n```hoqus```. The simplest example of using it is the calculation of the sum of\ntwo complex numbers using ```ghci``` interpreter. This requires loading\n```Cplx.hs``` module, so you need to make sure that ```ghci``` know whre it is\nlocated.\n\n```haskell\nghci\u003e :load Cplx\n[1 of 1] Compiling Cplx             ( Cplx.hs, interpreted )\nOk, modules loaded: Cplx.\nghci\u003e let a = 1+:2\nghci\u003e let b = 3+:3\nghci\u003e a+b\n(4.0,5.0)\n```\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjmiszczak%2Fhoqus","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fjmiszczak%2Fhoqus","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjmiszczak%2Fhoqus/lists"}