Skip to content

Commit

Permalink
Merge branch 'main' into update/return-beam-intencities-from-leed-fun…
Browse files Browse the repository at this point in the history
…ction
  • Loading branch information
yakutovicha committed Aug 5, 2024
2 parents 03e432c + f1d7e89 commit b604eb1
Show file tree
Hide file tree
Showing 3 changed files with 172 additions and 218 deletions.
27 changes: 26 additions & 1 deletion cleedpy/cleed/src/leed.c
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,29 @@ typedef struct {
real * iv_curves;
} CleedResult;

void print_phase_shift(struct phs_str phs_shift)
{
int i;
printf("Phase shift:\n");
printf(" lmax: %d\n", phs_shift.lmax);
printf(" neng: %d\n", phs_shift.neng);
printf(" t_type: %d\n", phs_shift.t_type);
printf(" eng_max: %lf\n", phs_shift.eng_max);
printf(" eng_min: %lf\n", phs_shift.eng_min);
printf(" energy: %lf\n", phs_shift.energy[0]);
printf(" dr: %lf\n", phs_shift.dr[0]);
printf(" input_file: %s\n", phs_shift.input_file);
printf(" pshift: ");
for (i=0; i<phs_shift.neng; i++)
{
printf("%lf ", phs_shift.pshift[i]);
if (i % 10 == 0)
printf("\n");
}
printf("\n");

}


CleedResult leed(char * par_file, char * bul_file)
{
Expand All @@ -28,7 +51,7 @@ CleedResult leed(char * par_file, char * bul_file)

CleedResult results;

int i_c, i_set, offset;
int i_c, i_set, offset, i;
int i_layer;
int energy_index;
int n_set;
Expand All @@ -47,6 +70,8 @@ CleedResult leed(char * par_file, char * bul_file)
inp_rdpar(&v_par, &eng, bulk, bul_file);
inp_rdovl_nd(&over, &phs_shifts, bulk, par_file);
inp_showbop(bulk, over, phs_shifts);
for (i=0; (phs_shifts + i)->lmax != I_END_OF_LIST; i++)
print_phase_shift(phs_shifts[i]);


// Construct energy list
Expand Down
Loading

0 comments on commit b604eb1

Please sign in to comment.