attachment
attachment

Convert this 3 day study plan into 2.5 days mind of the 28-06-2025 remember important topic give greater time

Generating Image

A clean, professional 2.5-day Physical Pharmacy study plan schedule table/planner. The plan covers Day 04 (Saturday 26 June 2025), Day 05 (Sunday 27 June 2025), and Day 05.5 Half Day (Sunday evening/Monday 28 June 2025 morning). Each day has Morning Session, Afternoon Session, and Evening Session blocks. Color scheme: blue header bars, yellow morning blocks, purple/lavender afternoon blocks, green evening blocks. Include important topics like Solutions, Solubilization, Ionization, Colloids, Emulsions, Suspensions, Micromeritics, Rheology, Kinetics, Stability Testing. Add IMP labels on high-priority topics. Include study tips at the bottom of each day. Clean academic planner style with clear fonts and section dividers.

Here is your 2.5-Day Physical Pharmacy Study Plan compressed to finish by 28 June 2025, with IMP topics given more time:

πŸ“… DAY 1 - Saturday, 26 June 2025

πŸŒ… Morning Session (3.5 hrs) - HIGH YIELD FOUNDATION

TopicTimePriority
Solutions (IMP) - Types, concentration expressions, ideal vs real solutions, Raoult's law60 min⭐⭐⭐
Solubilization (IMP) - Factors affecting solubility, cosolvency, complexation, micellar solubilization60 min⭐⭐⭐
Ionization - pH, pKa, Henderson-Hasselbalch equation, Buffer systems75 min⭐⭐⭐
MCQs: Solutions + Solubilization + Ionization15 minβœ…
Tip: Memorize H-H equation cold - it appears in every exam. Practice numerical pH calculations.

β˜€οΈ Afternoon Session (3 hrs) - DISPERSED SYSTEMS

TopicTimePriority
Colloids (IMP) - Lyophilic/lyophobic, Tyndall effect, zeta potential60 min⭐⭐⭐
Emulsions (IMP) - O/W vs W/O, emulsifying agents, HLB system, stability60 min⭐⭐⭐
Suspensions (IMP) - Flocculated vs Deflocculated, Stoke's law, stability50 min⭐⭐⭐
MCQs: Colloids + Emulsions + Suspensions10 minβœ…
Tip: Know HLB values by heart. Draw the Stoke's law formula and understand each variable.

πŸŒ™ Evening Session (2 hrs) - SURFACE & POWDER

TopicTimePriority
Hydrolysis + Adsorption (Langmuir & Freundlich isotherms) - combined quick read45 min⭐⭐
Micromeritics (IMP) - Particle size, sieving, flow properties, Carr's index, angle of repose60 min⭐⭐⭐
Quick formula review15 minβœ…

πŸ“… DAY 2 - Sunday, 27 June 2025

πŸŒ… Morning Session (3 hrs) - RHEOLOGY + KINETICS

TopicTimePriority
Rheology (IMP) - Newtonian vs Non-Newtonian, viscosity, thixotropy (draw flow curve!)70 min⭐⭐⭐
Rate & Order of Reaction - Zero, First, Second order kinetics50 min⭐⭐⭐
Half-life calculations + Integrated rate laws40 min⭐⭐⭐
Tip: Draw thixotropy hysteresis loop - frequently asked as a diagram question.

β˜€οΈ Afternoon Session (3 hrs) - STABILITY + PROCESSES

TopicTimePriority
Kinetics & Stability Testing (IMP) - Arrhenius equation, shelf life, accelerated stability studies75 min⭐⭐⭐
Physicochemical Processes - Precipitation, Crystallization, Distillation methods45 min⭐⭐
Miscellaneous (IMP) - Drying, Filtration, Sterilization + Extraction (Maceration, Percolation, Soxhlet)40 min⭐⭐
Pharmacy Orientation & History - Quick skim only (low weightage)20 min⭐

πŸŒ™ Evening Session (2.5 hrs) - FULL REVISION ROUND 1

TopicTimePriority
Full Physical Pharmacy Revision - Colloids, Emulsions, Suspensions, Solutions60 minβœ…
Rheology + Kinetics quick review30 minβœ…
Past paper MCQ session (30-40 questions)60 minβœ…

πŸ“… DAY 2.5 - Monday Morning, 28 June 2025 (EXAM DAY PREP)

πŸŒ… Final Half-Day (3 hrs) - CONSOLIDATION

TopicTimePriority
Weak areas targeted revision (identify from MCQ session)60 minβœ…
Formula Sheet Preparation - Stoke's law, H-H equation, Arrhenius, Rate laws, Carr's index45 min⭐⭐⭐
Final MCQ round (20-25 questions across all topics)45 minβœ…
Last 30-min read: IMP topics only - skim headings and key points30 minβœ…

πŸ“‹ KEY FORMULAS TO MEMORIZE (HIGH YIELD)

FormulaTopic
pH = pKa + log([A⁻]/[HA])Henderson-Hasselbalch
v = 2rΒ²(ρ₁-ρ₂)g / 9Ξ·Stoke's Law
k = Ae^(-Ea/RT)Arrhenius Equation
tΒ½ = 0.693/kFirst-order half-life
CI = (ρtap - ρbulk)/ρtap Γ— 100Carr's Index

⚠️ What Was Cut / Merged to Save Time

  • Pharmacy history - reduced to 20 min skim (low weightage as noted in original)
  • Extraction processes - merged with Misc Processes afternoon block
  • Physicochemical processes (crystallization, distillation) - compressed into one 45-min block
  • Separate hydrolysis + adsorption blocks - merged into a single 45-min reading
This plan saves roughly 4-5 hours vs the original while keeping all IMP topics at full or extended time.

Generate a printable PDF quick reference guide with all formulas and mnemonics

Reading File
Running Command

ls -la /home/daytona/workspace/ 2>/dev/null || echo "workspace empty or not foun…

Running Command

mkdir -p /home/daytona/workspace/pharm-formula-guide

Writing File

~/pharm-formula-guide/generate_guide.py

from reportlab.lib.pagesizes import A4
from reportlab.lib import colors
from reportlab.lib.styles import getSampleStyleSheet, ParagraphStyle
from reportlab.lib.units import cm, mm
from reportlab.platypus import (
    SimpleDocTemplate, Paragraph, Spacer, Table, TableStyle,
    HRFlowable, KeepTogether
)
from reportlab.lib.enums import TA_CENTER, TA_LEFT, TA_JUSTIFY
from reportlab.pdfgen import canvas
from reportlab.platypus import BaseDocTemplate, PageTemplate, Frame

# ── Colour palette ─────────────────────────────────────────────────────────────
NAVY       = colors.HexColor("#1a3a5c")
BLUE       = colors.HexColor("#2563EB")
LIGHT_BLUE = colors.HexColor("#DBEAFE")
YELLOW     = colors.HexColor("#FEF9C3")
YELLOW_BDR = colors.HexColor("#F59E0B")
GREEN      = colors.HexColor("#D1FAE5")
GREEN_BDR  = colors.HexColor("#059669")
PURPLE     = colors.HexColor("#EDE9FE")
PURPLE_BDR = colors.HexColor("#7C3AED")
RED_LIGHT  = colors.HexColor("#FEE2E2")
RED_BDR    = colors.HexColor("#DC2626")
ORANGE     = colors.HexColor("#FFF7ED")
ORANGE_BDR = colors.HexColor("#EA580C")
WHITE      = colors.white
GRAY_LIGHT = colors.HexColor("#F1F5F9")
GRAY_MID   = colors.HexColor("#94A3B8")
DARK_TEXT  = colors.HexColor("#1E293B")

W, H = A4

# ── Page-number callback ────────────────────────────────────────────────────────
def add_page_number(canvas_obj, doc):
    canvas_obj.saveState()
    canvas_obj.setFont("Helvetica", 8)
    canvas_obj.setFillColor(GRAY_MID)
    canvas_obj.drawCentredString(W / 2, 18, f"Physical Pharmacy Quick Reference  |  Page {doc.page}")
    canvas_obj.setStrokeColor(GRAY_MID)
    canvas_obj.setLineWidth(0.5)
    canvas_obj.line(2*cm, 25, W - 2*cm, 25)
    canvas_obj.restoreState()

# ── Styles ──────────────────────────────────────────────────────────────────────
styles = getSampleStyleSheet()

def S(name, **kw):
    return ParagraphStyle(name, **kw)

title_style = S("Title2", fontSize=22, textColor=WHITE, alignment=TA_CENTER,
                fontName="Helvetica-Bold", spaceAfter=4, leading=28)
subtitle_style = S("Subtitle2", fontSize=11, textColor=colors.HexColor("#BFDBFE"),
                   alignment=TA_CENTER, fontName="Helvetica", spaceAfter=2, leading=14)
section_header = S("SecHdr", fontSize=13, textColor=WHITE, alignment=TA_LEFT,
                   fontName="Helvetica-Bold", leading=18, leftIndent=6)
subsection_header = S("SubSecHdr", fontSize=10, textColor=NAVY,
                       fontName="Helvetica-Bold", leading=14, spaceAfter=2)
body = S("Body2", fontSize=9, textColor=DARK_TEXT, fontName="Helvetica",
          leading=13, spaceAfter=2)
formula_style = S("Formula", fontSize=10, textColor=NAVY, fontName="Helvetica-Bold",
                   leading=14, spaceAfter=1)
mnemonic_style = S("Mnemonic", fontSize=9.5, textColor=colors.HexColor("#7C3AED"),
                    fontName="Helvetica-Bold", leading=13)
note_style = S("Note", fontSize=8.5, textColor=colors.HexColor("#374151"),
               fontName="Helvetica-Oblique", leading=12)
tip_style = S("Tip", fontSize=8.5, textColor=colors.HexColor("#065F46"),
              fontName="Helvetica-Bold", leading=12)
small_body = S("SmallBody", fontSize=8.5, textColor=DARK_TEXT, fontName="Helvetica",
               leading=12, spaceAfter=1)

# ── Helper builders ─────────────────────────────────────────────────────────────
def section_title(text, bg=NAVY):
    data = [[Paragraph(text, section_header)]]
    t = Table(data, colWidths=[W - 4*cm])
    t.setStyle(TableStyle([
        ("BACKGROUND", (0,0), (-1,-1), bg),
        ("ROUNDEDCORNERS", [6]),
        ("TOPPADDING",  (0,0), (-1,-1), 7),
        ("BOTTOMPADDING",(0,0),(-1,-1), 7),
        ("LEFTPADDING", (0,0), (-1,-1), 10),
    ]))
    return t

def formula_box(label, formula, notes="", bg=LIGHT_BLUE, border=BLUE):
    content = [
        [Paragraph(f"<b>{label}</b>", small_body),
         Paragraph(f"<b>{formula}</b>", formula_style)]
    ]
    if notes:
        content.append(["", Paragraph(notes, note_style)])
    t = Table(content, colWidths=[4.5*cm, W - 4*cm - 4.5*cm - 0.2*cm])
    t.setStyle(TableStyle([
        ("BACKGROUND",    (0,0), (-1,-1), bg),
        ("BOX",           (0,0), (-1,-1), 1.2, border),
        ("LEFTPADDING",   (0,0), (-1,-1), 8),
        ("RIGHTPADDING",  (0,0), (-1,-1), 8),
        ("TOPPADDING",    (0,0), (-1,-1), 5),
        ("BOTTOMPADDING", (0,0), (-1,-1), 5),
        ("VALIGN",        (0,0), (-1,-1), "MIDDLE"),
        ("SPAN",          (1,1), (1,-1)),
    ]))
    return t

def mnemonic_box(title_text, items, bg=PURPLE, border=PURPLE_BDR):
    rows = [[Paragraph(f"<b>{title_text}</b>", mnemonic_style), ""]]
    for letter, meaning in items:
        rows.append([
            Paragraph(f"<b>{letter}</b>", mnemonic_style),
            Paragraph(meaning, small_body)
        ])
    t = Table(rows, colWidths=[1.8*cm, W - 4*cm - 1.8*cm - 0.2*cm])
    t.setStyle(TableStyle([
        ("BACKGROUND",    (0,0), (-1,-1), bg),
        ("BOX",           (0,0), (-1,-1), 1.2, border),
        ("SPAN",          (0,0), (-1,0)),
        ("TOPPADDING",    (0,0), (-1,-1), 4),
        ("BOTTOMPADDING", (0,0), (-1,-1), 4),
        ("LEFTPADDING",   (0,0), (-1,-1), 8),
        ("RIGHTPADDING",  (0,0), (-1,-1), 8),
    ]))
    return t

def tip_box(text, bg=GREEN, border=GREEN_BDR):
    data = [[Paragraph(f"β˜…  HIGH YIELD: {text}", tip_style)]]
    t = Table(data, colWidths=[W - 4*cm])
    t.setStyle(TableStyle([
        ("BACKGROUND",    (0,0), (-1,-1), bg),
        ("BOX",           (0,0), (-1,-1), 1, border),
        ("LEFTPADDING",   (0,0), (-1,-1), 10),
        ("TOPPADDING",    (0,0), (-1,-1), 5),
        ("BOTTOMPADDING", (0,0), (-1,-1), 5),
    ]))
    return t

def two_col_table(rows_data, headers=None, col_w=None):
    if col_w is None:
        half = (W - 4*cm) / 2
        col_w = [half, half]
    data = []
    if headers:
        data.append([Paragraph(f"<b>{h}</b>", small_body) for h in headers])
    for row in rows_data:
        data.append([Paragraph(str(c), small_body) for c in row])
    t = Table(data, colWidths=col_w)
    style = [
        ("GRID",          (0,0), (-1,-1), 0.5, GRAY_MID),
        ("TOPPADDING",    (0,0), (-1,-1), 4),
        ("BOTTOMPADDING", (0,0), (-1,-1), 4),
        ("LEFTPADDING",   (0,0), (-1,-1), 6),
        ("BACKGROUND",    (0,0), (-1,0), GRAY_LIGHT),
        ("FONTNAME",      (0,0), (-1,0), "Helvetica-Bold"),
        ("FONTSIZE",      (0,0), (-1,-1), 8.5),
    ]
    if headers:
        style.append(("BACKGROUND", (0,0), (-1,0), NAVY))
        style.append(("TEXTCOLOR",  (0,0), (-1,0), WHITE))
    t.setStyle(TableStyle(style))
    return t

SP = lambda n=6: Spacer(1, n)
HR = lambda: HRFlowable(width="100%", thickness=0.5, color=GRAY_MID, spaceAfter=4, spaceBefore=4)

# ══════════════════════════════════════════════════════════════════════════════
#  BUILD STORY
# ══════════════════════════════════════════════════════════════════════════════
story = []

# ─── COVER HEADER ──────────────────────────────────────────────────────────────
cover_data = [[
    Paragraph("Physical Pharmacy", title_style),
    Paragraph("Quick Reference Guide", title_style),
    Paragraph("All Formulas Β· Mnemonics Β· High-Yield Notes", subtitle_style),
    Paragraph("Exam Date: 28 June 2025  |  Compiled for 2.5-Day Study Sprint", subtitle_style),
]]
cover_t = Table([[
    Paragraph("Physical Pharmacy", title_style)],
    [Paragraph("Quick Reference Guide β€” Formulas &amp; Mnemonics", subtitle_style)],
    [Paragraph("Exam: 28 June 2025  |  2.5-Day Study Sprint", subtitle_style)],
], colWidths=[W - 4*cm])
cover_t.setStyle(TableStyle([
    ("BACKGROUND",    (0,0), (-1,-1), NAVY),
    ("TOPPADDING",    (0,0), (-1,-1), 10),
    ("BOTTOMPADDING", (0,0), (-1,-1), 10),
    ("LEFTPADDING",   (0,0), (-1,-1), 14),
]))
story.append(cover_t)
story.append(SP(12))

# ══════════════════════════════════════════════════════════════════════════════
# SECTION 1 β€” SOLUTIONS & COLLIGATIVE PROPERTIES
# ══════════════════════════════════════════════════════════════════════════════
story.append(section_title("1.  SOLUTIONS & COLLIGATIVE PROPERTIES", NAVY))
story.append(SP(5))

story.append(formula_box("Raoult's Law",
    "P = Xsolvent Γ— PΒ°solvent",
    "P = vapour pressure of solution  |  X = mole fraction  |  PΒ° = pure solvent VP"))
story.append(SP(4))

story.append(formula_box("Osmotic Pressure",
    "Ο€ = iMRT",
    "i = van't Hoff factor  |  M = molarity  |  R = 0.0821 LΒ·atm/molΒ·K  |  T = Kelvin"))
story.append(SP(4))

story.append(formula_box("Molarity",
    "M = (mass / MW) / V(L)",
    "Most common concentration expression β€” practice calculations!"))
story.append(SP(4))

story.append(formula_box("% w/v",
    "% w/v = (g of solute / 100 mL solution) Γ— 100",
    "Most common pharma concentration unit"))
story.append(SP(4))

story.append(mnemonic_box("Mnemonic: Colligative Properties β€” 'Very Bad Osmotic Force'",
    [("V", "Vapour pressure lowering"),
     ("B", "Boiling point elevation"),
     ("O", "Osmotic pressure"),
     ("F", "Freezing point depression")]))
story.append(SP(6))
story.append(tip_box("Raoult's law deviations: positive = stronger solute-solvent interaction breaks; negative = stronger mixed interactions."))
story.append(SP(10))

# ══════════════════════════════════════════════════════════════════════════════
# SECTION 2 β€” IONIZATION & BUFFERS
# ══════════════════════════════════════════════════════════════════════════════
story.append(section_title("2.  IONIZATION, pH & BUFFER SYSTEMS", colors.HexColor("#1D4ED8")))
story.append(SP(5))

story.append(formula_box("Henderson-Hasselbalch (Acid)",
    "pH = pKa + log ( [A⁻] / [HA] )",
    "A⁻ = conjugate base  |  HA = weak acid  |  Buffer range: pKa ± 1"))
story.append(SP(4))

story.append(formula_box("Henderson-Hasselbalch (Base)",
    "pOH = pKb + log ( [BH⁺] / [B] )",
    "BH⁺ = conjugate acid  |  B = weak base"))
story.append(SP(4))

story.append(formula_box("pH from Strong Acid",
    "pH = -log[H⁺]",
    "e.g. 0.01 M HCl β†’ pH = -log(0.01) = 2"))
story.append(SP(4))

story.append(formula_box("pKa Relation",
    "pH = pKa  β†’  50% ionized",
    "Weak acid: >50% ionized above pKa  |  Weak base: >50% ionized below pKa"))
story.append(SP(4))

story.append(formula_box("Buffer Capacity (Ξ²)",
    "Ξ² = Ξ”B / Ξ”pH",
    "Maximum buffer capacity when pH = pKa"))
story.append(SP(5))

story.append(mnemonic_box("Mnemonic: Ionization of Weak Acid β€” 'ABHA'",
    [("A", "Above pKa β†’ more ionized (A⁻ form dominates)"),
     ("B", "Below pKa β†’ less ionized (HA form dominates)"),
     ("H", "Henderson-Hasselbalch links pH, pKa, and ratio"),
     ("A", "At pKa β†’ equal parts HA and A⁻")]))
story.append(SP(6))
story.append(tip_box("Most tested: Calculate pH when ratio [A⁻]/[HA] = 10 β†’ pH = pKa + 1. Ratio = 0.1 β†’ pH = pKa - 1."))
story.append(SP(10))

# ══════════════════════════════════════════════════════════════════════════════
# SECTION 3 β€” SOLUBILITY & SOLUBILIZATION
# ══════════════════════════════════════════════════════════════════════════════
story.append(section_title("3.  SOLUBILITY & SOLUBILIZATION", colors.HexColor("#065F46")))
story.append(SP(5))

story.append(formula_box("log S = f(pH)",
    "log S = log Sβ‚€ + (pH - pKa)   [for weak acid]",
    "Sβ‚€ = intrinsic solubility (unionized form)  |  Solubility increases above pKa for acids"))
story.append(SP(4))

story.append(formula_box("Micellar Solubilization",
    "CMC: minimum concentration for micelle formation",
    "Below CMC: monomers only  |  Above CMC: micelles form, drug partitions inside"))
story.append(SP(4))

story.append(Paragraph("<b>Factors Affecting Solubility (IMP):</b>", subsection_header))
story.append(two_col_table([
    ["Temperature", "Endothermic solutes: ↑ temp β†’ ↑ solubility"],
    ["Particle size", "↓ size β†’ ↑ solubility (Noyes-Whitney)"],
    ["Cosolvency", "Polar + non-polar solvent blend (e.g. EtOH + water)"],
    ["Complexation", "Drug + ligand complex (e.g. cyclodextrins)"],
    ["Salting out", "Added electrolyte reduces organic solubility"],
    ["pH", "Ionization increases solubility of weak acids/bases"],
], headers=["Factor", "Effect"]))
story.append(SP(5))

story.append(mnemonic_box("Mnemonic: Solubilization Methods β€” 'CAMP'",
    [("C", "Cosolvency (EtOH, PEG, glycerol)"),
     ("A", "Acids/Alkalis (pH adjustment)"),
     ("M", "Micellization (surfactants, CMC)"),
     ("P", "Prodrugs + Complexation (cyclodextrins)")]))
story.append(SP(10))

# ══════════════════════════════════════════════════════════════════════════════
# SECTION 4 β€” MICROMERITICS & POWDER FLOW
# ══════════════════════════════════════════════════════════════════════════════
story.append(section_title("4.  MICROMERITICS & POWDER FLOW", colors.HexColor("#92400E")))
story.append(SP(5))

story.append(formula_box("Carr's Compressibility Index",
    "CI = [(ρtap - ρbulk) / ρtap] Γ— 100",
    "CI < 15% β†’ good flow  |  CI 16-20% β†’ fair  |  CI > 25% β†’ poor (cohesive powder)"))
story.append(SP(4))

story.append(formula_box("Hausner Ratio",
    "HR = ρtap / ρbulk",
    "HR < 1.25 β†’ good flow  |  HR > 1.5 β†’ poor flow"))
story.append(SP(4))

story.append(formula_box("Angle of Repose",
    "tan ΞΈ = h / r   β†’   ΞΈ = arctan(h/r)",
    "ΞΈ < 25Β° β†’ excellent flow  |  25-30Β° β†’ good  |  30-40Β° β†’ fair  |  >40Β° β†’ very poor"))
story.append(SP(4))

story.append(formula_box("Specific Surface Area",
    "Sv = 6 / (ρ Γ— d)   [for spherical particles]",
    "Sv = surface area per unit volume  |  Smaller d β†’ larger Sv"))
story.append(SP(5))

story.append(mnemonic_box("Mnemonic: Powder Flow Tests β€” 'CASH'",
    [("C", "Carr's Index (compressibility)"),
     ("A", "Angle of Repose (static friction)"),
     ("S", "Shear cell testing"),
     ("H", "Hausner Ratio (tap/bulk density)")]))
story.append(SP(6))
story.append(tip_box("Sieve sizes: smaller mesh number = larger opening. USP sieves use mesh numbers. Know: 20 mesh = 850 Β΅m, 60 mesh = 250 Β΅m."))
story.append(SP(10))

# ══════════════════════════════════════════════════════════════════════════════
# SECTION 5 β€” DISPERSED SYSTEMS (Colloids, Emulsions, Suspensions)
# ══════════════════════════════════════════════════════════════════════════════
story.append(section_title("5.  DISPERSED SYSTEMS", colors.HexColor("#4C1D95")))
story.append(SP(5))

story.append(formula_box("Stoke's Law (Sedimentation Rate)",
    "v = 2rΒ²(ρ₁ - ρ₂)g / 9Ξ·",
    "v = velocity  |  r = particle radius  |  ρ₁/ρ₂ = densities  |  Ξ· = viscosity  |  g = gravity"))
story.append(SP(4))

story.append(formula_box("Zeta Potential",
    "ΞΆ > Β±30 mV β†’ stable colloid",
    "High zeta potential = strong electrostatic repulsion = stable dispersion"))
story.append(SP(4))

story.append(formula_box("HLB Value (Griffin)",
    "HLB = 20 Γ— (Mh / M)",
    "Mh = MW hydrophilic portion  |  M = total MW  |  HLB 8-18 β†’ O/W  |  HLB 3-6 β†’ W/O"))
story.append(SP(4))

story.append(formula_box("HLB (Davies Method)",
    "HLB = 7 + Ξ£(hydrophilic group nos.) - Ξ£(lipophilic group nos.)",
    "Commonly used for blending emulsifiers"))
story.append(SP(5))

story.append(Paragraph("<b>HLB Values Quick Reference (IMP):</b>", subsection_header))
story.append(two_col_table([
    ["3-6",   "W/O emulsifier (water-in-oil)"],
    ["7-9",   "Wetting / spreading agent"],
    ["8-18",  "O/W emulsifier (oil-in-water)"],
    ["13-15", "Detergent"],
    ["15-18", "Solubilizer / micellar"],
], headers=["HLB Range", "Application"], col_w=[3*cm, W - 4*cm - 3*cm - 0.2*cm]))
story.append(SP(5))

story.append(mnemonic_box("Mnemonic: Colloid Stability β€” 'ZEST'",
    [("Z", "Zeta potential (electrostatic repulsion)"),
     ("E", "Electrolyte concentration (reduces double layer)"),
     ("S", "Steric stabilization (polymer coating)"),
     ("T", "Temperature (kinetic energy affects flocculation)")]))
story.append(SP(5))

story.append(mnemonic_box("Mnemonic: Flocculated vs Deflocculated β€” 'FED vs DEC'",
    [("F", "Flocculated: Easy to redisperse, Dose uniform, caking absent"),
     ("D", "Deflocculated: Elegant appearance, Caking risk, slower sedimentation")]))
story.append(SP(6))
story.append(tip_box("Stoke's law exam trick: To slow sedimentation β€” decrease particle size, increase viscosity, or match densities (ρ₁ = ρ₂)."))
story.append(SP(10))

# ══════════════════════════════════════════════════════════════════════════════
# SECTION 6 β€” RHEOLOGY
# ══════════════════════════════════════════════════════════════════════════════
story.append(section_title("6.  RHEOLOGY", colors.HexColor("#7C3AED")))
story.append(SP(5))

story.append(formula_box("Newton's Law of Viscosity",
    "Ο„ = Ξ· Γ— (dv/dr)   β†’   F/A = Ξ· Γ— G",
    "Ο„ = shear stress  |  Ξ· = viscosity (poise)  |  G = shear rate (s⁻¹)  |  F/A = force/area"))
story.append(SP(4))

story.append(formula_box("Fluidity",
    "Ο† = 1 / Ξ·",
    "Reciprocal of viscosity  |  Units: rhe (poise⁻¹)"))
story.append(SP(4))

story.append(formula_box("Kinematic Viscosity",
    "ν = η / ρ",
    "Units: Stokes (St) or cSt  |  ρ = density of fluid"))
story.append(SP(5))

story.append(Paragraph("<b>Flow Types Quick Reference (IMP):</b>", subsection_header))
story.append(two_col_table([
    ["Newtonian",       "Constant viscosity regardless of shear rate (water, dilute solutions)"],
    ["Plastic (Bingham)","Requires yield value before flow begins (tooth paste, concentrated suspensions)"],
    ["Pseudoplastic",   "Shear thinning β€” viscosity ↓ as shear ↑ (polymer solutions, most gels)"],
    ["Dilatant",        "Shear thickening β€” viscosity ↑ as shear ↑ (starch suspensions)"],
    ["Thixotropy",      "Time-dependent shear thinning β€” forms hysteresis loop on flow curve"],
], headers=["Flow Type", "Key Feature"], col_w=[3.5*cm, W - 4*cm - 3.5*cm - 0.2*cm]))
story.append(SP(5))

story.append(mnemonic_box("Mnemonic: Non-Newtonian Flow Types β€” 'PPD-T'",
    [("P", "Plastic β€” needs yield value (Bingham)"),
     ("P", "Pseudoplastic β€” shear thinning (most gels)"),
     ("D", "Dilatant β€” shear thickening (starch)"),
     ("-T", "Thixotropy β€” time-dependent, hysteresis loop")]))
story.append(SP(6))
story.append(tip_box("Draw the thixotropy curve: ascending curve (increasing shear) + descending curve (decreasing shear) = hysteresis loop. Area = degree of thixotropy."))
story.append(SP(10))

# ══════════════════════════════════════════════════════════════════════════════
# SECTION 7 β€” ADSORPTION
# ══════════════════════════════════════════════════════════════════════════════
story.append(section_title("7.  ADSORPTION", colors.HexColor("#B45309")))
story.append(SP(5))

story.append(formula_box("Langmuir Isotherm",
    "x/m = abC / (1 + bC)",
    "x/m = amount adsorbed/g adsorbent  |  C = conc at equilibrium  |  a,b = Langmuir constants\nMonolayer adsorption, finite sites"))
story.append(SP(4))

story.append(formula_box("Freundlich Isotherm",
    "x/m = KC^(1/n)",
    "log(x/m) = log K + (1/n) log C  |  Plot: log(x/m) vs log C β†’ straight line\nMultilayer, empirical, 1/n < 1 β†’ favourable adsorption"))
story.append(SP(5))

story.append(mnemonic_box("Mnemonic: Langmuir vs Freundlich β€” 'LMF'",
    [("L", "Langmuir: Limited (monolayer), Linear at low conc, Saturation occurs"),
     ("M", "Monolayer maximum defined by constant 'a'"),
     ("F", "Freundlich: Free multilayer, Follows power law, No saturation plateau")]))
story.append(SP(6))
story.append(tip_box("Langmuir linearized: C/(x/m) = 1/(ab) + C/a β†’ plot C/(x/m) vs C β†’ slope = 1/a, intercept = 1/ab"))
story.append(SP(10))

# ══════════════════════════════════════════════════════════════════════════════
# SECTION 8 β€” CHEMICAL KINETICS & STABILITY
# ══════════════════════════════════════════════════════════════════════════════
story.append(section_title("8.  CHEMICAL KINETICS & STABILITY TESTING", colors.HexColor("#B91C1C")))
story.append(SP(5))

story.append(Paragraph("<b>Rate Laws Summary (IMP):</b>", subsection_header))
story.append(two_col_table([
    ["Zero Order",  "-dC/dt = kβ‚€",   "C = Cβ‚€ - kβ‚€t",        "tΒ½ = Cβ‚€/2kβ‚€",    "Conc vs t β†’ straight line"],
    ["First Order", "-dC/dt = k₁C",  "ln C = ln Cβ‚€ - k₁t",  "tΒ½ = 0.693/k₁",  "ln Conc vs t β†’ straight line"],
    ["Second Order","-dC/dt = kβ‚‚CΒ²", "1/C = 1/Cβ‚€ + kβ‚‚t",    "tΒ½ = 1/kβ‚‚Cβ‚€",   "1/Conc vs t β†’ straight line"],
], headers=["Order", "Rate Eq", "Integrated Law", "Half-Life", "Graphical Test"],
   col_w=[2.2*cm, 2.8*cm, 3.5*cm, 2.5*cm, W - 4*cm - 11*cm - 0.2*cm]))
story.append(SP(5))

story.append(formula_box("Arrhenius Equation",
    "k = A Β· e^(-Ea / RT)",
    "A = frequency factor  |  Ea = activation energy (J/mol)  |  R = 8.314 J/molΒ·K  |  T = Kelvin"))
story.append(SP(4))

story.append(formula_box("Arrhenius (log form)",
    "log k = log A - Ea / (2.303 RT)",
    "Plot: log k vs 1/T β†’ slope = -Ea/2.303R  |  Used to predict shelf life at different temps"))
story.append(SP(4))

story.append(formula_box("First-Order Half-Life",
    "tΒ½ = 0.693 / k",
    "Independent of initial concentration β€” constant tΒ½ is hallmark of first-order kinetics"))
story.append(SP(4))

story.append(formula_box("Shelf Life (t₉₀)",
    "t₉₀ = 0.105 / k   [first order]",
    "Time for drug to degrade to 90% of original potency  |  t₉₀ = 0.1 Cβ‚€/kβ‚€ for zero order"))
story.append(SP(4))

story.append(formula_box("Q10 Rule (Temperature Coefficient)",
    "Q10 = k(T+10) / k(T)   β‰ˆ 2-3 for most reactions",
    "For every 10Β°C rise, rate roughly doubles  |  Used in accelerated stability prediction"))
story.append(SP(5))

story.append(mnemonic_box("Mnemonic: Order of Reaction Identification β€” 'ZFL'",
    [("Z", "Zero: straight line on Conc vs Time plot"),
     ("F", "First: straight line on ln(Conc) vs Time plot"),
     ("L", "Log/Second: straight line on 1/Conc vs Time plot")]))
story.append(SP(5))

story.append(mnemonic_box("Mnemonic: Arrhenius Equation β€” 'A-E-RT'",
    [("A", "A = pre-exponential (Arrhenius) factor β€” collision frequency"),
     ("E", "Ea = activation energy β€” minimum energy for reaction"),
     ("R", "R = gas constant (8.314 J/molΒ·K)"),
     ("T", "T = absolute temperature in KELVIN (not Β°C!)")]))
story.append(SP(6))
story.append(tip_box("ICH Accelerated Stability: 40Β°C/75% RH for 6 months (Zone III/IV). Long-term: 25Β°C/60% RH for 12-24 months."))
story.append(SP(10))

# ══════════════════════════════════════════════════════════════════════════════
# SECTION 9 β€” MASTER FORMULA SHEET
# ══════════════════════════════════════════════════════════════════════════════
story.append(section_title("9.  MASTER FORMULA SHEET β€” CUT & KEEP", colors.HexColor("#0F172A")))
story.append(SP(6))

master_data = [
    ["Henderson-Hasselbalch",   "pH = pKa + log([A⁻]/[HA])"],
    ["Stoke's Law",             "v = 2rΒ²(ρ₁-ρ₂)g / 9Ξ·"],
    ["Arrhenius Equation",      "k = AΒ·e^(-Ea/RT)"],
    ["1st Order Half-Life",     "tΒ½ = 0.693 / k"],
    ["Zero Order Half-Life",    "tΒ½ = Cβ‚€ / 2kβ‚€"],
    ["2nd Order Half-Life",     "tΒ½ = 1 / kβ‚‚Cβ‚€"],
    ["Shelf Life (t₉₀) 1st",   "t₉₀ = 0.105 / k"],
    ["Carr's Index",            "CI = [(ρtap - ρbulk)/ρtap] Γ— 100"],
    ["Hausner Ratio",           "HR = ρtap / ρbulk"],
    ["Raoult's Law",            "P = Xsolvent Γ— PΒ°solvent"],
    ["Osmotic Pressure",        "Ο€ = iMRT"],
    ["Langmuir Isotherm",       "x/m = abC / (1 + bC)"],
    ["Freundlich Isotherm",     "x/m = KC^(1/n)  β†’  log(x/m) = logK + (1/n)logC"],
    ["Newton's Viscosity Law",  "Ο„ = Ξ· Γ— G   (F/A = Ξ· Γ— dv/dr)"],
    ["HLB (Griffin)",           "HLB = 20 Γ— Mh / M"],
    ["Zeta Potential (stable)", "ΞΆ > Β±30 mV"],
    ["Buffer Capacity",         "Ξ² = Ξ”B / Ξ”pH"],
    ["Q10 Rule",                "Q10 = k(T+10) / k(T)  β‰ˆ 2-3"],
]

master_t = Table(
    [[Paragraph(f"<b>{r}</b>", small_body), Paragraph(f, formula_style)] for r, f in master_data],
    colWidths=[5*cm, W - 4*cm - 5*cm - 0.2*cm]
)
master_t.setStyle(TableStyle([
    ("GRID",          (0,0), (-1,-1), 0.5, colors.HexColor("#CBD5E1")),
    ("BACKGROUND",    (0,0), (0,-1),  GRAY_LIGHT),
    ("BACKGROUND",    (1,0), (1,-1),  YELLOW),
    ("TOPPADDING",    (0,0), (-1,-1), 5),
    ("BOTTOMPADDING", (0,0), (-1,-1), 5),
    ("LEFTPADDING",   (0,0), (-1,-1), 7),
    ("FONTSIZE",      (0,0), (-1,-1), 9),
    # Alternate rows
    *[("BACKGROUND", (0,i), (-1,i), colors.HexColor("#F8FAFC")) for i in range(1, len(master_data), 2)],
]))
story.append(master_t)
story.append(SP(10))

# ══════════════════════════════════════════════════════════════════════════════
# SECTION 10 β€” ALL MNEMONICS AT A GLANCE
# ══════════════════════════════════════════════════════════════════════════════
story.append(section_title("10.  ALL MNEMONICS AT A GLANCE", colors.HexColor("#5B21B6")))
story.append(SP(5))

mnemonics_summary = [
    ["VBOF", "Colligative Properties", "Vapour lowering Β· Boiling pt elevation Β· Osmotic pressure Β· Freezing pt depression"],
    ["ABHA", "Ionization of Weak Acid", "Above pKa = ionized Β· Below pKa = unionized Β· H-H equation Β· At pKa = 50:50"],
    ["CAMP", "Solubilization Methods",  "Cosolvency Β· Acids/Alkalis Β· Micellization Β· Prodrugs+Complexation"],
    ["CASH", "Powder Flow Tests",       "Carr's Index Β· Angle of repose Β· Shear cell Β· Hausner Ratio"],
    ["ZEST", "Colloid Stability",       "Zeta potential Β· Electrolyte Β· Steric stabilization Β· Temperature"],
    ["FED vs DEC","Floc vs Defloc",     "Floc: Easy redisperse, Dose uniform | Defloc: Elegant, Caking risk"],
    ["PPD-T","Non-Newtonian Flow",      "Plastic Β· Pseudoplastic Β· Dilatant Β· Thixotropy (time-dependent)"],
    ["LMF",  "Adsorption Isotherms",    "Langmuir=Limited monolayer Β· Freundlich=Free multilayer"],
    ["ZFL",  "Reaction Order ID",       "Zero=Conc vs t straight Β· First=lnC vs t Β· Second=1/C vs t"],
    ["AERT", "Arrhenius Equation",      "A=frequency factor Β· Ea=activation energy Β· R=8.314 Β· T=Kelvin"],
]

msum_t = Table(
    [[Paragraph(f"<b>{m}</b>", mnemonic_style),
      Paragraph(f"<b>{topic}</b>", small_body),
      Paragraph(meaning, small_body)]
     for m, topic, meaning in mnemonics_summary],
    colWidths=[2*cm, 3.5*cm, W - 4*cm - 5.7*cm]
)
msum_t.setStyle(TableStyle([
    ("GRID",          (0,0), (-1,-1), 0.5, colors.HexColor("#C4B5FD")),
    ("BACKGROUND",    (0,0), (-1,-1), PURPLE),
    ("TOPPADDING",    (0,0), (-1,-1), 5),
    ("BOTTOMPADDING", (0,0), (-1,-1), 5),
    ("LEFTPADDING",   (0,0), (-1,-1), 7),
    ("FONTSIZE",      (0,0), (-1,-1), 8.5),
    *[("BACKGROUND", (0,i), (-1,i), colors.HexColor("#EDE9FE")) for i in range(0, len(mnemonics_summary), 2)],
]))
story.append(msum_t)
story.append(SP(10))

# ══════════════════════════════════════════════════════════════════════════════
# FOOTER TIP BOX
# ══════════════════════════════════════════════════════════════════════════════
final_tip = Table([[Paragraph(
    "<b>EXAM DAY CHECKLIST:</b>  H-H equation βœ“  |  Stoke's Law βœ“  |  Arrhenius βœ“  |  "
    "Rate laws (0, 1st, 2nd) βœ“  |  HLB values βœ“  |  Carr's Index thresholds βœ“  |  "
    "Thixotropy curve βœ“  |  Zeta potential Β±30 mV βœ“",
    tip_style)]],
    colWidths=[W - 4*cm])
final_tip.setStyle(TableStyle([
    ("BACKGROUND",    (0,0), (-1,-1), colors.HexColor("#FEF3C7")),
    ("BOX",           (0,0), (-1,-1), 2, YELLOW_BDR),
    ("LEFTPADDING",   (0,0), (-1,-1), 12),
    ("TOPPADDING",    (0,0), (-1,-1), 8),
    ("BOTTOMPADDING", (0,0), (-1,-1), 8),
]))
story.append(final_tip)

# ══════════════════════════════════════════════════════════════════════════════
# BUILD PDF
# ══════════════════════════════════════════════════════════════════════════════
output_path = "/home/daytona/workspace/pharm-formula-guide/Physical_Pharmacy_Quick_Reference.pdf"

doc = SimpleDocTemplate(
    output_path,
    pagesize=A4,
    leftMargin=2*cm,
    rightMargin=2*cm,
    topMargin=1.8*cm,
    bottomMargin=2*cm,
    title="Physical Pharmacy Quick Reference Guide",
    author="Study Sprint"
)

doc.build(story, onFirstPage=add_page_number, onLaterPages=add_page_number)
print(f"PDF generated: {output_path}")
Running Command

cd /home/daytona/workspace/pharm-formula-guide && python generate_guide.py

Running Command

ls -lh /home/daytona/workspace/pharm-formula-guide/Physical_Pharmacy_Quick_Refer…

Your PDF is ready! Here's your download link:

Physical Pharmacy Quick Reference

PDF Document Β· PDF


What's inside the guide (10 sections, print-ready A4):

SectionContents
1. SolutionsRaoult's Law, Osmotic Pressure, Molarity, % w/v + "VBOF" mnemonic
2. Ionization & BuffersHenderson-Hasselbalch (acid + base), buffer capacity, "ABHA" mnemonic
3. Solubilitylog S vs pH, CMC, factors table, "CAMP" mnemonic
4. MicromeriticsCarr's Index, Hausner Ratio, Angle of Repose, surface area, "CASH" mnemonic
5. Dispersed SystemsStoke's Law, Zeta Potential, HLB (Griffin + Davies), HLB values table, "ZEST" + "FED vs DEC"
6. RheologyNewton's viscosity law, flow types table, thixotropy tip, "PPD-T" mnemonic
7. AdsorptionLangmuir + Freundlich isotherms (both forms), linearization formulas, "LMF"
8. Kinetics & StabilityFull rate laws table (0, 1st, 2nd), Arrhenius, tΒ½, t₉₀, Q10, ICH conditions
9. Master Formula SheetAll 18 key formulas in one cut-and-keep table (colour-coded)
10. All MnemonicsEvery mnemonic summarized in one quick-scan table

Print tip: Print A4, single-sided at 100% scale. The colour-coded boxes (blue = solutions, green = solubility, purple = colloids, red = kinetics) make it easy to flip to any section fast during revision.

Create image for study time table

Generating Image

A beautiful, colorful printable study timetable image for Physical Pharmacy exam preparation. 2.5 day study plan starting 26 June 2025 ending 28 June 2025 morning. Structured like a professional academic planner with: DAY 1 - Saturday 26 June 2025: - Morning Session (7:00 AM - 10:30 AM): Solutions (IMP), Solubilization (IMP), Ionization & Henderson-Hasselbalch - marked with red star IMP - Afternoon Session (12:00 PM - 3:00 PM): Colloids (IMP), Emulsions & HLB (IMP), Suspensions & Stokes Law (IMP) - Evening Session (5:00 PM - 7:00 PM): Hydrolysis + Adsorption, Micromeritics (IMP), Formula Review DAY 2 - Sunday 27 June 2025: - Morning Session (7:00 AM - 10:00 AM): Rheology (IMP), Kinetics - Rate & Order, Half-life calculations - Afternoon Session (12:00 PM - 3:00 PM): Arrhenius & Stability Testing (IMP), Physicochemical Processes, Miscellaneous Processes - Evening Session (5:00 PM - 7:30 PM): Full Revision Round, Past Paper MCQs (30-40 questions) DAY 2.5 - Monday 28 June 2025 (EXAM DAY): - Morning (7:00 AM - 10:00 AM): Weak areas revision, Formula Sheet review, Final MCQ round 20-25 questions, Last IMP skim Design: dark navy blue header, pastel yellow morning blocks, soft lavender afternoon blocks, mint green evening blocks, orange exam day block. Bold IMP tags in red. Clean sans-serif fonts. Motivational quote at bottom. Star ratings for priority topics. Professional academic planner aesthetic on white background with subtle grid lines.

Physical Pharmacy 2.5-Day Study Timetable
Here's your study timetable image! It covers all 3 sessions across the 2.5 days (26-28 June 2025) with:
  • Yellow blocks - Morning sessions (foundation topics)
  • Lavender blocks - Afternoon sessions (dispersed systems + kinetics)
  • Mint green blocks - Evening sessions (revision + MCQs)
  • Orange block - Exam morning (final consolidation)
  • IMP tags - High-priority topics marked clearly
You can save or screenshot this image and use it as your desktop wallpaper or print it out alongside the

Physical Pharmacy Quick Reference

PDF Document Β· PDF

for your study sprint. Good luck on 28 June!
This is a shared conversation. Sign in to Orris to start your own chat.