Hi,

I have a problem with the function "load-minus-flux". After saving the fourier
transformed fields from the normalisation run, i did the second run where i
included the "load-minus-flux" function to compute the relection spectra.
Th second run doesn't work because it doesn't read the HDF5 file extracting from
the normalisation run.

My ctl file is :

For the normalisation run :
(define-param fcen 0.6); pulse center frequency
(define-param df 0.6);  pulse freq. width

(define ((my-amp sigma k)x)
        (exp(-(* 0+2i pi (vector3-dot k x))
        (/ (vector3-dot x x)(* 2 sigma sigma)))))

(set! sources (list
                (make source
                        (src (make gaussian-src (frequency fcen) (fwidth df)))
                        (component Hz)
                        (center 0 0 2.5)
                        (amp-func (my-amp 3 (vector3 0 0 -2)))
                        (size sx sy 0))))

(set! symmetries (list  (make mirror-sym (direction X) (phase -1))
                        (make mirror-sym (direction Y) (phase -1))))

;transmitted & reflected fluxes
(define-param nfreq 300)
(define trans ;transmitted flux
        (add-flux fcen df nfreq
                (make flux-region (center 0 0 -3) (size 10 10 0))))
(define refl ; reflected flux
        (add-flux fcen df nfreq
                (make flux-region
                  (center 0 0 3) (size 10 10 0))))

(run-sources+ 900
        (at-beginning output-epsilon)
        (after-sources (harminv Hz (vector3 0 0 0) fcen df))
        (at-end output-hfield-z))

(save-flux "refl-flux" refl)

(display-fluxes trans refl)


And for the second run :

(define-param fcen 0.6); pulse center frequency
(define-param df 0.6);  pulse freq. width

(define ((my-amp sigma k)x)
        (exp(-(* 0+2i pi (vector3-dot k x))
        (/ (vector3-dot x x)(* 2 sigma sigma)))))

(set! sources (list
                (make source
                        (src (make gaussian-src (frequency fcen) (fwidth df)))
                        (component Hz)
                        (center 0 0 2.5)
                        (amp-func (my-amp 3 (vector3 0 0 -2)))
                        (size sx sy 0))))

(set! symmetries (list  (make mirror-sym (direction X) (phase -1))
                        (make mirror-sym (direction Y) (phase -1))))

;transmitted & reflected fluxes
(define-param nfreq 300)
(define trans ;transmitted flux
        (add-flux fcen df nfreq
                (make flux-region (center 0 0 -3) (size 10 10 0))))
(define refl ; reflected flux
        (add-flux fcen df nfreq
                (make flux-region
                  (center 0 0 3) (size 10 10 0))))

(load-minus-flux "refl-flux" refl)

(run-sources+ 900
        (at-beginning output-epsilon)
        (after-sources (harminv Hz (vector3 0 0 0) fcen df))
        (at-end output-hfield-z))

(display-fluxes trans refl)

After the normalisation run, everyting is fine, a blabla-refl-flux.h5 is
created, but in the .out file (of the second run) the message is :
HDF5-DIAG: Error detected in HDF5 library version: 1.6.5 thread 16384.  Back
trace follows.
  #000: ../../../src/H5F.c line 2048 in H5Fopen(): unable to open file
    major(04): File interface
    minor(17): Unable to open file
  #001: ../../../src/H5F.c line 1725 in H5F_open(): unable to open file
    major(04): File interface
    minor(17): Unable to open file
  #002: ../../../src/H5FD.c line 1044 in H5FD_open(): open failed
    major(22): Virtual File Layer
    minor(29): Unable to initialize object
  #003: ../../../src/H5FDsec2.c line 366 in H5FD_sec2_open(): unable to open 
file
    major(04): File interface
    minor(17): Unable to open file
  #004: ../../../src/H5FDsec2.c line 366 in H5FD_sec2_open(): No such file or
directory
    major(03): Internal HDF5 error
    minor(87): System error message
meep: error on line 243 of h5file.cpp: error opening HDF5 input file


What am I doing wrong?
Is there something wrong in the meep installation??

Thank you very much.



Lydie.



*******************************************************************************
Lydie Ferrier
Doctorante
Institut des Nanotechnologies de Lyon (INL, UMR CNRS 5270)
Ecole Centrale de Lyon
36 avenue Guy de Collongue, 69134 Ecully - FRANCE
tel : 04 72 18 60 61
*******************************************************************************




_______________________________________________
meep-discuss mailing list
[email protected]
http://ab-initio.mit.edu/cgi-bin/mailman/listinfo/meep-discuss

Reply via email to