18.01.2013 Aufrufe

4.6 Vergleichsrechnung mit Hilfe des SST Modells - Lehrstuhl ...

4.6 Vergleichsrechnung mit Hilfe des SST Modells - Lehrstuhl ...

4.6 Vergleichsrechnung mit Hilfe des SST Modells - Lehrstuhl ...

MEHR ANZEIGEN
WENIGER ANZEIGEN

Erfolgreiche ePaper selbst erstellen

Machen Sie aus Ihren PDF Publikationen ein blätterbares Flipbook mit unserer einzigartigen Google optimierten e-Paper Software.

Anhang A<br />

#include "udf.h"<br />

DEFINE_PROFILE(inlet_x_velocity, thread, index){<br />

real p[ND_ND];<br />

real v; //Geschwindigkeit<br />

real vx; //Geschwindigkeit in x<br />

real x; //Koordinate<br />

real y; //Koordinate<br />

real r; //Radius<br />

real alpha; //Winkel<br />

real pi = 3.141592654; //Pi<br />

real n; //Drehzahl<br />

face_t f;<br />

n = 0.025; //Drehzahl<br />

begin_f_loop(f, thread)<br />

{<br />

F_CENTROID(p,f,thread);<br />

x = p[0];<br />

x = x - 823.0; //Verschiebung auf globale Koordinaten<br />

y = p[1];<br />

y = y - 679.674; //Verschiebung auf globale Koordinaten<br />

r = sqrt(x*x+y*y);<br />

v = r*pi*n*2.0;<br />

alpha = asin(y/r);<br />

vx = v*sin(alpha);<br />

F_PROFILE(f, thread, index) = vx;<br />

}<br />

end_f_loop(f, thread)<br />

}<br />

DEFINE_PROFILE(inlet_y_velocity, thread, index)<br />

{<br />

real p[ND_ND];<br />

real v; //Geschwindigkeit<br />

real vy; //Geschwindigkeit in y<br />

real x; //Koordinate<br />

real y; //Koordinate<br />

real r; //Radius<br />

real alpha; //Winkel<br />

real pi = 3.141592654; //Pi<br />

real n; //Drehzahl<br />

face_t f;<br />

n = 0.025; //Drehzahl<br />

begin_f_loop(f, thread)<br />

{<br />

F_CENTROID(p,f,thread);<br />

x = p[0];<br />

x = x - 823.0; //Verschiebung auf globale Koordinaten<br />

y = p[1];<br />

y = y - 679.674;/ //Verschiebung auf globale Koordinaten<br />

r = sqrt(x*x+y*y);<br />

v = r*pi*n*2.0;<br />

alpha = asin(y/r);<br />

vy = v*cos(alpha); if ( x>= 0) {vy = vy * (-1.0);}<br />

F_PROFILE(f, thread, index) = vy;<br />

}<br />

end_f_loop(f, thread) }<br />

91

Hurra! Ihre Datei wurde hochgeladen und ist bereit für die Veröffentlichung.

Erfolgreich gespeichert!

Leider ist etwas schief gelaufen!