matlab equation to latex
조회 수: 10 (최근 30일)
이전 댓글 표시
Hello,
I am trying to convert a matlab equation to latex using a script like:
chr = latex(x^2 + 1/x)
The output is :'\frac{1}{x}+x^2'
Are there anyway to include '\displaystyle' before \frac
댓글 수: 2
Nyemwerererai Matshaka
2023년 5월 10일
편집: Nyemwerererai Matshaka
2023년 5월 10일
can I have the code for conversion?
Walter Roberson
2023년 5월 10일
What are the rules about where the \displaystyle should be put in?
regexprep(chr, '\\frac', '\\displaystyle\\frac')
채택된 답변
Walter Roberson
2023년 4월 25일
The latex function does not have any option to add that in automatically, so you would need to use text manipulation to add it in.
댓글 수: 0
추가 답변 (0개)
참고 항목
카테고리
Help Center 및 File Exchange에서 Filter Design에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!