Get Y value based on X from Curve

Dear Experts,
do you have any information how get Y value based on X value from curve?
i.e. (see photo):
Input: X=3.5
Curve

output Y= 2.xxx

Without knowing the formula for the curve or how it was created, the quick and dirty way would be to just create vertical lines at the X value and intersect with the curve for the point.