/*******************************************************************************
* This file is part of SWIFT.
* Copyright (c) 2023 Matthieu Schaller (schaller@strw.leidenuniv.nl)
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License as published
* by the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* This program 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 Lesser General Public License
* along with this program. If not, see .
*
******************************************************************************/
#ifndef SWIFT_FORCING_NONE_H
#define SWIFT_FORCING_NONE_H
/* Config parameters. */
#include
/* Standard includes. */
#include
/* Local includes. */
#include "error.h"
#include "parser.h"
#include "part.h"
#include "physical_constants.h"
#include "space.h"
#include "units.h"
/**
* @brief Forcing Term Properties
*/
struct forcing_terms {};
/**
* @brief Computes the forcing terms.
*
* We do nothing in this 'none' scheme.
*
* @param time The current time.
* @param terms The properties of the forcing terms.
* @param s The #space we act on.
* @param phys_const The physical constants in internal units.
* @param p Pointer to the particle data.
* @param xp Pointer to the extended particle data.
*/
__attribute__((always_inline)) INLINE static void forcing_terms_apply(
const double time, const struct forcing_terms* terms, const struct space* s,
const struct phys_const* phys_const, struct part* p, struct xpart* xp) {
/* Nothing to do here */
}
/**
* @brief Computes the time-step condition due to the forcing terms.
*
* Nothing to do here. --> Return FLT_MAX.
*
* @param time The current time.
* @param terms The properties of the forcing terms.
* @param phys_const The physical constants in internal units.
* @param p Pointer to the particle data.
* @param xp Pointer to the extended particle data.
*/
__attribute__((always_inline)) INLINE static float forcing_terms_timestep(
double time, const struct forcing_terms* terms,
const struct phys_const* phys_const, const struct part* p,
const struct xpart* xp) {
/* No time-step size limit */
return FLT_MAX;
}
/**
* @brief Prints the properties of the forcing terms to stdout.
*
* @param terms The #forcing_terms properties of the run.
*/
static INLINE void forcing_terms_print(const struct forcing_terms* terms) {
message("Forcing terms is 'No forcing terms'.");
}
/**
* @brief Initialises the forcing term properties
*
* Nothing to do here.
*
* @param parameter_file The parsed parameter file
* @param phys_const Physical constants in internal units
* @param us The current internal system of units
* @param s The #space object.
* @param terms The forcing term properties to initialize
*/
static INLINE void forcing_terms_init(struct swift_params* parameter_file,
const struct phys_const* phys_const,
const struct unit_system* us,
const struct space* s,
struct forcing_terms* terms) {
/* Nothing to do here */
}
#endif /* SWIFT_FORCING_NONE_H */