mirror of
https://github.com/OPM/opm-simulators.git
synced 2025-01-14 04:01:55 -06:00
TargetCalculator: optionally instantiate for float
This commit is contained in:
parent
836436ccdc
commit
8ddd898666
@ -266,28 +266,35 @@ InjectionTargetCalculator<Scalar>::guideTargetMode() const
|
||||
return target_;
|
||||
}
|
||||
|
||||
#define INSTANCE_TARGET_CALCULATOR(...) \
|
||||
template __VA_ARGS__ TargetCalculator<double>::calcModeRateFromRates<__VA_ARGS__>(const __VA_ARGS__* rates) const;
|
||||
#define INSTANTIATE_TARGET_CALCULATOR(T,...) \
|
||||
template __VA_ARGS__ \
|
||||
TargetCalculator<T>::calcModeRateFromRates(const __VA_ARGS__* rates) const;
|
||||
|
||||
template class TargetCalculator<double>;
|
||||
template class InjectionTargetCalculator<double>;
|
||||
#define INSTANTIATE_TYPE(T) \
|
||||
template class TargetCalculator<T>; \
|
||||
template class InjectionTargetCalculator<T>; \
|
||||
INSTANTIATE_TARGET_CALCULATOR(T,T) \
|
||||
INSTANTIATE_TARGET_CALCULATOR(T,DenseAd::Evaluation<T,3,0>) \
|
||||
INSTANTIATE_TARGET_CALCULATOR(T,DenseAd::Evaluation<T,4,0>) \
|
||||
INSTANTIATE_TARGET_CALCULATOR(T,DenseAd::Evaluation<T,5,0>) \
|
||||
INSTANTIATE_TARGET_CALCULATOR(T,DenseAd::Evaluation<T,6,0>) \
|
||||
INSTANTIATE_TARGET_CALCULATOR(T,DenseAd::Evaluation<T,7,0>) \
|
||||
INSTANTIATE_TARGET_CALCULATOR(T,DenseAd::Evaluation<T,8,0>) \
|
||||
INSTANTIATE_TARGET_CALCULATOR(T,DenseAd::Evaluation<T,9,0>) \
|
||||
INSTANTIATE_TARGET_CALCULATOR(T,DenseAd::Evaluation<T,10,0>) \
|
||||
INSTANTIATE_TARGET_CALCULATOR(T,DenseAd::Evaluation<T,-1,4>) \
|
||||
INSTANTIATE_TARGET_CALCULATOR(T,DenseAd::Evaluation<T,-1,5>) \
|
||||
INSTANTIATE_TARGET_CALCULATOR(T,DenseAd::Evaluation<T,-1,6>) \
|
||||
INSTANTIATE_TARGET_CALCULATOR(T,DenseAd::Evaluation<T,-1,7>) \
|
||||
INSTANTIATE_TARGET_CALCULATOR(T,DenseAd::Evaluation<T,-1,8>) \
|
||||
INSTANTIATE_TARGET_CALCULATOR(T,DenseAd::Evaluation<T,-1,9>) \
|
||||
INSTANTIATE_TARGET_CALCULATOR(T,DenseAd::Evaluation<T,-1,10>) \
|
||||
INSTANTIATE_TARGET_CALCULATOR(T,DenseAd::Evaluation<T,-1,11>)
|
||||
|
||||
INSTANCE_TARGET_CALCULATOR(double)
|
||||
INSTANCE_TARGET_CALCULATOR(DenseAd::Evaluation<double,3,0>)
|
||||
INSTANCE_TARGET_CALCULATOR(DenseAd::Evaluation<double,4,0>)
|
||||
INSTANCE_TARGET_CALCULATOR(DenseAd::Evaluation<double,5,0>)
|
||||
INSTANCE_TARGET_CALCULATOR(DenseAd::Evaluation<double,6,0>)
|
||||
INSTANCE_TARGET_CALCULATOR(DenseAd::Evaluation<double,7,0>)
|
||||
INSTANCE_TARGET_CALCULATOR(DenseAd::Evaluation<double,8,0>)
|
||||
INSTANCE_TARGET_CALCULATOR(DenseAd::Evaluation<double,9,0>)
|
||||
INSTANCE_TARGET_CALCULATOR(DenseAd::Evaluation<double,10,0>)
|
||||
INSTANCE_TARGET_CALCULATOR(DenseAd::Evaluation<double,-1,4>)
|
||||
INSTANCE_TARGET_CALCULATOR(DenseAd::Evaluation<double,-1,5>)
|
||||
INSTANCE_TARGET_CALCULATOR(DenseAd::Evaluation<double,-1,6>)
|
||||
INSTANCE_TARGET_CALCULATOR(DenseAd::Evaluation<double,-1,7>)
|
||||
INSTANCE_TARGET_CALCULATOR(DenseAd::Evaluation<double,-1,8>)
|
||||
INSTANCE_TARGET_CALCULATOR(DenseAd::Evaluation<double,-1,9>)
|
||||
INSTANCE_TARGET_CALCULATOR(DenseAd::Evaluation<double,-1,10>)
|
||||
INSTANCE_TARGET_CALCULATOR(DenseAd::Evaluation<double,-1,11>)
|
||||
INSTANTIATE_TYPE(double)
|
||||
|
||||
#if FLOW_INSTANTIATE_FLOAT
|
||||
INSTANTIATE_TYPE(float)
|
||||
#endif
|
||||
|
||||
} // namespace Opm::WGHelpers
|
||||
|
Loading…
Reference in New Issue
Block a user