2022-09-04 21:26:29 +00:00
|
|
|
/*------------------------------- phasicFlow ---------------------------------
|
|
|
|
O C enter of
|
|
|
|
O O E ngineering and
|
|
|
|
O O M ultiscale modeling of
|
|
|
|
OOOOOOO F luid flow
|
|
|
|
------------------------------------------------------------------------------
|
|
|
|
Copyright (C): www.cemf.ir
|
|
|
|
email: hamid.r.norouzi AT gmail.com
|
|
|
|
------------------------------------------------------------------------------
|
|
|
|
Licence:
|
|
|
|
This file is part of phasicFlow code. It is a free software for simulating
|
|
|
|
granular and multiphase flows. You can redistribute it and/or modify it under
|
|
|
|
the terms of GNU General Public License v3 or any other later versions.
|
|
|
|
|
|
|
|
phasicFlow is distributed to help others in their research in the field of
|
|
|
|
granular and multiphase flows, but WITHOUT ANY WARRANTY; without even the
|
|
|
|
implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
|
|
|
|
|
|
|
|
-----------------------------------------------------------------------------*/
|
|
|
|
|
|
|
|
|
2022-12-09 22:02:54 +00:00
|
|
|
#ifndef __dynamicPointStructure_hpp__
|
|
|
|
#define __dynamicPointStructure_hpp__
|
2022-09-04 21:26:29 +00:00
|
|
|
|
2022-12-09 22:02:54 +00:00
|
|
|
#include "Time.hpp"
|
|
|
|
#include "pointFields.hpp"
|
2023-04-23 19:47:12 +00:00
|
|
|
#include "integration.hpp"
|
2022-12-09 22:02:54 +00:00
|
|
|
#include "uniquePtr.hpp"
|
2022-09-04 21:26:29 +00:00
|
|
|
|
|
|
|
namespace pFlow
|
|
|
|
{
|
|
|
|
|
2024-01-21 21:26:23 +00:00
|
|
|
class systemControl;
|
|
|
|
|
2022-09-04 21:26:29 +00:00
|
|
|
class dynamicPointStructure
|
2022-10-25 16:00:57 +00:00
|
|
|
:
|
2024-01-21 21:26:23 +00:00
|
|
|
public pointStructure
|
2022-09-04 21:26:29 +00:00
|
|
|
{
|
2024-01-21 21:26:23 +00:00
|
|
|
private:
|
2022-09-04 21:26:29 +00:00
|
|
|
|
2024-01-21 21:26:23 +00:00
|
|
|
realx3PointField_D velocity_;
|
2022-09-04 21:26:29 +00:00
|
|
|
|
2024-01-21 21:26:23 +00:00
|
|
|
uniquePtr<integration> integrationPos_ = nullptr;
|
2022-09-04 21:26:29 +00:00
|
|
|
|
2024-01-21 21:26:23 +00:00
|
|
|
uniquePtr<integration> integrationVel_ = nullptr;
|
2022-09-04 21:26:29 +00:00
|
|
|
|
2024-01-21 21:26:23 +00:00
|
|
|
/// @brief integration method for velocity and position
|
|
|
|
word integrationMethod_;
|
2022-09-04 21:26:29 +00:00
|
|
|
|
|
|
|
public:
|
|
|
|
|
2022-12-09 22:02:54 +00:00
|
|
|
TypeInfo("dynamicPointStructure");
|
2022-09-04 21:26:29 +00:00
|
|
|
|
2024-01-21 21:26:23 +00:00
|
|
|
dynamicPointStructure(systemControl& control);
|
2022-10-25 16:00:57 +00:00
|
|
|
|
2024-01-21 21:26:23 +00:00
|
|
|
dynamicPointStructure(const dynamicPointStructure& ps) = delete;
|
2022-10-25 16:00:57 +00:00
|
|
|
|
2024-01-21 21:26:23 +00:00
|
|
|
// - no move construct
|
2022-10-25 16:00:57 +00:00
|
|
|
dynamicPointStructure(dynamicPointStructure&&) = delete;
|
|
|
|
|
2024-01-21 21:26:23 +00:00
|
|
|
///
|
|
|
|
dynamicPointStructure& operator=(const dynamicPointStructure&) = delete;
|
2022-10-25 16:00:57 +00:00
|
|
|
|
|
|
|
// - no move assignment
|
|
|
|
dynamicPointStructure& operator=(dynamicPointStructure&&) = delete;
|
|
|
|
|
|
|
|
// - destructor
|
2024-01-21 21:26:23 +00:00
|
|
|
~dynamicPointStructure() override = default;
|
2022-09-04 21:26:29 +00:00
|
|
|
|
2022-10-25 16:00:57 +00:00
|
|
|
|
2024-01-21 21:26:23 +00:00
|
|
|
inline
|
|
|
|
const realx3PointField_D& velocity()const
|
2022-09-04 21:26:29 +00:00
|
|
|
{
|
2024-01-21 21:26:23 +00:00
|
|
|
return velocity_;
|
2022-09-04 21:26:29 +00:00
|
|
|
}
|
|
|
|
|
2024-01-21 21:26:23 +00:00
|
|
|
inline
|
|
|
|
realx3PointField_D& velocity()
|
2022-09-04 21:26:29 +00:00
|
|
|
{
|
|
|
|
return velocity_;
|
|
|
|
}
|
|
|
|
|
2024-01-29 15:57:19 +00:00
|
|
|
/// In the time loop before iterate
|
|
|
|
//bool beforeIteration() override;
|
|
|
|
|
|
|
|
/// @brief This is called in time loop. Perform the main calculations
|
|
|
|
/// when the component should evolve along time.
|
|
|
|
//bool iterate() override;
|
|
|
|
|
|
|
|
|
2022-09-04 21:26:29 +00:00
|
|
|
|
|
|
|
bool predict(real dt, realx3PointField_D& acceleration);
|
|
|
|
|
|
|
|
bool correct(real dt, realx3PointField_D& acceleration);
|
|
|
|
|
|
|
|
};
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
#endif
|