#!/usr/bin/perl -w use Math::GSL qw/:all/; use Math::GSL::Eigen qw/:all/; use Math::GSL::Matrix qw/:all/; use Math::GSL::Vector qw/:all/; use Math::GSL::Complex qw/:all/; use Math::GSL::Errno qw/:all/; use Math::Complex; use Data::Dumper; use strict; my $matrix = Math::GSL::Matrix->new(2,2) ->set_row(0, [0,-1] ) ->set_row(1, [1, 0] ); print <raw,$vector, $evec, $eigen); my $x = gsl_vector_complex_real($vector); my $y = gsl_vector_complex_imag($vector); my $eig1 = as_complex( gsl_vector_get($x->{vector}, 0) , gsl_vector_get($y->{vector}, 0) ); my $eig2 = as_complex( gsl_vector_get($x->{vector}, 1) , gsl_vector_get($y->{vector}, 1) ); my $u1 = as_complex( gsl_matrix_complex_get($evec, 0, 0) ); my $u2 = as_complex( gsl_matrix_complex_get($evec, 1, 0) ); my $v1 = as_complex( gsl_matrix_complex_get($evec, 0, 1) ); my $v2 = as_complex( gsl_matrix_complex_get($evec, 1, 1) ); print <make( $x, $y); return qq{$z}; }