mirror of
https://github.com/ParticulateFlow/CFDEMcoupling-PFM.git
synced 2025-12-08 06:37:44 +00:00
Consists of a comparison of the angular velocity damping when the two- way coupling is considered.
34 lines
789 B
Matlab
34 lines
789 B
Matlab
clear all;
|
|
clc;
|
|
|
|
%% Script to plot the angular velocities and the particle positions
|
|
|
|
A = importdata('DEM/angular_velocity_no_coupling.txt',' ',1);
|
|
B = importdata('DEM/position_no_coupling.txt',' ',1);
|
|
C = importdata('DEM/angular_velocity.txt',' ',1);
|
|
D = importdata('DEM/position.txt',' ',1);
|
|
|
|
pos1 = B.data();
|
|
omega1 = A.data();
|
|
pos2 = D.data();
|
|
omega2 = C.data();
|
|
|
|
time = omega1(:,1);
|
|
omegax1 = omega1(:,2);
|
|
omegay1 = omega1(:,3);
|
|
omegaz1 = omega1(:,4);
|
|
|
|
time2 = omega2(:,1);
|
|
omegax2 = omega2(:,2);
|
|
omegay2 = omega2(:,3);
|
|
omegaz2 = omega2(:,4);
|
|
|
|
figure
|
|
plot(time,omegaz1,'-.-',time2,omegaz2,'Linewidth',1.5)
|
|
xlabel('Time (s)')
|
|
ylabel('Angular velocity (1/s)')
|
|
legend('One-way coupling','Two-way coupling')
|
|
axis([0 0.5 0 11])
|
|
set(gca,'FontSize',12)
|
|
print('angular_velocity_compare.eps')
|