import java.text.SimpleDateFormat;
import java.util.Calendar;
import java.util.Locale;
import java.util.TimeZone;


class MyTest {
    
    private static Calendar calendar = Calendar.getInstance(TimeZone.getTimeZone("CET"), Locale.FRANCE);
    private static SimpleDateFormat dateFormat = new SimpleDateFormat("yyyyMMdd");

    public static void main(String[] args) {
        
        // Set to any date.
        calendar.set(2013, 10, 3);
        System.out.println(dateFormat.format(calendar.getTime()));
        
        // Set to another day.
        calendar.set(2014, 0, 15);
        // --- THE WTF STARTS HERE ---
        // Uncommenting the line below returns the correct date in the end.
        //calendar.getTime();
        
        // Set to monday of current week.
        calendar.set(Calendar.DAY_OF_WEEK, calendar.getFirstDayOfWeek());

        // Expected outdate is 20140113.
        System.out.println(dateFormat.format(calendar.getTime()));

    }

}
