I am working with an angular app, where service are as declared as follows:
App.service(\"myService\", function(){ this.
Just declare it outside the calculation1 function:
calculation1
App.service("myService", function(){ var util = function(){ } this.calculation1 = function(){ //doing something } this.calculation2 = function(){ } }