Размер видео: 1280 X 720853 X 480640 X 360
Показать панель управления
Автовоспроизведение
Автоповтор
0:19 - Inputs and outputs1:38 - Structs3:15 - Swap function4:00 - Check sqrt price limit6:10 - Swap state7:45 - Update sqrt price and tick9:20 - Update liquidity9:50 - Update fee growth global10:40 - Calculate final amount 0 and amount 113:42 - Transfer tokensCodegithub.com/t4sk/clammTake a coursewww.smartcontract.engineer/
great explanation , thanks
How can squareroot price change without changing tick?
ticks increment by tick spacingfor example if tick spacing is 10, during a swap the active tick would move but the change may be less than tick spacing
@@smartcontractprogrammer Thanks for reply.I wonder why the tick spacing is being used? What is the purpose of introducting tick spacing.
@@Rollex-rr2xq I think it's mostly for liquidity providers. It allows them to set a range for active liquidity.
0:19 - Inputs and outputs
1:38 - Structs
3:15 - Swap function
4:00 - Check sqrt price limit
6:10 - Swap state
7:45 - Update sqrt price and tick
9:20 - Update liquidity
9:50 - Update fee growth global
10:40 - Calculate final amount 0 and amount 1
13:42 - Transfer tokens
Code
github.com/t4sk/clamm
Take a course
www.smartcontract.engineer/
great explanation , thanks
How can squareroot price change without changing tick?
ticks increment by tick spacing
for example if tick spacing is 10, during a swap the active tick would move but the change may be less than tick spacing
@@smartcontractprogrammer
Thanks for reply.
I wonder why the tick spacing is being used? What is the purpose of introducting tick spacing.
@@Rollex-rr2xq I think it's mostly for liquidity providers. It allows them to set a range for active liquidity.