Used and loved by millions

Since I tried Ludwig back in 2017, I have been constantly using it in both editing and translation. Ever since, I suggest it to my translators at ProSciEditing.

Justyna Jupowicz-Kozak quote

Justyna Jupowicz-Kozak

CEO of Professional Science Editing for Scientists @ prosciediting.com

MitStanfordHarvardAustralian Nationa UniversityNanyangOxford

to replace x with y

Grammar usage guide and real-world examples

USAGE SUMMARY

The phrase "to replace x with y" is correct and can be used in written English.
You can use the phrase when you want to express that something is being exchanged, substituted, or replaced with something else. For example, "We decided to replace the faulty part with a new one."

✓ Grammatically correct

Science

Wiki

Academia

Human-verified similar examples from authoritative sources

Similar Expressions

60 human-written examples

If f y) < f(x) then replace the agent in the population with the improved candidate solution, that is, replace x with y in the population.

For all populations x in the current solution and for all y outside the solution, replace x with y, if the change reduces the error.

So, when you want to replace x and y by some variables, u and v, given by some formulas in terms of x and y.

Replace x with y and vice versa.

In the second equation, replace x with "2 - ½y": 5(2 - ½y) + 3y = 9.

Using relation (37) and by replacing x with x / A 2 relation (30) becomes: y = ∫ 0 x x 2 2 A 2 1 − x 4 4 A 4 dx = ∫ 0 x f x dx (38 where the equation: f x = ∑ i = 0 n b i (39 with coefficients b i of the form: b i = b i − 1 2 i − 1 2 i x 4 4 A 4, b 0 = x 2 2 A 2 (40).

Replacing x with ξ and y with (E[xi ]), we obtain f xi -fbigl(E[xi]bigr)ge kcdotbigl(xi-E[xi]bigr). Taking the expected values on both sides, we have Ebigl[f xi -fbiglfbigl(E[xi]bigr ge kcdotbigl xi-E[xi]bigrigr)=0.

By applying the Fourier transformation F ′ in problem (28 - 29) with respect to x ′ ( x ′ → ξ ′ ), supposing that f = 0, and by replacing x n with y, we get the problem on the half-line A ( ξ ′, − i d d y, q ) v ( y ) = 0, y > 0, (32).

Replacing X with P X), the assumption becomes T∐Y 0|P X).

If we replace x and y in (13) with (2^{n} x) and (2^{n} y), respectively, and divide by (2^{2n}) the resulting inequality, then we have biglVert f_{i} bigl(mu x, y) bigr)- nu bigl(f_{i}(x), f_{i} y) bigr) bigrVert _{mathcal{L}'} leq2^{-2n} psibigl(2^{n}x, 2^{n}ybigr)leq q^{n} psi x, y) (15) for all (x, y inmathcal{L}_{bar{0}} cupmathcal{L}_{bar{1}}), (i inmathbb{Z}_{2}) and (n inmathbb{N}).

Then, by replacing x, y with in Equation 2.5, we obtain the following identities: for any solution g : V1 → V2 of the Equation (2.5), and (2.14).

Show more...

Expert writing Tips

Best practice

When writing instructions or procedures, use "to replace x with y" for clarity. For example, "To update the software, replace the old file with the new version."

Common error

Avoid using incorrect prepositions such as "to replace x by y" or "to replace x for y". The correct form is "to replace x with y".

Antonio Rotolo, PhD - Digital Humanist | Computational Linguist | CEO @Ludwig.guru

Antonio Rotolo, PhD

Digital Humanist | Computational Linguist | CEO @Ludwig.guru

Source & Trust

74%

Authority and reliability

4.5/5

Expert rating

Real-world application tested

Linguistic Context

The phrase "to replace x with y" functions as a verb phrase indicating the action of substituting one entity (x) for another (y). It is used to describe a process of exchange or substitution, as confirmed by Ludwig.

Expression frequency: Uncommon

Frequent in

Science

50%

Wiki

25%

Academia

25%

Less common in

News & Media

0%

Formal & Business

0%

Encyclopedias

0%

Ludwig's WRAP-UP

In summary, the phrase "to replace x with y" is a grammatically sound and commonly used expression for indicating substitution. As confirmed by Ludwig, it serves to instruct, inform, or describe a process where one item is exchanged for another. While it appears most frequently in scientific and technical contexts, its neutral register makes it appropriate for a wide range of writing situations. Remember to use the correct preposition, "with", and consider alternatives like "substitute x for y" for a more formal tone.

FAQs

How do I use "to replace x with y" in a sentence?

Use "to replace x with y" when you want to indicate that you are substituting one item or value (x) for another (y). For example, "I need to "replace the old tires with new ones"."

What's a more formal way to say "to replace x with y"?

A more formal alternative could be "to substitute y for x". For example, instead of "replace the damaged component with a new one" you might say, "substitute a new component for the damaged one".

Is it correct to say "replace x by y" instead of "to replace x with y"?

While "replace x by y" might be understood, it's less common and can sound awkward. "To replace x with y" is generally the preferred and more grammatically accepted form.

What's the difference between "to replace x with y" and "to substitute x for y"?

Both phrases indicate a substitution, but they differ in focus. "To replace x with y" focuses on what's being put in place, while "to substitute x for y" emphasizes what's being removed. They are often interchangeable, but the nuance can subtly shift the meaning.

ChatGPT power + Grammarly precisionChatGPT power + Grammarly precision
ChatGPT + Grammarly

Editing plus AI, all in one place.

Stop switching between tools. Your AI writing partner for everything—polishing proposals, crafting emails, finding the right tone.

Source & Trust

74%

Authority and reliability

4.5/5

Expert rating

Real-world application tested

Most frequent sentences: