function V = VandermondeMatrix3D(N,r,s,t)

% computes Vandermonde matrix (as in Hesthaven book) using provided sets of nodes
% for further computation of mass matrix

N_p = length(r);
V = zeros(N_p);

[a,b,c] = rsttoabc(r,s,t);

col = 1;
for i = 0:N
	for j = 0:(N - i)
		for k = 0:(N - i - j)
			vect = ModalBaseValues3D(a,b,c,i,j,k);
			V(:,col) = vect';
			col = col + 1;
		end
	end
end

end