{"id":19604701,"url":"https://github.com/victorvoid/gens","last_synced_at":"2025-07-28T05:07:04.663Z","repository":{"id":89705883,"uuid":"57999732","full_name":"victorvoid/genS","owner":"victorvoid","description":"Sorts file values using external memory, and generates random number files.","archived":false,"fork":false,"pushed_at":"2018-04-23T11:50:23.000Z","size":27,"stargazers_count":2,"open_issues_count":0,"forks_count":1,"subscribers_count":0,"default_branch":"master","last_synced_at":"2025-01-09T08:41:55.246Z","etag":null,"topics":["number-generator","sorting-algorithms"],"latest_commit_sha":null,"homepage":"","language":"C","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/victorvoid.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"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":"2016-05-03T20:29:19.000Z","updated_at":"2018-04-23T11:50:25.000Z","dependencies_parsed_at":null,"dependency_job_id":"0a9c6b9f-eb1b-4897-8e60-446c83b6f626","html_url":"https://github.com/victorvoid/genS","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/victorvoid%2FgenS","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/victorvoid%2FgenS/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/victorvoid%2FgenS/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/victorvoid%2FgenS/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/victorvoid","download_url":"https://codeload.github.com/victorvoid/genS/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":240887878,"owners_count":19873554,"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":["number-generator","sorting-algorithms"],"created_at":"2024-11-11T09:37:53.999Z","updated_at":"2025-02-26T16:19:36.786Z","avatar_url":"https://github.com/victorvoid.png","language":"C","funding_links":[],"categories":[],"sub_categories":[],"readme":"# genS\n\n![C](https://img.shields.io/badge/language-c-green.svg?style=flat-square)\n\n- [Objective](#objective)\n- [Some project descriptions](#dev)\n- [How to compile and run](#how-to-compile-and-run)\n- [Experiments](#experiments)\n\n# Objective\n\nThe project aims to implement a high level algorithm that has the function of ordering files that do not fit into the main memory of the computer. Therefore, it is necessary to use an external sorting algorithm to store the files in auxiliary memory. To sort a given data file as input, the sorting method to use will be Merge-Sort, and the strategy will be to combine multiple ordered file units into a single sorted file block (merge).\n\n# dev\n\n1. The C language was used for implementation.\n2. Used libraries: `stdlib.h`, `stdio.h`, `stdint.h`, `math.h`, `string.h`, `unistd.h` e `time.h`.\n3. Data structure: `Stack`.\n\n### Complexity\n\n- The height of the execution tree can be defined by O (log n)..\n- The number of operations at each level of the execution tree is defined by O (n).\n- Therefore, the complexity of the algorithm for any case is O (n log n).\n\n# How to compile and run\n\nThe process is the simple way to compile C files using [gcc](https://gcc.gnu.org/).\n\nTo facilitate typing, the project has the Makefile to execute the command for you.\n\nTo use it just type ** make ** on your terminal at the file location. Then choose the one you want to run first:\n\n1. Generate a random number file\n2. Sort values within a file\n\nTo generate a file, run:\n\n\u003e ./gerarArquivo primeiroPARAMETRO segundoPARAMETRO\n\nFirst parameter is the name of the file, and the second is the SIZE IN MB\n\nTo sort execute:\n\n\u003e ./msort primeiroPARAMETRO segundoPARAMETRO terceiroPARAMETRO quartoPARAMETRO\n\nFirst parameter is the ** filename ** that you want to sort, second is the ** output name **, third the total amount of ** memory ** available for sorting, and the fourth the ** K ** (number of routes used by Merge-sort).\n\n# Experiments\n\n## Generating a 6GB file\n    \nIt lasted an average time of `` 64.4198s``.\n\nPC 4GB de RAM, i3.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fvictorvoid%2Fgens","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fvictorvoid%2Fgens","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fvictorvoid%2Fgens/lists"}