Wenn ich richtig verstehe, sollte das ungefähr das machen, was du möchtest:
Delphi-Quellcode:
function pseudoKW(date: TDateTime): integer;
begin
result = weekOf(date);
if (result > 51) and (monthOf(date) = 1) then
result = 0
else if (result = 1) and (monthOf(date) = 12) then
result = weekOf(incWeek(date, -1)) + 1;
end;