{"id":21352277,"url":"https://github.com/luisdasartimanhas/busca-a-star","last_synced_at":"2025-03-16T04:43:17.440Z","repository":{"id":261830903,"uuid":"885471082","full_name":"LUISDASARTIMANHAS/Busca-A-STAR","owner":"LUISDASARTIMANHAS","description":"Implementação do A*","archived":false,"fork":false,"pushed_at":"2024-12-05T16:14:40.000Z","size":28163,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-01-22T17:23:09.867Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"C","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/LUISDASARTIMANHAS.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":"2024-11-08T16:42:21.000Z","updated_at":"2024-12-05T16:14:45.000Z","dependencies_parsed_at":"2024-11-24T21:31:32.027Z","dependency_job_id":null,"html_url":"https://github.com/LUISDASARTIMANHAS/Busca-A-STAR","commit_stats":null,"previous_names":["luisdasartimanhas/busca-a-star"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/LUISDASARTIMANHAS%2FBusca-A-STAR","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/LUISDASARTIMANHAS%2FBusca-A-STAR/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/LUISDASARTIMANHAS%2FBusca-A-STAR/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/LUISDASARTIMANHAS%2FBusca-A-STAR/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/LUISDASARTIMANHAS","download_url":"https://codeload.github.com/LUISDASARTIMANHAS/Busca-A-STAR/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":243826778,"owners_count":20354220,"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":[],"created_at":"2024-11-22T03:13:09.255Z","updated_at":"2025-03-16T04:43:17.415Z","avatar_url":"https://github.com/LUISDASARTIMANHAS.png","language":"C","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Busca-A-STAR\nImplementação do A*\n\n## Busca A*\n• Estratégia:\n- Combina o custo do caminho g(n) com o valor da\nheurística h(n)\n\n- g(n) = custo do caminho do nó inicial até o nó n\n\n- h(n) = valor da heurística do nó n até um nó\n\nobjetivo (distancia em linha reta no caso de\ndistancias espaciais)\n\n- f(n) = g(n) + h(n)\n\n - É a técnica de busca mais utilizada.\n\n## A estratégia é completa e ótima.\n\n• Custo de tempo:\n- Exponencial com o comprimento da solução,\nporém boas funções heurísticas diminuem\nsignificativamente esse custo.\n\n- Custo memória:\n- Guarda todos os nós expandidos na memória.\n- Nenhum outro algoritmo ótimo garante expandir\nmenos nós.\n\nguardar dois vetores pra guardar a precisão do A*, os dados serão jogados de um para o outro ate um deles estiver vazio.\n\n***\n\n## Definindo Heurísticas\n- Um problema com a geração de novas funções\nheurísticas é que muitas vezes não se consegue\nobter uma única heurística “claramente melhor”.\n\n- Podemos ter o melhor dos mundos através da\ndefinição:\n\nh(n) = max {h¹(n),..., hm\n(n)}.\n\n- Heurística do A*: f(n) = g(n) + h(n)\n  - g(n) = custo do caminho\n  - h(n) = função heurística\n- Qual seria a função heurística h(n) mais\nadequada para este problema?\n  - A distância em linha reta é uma opção.\n  - Essa heurística composta utiliza qualquer função\nque seja mais precisa no nó em questão.\n\nO próximo passo é gerar a árvore de\nbusca e expandir os nós que tiverem\no menor valor resultante da função\nheurística f(n).\n\n- f(n) = g(n) + h(n)\nEX:\n\n[1,2] = f(n) = ?? + ??\n\n[2,1] = f(n) = ?? + ??\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fluisdasartimanhas%2Fbusca-a-star","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fluisdasartimanhas%2Fbusca-a-star","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fluisdasartimanhas%2Fbusca-a-star/lists"}