some code for fq