Graph::Undirected::Hamiltonicity::Wolfram - determine the Hamiltonicity of a given graph using the Wolfram Open Cloud.
use Graph::Undirected::Hamiltonicity::Wolfram; my $result; eval { # $g is a Graph::Undirected $result = is_hamiltonian_per_wolfram( $g ); }; die $@ if $@; if ( $result ) { say "Graph is Hamiltonian."; } else { say "Graph is not Hamiltonian."; }
The is_hamiltonian_per_wolfram() subroutine is exported by default.
Takes: a Graph::Undirected
Returns: 1 if the graph is Hamiltonian according to the Wolfram Open Cloud, 0 if the graph is non-Hamiltonian
Throws: an exception if an error is encountered.
WOLFRAM.md
Please report issues on GitHub.
Ashwin Dixit, <ashwin at ownlifeful dot com>
<ashwin at ownlifeful dot com>
To install Graph::Undirected::Hamiltonicity, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Graph::Undirected::Hamiltonicity
CPAN shell
perl -MCPAN -e shell install Graph::Undirected::Hamiltonicity
For more information on module installation, please visit the detailed CPAN module installation guide.