2020-08-21 17:03:33 +02:00
|
|
|
// This file is part of monofonIC (MUSIC2)
|
|
|
|
// A software package to generate ICs for cosmological simulations
|
|
|
|
// Copyright (C) 2020 by Oliver Hahn
|
|
|
|
//
|
|
|
|
// monofonIC is free software: you can redistribute it and/or modify
|
|
|
|
// it under the terms of the GNU General Public License as published by
|
|
|
|
// the Free Software Foundation, either version 3 of the License, or
|
|
|
|
// (at your option) any later version.
|
|
|
|
//
|
|
|
|
// monofonIC is distributed in the hope that it will be useful,
|
|
|
|
// but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
|
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
|
|
// GNU General Public License for more details.
|
|
|
|
//
|
|
|
|
// You should have received a copy of the GNU General Public License
|
|
|
|
// along with this program. If not, see <http://www.gnu.org/licenses/>.
|
2019-08-07 18:43:00 +02:00
|
|
|
#pragma once
|
|
|
|
|
2019-08-11 22:48:04 +02:00
|
|
|
#include <array>
|
|
|
|
#include <general.hh>
|
|
|
|
#include <config_file.hh>
|
|
|
|
#include <grid_fft.hh>
|
2019-10-24 14:44:06 +02:00
|
|
|
#include <cosmology_calculator.hh>
|
2019-08-11 22:48:04 +02:00
|
|
|
|
2019-08-07 18:43:00 +02:00
|
|
|
namespace testing{
|
|
|
|
void output_potentials_and_densities(
|
2020-04-04 20:55:24 +02:00
|
|
|
config_file& the_config,
|
2019-08-07 18:43:00 +02:00
|
|
|
size_t ngrid, real_t boxlen,
|
2019-08-11 22:48:04 +02:00
|
|
|
Grid_FFT<real_t>& phi,
|
|
|
|
Grid_FFT<real_t>& phi2,
|
2020-08-16 17:41:21 +02:00
|
|
|
Grid_FFT<real_t>& phi3,
|
2019-08-11 22:48:04 +02:00
|
|
|
std::array< Grid_FFT<real_t>*,3 >& A3 );
|
2019-10-10 21:48:00 +02:00
|
|
|
|
|
|
|
void output_velocity_displacement_symmetries(
|
2020-04-04 20:55:24 +02:00
|
|
|
config_file &the_config,
|
2019-10-12 14:43:06 +02:00
|
|
|
size_t ngrid, real_t boxlen, real_t vfac, real_t dplus,
|
2019-10-10 21:48:00 +02:00
|
|
|
Grid_FFT<real_t> &phi,
|
|
|
|
Grid_FFT<real_t> &phi2,
|
2020-08-16 17:41:21 +02:00
|
|
|
Grid_FFT<real_t> &phi3,
|
2019-10-12 14:43:06 +02:00
|
|
|
std::array<Grid_FFT<real_t> *, 3> &A3,
|
|
|
|
bool bwrite_out_fields=false);
|
2019-10-16 18:18:46 +02:00
|
|
|
|
|
|
|
void output_convergence(
|
2020-04-04 20:55:24 +02:00
|
|
|
config_file &the_config,
|
2020-03-29 14:49:17 +02:00
|
|
|
cosmology::calculator* the_cosmo_calc,
|
2019-10-16 18:18:46 +02:00
|
|
|
std::size_t ngrid, real_t boxlen, real_t vfac, real_t dplus,
|
|
|
|
Grid_FFT<real_t> &phi,
|
|
|
|
Grid_FFT<real_t> &phi2,
|
2020-08-16 17:41:21 +02:00
|
|
|
Grid_FFT<real_t> &phi3,
|
2019-10-16 18:18:46 +02:00
|
|
|
std::array<Grid_FFT<real_t> *, 3> &A3);
|
2019-08-07 18:43:00 +02:00
|
|
|
}
|