Skip to content
Snippets Groups Projects
Commit f25ea032 authored by Cristian Lalescu's avatar Cristian Lalescu
Browse files

code compiles and works with no obvious problem

parent c841b206
No related branches found
No related tags found
No related merge requests found
......@@ -706,6 +706,8 @@ class PP(_code):
scal_rspace_stats = []
if self.dns_type == 'bandpass_stats':
vec4_rspace_stats.append('velocity')
for kindex in range(len(self.pp_parameters['k0list'])):
vec4_rspace_stats.append('velocity_band{0}'.format(kindex))
if self.dns_type == 'joint_acc_vel_stats':
vec_spectra_stats.append('velocity')
vec4_rspace_stats.append('velocity')
......
......@@ -148,17 +148,27 @@ int bandpass_stats<rnumber>::work_on_current_iteration(void)
for (int band_counter = 0; band_counter < this->k0list.size(); band_counter++)
{
*filtered_vel0 = *vel;
filtered_vel1->operator=(*vel);
filtered_vel1 =*vel;
*filtered_vel1 = *vel;
this->kk->template filter_calibrated_ell<rnumber, THREE>(
this->filtered_vel0->get_cdata(),
filtered_vel0->get_cdata(),
4*acos(0) / this->k0list[band_counter],
this->filter_type);
this->kk->template filter_calibrated_ell<rnumber, THREE>(
this->filtered_vel1->get_cdata(),
filtered_vel1->get_cdata(),
4*acos(0) / this->k1list[band_counter],
this->filter_type);
filtered_vel->compute_rspace_stats(
this->kk->CLOOP(
[&](
ptrdiff_t cindex,
ptrdiff_t xindex,
ptrdiff_t yindex,
ptrdiff_t zindex){
for (unsigned int component=0; component < 3; component++)
for (unsigned int cc=0; cc < 2; cc++)
filtered_vel1->cval(cindex, component, cc) -= filtered_vel0->cval(cindex, component, cc);
});
filtered_vel1->ift();
filtered_vel1->compute_rspace_stats(
stat_group,
"velocity_band" + std::to_string(band_counter),
this->iteration / this->niter_out,
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment