Hence the 3-dimensional chart for determining adjective ending -- it depends on gender, case, and the word preceding it (i.e., definite article, indefinite, or nothing). Although I found a chart on this page that "reduces" it to a four-branch flow chart: