필터 지우기
필터 지우기

How to solve incosistent scientific format ?

조회 수: 1 (최근 30일)
Arif
Arif 2024년 3월 8일
이동: Stephen23 2024년 3월 11일
Hi guys, im facing trouble when i use 'strcmp'. I was trying to get a data from variable "Stepnum" when its "R3Plastic" is 3,673E-06. But i only have string "3,673e-06" which is automatic created in previous calculation.
how to fix the text-formatting scientific, want to make it fix only using "E"
  댓글 수: 1
Stephen23
Stephen23 2024년 3월 8일
이동: Stephen23 2024년 3월 11일
Do not convert to text and compare text.
Compare the numeric values. Best of all by comparing the absolute difference against a tolerance:
abs(A-B)<tol

댓글을 달려면 로그인하십시오.

채택된 답변

Walter Roberson
Walter Roberson 2024년 3월 8일
  댓글 수: 1
Arif
Arif 2024년 3월 11일
hey thank you so much. u solved my problem. But what is the difference ?

댓글을 달려면 로그인하십시오.

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Characters and Strings에 대해 자세히 알아보기

제품

Community Treasure Hunt

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

Start Hunting!

Translated by