Code_TYMPAN
4.2.0
Industrial site acoustic simulation
|
Acoustic path. More...
#include <acoustic_path.h>
Public Member Functions | |
acoustic_path () | |
Default constructor. More... | |
virtual | ~acoustic_path () |
Destructor. More... | |
acoustic_path (unsigned int source_idx, unsigned int receptor_idx, tab_acoustic_events &_events) | |
Build the acoustic path with a source id, a receptor id and a list of acoustic events positions (reflection, diffraction, etc...) More... | |
acoustic_path (const acoustic_path &ray) | |
Copy constructor of a acoustic path. More... | |
virtual void | cleanEventsTab () |
clean tab of events More... | |
virtual acoustic_path & | operator= (const acoustic_path &other) |
equal operator More... | |
virtual bool | deepCopy (acoustic_path *pOther) |
Deep copy of a ray mainly the events tab. More... | |
virtual void | tyRayCorrection (IGeometryModifier *transformer) |
Curve acoustic_path with respect to meteo influence This is only for watching curved rays on screen. More... | |
virtual void | setSource (unsigned int source_idx_, OPoint3D &globalPosition) |
Set the ray source. More... | |
virtual void | setSource (unsigned int source_idx_) |
Set the ray source. More... | |
virtual unsigned int | getSource_idx () |
Get the source id. More... | |
virtual void | setRecepteur (unsigned int receptor_idx_, OPoint3D &globalPosition) |
Set the ray receptor. The last polyline point is updated. More... | |
virtual void | setRecepteur (unsigned int receptor_idx_) |
Set the ray receptor. More... | |
virtual unsigned int | getRecepteur_idx () |
Get the receptor id. More... | |
virtual void | setIdentifiant (unsigned int id) |
Set the ray id. More... | |
virtual unsigned int | getIdentifiant () const |
Get the ray id. More... | |
virtual void | addEvent (acoustic_event *TYEvent) |
Add an event to the events list of the ray. More... | |
virtual tab_acoustic_events & | getEvents () |
Get the events list of the ray. More... | |
virtual const tab_acoustic_events & | getEvents () const |
virtual void | setEvents (tab_acoustic_events &tabEvents) |
Set the events list of the ray. More... | |
virtual std::vector< int > | getIndexOfEvents (const int &eventType) const |
return a tab of indexes of events of the same type in a ray you can merge two types of events (example TYREFLEXION | TYRECEPTEUR) vector returned count all events of the two types More... | |
virtual unsigned int | getNbEventType (const ACOUSTIC_EVENT_TYPES &eventType) |
return the number of events of a type More... | |
virtual void | copyEvents (const acoustic_path *tyRay, ACOUSTIC_EVENT_TYPES eventType) |
copy only events matching eventType to _events tab More... | |
virtual void | setNextDistance (ACOUSTIC_EVENT_TYPES eventType) |
Compute distance between events of the type "eventType" and set distNextEvent to each event matching enventType. More... | |
virtual void | setAngles (ACOUSTIC_EVENT_TYPES eventType) |
Compute angles of incoming ray segment at event point. More... | |
virtual double | getLength () |
Return total length of the ray taking account of all events. More... | |
virtual int | getnbEvents () |
Return the number of events of the ray. More... | |
virtual void | setPosSourceGlobal (const OPoint3D &pos) |
Set the source position in the global frame. More... | |
virtual OPoint3D & | getPosSourceGlobal () |
Get the source position in the global frame. More... | |
virtual void | setPosReceptGlobal (const OPoint3D &pos) |
Set the receptor position in the global frame. More... | |
virtual OPoint3D & | getPosReceptGlobal () |
Get the receptor position in the global frame. More... | |
virtual void | overSample (IGeometryModifier *transformer, const double &dMin) |
Add events to ray. More... | |
virtual void | sampleAndCorrection (IGeometryModifier *transformer) |
Computes angle and length correction \ by calling the three previous functions \ Creates two matrix which have corrected lengths and angles. More... | |
virtual void | endLenghtCompute (IGeometryModifier *transformer) |
compute the length between an event and the next pertinent event (i.e. between a diffraction and the next reflection or receptor) More... | |
virtual void | angleCompute (IGeometryModifier *transformer) |
compute the angle between incident ray and the face More... | |
virtual void | nextLenghtCompute (IGeometryModifier *transformer) |
compute the length between an event and the next event More... | |
virtual void | prevNextLengthCompute (IGeometryModifier *transformer) |
Computes the length between event-1 and event+1. More... | |
virtual void | eventPosCompute (IGeometryModifier *transformer) |
compute the length between an event and the next event More... | |
virtual double | lengthCorrection (acoustic_event *ev1, const acoustic_event *ev2, IGeometryModifier *transformer) |
Computes length correction on path \ Works on over-sampled TYRays \ Creates a vector which has all corrected path lengths. More... | |
virtual double | angleCorrection (const acoustic_event *ev1, acoustic_event *ev2, const acoustic_event *ev3, IGeometryModifier *transformer) |
Computes angle correction on path ev1 -> previous event ev2 -> event to which compute angle ev3 -> next event. More... | |
void | build_links_between_events () |
TYRayEvent has to know is direct neighbourg (before and after him) More... | |
void | compute_shot_angle () |
Compute shot angle from source. More... | |
Static Public Member Functions | |
static void | set_sampler_step (double sampler_step_) |
Set the sampler step. More... | |
Protected Attributes | |
unsigned int | _identifiant |
Ray id. More... | |
unsigned int | source_idx |
Source id. More... | |
unsigned int | receptor_idx |
Receptor id. More... | |
OPoint3D | _posSourceGlobal |
Source position in the global frame. More... | |
OPoint3D | _posReceptGlobal |
Receptor position in the global frame. More... | |
tab_acoustic_events | _events |
Events vector containing the events list (and their positions) of the associated ray. More... | |
Static Protected Attributes | |
static double | sampler_step = 20.0 |
max size of step between events after spatial sampling More... | |
Acoustic path.
Definition at line 75 of file acoustic_path.h.
acoustic_path::acoustic_path | ( | ) |
Default constructor.
Definition at line 87 of file acoustic_path.cpp.
|
virtual |
Destructor.
Definition at line 96 of file acoustic_path.cpp.
acoustic_path::acoustic_path | ( | unsigned int | source_idx, |
unsigned int | receptor_idx, | ||
tab_acoustic_events & | _events | ||
) |
Build the acoustic path with a source id, a receptor id and a list of acoustic events positions (reflection, diffraction, etc...)
acoustic_path::acoustic_path | ( | const acoustic_path & | ray | ) |
Copy constructor of a acoustic path.
Definition at line 91 of file acoustic_path.cpp.
|
inlinevirtual |
Add an event to the events list of the ray.
Definition at line 175 of file acoustic_path.h.
|
virtual |
compute the angle between incident ray and the face
Definition at line 390 of file acoustic_path.cpp.
|
virtual |
Computes angle correction on path ev1 -> previous event ev2 -> event to which compute angle ev3 -> next event.
Definition at line 408 of file acoustic_path.cpp.
void acoustic_path::build_links_between_events | ( | ) |
TYRayEvent has to know is direct neighbourg (before and after him)
It also has to know his the next REFLEXION event or (if not exist) the RECEPTOR
Definition at line 277 of file acoustic_path.cpp.
|
virtual |
clean tab of events
Definition at line 101 of file acoustic_path.cpp.
void acoustic_path::compute_shot_angle | ( | ) |
Compute shot angle from source.
Definition at line 295 of file acoustic_path.cpp.
|
virtual |
copy only events matching eventType to _events tab
Definition at line 188 of file acoustic_path.cpp.
|
virtual |
Deep copy of a ray mainly the events tab.
Definition at line 131 of file acoustic_path.cpp.
|
virtual |
compute the length between an event and the next pertinent event (i.e. between a diffraction and the next reflection or receptor)
Definition at line 372 of file acoustic_path.cpp.
|
virtual |
compute the length between an event and the next event
Definition at line 399 of file acoustic_path.cpp.
|
inlinevirtual |
Get the events list of the ray.
Definition at line 181 of file acoustic_path.h.
|
inlinevirtual |
Definition at line 182 of file acoustic_path.h.
|
inlinevirtual |
Get the ray id.
Definition at line 169 of file acoustic_path.h.
|
virtual |
return a tab of indexes of events of the same type in a ray you can merge two types of events (example TYREFLEXION | TYRECEPTEUR) vector returned count all events of the two types
Definition at line 174 of file acoustic_path.cpp.
|
virtual |
Return total length of the ray taking account of all events.
Definition at line 163 of file acoustic_path.cpp.
|
inlinevirtual |
Return the number of events of the ray.
Definition at line 235 of file acoustic_path.h.
|
inlinevirtual |
return the number of events of a type
Definition at line 203 of file acoustic_path.h.
|
inlinevirtual |
Get the receptor position in the global frame.
Definition at line 259 of file acoustic_path.h.
|
inlinevirtual |
Get the source position in the global frame.
Definition at line 247 of file acoustic_path.h.
|
inlinevirtual |
Get the receptor id.
Definition at line 157 of file acoustic_path.h.
|
inlinevirtual |
Get the source id.
Definition at line 138 of file acoustic_path.h.
|
virtual |
Computes length correction on path \ Works on over-sampled TYRays \ Creates a vector which has all corrected path lengths.
Definition at line 351 of file acoustic_path.cpp.
|
virtual |
compute the length between an event and the next event
Definition at line 342 of file acoustic_path.cpp.
|
virtual |
equal operator
Definition at line 115 of file acoustic_path.cpp.
|
virtual |
Add events to ray.
Definition at line 239 of file acoustic_path.cpp.
|
virtual |
Computes the length between event-1 and event+1.
Definition at line 381 of file acoustic_path.cpp.
|
virtual |
Computes angle and length correction \ by calling the three previous functions \ Creates two matrix which have corrected lengths and angles.
Definition at line 324 of file acoustic_path.cpp.
|
inlinestatic |
Set the sampler step.
Definition at line 323 of file acoustic_path.h.
|
virtual |
Compute angles of incoming ray segment at event point.
Definition at line 225 of file acoustic_path.cpp.
|
inlinevirtual |
Set the events list of the ray.
Definition at line 189 of file acoustic_path.h.
|
inlinevirtual |
Set the ray id.
Definition at line 163 of file acoustic_path.h.
|
virtual |
Compute distance between events of the type "eventType" and set distNextEvent to each event matching enventType.
Definition at line 204 of file acoustic_path.cpp.
|
inlinevirtual |
Set the receptor position in the global frame.
Definition at line 253 of file acoustic_path.h.
|
inlinevirtual |
Set the source position in the global frame.
Definition at line 241 of file acoustic_path.h.
|
virtual |
Set the ray receptor. The last polyline point is updated.
Definition at line 157 of file acoustic_path.cpp.
|
inlinevirtual |
Set the ray receptor.
Definition at line 150 of file acoustic_path.h.
|
virtual |
Set the ray source.
Definition at line 151 of file acoustic_path.cpp.
|
inlinevirtual |
Set the ray source.
Definition at line 131 of file acoustic_path.h.
|
virtual |
Curve acoustic_path with respect to meteo influence This is only for watching curved rays on screen.
Definition at line 430 of file acoustic_path.cpp.
|
protected |
Events vector containing the events list (and their positions) of the associated ray.
Definition at line 346 of file acoustic_path.h.
|
protected |
Ray id.
Definition at line 340 of file acoustic_path.h.
|
protected |
Receptor position in the global frame.
Definition at line 344 of file acoustic_path.h.
|
protected |
Source position in the global frame.
Definition at line 343 of file acoustic_path.h.
|
protected |
Receptor id.
Definition at line 342 of file acoustic_path.h.
|
staticprotected |
max size of step between events after spatial sampling
Definition at line 339 of file acoustic_path.h.
|
protected |
Source id.
Definition at line 341 of file acoustic_path.h.