function [D_drag_tmp] = Diss_drag(x,x_1,C_phi,C_phi_1,dt)

global Invariant ini_Val Material Constraints 

[C,C1,C2,C3] = interpolate(Invariant,x);
[C_1,C1_1,C2_1,C3_1] = interpolate(Invariant,x_1);

[phi, d_phi, dd_phi] = interpolate_func_2(Invariant,C_phi);
[phi_1, d_phi_1, dd_phi_1] = interpolate_func_2(Invariant,C_phi_1);
% v_t=[];
% v_n=[];
Aux = auxiliary_calculations(Invariant,ini_Val.p,Constraints.C0,C,C1,C2,phi,C3);
% x
% v_t = 1/Aux.au .*(C1(:,1).*(C(:,1)-C_1(:,1)) + C1(:,2).*(C(:,2)-C_1(:,2)))/dt;
% 
% v_n = 1/Aux.au .*(-C1(:,2).*(C(:,1)-C_1(:,1)) + C1(:,1).*(C(:,2)-C_1(:,2)))/dt;

Tmp_A = Aux.au.*C(:,1).*Invariant.gweight;
Tmp_A=(phi-phi_1)/dt.*Tmp_A;
w_t = zeros(size(phi));

for i=1:length(phi)-1
    Tmp_B = (1:i);
    w_t(i) = -sum(Tmp_A(Tmp_B))/C(i,1)/phi(i);
end
D_drag_tmp = sum(pi*Material.eta_a0.*phi.*w_t.^2.*Aux.au.*C(:,1).*Invariant.gweight);