#include "ChronoReading.h"
#include "ChronoProfile.h"


// Constructor implementation
ChronoReading::ChronoReading(){}
ChronoReading::ChronoReading(int fps, ChronoProfile profile) {
   _fps=fps;
   _profile=profile;
}
ChronoProfile ChronoReading::getProfile(){return _profile;}
int ChronoReading::getFPS(){
   return _fps;
}
int ChronoReading::getFPE(){
   float weight=_profile.getProjectileProfile().getWeight();
   return (int)round(_calculateFPE(_fps, weight));
}
float ChronoReading::_calculateFPE(float fps, float weight){
    //weight in grains
    return (fps*fps*weight) / 450240;
}