Main Lemma Repository
Ви не можете вибрати більше 25 тем Теми мають розпочинатися з літери або цифри, можуть містити дефіси (-) і не повинні перевищувати 35 символів.

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485
  1. namespace Lemma{
  2. /**
  3. \page Tutorial
  4. A basic tutorial outlining the goals of Lemma, how to acquire and use it, and how to extend it
  5. for your own purposes.
  6. - \subpage Intro - Introduction to the project
  7. - \subpage Compiling - how to compile the library
  8. - \subpage Memory - our implementation of garbage collection, and what it means to you
  9. - \subpage Minimal - compiling your first minimal Lemma application
  10. - \subpage EmSources - Electromagnetic sources
  11. \page Intro
  12. <div class="lemmamainmenu">
  13. \b Intro
  14. | \ref Compiling "Compiling"
  15. | \ref Memory "Memory management"
  16. | \ref Minimal "Minimal programme"
  17. | \ref EmSources "EM Sources"
  18. </div>
  19. Some basic information about Lemma to get you started. If you are familiar with
  20. C++ and API's you can skip this page.
  21. \section C Why C++?
  22. We get this a lot as most EM software seems to be written in fortran or Matlab. We
  23. begin by discussing why we didn't choose certain languages/platforms.
  24. \subsection Fortran Why not fortran?
  25. We have lots of reasons for choosing C++ over fortran, some of them better than others.
  26. - We know it better, and we like it better. Too many hours debugging old
  27. FORTRAN subroutines has left us jaded.
  28. - Easy integration with existing libraries. For example Lemma has built in
  29. support for VTK, an extremely powerful visualization package. We also include
  30. MATLAB file IO readers and an XML parser. Providing fortran wrappers for all
  31. of this would be a huge undertaking.
  32. - Flexibility. Lemma is NOT a program, its an API that lets you build
  33. applications that fit your needs. This approach is a natural fit for object oriented
  34. programming and C++ is a much more natural choice for an OO project.
  35. - Infinitely better interface. We leverage the Eigen
  36. <http://eigen.tuxfamily.org> linear algebra package
  37. to deliver expressive, fast code. Their benchmarks are right in line with
  38. fast BLAS and LAPACK implimentations. If you honestly feel that
  39. \code
  40. DGEMM ( TRANSA, TRANSB, M, N, K, ALPHA, A, LDA, B, LDB, BETA, C, LDC )
  41. \endcode
  42. is superior to
  43. \code
  44. C = A*B.transpose();
  45. \endcode
  46. you are living in denial. Check the benchmarks if you are still skeptical.
  47. - We know fortran 2003 has come a long way, but hey, so has C++. Give it a
  48. chance.
  49. \subsection Matlab Ok, so why not MATLAB?
  50. First its closed source, second most large MATLAB programs suffer severe
  51. performance issues. Third, support for object-oriented programming is a joke.
  52. Finally, its also expensive and we don't think the graphics are all
  53. that great.
  54. \subsection Python How about Python?
  55. We like Python. While large 100% native Python applications are often very slow, it is easy to wrap fast C++ and Fortran routines around a Python interface.
  56. We actually plan on doing this in the future, and it is likely that at some
  57. point this may be the most common way to use Lemma. Lots of great visualization
  58. solutions exist in Python (including VTK) and it is a great programming environment. The hard
  59. part is that Eigen relies heavily on Expression templates that cannot be
  60. trivially wrapped into a python interface. So any python interface would have
  61. to be carefully constructed. We would welcome help in this department.
  62. In the mean-time our API is elegant and easy to use.
  63. \section API An API? What's that?
  64. Lemma is not a program. It's an API, or an Application Programming Interface.
  65. This offers a lot of advantages over traditional programs.
  66. - First, its flexible. Its easy to put together components to do exactly what
  67. you want and nothing more.
  68. - Second, its extendible. If we have a class that does almost what you want, you
  69. can just extend a class.
  70. - Third, it limits the amount of file IO you might need to do.
  71. - Four, there are lots of other good reasons too. Just give it a try.
  72. */
  73. /** @} */
  74. }