Thank you for asking a question on This is your Bible.
Psalm 51:10 Create in me a clean heart, O God; and renew a right spirit within me.
The problem that David had is that which is common to all men.
Jeremiah 17:9 The heart is deceitful above all things, and desperately wicked: who can know it?
Mark 7:21 For from within, out of the heart of men, proceed evil thoughts, adulteries, fornications, murders,
22 Thefts, covetousness, wickedness, deceit, lasciviousness, an evil eye, blasphemy, pride, foolishness:
The problem cannot be solved by man himself.
Job 14:4 Who can bring a clean thing out of an unclean? not one.
Proverbs 20:9 Who can say, I have made my heart clean, I am pure from my sin?
The solution is found in the word of God.
Psalms 119:9 Wherewithal shall a young man cleanse his way? by taking heed thereto according to thy word.
Psalms 19:7 The law of the LORD is perfect, converting the soul: the testimony of the LORD is sure, making wise the simple. 8 The statutes of the LORD are right, rejoicing the heart: the commandment of the LORD is pure, enlightening the eyes. 9 The fear of the LORD is clean, enduring for ever: the judgments of the LORD are true and righteous altogether. 10 More to be desired are they than gold, yea, than much fine gold: sweeter also than honey and the honeycomb. 11 Moreover by them is thy servant warned: and in keeping of them there is great reward.
For God to create in us a clean heart and a right spirit we need to understand and absorb his word.
John 15:3 Now ye are clean through the word which I have spoken unto you.
Ephesians 5:26 That he might sanctify and cleanse it with the washing of water by the word,
1 Peter 1:22 Seeing ye have purified your souls in obeying the truth through the Spirit unto unfeigned love of the brethren, see that ye love one another with a pure heart fervently:
The object is to prayerfully allow the word of God to effectually work in us.
1 Thessalonians 2:13 For this cause also thank we God without ceasing, because, when ye received the word of God which ye heard of us, ye received it not as the word of men, but as it is in truth, the word of God, which effectually worketh also in you that believe.
This was what David is requesting. We have the same need as David, to be reborn in heart and mind.
1 Peter 1:23 Being born again, not of corruptible seed, but of incorruptible, by the word of God, which liveth and abideth for ever.
Ephesians 4:23 And be renewed in the spirit of your mind;
Romans 12:2 And be not conformed to this world: but be ye transformed by the renewing of your mind, that ye may prove what is that good, and acceptable, and perfect, will of God.
Romans 8:6 For to be carnally minded is death; but to be spiritually minded is life and peace.
God promised a New Covenant to Israel which became available also to the gentiles through Christ.
Jeremiah 31:33 But this shall be the covenant that I will make with the house of Israel; After those days, saith the LORD, I will put my law in their inward parts, and write it in their hearts; and will be their God, and they shall be my people.
34 And they shall teach no more every man his neighbour, and every man his brother, saying, Know the LORD: for they shall all know me, from the least of them unto the greatest of them, saith the LORD: for I will forgive their iniquity, and I will remember their sin no more.
Hebrews 10:16 This is the covenant that I will make with them after those days, saith the Lord, I will put my laws into their hearts, and in their minds will I write them;
17 And their sins and iniquities will I remember no more.
David could not do it alone, he needed God as we do.
Philippians 2:13 For it is God which worketh in you both to will and to do of his good pleasure.
God works through his word to change us.
2 Corinthians 3:3 Forasmuch as ye are manifestly declared to be the epistle of Christ ministered by us, written not with ink, but with the Spirit of the living God; not in tables of stone, but in fleshy tables of the heart.
Romans 8:29 For whom he did foreknow, he also did predestinate to be conformed to the image of his Son, that he might be the firstborn among many brethren.
Through understanding the Bible and taking heed to the word of God wecan have Godcreate within us a clean heart and a right spirit, and have the hope of everlasting life promised through Jesus Christ.
If you want to come to grips with what the Bible really teaches, why not take the free online Bible study course available on our website, www.thisisyourbible.com? This course will give you a background in the major themes of the Bible from Genesis to Revelation. As with everything we offer, there is no cost to you other than your time and effort... You will also have a personal tutor to whom you may pose questions either from the course itself or those questions which come to you as you read the Bible.
I hope this helps.