# Tidal prediction The tidal prediction is calculted for harmonic coefficient for each tidal constituent as : $ \eta_{tides}(t) = Re\left( \sum^{n=M2, S2...} f_n(t) A_ne^{i\left(\omega_nt + u_n(t) -\phi_n\right)} \right) $ with $A$ the amplitude, $\omega$ the tidal pulsation and $\phi$ the phase lag. $f$ are and $u$ are the amplitude and phase nodal corrections. ## Time series from atlas To predict the tidal signal at specific locations from atlases or [model harmonic analyses](#models-harmonics), use the [predictor](../../tidal-processing/predictor.md) command. Fist you need a locations.dat file with all the wanted loactions: ```bash number of locations lon lat lon lat lon lat ... ``` For example: ```bash 6 -45.309906 2.587339 -45.202062 3.810184 -44.544542 3.466784 -44.422247 2.818729 -44.422247 2.818729 -46.000000 0.500000 ``` Then, compute the prediction: ```bash fes=/ecola/share/data/tides/FES2022/ predictor -p locations.dat \ -s "2021/08/01 00:00:00.000" -f "2025/01/01 00:00:00.000" \ -g $fes/mesh-FES2022.nc \ -a $fes/DOI/WAVE.FES2022.nc \ -v Ha Hg \ -w M2 S2 ``` *TIPS: is doing the interpolation calculation only once for each location so it is better to ask for all the wanted tidal constituent at once.* The predictions will be stored the files "predictions.dat", an ASCII table with one column for each location: 1. Time [days since the begining of prediction] 2. Day [YYYY-MM-DD] 3. Hour [HH:MM:SS] 4. Location 1 5. Location 2 6. ...