Make the optimizer available using fpm
#1
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Hi! I've seen your code and it can be really useful in some of my works. I've did some editions to it to make it able to use it as a dependency with the Fortran Package Manager fpm, this will be helpful for me and other users that want to use your code in their work.
Besides that compatibility, I did some minor changes to make it easier to use in other projects. Now the optimizer routine is included in a module instead of being a main program, and receives the desired fitness function as an argument. An usage example can be seen at the new directory
example
:With
fpm
installed an user can try this example by runningfpm run --example
inside the repo folder.Other way of using it is making a
fpm
project and including this package as a dependency in thefpm.toml
manifest fileWithout downloading anything manually now the optimizer can be available to call in another project.
I don't know much details of the algorithm itself, but this could be further improved to have a nice package for other users :)