From 6da644f98434d3eac8b4e19981754f6030a315a5 Mon Sep 17 00:00:00 2001 From: Samo Penic <samo.penic@gmail.com> Date: Wed, 27 Jun 2018 12:05:32 +0000 Subject: [PATCH] Resolving the issues with restoring vesicles from vtu and fixing the volume. Dump to vtu has been repaired. --- src/shcomplex.c | 9 ++++++++- 1 files changed, 8 insertions(+), 1 deletions(-) diff --git a/src/shcomplex.c b/src/shcomplex.c index 7d8c9d8..9002e7e 100644 --- a/src/shcomplex.c +++ b/src/shcomplex.c @@ -1,3 +1,4 @@ +/* vim: set ts=4 sts=4 sw=4 noet : */ #include<math.h> #include<stdlib.h> #include<gsl/gsl_complex.h> @@ -68,7 +69,7 @@ if(sph->co != NULL) free(sph->co); if(sph->ulm !=NULL) free(sph->ulm); if(sph->ulmComplex !=NULL) free(sph->ulmComplex); - + if(sph->sumUlm2 !=NULL) free(sph->sumUlm2); if(sph->Ylmi!=NULL) { for(i=0;i<sph->l;i++){ if(sph->Ylmi[i]!=NULL){ @@ -170,3 +171,9 @@ return retval; } + + +ts_double get_absolute_ulm2(ts_vesicle *vesicle, int l, int m){ + return gsl_complex_abs2(vesicle->sphHarmonics->ulmComplex[l][m]); +} + -- Gitblit v1.9.3