Depends on exactly what you mean by secure?
Virus risk..
or, ahem, detection.
You will only be able realistically to download a fully working version of Matlab and all the necessary component files for free by using torrents via hosting sites - therefore avoid Pirate Bay (if indeed, your ISP still allows access), as you are at greater risk of being traced by your ISP and this information may find its way back to the copyright owner.
If you are willing to use torrents, then Demonoid is less well known host than Pirate Bay and as far as I'm aware has yet to appear under the glaring eye of ISP's and the copyright holders - they will probably still be aware of it, though not on the same scale as PB, so the risk of detection by your ISP is definitely lower - at present!
Demonoid is quite secure in terms of virus threats - though only you can make a judgement on this - especially when downloading .exe files. I've just ran a basic search for Matlab and Demonoid has plenty of torrent file entries for Matlab and a number specifically related to Windows versions. Also, you can get good download speeds on Demonoid.
No need to register, just clink on the torrent links. I rate Vuze - If your familiar with torrent clients??
If your not familiar with torrents and peer 2 peer, then have a read round on the internet first, looking for terms such as torrent files, peers, seeds, share ratio, torrent clients and also 'port-forwarding' (thru a router / server - depending on your net connection). Its easy to get up to speed on the basics, especially if you are just looking to download one file only and you may be able to get good download speeds without port forwarding (instructions widely available for most routers).
You will need to download a Torrent client like Vuze - software that allows connection to demonoid - which in turn, provides the connection interface between your pc and pc's of other torrent users. The torrent client will need configuring (again, instructions widely available), unless you want to use the default settings.
Hope this helps