diff --git a/src/Evolution/Executables/RadiationTransport/MonteCarlo/EvolveMonteCarlo.hpp b/src/Evolution/Executables/RadiationTransport/MonteCarlo/EvolveMonteCarlo.hpp index 3511fbed7d8ee..90e8f17af930c 100644 --- a/src/Evolution/Executables/RadiationTransport/MonteCarlo/EvolveMonteCarlo.hpp +++ b/src/Evolution/Executables/RadiationTransport/MonteCarlo/EvolveMonteCarlo.hpp @@ -178,19 +178,20 @@ struct EvolutionMetavars { tmpl::at>>>; using step_actions = tmpl::flatten, - Particles::MonteCarlo::Actions::ReceiveDataForMcCommunication< - volume_dim, Particles::MonteCarlo::CommunicationStep::PreStep>, + // Actions::RecordTimeStepperData, + // Particles::MonteCarlo::Actions::SendDataForMcCommunication< + // volume_dim, + // No local time stepping + // false, Particles::MonteCarlo::CommunicationStep::PreStep>, + // Particles::MonteCarlo::Actions::ReceiveDataForMcCommunication< + // volume_dim, Particles::MonteCarlo::CommunicationStep::PreStep>, Particles::MonteCarlo::Actions::TakeTimeStep, - Particles::MonteCarlo::Actions::SendDataForMcCommunication< - volume_dim, - // No local time stepping - false, Particles::MonteCarlo::CommunicationStep::PostStep>, - Particles::MonteCarlo::Actions::ReceiveDataForMcCommunication< - volume_dim, Particles::MonteCarlo::CommunicationStep::PostStep>, + // Particles::MonteCarlo::Actions::SendDataForMcCommunication< + // volume_dim, + // No local time stepping + // false, Particles::MonteCarlo::CommunicationStep::PostStep>, + // Particles::MonteCarlo::Actions::ReceiveDataForMcCommunication< + // volume_dim, Particles::MonteCarlo::CommunicationStep::PostStep>, // Actions::RecordTimeStepperData, // evolution::Actions::RunEventsAndDenseTriggers>, Actions::CleanHistory>>; @@ -201,7 +202,9 @@ struct EvolutionMetavars { using initialization_actions = tmpl::list< Initialization::Actions::InitializeItems< Initialization::TimeStepping, - evolution::dg::Initialization::Domain>, + evolution::dg::Initialization::Domain //, + // Initialization::TimeStepperHistory + >, Initialization::Actions::AddSimpleTags< evolution::dg::BackgroundGrVars>, evolution::dg::subcell::Actions::SetSubcellGrid, - //, // Parallel::PhaseActions< // Parallel::Phase::InitializeTimeStepperHistory, // SelfStart::self_start_procedure>, @@ -235,9 +237,27 @@ struct EvolutionMetavars { Parallel::PhaseActions< Parallel::Phase::Evolve, - tmpl::list, - Parallel::Actions::TerminatePhase>> + tmpl::list< + Actions::AdvanceTime, Actions::AdvanceTime, + Actions::AdvanceTime, + Particles::MonteCarlo::Actions::SendDataForMcCommunication< + volume_dim, + // No local time stepping + false, Particles::MonteCarlo::CommunicationStep::PreStep>, + Particles::MonteCarlo::Actions::ReceiveDataForMcCommunication< + volume_dim, + Particles::MonteCarlo::CommunicationStep::PreStep>, + Particles::MonteCarlo::Actions::TakeTimeStep, + Particles::MonteCarlo::Actions::SendDataForMcCommunication< + volume_dim, + // No local time stepping + false, + Particles::MonteCarlo::CommunicationStep::PostStep>, + Particles::MonteCarlo::Actions::ReceiveDataForMcCommunication< + volume_dim, + Particles::MonteCarlo::CommunicationStep::PostStep>, + Parallel::Actions::TerminatePhase>> // tmpl::list /// * Background hydro variables /// * Particles::MonteCarlo::Tags::MortarDataTag +/// * Particles::MonteCarlo::Tags::McGhostZoneDataTag /// /// - Removes: nothing /// - Modifies: nothing @@ -67,7 +69,8 @@ struct InitializeMCTags { NeutrinoSpecies>, Particles::MonteCarlo::Tags::CellLightCrossingTime, hydro_variables_tag, - Particles::MonteCarlo::Tags::MortarDataTag>; + Particles::MonteCarlo::Tags::MortarDataTag, + Particles::MonteCarlo::Tags::McGhostZoneDataTag>; using compute_tags = tmpl::list<>; @@ -142,6 +145,13 @@ struct InitializeMCTags { tmpl::list>>( make_not_null(&box), std::move(mortar_data)); + using GhostZoneData = + typename Particles::MonteCarlo::Tags::McGhostZoneDataTag::type; + GhostZoneData ghost_zone_data{}; + Initialization::mutate_assign< + tmpl::list>>( + make_not_null(&box), std::move(ghost_zone_data)); + return {Parallel::AlgorithmExecution::Continue, std::nullopt}; } }; diff --git a/src/Evolution/Particles/MonteCarlo/Actions/TimeStepActions.hpp b/src/Evolution/Particles/MonteCarlo/Actions/TimeStepActions.hpp index 7d60ecb6dff77..42bf52adaad26 100644 --- a/src/Evolution/Particles/MonteCarlo/Actions/TimeStepActions.hpp +++ b/src/Evolution/Particles/MonteCarlo/Actions/TimeStepActions.hpp @@ -118,8 +118,8 @@ struct TimeStepMutator { const size_t num_ghost_zones = 1; // Get information stored in various databox containers in // the format expected by take_time_step_on_element - const double start_time = 0.0; // current_step_id.step_time().value(); - const double end_time = 0.1; // next_step_id.step_time().value(); + const double start_time = current_step_id.step_time().value(); + const double end_time = next_step_id.step_time().value(); Scalar det_jacobian_logical_to_inertial(lapse); get(det_jacobian_logical_to_inertial) = 1.0 / get(det_inverse_jacobian_logical_to_inertial); diff --git a/src/Evolution/Particles/MonteCarlo/GhostZoneCommunication.hpp b/src/Evolution/Particles/MonteCarlo/GhostZoneCommunication.hpp index 2f9422a5848a7..d11ba5cedcc30 100644 --- a/src/Evolution/Particles/MonteCarlo/GhostZoneCommunication.hpp +++ b/src/Evolution/Particles/MonteCarlo/GhostZoneCommunication.hpp @@ -311,8 +311,8 @@ struct ReceiveDataForMcCommunication { const DataVector& received_data_direction = received_data[directional_element_id] .ghost_zone_hydro_variables; - REQUIRE(received_data[directional_element_id] - .packets_entering_this_element == std::nullopt); + // REQUIRE(received_data[directional_element_id] + // .packets_entering_this_element == std::nullopt); if (mortar_data->rest_mass_density[directional_element_id] == std::nullopt) { continue; @@ -368,8 +368,8 @@ struct ReceiveDataForMcCommunication { received_data[directional_element_id] .packets_entering_this_element; // Temporary: currently no data for coupling to the fluid - REQUIRE(received_data[directional_element_id] - .ghost_zone_hydro_variables.size() == 0); + // REQUIRE(received_data[directional_element_id] + // .ghost_zone_hydro_variables.size() == 0); if (received_data_packets == std::nullopt) { continue; } else {