26#include <unordered_map>
80 std::unordered_map<SimId, CwPhaseNoiseBuffer>
buffers;
126 return "Range error in radar equation calculations";
175 RealType timeK,
const CwPhaseNoiseLookup* phase_noise_lookup =
nullptr);
218 const CwPhaseNoiseLookup* phase_noise_lookup =
nullptr);
234 RealType timeK,
const CwPhaseNoiseLookup* phase_noise_lookup =
nullptr,
The World class manages the simulator environment.
Class representing a radar signal with associated properties.
Manages radar signal reception and response processing.
Base class for radar targets.
Represents a radar transmitter system.
Exception thrown when a range calculation fails, typically due to objects being too close.
const char * what() const noexcept override
Provides the error message for the exception.
Represents a timing source for simulation.
Global configuration file for the project.
double RealType
Type for real numbers.
std::complex< RealType > ComplexType
Type for complex numbers.
Classes and operations for 3D geometry.
ComplexType calculateStreamingDirectPathContribution(const core::ActiveStreamingSource &source, const Receiver *recv, const RealType timeK, const CwPhaseNoiseLookup *const phase_noise_lookup, core::FmcwChirpBoundaryTracker *const chirp_tracker, const StreamingTimingPhaseMode timing_phase_mode)
Calculates a direct-path contribution from a cached streaming source.
LinkType
Categorizes the visual link for rendering.
@ DirectTxRx
Interference path.
@ Monostatic
Combined Tx/Rx path.
@ BistaticTgtRx
Scattered path.
@ BistaticTxTgt
Illuminator path.
ComplexType calculateReflectedPathContribution(const Transmitter *trans, const Receiver *recv, const Target *targ, const RealType timeK, const CwPhaseNoiseLookup *const phase_noise_lookup)
Calculates the complex envelope contribution for a reflected path (Tx -> Tgt -> Rx) at a specific tim...
LinkQuality
Describes the radiometric quality of the link.
@ Weak
SNR < 0 dB (Geometric line of sight, but below noise floor)
void solveReDirect(const Transmitter *trans, const Receiver *recv, const std::chrono::duration< RealType > &time, const RadarSignal *wave, ReResults &results)
Solves the radar equation for a direct path (Tx -> Rx).
bool calculateStreamingReferencePhase(const core::ActiveStreamingSource &source, const RealType timeK, core::FmcwChirpBoundaryTracker *const chirp_tracker, RealType &phase_out)
Evaluates a receive-time streaming waveform phase for receiver LO/dechirp references.
StreamingTimingPhaseMode
Selects how timing phase noise is applied to streaming channel contributions.
@ TransmitterOnly
Incoming RF/baseband signal before receiver LO subtraction.
@ None
Ignore timing phase noise entirely.
@ ReceiverRelative
Existing raw streaming convention: transmitter phase minus receiver LO phase.
void solveRe(const Transmitter *trans, const Receiver *recv, const Target *targ, const std::chrono::duration< RealType > &time, const RadarSignal *wave, ReResults &results)
Solves the bistatic radar equation for a reflected path (Tx -> Tgt -> Rx).
ComplexType calculateStreamingReflectedPathContribution(const core::ActiveStreamingSource &source, const Receiver *recv, const Target *targ, const RealType timeK, const CwPhaseNoiseLookup *const phase_noise_lookup, core::FmcwChirpBoundaryTracker *const chirp_tracker, const StreamingTimingPhaseMode timing_phase_mode)
Calculates a reflected-path contribution from a cached streaming source.
ComplexType calculateDirectPathContribution(const Transmitter *trans, const Receiver *recv, const RealType timeK, const CwPhaseNoiseLookup *const phase_noise_lookup)
Calculates the complex envelope contribution for a direct propagation path (Tx -> Rx) at a specific t...
std::vector< PreviewLink > calculatePreviewLinks(const core::World &world, const RealType time)
Calculates all visual links for the current world state at a specific time.
std::unique_ptr< serial::Response > calculateResponse(const Transmitter *trans, const Receiver *recv, const RadarSignal *signal, const RealType startTime, const Target *targ)
Creates a Response object by simulating a signal's interaction over its duration.
uint64_t SimId
64-bit Unique Simulation ID.
Defines the global state for the event-driven simulation engine.
Cached description of an active streaming transmitter segment.
Tracks the current FMCW chirp boundary for a streaming path.
Sampled phase-noise buffer for one timing source.
RealType start_time
First sample time in seconds.
RealType sampleAt(RealType time) const noexcept
Returns the interpolated phase-noise sample at the specified time.
std::vector< RealType > samples
Phase-noise samples in radians.
RealType dt
Time spacing between phase-noise samples in seconds.
Lookup table for CW phase noise across timing sources.
static CwPhaseNoiseLookup build(std::span< const std::shared_ptr< timing::Timing > > timings, RealType start_time, RealType end_time)
Builds a phase-noise lookup for the requested timing sources and time range.
RealType dt
Lookup sample spacing in seconds.
RealType end_time
Lookup end time in seconds.
std::unordered_map< SimId, CwPhaseNoiseBuffer > buffers
Per-timing-source phase-noise buffers.
RealType start_time
Lookup start time in seconds.
RealType sample(const timing::Timing *timing, RealType time) const noexcept
Samples phase noise for one timing source at the specified time.
RealType phaseDifference(const timing::Timing *rx_timing, RealType rx_time, const timing::Timing *tx_timing, RealType tx_time) const noexcept
Computes receiver-minus-transmitter phase noise at two propagation times.
A calculated link segment for 3D visualization.
double rcs
RCS in square meters, or -1.0 when not applicable.
LinkType type
Visual link category.
double display_value
Numeric value represented by label, in the label's unit.
SimId source_id
SimId at the start of this specific link segment.
SimId dest_id
SimId at the end of this specific link segment.
LinkQuality quality
Radiometric link quality.
double actual_power_dbm
Received power in dBm with actual RCS, or sentinel when unavailable.
std::string label
Human-readable label for display.
SimId origin_id
Original transmitted-energy source SimId.
Stores the intermediate results of a radar equation calculation for a single time point.
RealType delay
Signal propagation delay in seconds.
RealType power
Power scaling factor (dimensionless, relative to transmitted power).
RealType phase
Phase shift in radians due to propagation delay.