LaTeX \vec command

56
18
Can anyone help? What is the convention for inserting the vector symbol?
I have a draft with -(\vec{2.5})^2 which displays correctly in preview
##-(\vec{2.5})^2\\##
why is vec troublesome and underlined in red?? Should I ignore!
I realise that I'm not using a variable.
 
32,735
4,467
Can anyone help? What is the convention for inserting the vector symbol?
I have a draft with -(\vec{2.5})^2 which displays correctly in preview
##-(\vec{2.5})^2\\##
why is vec troublesome and underlined in red?? Should I ignore!
I realise that I'm not using a variable.
What you have is how this command is used. I don't see any red underlining.

##\vec x## - Raw script \vec x
##\vec {x_1}## - Raw script \vec{x_1}
The braces, { }, used in the 2nd example are not required in this and most other commands when what follows the command is a single character. If there are two or more characters, you have to use braces to indicate what is included.

Before anyone else jumps in to comment about 2.5 not being a vector, this post is about LaTeX use, not vectors per se.
 
56
18
Thanks for the full description, Mark44
 

FactChecker

Science Advisor
Gold Member
2018 Award
5,088
1,792
The red underlining is probably the spellchecker doing that in the editor. Those are not very sophisticated when it comes to anything that is not a word of the English language.
 

Want to reply to this thread?

"\vec command" You must log in or register to reply here.

Related Threads for: \vec command

Replies
5
Views
2K
Replies
9
Views
3K
Replies
2
Views
2K
  • Posted
Replies
4
Views
2K
Replies
2
Views
15K
Replies
4
Views
903
Replies
4
Views
13K

Physics Forums Values

We Value Quality
• Topics based on mainstream science
• Proper English grammar and spelling
We Value Civility
• Positive and compassionate attitudes
• Patience while debating
We Value Productivity
• Disciplined to remain on-topic
• Recognition of own weaknesses
• Solo and co-op problem solving
Top