Group Abstract Group Abstract

Message Boards Message Boards

0
|
3.9K Views
|
1 Reply
|
0 Total Likes
View groups...
Share
Share this post:
GROUPS:

How to create a string including a number in scientific or engineering form

Posted 10 years ago

For example:

u=1.0 10^-8
v="u: "<>u

u = 1.0 10^-8;
v = "u= " <> u;
v

StringJoin::string: String expected at position 2 in u= <>1.*10^-8. >>
"u= " <> 1.*10^-8

This is not what I want I want: u=1.0*10^-8

Thanks

POSTED BY: Kai Hansen
u = 1.0*10^(-8);
v = "u = " <> ToString@TraditionalForm[u];
v

enter image description here

Head[v]
(*String*)
POSTED BY: Nasser M. Abbasi
Reply to this discussion
Community posts can be styled and formatted using the Markdown syntax.
Reply Preview
Attachments
Remove
or Discard