stable disk-like model.
This commit is contained in:
@@ -254,6 +254,8 @@ simple_uniform_core(AcMesh* mesh)
|
||||
//TEMPORARY TEST INPUT PARAMETERS
|
||||
const double core_radius = DX*32.0;
|
||||
const double trans = DX*12.0;
|
||||
const double vel_scale = mesh->info.real_params[AC_ampl_uu];
|
||||
double abso_vel;
|
||||
|
||||
RR = 1.0;
|
||||
printf("%e %e %e \n", RR, trans, core_radius);
|
||||
@@ -274,12 +276,19 @@ simple_uniform_core(AcMesh* mesh)
|
||||
//tanhRR = double(-0.5)*tanh((core_radius-RR)/trans) + double(0.5)
|
||||
// + double(0.1);
|
||||
tanhRR = double(1.0);
|
||||
|
||||
if (RR >= mesh->info.real_params[AC_soft]) {
|
||||
|
||||
abso_vel = c * sqrt(2.0 * mesh->info.real_params[AC_G_const] * mesh->info.real_params[AC_M_sink_init] / RR);
|
||||
abso_vel = vel_scale * sqrt(2.0 * mesh->info.real_params[AC_G_const] * mesh->info.real_params[AC_M_sink_init] / RR);
|
||||
} else {
|
||||
abso_vel = 0.0;
|
||||
RR = 1.0;
|
||||
}
|
||||
|
||||
|
||||
mesh->vertex_buffer[VTXBUF_LNRHO][idx] = log(exp(ampl_lnrho)*tanhRR);
|
||||
mesh->vertex_buffer[VTXBUF_UUX][idx] = double(0.0);
|
||||
mesh->vertex_buffer[VTXBUF_UUY][idx] = double(0.0);
|
||||
mesh->vertex_buffer[VTXBUF_UUX][idx] = -abso_vel * (yy / RR);
|
||||
mesh->vertex_buffer[VTXBUF_UUY][idx] = abso_vel * (xx / RR);
|
||||
mesh->vertex_buffer[VTXBUF_UUZ][idx] = double(0.0);
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user