The function $f:\mathbb{N} \rightarrow \mathbb{N}$ verifies: $1) f(n+2)-2022 \cdot f(n+1)+2021 \cdot f(n)=0, \forall n \in \mathbb{N};$ $2) f(20^{22})=f(22^{20});$ $3) f(2021)=2022$. Find all possible values of $f(2022)$.
Problem
Source: Moldova TST 2022
Tags: function, algebra, functional equation
01.04.2022 23:46
The only such $f$ is constant $f$, $f(n)=2022$ for all $n$. Let $a_n \triangleq f(n)$, and interpret $(a_n)_{n\ge 1}$ as a sequence with recursion \[ a_{n+2} - 2022 a_{n+1} + 2021 a_n = 0. \]The characteristic equation of this sequence is \[ \lambda^2 - 2022\lambda + 2021 = 0 \iff \lambda \in\{1,2021\}. \]Hence, there exists $u,v$ such that \[ a_n = u\cdot 2021^n + v,\qquad n\ge 1. \]Now, the second condition yields a contradiction unless $u=0$ (note that $20^{22}\ne 22^{20}$ as the LHS is not divisible by 11). Hence, $a_n$ is constant, whose value is 2022 per the third condition. The end.
01.01.2025 00:45
First, I define a new function $g:\mathbb{N} \rightarrow \mathbb{Z}$ $g(n)=f(n)+2022$ Now we obtain $g(n+2)+2021.g(n)=2022.g(n+1)$ , $g(2021)=0$ , $g(22^{20})=g(20^{22})$ Now, we define another function again $g(n+1)-g(n)=T(n)$ Therefore, we have $T(n+1)=2021.T(n)$ it can be easily concluded $T(n)=2021^{n-1}.T(1)$ ==> $g(n+1)=g(n)+2021^{n-1}.T(1)$ Suppose $T(1)$ is not equal to zero $g(2022)=2021^{2020}.T(1)$ Therefore, We clearly conclude that the function is strictly increasing or strictly decreasing from 2022 onwards but we know that $g(22^{20})=g(20^{22})$ Which is a contradiction Hence, we have $T(1)=0$ , $g(n+1)=g(n)$ (the function is constant) Thus, we have $f$ is constant $f(n)=2022$ for all n