Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.
it is easier to write a function of your own like this:
Since cos is a built-in function that you cannot change its source code, another way may be to name the function above as cos and put it in your "work" folder, generally the m file with the same name in the work folder will be called first.