Python
What is yield from? Python Generators
·1134 words·6 mins
Python
Generators
Drops
Have you ever seen the term yield from in some Python code and wondered what it was? In this article we will delve even deeper into generators and understand, with examples, what yield from means and how we can use it to make our code even more efficient.
Infinite Sequences in Python - Impressive Fibonacci
·1024 words·5 mins
Python
Sequences
Drops
Fibonacci
Itertools
Islice
Did you know that you can create an infinite sequence without having memory problems and still consume this sequence in any way you want? Today we will see a specific function of the itertools standard library module, the islice, and see how can it be used to create the Fibonacci infinite sequence in Python.
Python Regular Expressions: Mastering RegEx
·3832 words·18 mins
Python
String
Format
Regex
Drops
Regular expressions (or, shortly, regex) are a language that detects patterns. You express a pattern that will be applied to strings. It is an efficient way to find patterns and extract information from texts. Within this pattern, each symbol represents a type of information. In this article, we will see the main symbols and their meanings with the help of several examples.
A Guide to Python String Format Techniques
·1610 words·8 mins
Python
String
Format
F-Strings
Drops
A significant part of our time is spent dealing with strings, so it is important to know how to present them in the desired way. This is what we will see in this article with several examples.
Polynomial Manipulation with SymPy
·1486 words·7 mins
Python
Sympy
Math
Polynomials
Certainly, one of the most abstract subjects in math classes: polynomials. After all, who has never been confused in a polynomial division, it is x everywhere. In this article, we will see how the SymPy library, for the Python language, helps us to deal with operations involving polynomials.
Plots with SymPy and Matplotlib
·3619 words·17 mins
Python
Sympy
Math
Equations
Matplotlib
Plot
In this article, we will see how to make graphs with SymPy and Matplotlib. Usually when we talk about SymPy we focus on the part related to solving mathematical calculations. But many forget that the library has some basic resources for building graphs, which we will see in this article.
Rational, Logarithm and Exponential Expressions with SymPy - Math with Python
·1135 words·6 mins
Python
Sympy
Math
Equations
In this article, we will see how to work with rational, exponential and logarithmic expressions with the SymPy library in Python.
Generators in Python - Your Code 1000+ Times More Efficient
·1950 words·10 mins
Python
Drops
Performance
Generators
Do you know the difference between a “normal” function and a generator function in Python? What is the difference between the return of a usual function and the yield of a generator? In this article we will answer these questions and also delve into some aspects of the language
Solving equations with SymPy - Math with Python
·1530 words·8 mins
Python
Sympy
Math
Equations
Much of the study of mathematics at more fundamental levels is dedicated to solving equations and systems of equations. In this article we will see how to use SymPy for these tasks quickly and intuitively.
Iterables vs Iterators in Python - Writing Efficient Code
·1414 words·7 mins
Python
Drops
Performance
Do you know what an iterable is? And an iterator? How to recognize these structures in Python? Answering these questions is the goal of this article.
Introduction to SymPy - Symbolic Math with Python
·2644 words·13 mins
Python
Sympy
Math
In this article, we’ll see an introduction to SymPy, one of the most powerful math packages for the Python language
Is Python Slow? How to Make Your Code 1000+ Times Faster
·1993 words·10 mins
Python
Performance
We’ll compare pure Python code and other approaches efficiency, delving into what truly impacts performance and optimizing Python’s advantages.
Balancing Chemical Equations with Python - ChemPy Package
·1709 words·9 mins
Python
Chemistry
Chempy
Balancing
In this article, we will explore the balancing of chemical equations using the ChemPy package.
Exploring the Molmass Python Package: A Awesome Tool for Chemists and Data Analysts
·2083 words·10 mins
Python
Chemistry
Molmass
molmass is a Python package designed for chemists and researchers. It provides tools for calculating the molar mass, mass distribution, and isotopic patterns of chemical substances.
Isotherms of ideal gases with Python and SymPy
·2061 words·10 mins
Python
Sympy
Matplotlib
Physics
In this post we will see how we can use SymPy and Matplotlib, both Python packages, to visualize ideal gas isotherms.