フィルターのクリア

I am trying to paste code in the Matlab Editor but the underscores are missing and there are spaces between the characters, how can I fix this?

4 ビュー (過去 30 日間)
When I try to paste code from a pdf document to the matlab editor, for example:
k_water ( v_ind ) = k_water ( v_ind ) + . . .
It comes out like this, with spaces between characters and without recognising the underscore:
k w a t e r ( v ind ) = k w a t e r ( v ind ) + . . .
When I paste from pdf to word, the code looks something like:
k _water ( v _ind ) = k _water ( v _ind ) + . . .
with a space between underscores and letter, while the underscore looks half the horizontal length and appears at different heights. when I then paste from word to matlab, i still get:
k w a t e r ( v ind ) = k w a t e r ( v ind ) + . . .
when I then copy paste from matlab editor to here, it appears like:
k water ( v ind ) = k water ( v ind ) + . . .

回答 (1 件)

Walter Roberson
Walter Roberson 2022 年 4 月 23 日
pdf files do not generally contain text strings. pdf contain commands in a programming language, with the commands drawing the text. The pdf language is not constrained to draw the elements in linear order.
  1 件のコメント
demos serghiou
demos serghiou 2022 年 4 月 23 日
So there is no solution to the problem from what you are saying, if I understood well?

サインインしてコメントする。

カテゴリ

Help Center および File ExchangeGet Started with MATLAB についてさらに検索

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by